-
Notifications
You must be signed in to change notification settings - Fork 117
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
How to decrypt file when already encrypted #254
Comments
@twiss
Result: Thanks |
Hi.
|
But where I'll input the bytes from encrypted file? |
This method is intended for attachments where the key packet is stored in a different place than the file (data packet).
|
All the code here:
|
Hi all, i'm little bit confuse when using this library
first thing what i am todo is receive file then i need to reupload encrypted file
so far i was already created public key and private key using passphrase for encrypted using Func EncryptAttachmentWithKey and then a have to rename file into encrypted.zip.gpg
and now i want to decrypt that file using Func DecryptAttachmentWithKey and my question is
where i can get keyPacket and dataPacket for parameter DecryptAttachmentWithKey, because EncryptAttachmentWithKey already pass at differenct Func of this decrypt Func.
I saw func crypto.SplitMessageFromArmored returned *crypto.PGPSplitMessage that have function to GetBinaryKeyPacket() and GetBinaryDataPacket() for decrypt, but when i use this function return error openpgp: invalid argument: no armored data found, parameter what i'm pass is string([]byte(of the encrypted file))
if please let me know anybody have example encrypt and decrypt file using this library.
thank you for answer,
The text was updated successfully, but these errors were encountered: