Questions tagged [openpgp]

The OpenPGP standard was originally derived from PGP (Pretty Good Privacy)

OpenPGP software uses a combination of strong public-key and symmetric cryptography to provide security services for electronic communications and data storage. These services include confidentiality, key management, authentication, and digital signatures.

See also:

362 questions
1
vote
0 answers

openpgp can't update large file

onmessage = async({data:{blob, privateKey},ports:[port]})=>{ try { const fileArray = await blob.arrayBuffer(); const uint8 = new Uint8Array(fileArray); var readableStream = new ReadableStream({ start(controller) { …
1
vote
0 answers

Python PGP Encrypt with Public Key

Python PGP Encrypt with Public Key I already tried with PGP, but it showed an error with my public key, then I tried with another one and I didn’t have any problem, but it still showed me and error with my Public Key. The Public Key’s provider told…
mamfredym
  • 28
  • 1
  • 7
1
vote
0 answers

Read file from folder then encrypt and decrypt it using GPG/PGP

I am trying to encrypt a file using GPG and then decrypt it whenever required. I saw an example to encrypt it https://gist.github.com/ayubmalik/a83ee23c7c700cdce2f8c5bf5f2e9f20 But, there is nothing described about how to decrypt it There is one…
Anand Vaidya
  • 609
  • 2
  • 16
  • 41
1
vote
1 answer

How to encrypt and decrypt .csv file to .csv.pgp using python script

I am trying to encrypt a file using pgpy. I am able to encrypt the content of files but unable to save it. I am trying to get output as .csv.pgp Getting this error: encrypted_file.write(encrypted_f_t_e) TypeError: a bytes-like object is required,…
Aman shaw
  • 51
  • 7
1
vote
0 answers

Decrypt pgp message using only public key

In the following use case, It shows that using the private key when encrypting a message is optional but when decrypting the message, they make the private key mandatory! How can I encrypted and decrypt a message using only one key, the public…
1
vote
1 answer

EOF while attempting go-pgp

I need to pgp encrypt a string in Go and I read that this library was good: "github.com/jchavannes/go-pgp/pgp" main.go package main import "fmt" func main() { encrypted := encrypt("4007400000000007", "123") …
pigfox
  • 1,301
  • 3
  • 28
  • 52
1
vote
0 answers

How to display prompt dialog with password field for encrypted pdf using openpgpjs?

I am working on a application where I am selecting pdf file from local file and encrypting it with openpgpjs. Though I am able to encrypt the pdf, When I try to open the encrypted pdf in chrome it is showing dialog with message "Failed to load PDF…
KonTash
  • 158
  • 1
  • 2
  • 15
1
vote
1 answer

How would you reconstruct a public key from the key s-expression and creation timestamp?

I'm specifically asking in relation to this answer where a user is trying to recreate the public key solely from the information in an openPGP Smartcard (due to losing the public key): https://stackoverflow.com/a/69903994/17503333 The answer states…
1
vote
1 answer

Encrypt a zip file with browserpgp javascript tool

I would like to encrypt a zip file using OpenPGP.js (https://browserpgp.github.io/). All processing needs to be done on the client-side, without involvement of Node.js. Using the javascript-based browserpgp.js, encryption of plaintext file is easy,…
1
vote
1 answer

How to decrypt an OpenPGP RSA Encrypted text file in C#?

I am hoping that this question can be met with some guidance for someone who is beginning to work with encryption/decryption in C#. There are existing examples on the web regarding this, but I am truthfully struggling to put it all into practice…
mherr
  • 348
  • 1
  • 7
  • 25
1
vote
0 answers

Decrypt using BCPGP private key in python

How do I read BouncingCastle PGP key and decrypt message using Python.? This private key is generated using GoAnywhere OpenPGP Studio, password is Test@123 Below is the key blob and the error I'm getting. I'm getting same error when I read from…
Hemanth
  • 159
  • 1
  • 12
1
vote
0 answers

Crypt::OpenPGP does not support .kbx ring format?

I've been trying to get Crypt::OpenPGP to work with a new pubring.kbx file but it fails with 'No known recipients for encryption'. If I export the keys in my pubring.kbx file to a pubring.gpg file then I can get the process to work successfully. Is…
Richard McKechnie
  • 2,748
  • 1
  • 15
  • 13
1
vote
0 answers

Decoding Java Bouncy Castle encoded PGP message with openpgp-js: No public key encrypted session key packet found

I am trying to decode a custom PGP message created in other application with Bouncy Castle library for Java. According to the params, it uses SHA512 to hash and RSA to encode and decode. The key's length is 1024 bits. const publicKeyArmored =…
1
vote
0 answers

Is there a way to get the key id and fingerprint of an AsymmetricKeyParameter in C#?

I'm creating an OpenPGP key with the following example code using BouncyCastle: IAsymmetricCipherKeyPairGenerator kpg = new RsaKeyPairGenerator(); kpg.Init(new RsaKeyGenerationParameters(BigInteger.ValueOf(0x1), new SecureRandom(), 2048,…
SpiritBob
  • 2,355
  • 3
  • 24
  • 62
1
vote
2 answers

Bouncy Castle: multiple PGPSignature's identical within same timeframe (~ 1 second)

While testing generation of a PGPSignature in a loop, always using the same input, I noticed I was getting identical signatures within a short timeframe. That did rather surprise me: I had been expecting the Signature not to be reproducible. Is this…
Dave The Dane
  • 650
  • 1
  • 7
  • 18