terl / lazysodium-java

A Java implementation of the Libsodium crypto library. For the lazy dev.
https://github.com/terl/lazysodium-java/wiki
Mozilla Public License 2.0
135 stars 48 forks source link

Fix return type for randombytes_random and _uniform #87

Closed ionspin closed 4 years ago

ionspin commented 4 years ago

Signature for randombytes_random and randombytes_uniform is uint32 in libsodium but in lazysodium it's byte. This pull request fixes that.

I used long as return type, because the libsodium function return unsigned int.

Fixes #86

gurpreet- commented 4 years ago

Another fantastic spot, merged!