Created
April 7, 2025 01:09
-
-
Save rikonor/5262c6dd65df0d3a78bfe5361d89289e to your computer and use it in GitHub Desktop.
Signing and Verifying
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Generate private key | |
openssl genpkey -algorithm Ed25519 -out private.pem | |
# Derive public key | |
openssl pkey -in private.pem -pubout -out public.pem | |
# Generate signature | |
openssl pkeyutl -sign -inkey private.pem -rawin -in data_to_sign.txt -out signature.sig | |
# Verify signature | |
openssl pkeyutl -verify -pubin -inkey public.pem -rawin -in data_to_sign.txt -sigfile signature.sig |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment