-
Notifications
You must be signed in to change notification settings - Fork 122
New issue
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
gopenpgp: unarmor failed for pgp message: EOF #320
Comments
Hi.
Instead call:
|
Thank you for your suggestion 🙇🏻♂️ Could you please review my function again, I tried to decrypt with private key and armored message that this repo provided in the crypto_example_test.go file It work but when I try to use my private key and armored message that I received from encrypted step it throw error incorrect key. I try to decrypt in another tools like on website it work so confused
Thank you 🙏🏻 |
You can try to add the |
@lubux I have add the I work on project k6 for performance test and it not allow for use external module they suggested about create the lib with Golang and register the function to JS module with xk6. for my progress only stuck decryption step. I think you can help my solve this one. Thank you |
I was able to decrypt the message with the key/message you sent me when enabling the key, err := crypto.NewKeyFromArmored(yourKey)
if err != nil {}
pgp := crypto.PGP()
decryptor, err := pgp.Decryption().DecryptionKey(key).InsecureAllowDecryptionWithSigningKeys().New()
if err != nil {}
res, err := decryptor.Decrypt([]byte(yourMessgae), crypto.Armor) |
Finally !! 🎉 it work. Thank you so much 🙇🏻♂️ |
Hi, I have a issue when I encryption the message and send it into api then I receive the response in term of pgp message
then I need to decryption using : decrypt function I got error = gopenpgp: unarmor failed for pgp message: EOF
I have try to take the armored message to Decrypt tools on website with private key it work.
can anyone give me the suggestion for this issue.
my function in below:
priKey, err := crypto.NewKeyFromArmored(string(cert))
if err != nil {
response.ErrorMessage = fmt.Sprintf("Error parsing private key: %v", err)
response.IsSuccess = false
return response
}
The text was updated successfully, but these errors were encountered: