In order to verify your ID with the app your phone must have NFC support to scan the passport/id, and on the screen where you do the verification it says: if your phone doesnt have support find a friend with a phone that supports it, I kid you not.. edit, found it in the code: https://github.com/MinBZK/woo-besluit-broncode-digid-app/blo...
Source code for Dutch DigiD app released under Dutch Open Government Act
11–20 of 161 posts
Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#12In order to verify your ID with the app your phone must have NFC support to scan the passport/id, and on the screen where you do the verification it says: if your phone doesnt have support find a friend with a phone that supports it, I kid you not.. edit, found it in the code: https://github.com/MinBZK/woo-besluit-broncode-digid-app/blo...
Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#13In order to verify your ID with the app your phone must have NFC support to scan the passport/id, and on the screen where you do the verification it says: if your phone doesnt have support find a friend with a phone that supports it, I kid you not.. edit, found it in the code: https://github.com/MinBZK/woo-besluit-broncode-digid-app/blo...
btw I see that attaching an nfc reader to your computer is also supported.
Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#14Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#15In order to verify your ID with the app your phone must have NFC support to scan the passport/id, and on the screen where you do the verification it says: if your phone doesnt have support find a friend with a phone that supports it, I kid you not.. edit, found it in the code: https://github.com/MinBZK/woo-besluit-broncode-digid-app/blo...
Access to a smartphone with NFC can indeed be an issue for some people, but it is still better than having to record videos of yourself holding your ID next to your face, then a couple of years later finding out that your personal data is freely circulating on the web because one of those sleezy identity verification services has been hacked.
Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#16Earlier quoted context omitted.
Access to a smartphone with NFC can indeed be an issue for some people, but it is still better than having to record videos of yourself holding your ID next to your face, then a couple of years later finding out that your personal data is freely circulating on the web because one of those sleezy identity verification services has been hacked.
Doesn't Apple block NFC support? Or do they allow peasant apps to read via NFC?
Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#17Example: https://imgur.com/a/9cIDQtk
Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#18Earlier quoted context omitted.
Is this literate programming?
It's been extensively discussed on twitter, and the general conclusion seems to be that yes, this particular snippet is good code.
if (percentage == 0)
return […];
if (percentage > 0.0 && […]
Can a double have a value that is larger than 0 but smaller or equal to 0.0? I would have expected '> 0' instead.Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#19Example: https://imgur.com/a/9cIDQtk
I like it. Easy to understand, fast, no allocations.
If I were reviewing this code I would at least ask the developer to add an assertion or contract requiring that the argument be in the inclusive range [0..1]
The choice of variable name, percentage, is also misleading. At least I suspect it is because I would expect the comparisons involving percentages to be to numbers between 0 and 100.
If lack of allocations is a requirement then one could create a static array of strings and use
int(percent * 10)
as the index. This would eliminate all of the comparisons and also throw an index out of range (in any sane language) if the value was outside the allowed range.Re: Source code for Dutch DigiD app released under Dutch Open Government Act
#20Example: https://imgur.com/a/9cIDQtk
I do object to the variable being called ‘percentage’ tho, as it clearly isn't one.