Skip to content
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

fix decrypt error rendering #1219

Merged
merged 13 commits into from
Dec 21, 2021
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
Received: from 717284730244
named unknown
by gmailapi.google.com
with HTTPREST;
Fri, 8 Jun 2018 04:15:40 -0700
Content-Type: multipart/mixed;
boundary="----sinikael-?=_1-15284565398080.6365395020974245"
From: [email protected]
To: [email protected]
Subject: not integrity protected - should show a warning and not decrypt
automatically
Date: Fri, 8 Jun 2018 04:15:40 -0700
Message-Id: <CAKbuLTreh7ZN-TP=8-2=ED=AKkgriEi0RLB51i16AcgcC5driQ@mail.gmail.com>
MIME-Version: 1.0

------sinikael-?=_1-15284565398080.6365395020974245
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

-----BEGIN PGP MESSAGE-----
Version: FlowCrypt 5.5.9 Gmail Encryption flowcrypt.com
Comment: Seamlessly send, receive and search encrypted email

wcFMA0taL/zmLZUBAQ/7Bwida5vvhXv5Zi+qJbG/QPst11jWfljDQlw1VLzF
ou8ofoIEHpvoFgXegZUnoQXBmlHGD+XLs9jG/TV1mtE2RWq4hDtqiTQ6rEIa
brN3Nx77Yr+4EN1aKI20aTLEPTIjVU2GH2i9DAmjHteBU3nkL9Z3yecB8Pn8
EdhpCRY6cj2yrhJ5MPwmXrus9OFv39wA2DqYpqW5Be+KD8mipZ2CtJo5xtin
aeEhpWSDsdg26rjx1nz4dA0NcFzZK2p/BPfPIFzRvmoXoWFigpUnwryEoCqX
/tgmcrv7PqiYT5oziPmMuBc1lb7icI/Aq69uXz2z6+4MJHOlcTEFygV36J+1
1opcjoX+JKJNn1nvHovBxuemcMwriJdmDj4Hmfo4zkd6ryUtGVrMVn8DbRp6
TWB/0MSE8cmfuiA5DgzdGbrevdL6RxnQDmalTHJ5oxurFQVoLwpmb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EeYrOe1SxwiZ6BZfIXO2/8M
hA=3D=3D
=3DB/NE
-----END PGP MESSAGE-----

------sinikael-?=_1-15284565398080.6365395020974245--
12 changes: 12 additions & 0 deletions Core/source/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -730,3 +730,15 @@ ava.default('verify signed message with detached signature by providing it corre
expect(parsedDecryptData.verifyRes.match).equals(true);
t.pass();
});

ava.default('verify not integrity protected message', async t => {
const { keys, pubKeys } = getKeypairs('new-key');
const { json: decryptJson, data: decryptData } = parseResponse(await endpoints.parseDecryptMsg({ keys, isEmail: true, verificationPubkeys: pubKeys }, [await getCompatAsset('mime-email-not-integrity-protected')]));
expect(decryptJson.replyType).equals('plain');
expect(decryptJson.subject).equals('not integrity protected - should show a warning and not decrypt automatically');

const blocks = decryptData.toString().split('\n').map(block => JSON.parse(block));
expect(blocks[1].decryptErr.error.type).equals('no_mdc');

t.pass();
});
11 changes: 9 additions & 2 deletions Core/source/test/test-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,12 +141,19 @@ const TEST_KEYS: { [name: string]: TestKey } = {
decrypted: '',
passphrase: '',
longid: ''
},
'new-key': {
pubKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\r\nVersion: FlowCrypt iOS 0.2 Gmail Encryption\r\nComment: Seamlessly send and receive encrypted email\r\n\r\nxsFNBFn7qV4BEACgKfufG6yseRP9jKXZ1zrM5sQtkGWiKLks1799m0KwIYuA\r\nQyYvw6cIWbM2dcuBNOzYHsLqluqoXaCDbUpK8wI/xnH/9ZHDyomk0ASdyI0K\r\nOgn2DrXFySuRlglPmnMQF7vhpnXeflqp9bxQ9m4yiHMS+FQazMvf/zcrAKKg\r\nhPxcYXC1BJfSub5tj1rY24ARpK91fWOQO6gAFUvpeSiNiKb7C4lmWuLg64UL\r\njLTLXO9P/2Vs2BBHOACs6u0pmDnFtDnFleGLC5jrL6VvQDp3ekEvcqcfC5MV\r\nR0N6uVTesRc5hlBtwhbGg4HuI5cFLL+jkRw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6Jvl4DVQiaNFam0kgjqtkkIdWsH+sU\r\nlVCFIdolAKxJ3wrQ3UM46u/ihoasv3PLM90BNbyLNj2vMhFo2D1KLwO9Qt8o\r\niF4sjjb1FYN95gWMU9UnyfnmDBp/bw2m3GzKjiYRaF/6kX+XwdpC07MsHzY8\r\nTg1fCvN/YyiA3PdbkEy9xZmjVWZrgjPUgl8d02Vlgk7W8wLu7/slgDO3IfnS\r\nZdP0mHpTaOKbk4SUVE0RSHfkTUvYbpfNF04msRduCEXsQ76J6QjJFJx/akT6\r\n80GEvaLCcmz4KGAUMUgadH5mPCXesbya7HSLKSx7m85OiJ3xIRnXqe7tYX1v\r\nyEjE6szs0EAhpZUP2iqzDy76ffQynQMH6lzQyeHLTGMxZ1OYtyn5SvlHa5np\r\nAJnSVjMsViztlbhfqZPdPC0ZZrt4E0hGLIAGbmDeOFOLyzBBeG/wy0bp4uLH\r\nwfn9cM5lL3XLo+VR0CN8NLfj8h4yVLxIzVAiUGQseonXy+JA0erD2Jht/nns\r\n0DoFWqjcDY5U/LIJVopGhgfctNxISnExyKo4eyq1iVKjt1HIk4RRDptYREgA\r\nfm8L3l8EuB2q1535rkqr/uHHyx+th0vWUnK2IvRWAZZLQZUvVxkxTCG++7xv\r\nEg==\r\n=r2et\r\n-----END PGP PUBLIC KEY BLOCK-----\r\n',
private: '-----BEGIN PGP PRIVATE KEY BLOCK-----\r\nVersion: FlowCrypt iOS 0.2 Gmail Encryption\r\nComment: Seamlessly send and receive encrypted email\r\n\r\nxcaGBFn7qV4BEACgKfufG6yseRP9jKXZ1zrM5sQtkGWiKLks1799m0KwIYuA\r\nQyYvw6cIWbM2dcuBNOzYHsLqluqoXaCDbUpK8wI/xnH/9ZHDyomk0ASdyI0K\r\nOgn2DrXFySuRlglPmnMQF7vhpnXeflqp9bxQ9m4yiHMS+FQazMvf/zcrAKKg\r\nhPxcYXC1BJfSub5tj1rY24ARpK91fWOQO6gAFUvpeSiNiKb7C4lmWuLg64UL\r\njLTLXO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OrM7NBAIaWVD9oqsw8u+n30Mp0DB+pc\r\n0Mnhy0xjMWdTmLcp+Ur5R2uZ6QCZ0lYzLFYs7ZW4X6mT3TwtGWa7eBNIRiyA\r\nBm5g3jhTi8swQXhv8MtG6eLix8H5/XDOZS91y6PlUdAjfDS34/IeMlS8SM1Q\r\nIlBkLHqJ18viQNHqw9iYbf557NA6BVqo3A2OVPyyCVaKRoYH3LTcSEpxMciq\r\nOHsqtYlSo7dRyJOEUQ6bWERIAH5vC95fBLgdqted+a5Kq/7hx8sfrYdL1lJy\r\ntiL0VgGWS0GVL1cZMUwhvvu8bxI=\r\n=rRS1\r\n-----END PGP PRIVATE KEY BLOCK-----\r\n',
decrypted: '',
passphrase: 'London blueBARREY capi',
longid: '4B5A2FFCE62D9501'
tomholub marked this conversation as resolved.
Show resolved Hide resolved
}
}

type KeypairName = 'rsa1' | 'rsa2' | 'ecc' | 'gpg-dummy' | 'expired' | 'revoked';
type KeypairName = 'rsa1' | 'rsa2' | 'ecc' | 'gpg-dummy' | 'expired' | 'revoked' | 'new-key';

export const allKeypairNames: KeypairName[] = ['rsa1', 'rsa2', 'ecc', 'gpg-dummy', 'expired', 'revoked'];
export const allKeypairNames: KeypairName[] = ['rsa1', 'rsa2', 'ecc', 'gpg-dummy', 'expired', 'revoked', 'new-key'];

export const getKeypairs = (...names: KeypairName[]) => {
return {
Expand Down