Open jackcmay opened 2 years ago
A security auditors brought this up, @samkim-crypto. can we get these tests in?
These syscalls have been removed (26311) and replaced by the curve25519 syscalls.
@samkim-crypto can you point me to the tests for the curve25519 syscalls?
@jackcmay The curve operations use the dalek library implementation. Currently, there are just tests for native code in the zk-token-sdk
bpf/rust
These syscalls have not been activated yet. If there are places that require more tests before activation, then I'd be happy to add more in.
Glad to hear there are tests for the curve operations themselves. We should also have tests for the syscalls themselves (in/out param handling, compute unit consumption, etc...). Take a look at the test for the other syscalls, they are located at the bottom of the file that declares/defines the syscalls
We'll definitely want these tests if they don't exist -- @samkim-crypto do the tests exist now?
Problem
QSP-4
The following system calls are not tested: • sol_zk_token_elgamal_op; • sol_zk_token_elgamal_op_with_lo_hi; and • sol_zk_token_elgamal_op_with_scalar.
Proposed Solution
Add tests