-
-
Notifications
You must be signed in to change notification settings - Fork 104
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Four fixes are applied in this patch: 1) The `SYS_RandomInt()` function is renamed to `SYS_RandomLong()`, and its return type is now `long`. It no longer takes a range as parameters for its random number generation; it always uses the full range. 2) The `getrandom()` syscall is added to configure.ac as a requested function. 3) The generator for `SYS_RandomLong()` is changed. The previous generator was from the `rand()` function, but now it uses `getrandom()` when available and otherwise `lrand48()`, from the POSIX API. 4) The seeding of the generator is via `SYS_InitRandom()`. It is modified accordingly to seed the new generator. Addresses Ref #9 "Improve SYS_RandomInt()" https://salsa.debian.org/rousseau/PCSC/-/issues/9
- Loading branch information
1 parent
615160f
commit 2c3d3bf
Showing
5 changed files
with
37 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters