We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
i see the test code for encode and decode like this
#[test] fn test_sig_encode_and_decode() { let string = String::from("abcdabcdabcdabcdabcdabcdabcdabcdabcdabcdabcd"); let msg = string.as_bytes(); let ctx = SigCtx::new(); let (pk, sk) = ctx.new_keypair(); let signature = ctx.sign(msg, &sk, &pk); let der = signature.der_encode(); let sig = Signature::der_decode(&der[..]).unwrap(); assert!(ctx.verify(msg, &pk, &sig)); let signature = ctx.sign(msg, &sk, &pk); let der = signature.der_encode(); let sig = Signature::der_decode_raw(&der[2..]).unwrap(); assert!(ctx.verify(msg, &pk, &sig)); }
but i need a methods to encrypt plaintext.
The text was updated successfully, but these errors were encountered:
You can use Hex or base64 to change bytes to string
Sorry, something went wrong.
No branches or pull requests
i see the test code for encode and decode like this
but i need a methods to encrypt plaintext.
The text was updated successfully, but these errors were encountered: