tel / saltine

Cryptography that's easy to digest (NaCl/libsodium bindings)
https://github.com/tel/saltine
MIT License
61 stars 29 forks source link

Thread safety for random functions. #7

Closed tel closed 7 years ago

tel commented 11 years ago

The random generation functions are not threadsafe, so it's unclear what their behavior will be in concurrent settings.

TomMD commented 7 years ago

Is this still accurate? I read:

sodium_init() initializes the library and should be called before any other function provided by Sodium. The function can be called more than once, and can be called simultaneously from multiple threads since version 1.0.11. After this function returns, all of the other functions provided by Sodium will be thread-safe.

linearray commented 7 years ago

Yep, this is quite outdated. All functions are thread-safe nowadays.