Closed Bug 1763907 Opened 4 years ago Closed 4 years ago

for external gnupg: cannot decrypt OpenPGP encrypted messages, CryptoAPI.sync() failed result: TypeError: this is undefined

Categories

(MailNews Core :: Security: OpenPGP, defect)

Thunderbird 100
defect

Tracking

(thunderbird_esr91 unaffected, thunderbird100+ fixed)

RESOLVED FIXED
101 Branch
Tracking Status
thunderbird_esr91 --- unaffected
thunderbird100 + fixed

People

(Reporter: chriechers, Assigned: mkmelin)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

Any attempt to decrypt OpenPGP encrypted messages fails after upgrading to TB 100.0b1. It's been working fine up to v99.0b2. No changes have been made to the profile, except the upgrade.
The private key is stored in the GnuPG keyring. When attempting to open an encrypted message I still get the Pinentry passphrase prompt, but then the message is never decrypted.
The error console has this:
CryptoAPI.sync() failed result: TypeError: this is undefined
enArmorCDataMessage chrome://openpgp/content/modules/RNP.jsm:3425
decrypt chrome://openpgp/content/modules/GPGME.jsm:136
decrypt chrome://openpgp/content/modules/RNP.jsm:1218
decrypt chrome://openpgp/content/modules/cryptoAPI/RNPCryptoAPI.jsm:233
decryptMime chrome://openpgp/content/modules/cryptoAPI/RNPCryptoAPI.jsm:260
onStopRequest chrome://openpgp/content/modules/mimeDecrypt.jsm:546
interface.js:46:17
TypeError: this is undefined
RNP.jsm:3425:5

This has been seen on both, Linux and Win10.

Keywords: regression
Summary: cannot decrypt OpenPGP encrypted messages, CryptoAPI.sync() failed result: TypeError: this is undefined → for external gnupg: cannot decrypt OpenPGP encrypted messages, CryptoAPI.sync() failed result: TypeError: this is undefined
Assignee: nobody → mkmelin+mozilla
Status: NEW → ASSIGNED
OS: Linux → All
Hardware: x86_64 → All

Christian, thanks for the report. Could you please test the fix works?

I've started a TB version 100 branch experimental build with Magnus' patch.
You can find it here:
https://treeherder.mozilla.org/jobs?repo=try-comm-central&revision=7847a39a5fc9d5d85056402978a31c1a87f3188c&selectedTaskRun=awT2MtsZRvmMkKY_FKiSRg.0

Click on the green B or Ba for your platform (once its green), then click "Artifacts and debugging", then download target.tar.bz2 for linux or target.zip for window.

Flags: needinfo?(chriechers)

I did install the 64-bit experimental version for Linux. The behavior is unchanged, an encrypted message still doesn't decrypt. From the error console:
CryptoAPI.sync() failed result: TypeError: this is undefined
enArmorCDataMessage chrome://openpgp/content/modules/RNP.jsm:3425
decrypt chrome://openpgp/content/modules/GPGME.jsm:136
decrypt chrome://openpgp/content/modules/RNP.jsm:1218
decrypt chrome://openpgp/content/modules/cryptoAPI/RNPCryptoAPI.jsm:233
decryptMime chrome://openpgp/content/modules/cryptoAPI/RNPCryptoAPI.jsm:260
onStopRequest chrome://openpgp/content/modules/mimeDecrypt.jsm:546
interface.js:46:17
TypeError: this is undefined
RNP.jsm:3425:5

Flags: needinfo?(chriechers)

The line numbers are exactly the same as previous, so I think that isn't using the patch. Try starting with --purgecaches if it really is the right binary

--purgecaches did the trick. Decryption now works with the experimental version.

Pushed by nicolai@thunderbird.net:
https://hg.mozilla.org/comm-central/rev/535ffd214012
decrypting with external opengpgp was broken. r=kaie

Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED

Comment on attachment 9271582 [details]
Bug 1763907 - decrypting with external opengpgp was broken. r=kaie

[Approval Request Comment]
Regression caused by (bug #): 1667564
User impact if declined: Using external PGP via GPGME not working
Risk to taking this patch (and alternatives if risky): low risk, can't break the feature any more than it is

Attachment #9271582 - Flags: approval-comm-beta?

Comment on attachment 9271582 [details]
Bug 1763907 - decrypting with external opengpgp was broken. r=kaie

[Triage Comment]
Approved for beta

Attachment #9271582 - Flags: approval-comm-beta? → approval-comm-beta+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: