* Check arguments passed to secp256k1 methods
Illegal arguments will trigger an internal callback that prints to stderr and calls abort.
We already check arguments in our JNI and kotlin native code but had missed 2 checks (recid in ecdsaRecover, empty arrays in pubkeyCombine).
* Implement the same "tweak" checks in the native code and JNI code
The native code was missing checks on the "tweak" size (which must be 32 bytes)
Don't throw in `seckey_verify`: it's inconsistent to have this function throw
for some invalid inputs and return false for other invalid inputs.
Document public key compression and add tests.
* Upgrade JNI interface
* Input signatures can be DER or compact format, output signatures are always in compact format
* Input public keys can be compressed or uncompressed, output public keys are always uncompressed
* Name and parameters match libsecp256k1's
* JNI implementation is now straightforward
No more ByteBuffers
Exceptions are thrown in case of failures
* Update src/nativeMain/kotlin/fr/acinq/secp256k1/Secp256k1Native.kt
* Add public key compression method
Co-authored-by: Salomon BRYS <salomon.brys@gmail.com>