Github messages for mblaze
 help / color / mirror / Atom feed
* [ISSUE] Encrypt + Sign
@ 2021-02-02 10:57 Eluminae
  2021-02-02 11:05 ` leahneukirchen
                   ` (17 more replies)
  0 siblings, 18 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 10:57 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1144 bytes --]

New issue by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202

Description:
I just configured filters with some contrib scripts from this repo and I received this mail

```
--- 1: multipart/encrypted size=2246 filter="mgpg" ---
--- --- 2: multipart/signed size=1138 ---
--- --- --- 3: text/plain size=356 ---
This is a test email sent from sourcehut to confirm that PGP is working as you
expect. This email is signed with this key:

447B 69E4 B34B E90B C829 A0E9 6597 04D1 A38A 93AE

and is encrypted with this key:

CAB1 2F60 BD13 A21D AB60  C510 5BAC 9232 8B7C 5D65

You may control your PGP settings here:

https://meta.sr.ht/privacy

--
Drew DeVault
sourcehut
--- --- --- 4: application/pgp-signature size=455 name="signature.asc" render="mverify; exit 0" ---
No signature found.
```

It seems this signature could not be verified.

After some check, it seems I can't send an encrypted + signed email too

In recap:

* Is it possible to encrypt then sign ? Or to encrypt+sign in one action (maybe easier) ?
* Does mverify and/or mpgp could handle signed crypted messages ?

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
@ 2021-02-02 11:05 ` leahneukirchen
  2021-02-02 11:34 ` Eluminae
                   ` (16 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: leahneukirchen @ 2021-02-02 11:05 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 314 bytes --]

New comment by leahneukirchen on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771556644

Comment:
mencrypt uses `--encrypt --sign` so that should be fine.

I think above error results due to using mverify as a filter, but it's a tool you need to call on the whole message.

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
  2021-02-02 11:05 ` leahneukirchen
@ 2021-02-02 11:34 ` Eluminae
  2021-02-02 11:37 ` Eluminae
                   ` (15 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 11:34 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 3913 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771573775

Comment:
> mencrypt uses --encrypt --sign so that should be fine.

I'll double check this part so

> I think above error results due to using mverify as a filter, but it's a tool you need to call on the whole message.

oh ? But it seems that the vanilla mverify can't check the signature too

```
[reed@terminator ~]$ mshow
From: sourcehut <outgoing@sr.ht>
Subject: Test email
To: foo@bar.net
Date: Tue, 02 Feb 2021 10:39:28 -0000 (49 minutes, 57 seconds ago)

--- 1: multipart/encrypted size=2246 filter="mgpg" ---
--- --- 2: multipart/signed size=1138 ---
--- --- --- 3: text/plain size=356 ---
This is a test email sent from sourcehut to confirm that PGP is working as you
expect. This email is signed with this key:

447B 69E4 B34B E90B C829 A0E9 6597 04D1 A38A 93AE

and is encrypted with this key:

CAB1 2F60 BD13 A21D AB60  C510 5BAC 9232 8B7C 5D65

You may control your PGP settings here:

https://meta.sr.ht/privacy

--
Drew DeVault
sourcehut
--- --- --- 4: application/pgp-signature size=455 name="signature.asc" render="mverify; exit 0" ---
No signature found.
[reed@terminator ~]$ mverify
No signature found.
```

The verification seems included in the encrypted part as the raw email looks like 

```
From: sourcehut <outgoing@sr.ht>
Subject: Test email
To: foo@bar
Date: Tue, 02 Feb 2021 10:39:28 -0000 (54 minutes, 34 seconds ago)

--===============5503615174114557129==
Content-Type: application/pgp-encrypted

Version: 1
--===============5503615174114557129==
Content-Type: application/octet-stream; name="message.asc"
Content-Description: OpenPGP encrypted message

-----BEGIN PGP MESSAGE-----

wcFMA0r01qAHYcQRARAA37lNNKuwNO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MG4wbCbETz
iaxoO55SX3N0ySDTAKhD9CfR/Oy9l8FkINyRf8CiTfbfAZtCefSfiSkQ6ruclGxs
GflqlYAg6OD2pls5j8iFUftyJrWO3rsCWtzaWfVha//She6bve5TudhSfYzTwE/y
vK3JZ7ZaoKmRrwa/hsD6xDPrnRqS30PkJ3QzttugHvo5IJe7N/hbI94t6XAyRdkH
R7SHaWiPxlaLWOhVntyPSbpeeCJszwe1lXpEVb3tgn1+Ufp84A5AufQEYB5qSmB/
MfZn6YaxV5yxN39GNvkPfzXROiPHn4wFSFQpYODQLre1Otcx5ff+4T79cInHbFmY
sSY7ak3Y0v7ZkyoYA3sUb+y1Do5PWH+Rp7hxTnCZxzATKQWGW0EqqWmDYKvgyBRK
jJqSMRr1lXB3Mmc78TKUxbo9YNGNU+s4iMcYWc2gH7U3PblOBxGnqEuiixCK2luh
kBzgx84WrqUft+lQ+d79b4qaOmPi0epmpaB/ms+FpVYNiN4t9dgRWZUwtGQVCw/j
6HVlc0NejF+ZSu+GpVHMQRUke6LkTq1K/jkPN53M1ShZkWwfqncEQIsXzGMtOVgJ
6DOVWsptZiXIJN+EFV+GSJRq3iB7c+pbh/7cBJICol6VxOYTkjGrdJlA7kWMwfjz
7nH1b+RN4BWcN0RKBBY9TOGtFEXdX/xb/pFb0TSqMLOEFd+krkaoSPXb5PqLwFI3
bREFKSKmPd0svZZqPfh5nW5WnkvJrNZa6rYipMP+/q9K5g6CzTp0B20WCPY0zaq3
wUw3NO6xNcYdAYqCPXQ=
=gJPx
-----END PGP MESSAGE-----

--===============5503615174114557129==--
```

Anyway I'll adapt it to be usable as filter. I'd like to display signature verification with mless

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
  2021-02-02 11:05 ` leahneukirchen
  2021-02-02 11:34 ` Eluminae
@ 2021-02-02 11:37 ` Eluminae
  2021-02-02 11:40 ` Eluminae
                   ` (14 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 11:37 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 578 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771575325

Comment:
> > mencrypt uses --encrypt --sign so that should be fine.
> I'll double check this part so

It seems it is not enough to emulate the mail from sr.ht

```
From: Foo bar <foo@bar>
Subject: crypted signed ?
To: toto@tutu
Date: Tue, 02 Feb 2021 12:35:51 +0100 (39 seconds ago)

--- 1: multipart/encrypted size=3155 filter="mgpg" ---
--- --- 2: multipart/mixed size=827 ---
--- --- --- 3: text/plain size=20 ---
this should be both
```

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (2 preceding siblings ...)
  2021-02-02 11:37 ` Eluminae
@ 2021-02-02 11:40 ` Eluminae
  2021-02-02 11:41 ` Eluminae
                   ` (13 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 11:40 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 338 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771576751

Comment:
I may be wrong about all this.

Does decrypt also check the signature ? Does the npgp filter will just break if the mail is wrongly signed ? In this case, I should not focus that much on the signature.asc

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (3 preceding siblings ...)
  2021-02-02 11:40 ` Eluminae
@ 2021-02-02 11:41 ` Eluminae
  2021-02-02 11:44 ` leahneukirchen
                   ` (12 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 11:41 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 3910 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771573775

Comment:
> mencrypt uses --encrypt --sign so that should be fine.

I'll double check this part so

> I think above error results due to using mverify as a filter, but it's a tool you need to call on the whole message.

oh ? But it seems that the vanilla mverify can't check the signature too

```
[reed@terminator ~]$ mshow
From: sourcehut <outgoing@sr.ht>
Subject: Test email
To: foo@bar.net
Date: Tue, 02 Feb 2021 10:39:28 -0000 (49 minutes, 57 seconds ago)

--- 1: multipart/encrypted size=2246 filter="mgpg" ---
--- --- 2: multipart/signed size=1138 ---
--- --- --- 3: text/plain size=356 ---
This is a test email sent from sourcehut to confirm that PGP is working as you
expect. This email is signed with this key:

447B 69E4 B34B E90B C829 A0E9 6597 04D1 A38A 93AE

and is encrypted with this key:

CAB1 2F60 BD13 A21D AB60  C510 5BAC 9232 8B7C 5D65

You may control your PGP settings here:

https://meta.sr.ht/privacy

--
Drew DeVault
sourcehut
--- --- --- 4: application/pgp-signature size=455 name="signature.asc" render="mverify; exit 0" ---
No signature found.
[reed@terminator ~]$ mverify
No signature found.
```

The signature seems included in the encrypted part as the raw email looks like 

```
From: sourcehut <outgoing@sr.ht>
Subject: Test email
To: foo@bar
Date: Tue, 02 Feb 2021 10:39:28 -0000 (54 minutes, 34 seconds ago)

--===============5503615174114557129==
Content-Type: application/pgp-encrypted

Version: 1
--===============5503615174114557129==
Content-Type: application/octet-stream; name="message.asc"
Content-Description: OpenPGP encrypted message

-----BEGIN PGP MESSAGE-----

wcFMA0r01qAHYcQRARAA37lNNKuwNOADjyjFsv18uZBkqKEdF4gz88fsNYXp/xD6
MIUhIEovxsbKXcUUP8q7xhFlI2ePgAnXSz6vlMsvTDxt3iygXXoz0FytkI3d+Yq2
8uRMU7BmJGWE6cZwV2gm1etDc0BK9iFj1V5UMsS4ddoKyx6y85msvIh/fGYbyGkg
ifXRpbwclqIgGK2PS+LY4zEiAHf+7nb7srQia5F2HPBOYSBSBDknvzqryrQ8Pmnh
G6ilRwIK7d5syXnme8IZOou/qkIpqG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YB5qSmB/
MfZn6YaxV5yxN39GNvkPfzXROiPHn4wFSFQpYODQLre1Otcx5ff+4T79cInHbFmY
sSY7ak3Y0v7ZkyoYA3sUb+y1Do5PWH+Rp7hxTnCZxzATKQWGW0EqqWmDYKvgyBRK
jJqSMRr1lXB3Mmc78TKUxbo9YNGNU+s4iMcYWc2gH7U3PblOBxGnqEuiixCK2luh
kBzgx84WrqUft+lQ+d79b4qaOmPi0epmpaB/ms+FpVYNiN4t9dgRWZUwtGQVCw/j
6HVlc0NejF+ZSu+GpVHMQRUke6LkTq1K/jkPN53M1ShZkWwfqncEQIsXzGMtOVgJ
6DOVWsptZiXIJN+EFV+GSJRq3iB7c+pbh/7cBJICol6VxOYTkjGrdJlA7kWMwfjz
7nH1b+RN4BWcN0RKBBY9TOGtFEXdX/xb/pFb0TSqMLOEFd+krkaoSPXb5PqLwFI3
bREFKSKmPd0svZZqPfh5nW5WnkvJrNZa6rYipMP+/q9K5g6CzTp0B20WCPY0zaq3
wUw3NO6xNcYdAYqCPXQ=
=gJPx
-----END PGP MESSAGE-----

--===============5503615174114557129==--
```

Anyway I'll adapt it to be usable as filter. I'd like to display signature verification with mless

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (4 preceding siblings ...)
  2021-02-02 11:41 ` Eluminae
@ 2021-02-02 11:44 ` leahneukirchen
  2021-02-02 11:46 ` leahneukirchen
                   ` (11 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: leahneukirchen @ 2021-02-02 11:44 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 221 bytes --]

New comment by leahneukirchen on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771578915

Comment:
Filters only get the attachment as input, but you need the whole message to verify.

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (5 preceding siblings ...)
  2021-02-02 11:44 ` leahneukirchen
@ 2021-02-02 11:46 ` leahneukirchen
  2021-02-02 11:50 ` Eluminae
                   ` (10 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: leahneukirchen @ 2021-02-02 11:46 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 231 bytes --]

New comment by leahneukirchen on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771579577

Comment:
And please provide the raw message, I don't want to guess the MIME headers to reproduce this.

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (6 preceding siblings ...)
  2021-02-02 11:46 ` leahneukirchen
@ 2021-02-02 11:50 ` Eluminae
  2021-02-02 11:51 ` Eluminae
                   ` (9 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 11:50 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 402 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771581818

Comment:
here the full message : http://dav.misterbanal.net/15c0ce9e-7092-431d-af90-5ae64107cbe1.11409_1.terminator,U=1706:2,

but I think you'll have difficulties to decrypt it. If you got an sr.ht account, this is the test email button after setting up the encryption pgp key

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (7 preceding siblings ...)
  2021-02-02 11:50 ` Eluminae
@ 2021-02-02 11:51 ` Eluminae
  2021-02-02 11:56 ` Eluminae
                   ` (8 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 11:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 403 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771581818

Comment:
here the [full message](http://dav.misterbanal.net/15c0ce9e-7092-431d-af90-5ae64107cbe1.11409_1.terminator,U=1706:2,)

but I think you'll have difficulties to decrypt it. If you got an sr.ht account, this is the test email button after setting up the encryption pgp key

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (8 preceding siblings ...)
  2021-02-02 11:51 ` Eluminae
@ 2021-02-02 11:56 ` Eluminae
  2021-02-02 11:57 ` leahneukirchen
                   ` (7 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 11:56 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1737 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771584792

Comment:
I think the encrypted part contain in itself multiple subparts. mblaze in it current state can't know about the signature encrypted subpart. 

Here the mpgp filter stdout

```
Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="===============2511636010367206221=="
MIME-Version: 1.0

--===============2511636010367206221==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit

This is a test email sent from sourcehut to confirm that PGP is working as you
expect. This email is signed with this key:

447B 69E4 B34B E90B C829 A0E9 6597 04D1 A38A 93AE

and is encrypted with this key:

CAB1 2F60 BD13 A21D AB60  C510 5BAC 9232 8B7C 5D65

You may control your PGP settings here:

https://meta.sr.ht/privacy

--
Drew DeVault
sourcehut

--===============2511636010367206221==
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature

-----BEGIN PGP SIGNATURE-----

wsBcBAABCgAGBQJgGSvgAAoJEGWXBNGjipOuccMH/18vOX99CyQP/mU8fOe/3YRc
nKCmq0iVdF5WuDNA2grB5Xjat3zEOqzWirUJ2hNcDzJ+rreL5sIltVuK6JnA9hBU
/5VB7xNmJglB04cwkuDaIfbvwVkhKiivTHbY8Y4PbW9k3vH4zYUY8cDvQc8qPCZc
UTHkdXapGz5eTuorFusJB1CaxCgWBrl8xUahJVNyNmMjnqTrpbib8RqWiNAdOjlz
KiH3i/SbIDYscLdFXXSQv+m82fuOD92a60Bac4E//B4XQg9q9YyBGa5fEkS8CXUZ
KULEGLehg/hOxd4Uq7He9xrWoUVS1KtGwTSS7MfSAvYHCPerS+in/UWmlSAvTpQ=
=D3Mk
-----END PGP SIGNATURE-----

--===============2511636010367206221==--
```

The mshow and mless display it as an ordinary subpart but it is a little trickier

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (9 preceding siblings ...)
  2021-02-02 11:56 ` Eluminae
@ 2021-02-02 11:57 ` leahneukirchen
  2021-02-02 11:59 ` leahneukirchen
                   ` (6 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: leahneukirchen @ 2021-02-02 11:57 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 347 bytes --]

New comment by leahneukirchen on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771585212

Comment:
Yes, mverify won't work on that encrypted file (could be extended I guess). But mgpg should show

```
gpg: Signature made ...
gpg:                using ...
gpg: Good signature from ...
```

at the end.

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (10 preceding siblings ...)
  2021-02-02 11:57 ` leahneukirchen
@ 2021-02-02 11:59 ` leahneukirchen
  2021-02-02 12:00 ` leahneukirchen
                   ` (5 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: leahneukirchen @ 2021-02-02 11:59 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 300 bytes --]

New comment by leahneukirchen on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771586339

Comment:
Putting an external signature into a GPG signed part seems weird, as you could just sign the GPG part in the first place. But on this content mverify should work.

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (11 preceding siblings ...)
  2021-02-02 11:59 ` leahneukirchen
@ 2021-02-02 12:00 ` leahneukirchen
  2021-02-02 12:06 ` Eluminae
                   ` (4 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: leahneukirchen @ 2021-02-02 12:00 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 152 bytes --]

New comment by leahneukirchen on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771586831

Comment:
Also see #175.

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (12 preceding siblings ...)
  2021-02-02 12:00 ` leahneukirchen
@ 2021-02-02 12:06 ` Eluminae
  2021-02-02 12:07 ` Eluminae
                   ` (3 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 12:06 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 514 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771589847

Comment:
gpg2 -d do not display signature information

```
gpg: Note: secret key 4AF4D6A00761C411 expired at Tue 17 Sep 2019 08:45:55 PM CEST
gpg: Note: key has been revoked
gpg: encrypted with 4096-bit RSA key, ID 4AF4D6A00761C411, created 2018-09-17
      "Eddie Barraco <contact@eddiebarraco.fr>"
```

probably cause the signature is in its dedicated subpart ant not the gpg part

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (13 preceding siblings ...)
  2021-02-02 12:06 ` Eluminae
@ 2021-02-02 12:07 ` Eluminae
  2021-02-02 12:11 ` Eluminae
                   ` (2 subsequent siblings)
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 12:07 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 240 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771590438

Comment:
I'll try to extends the mverify to decrypt the encrypted part then check signature in the case of pgp emails

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (14 preceding siblings ...)
  2021-02-02 12:07 ` Eluminae
@ 2021-02-02 12:11 ` Eluminae
  2021-02-02 12:59 ` Eluminae
  2021-02-02 13:10 ` Eluminae
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 12:11 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 356 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771592421

Comment:
> gpg2 -d do not display signature information

It work nicely with encrypted email from mblaze (signature in the gpg part) but I dunno what will be display if there is a signature missmatch. I'd like to be noticed somehow

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (15 preceding siblings ...)
  2021-02-02 12:11 ` Eluminae
@ 2021-02-02 12:59 ` Eluminae
  2021-02-02 13:10 ` Eluminae
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 12:59 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 695 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771617509

Comment:
Something like this seems enough to me

```
diff --git a/bin/mverify b/bin/mverify
index 1624d49..21e7e24 100755
--- a/bin/mverify
+++ b/bin/mverify
@@ -11,6 +11,13 @@ fi

 [ "$#" -eq 0 ] && set -- .

+if mshow -t "$1" | grep -q "multipart/encrypted"; then
+       tmp=$(mktemp -t mgpg.XXXXXX)
+       trap "rm -f '$tmp'" INT TERM EXIT
+       mshow -r "$1" | "$GPG" -d > "$tmp"
+       set -- "$tmp"
+fi
+
 mshow -t "$1" | DOS2UNIX='/^M$/!s/$/^M/' awk -v "msg=$1" '
 { match($0, "^ *"); indent = RLENGTH }
 $2 == "text/plain" { plain++ }
```

^ permalink raw reply	[flat|nested] 19+ messages in thread

* Re: Encrypt + Sign
  2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
                   ` (16 preceding siblings ...)
  2021-02-02 12:59 ` Eluminae
@ 2021-02-02 13:10 ` Eluminae
  17 siblings, 0 replies; 19+ messages in thread
From: Eluminae @ 2021-02-02 13:10 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 780 bytes --]

New comment by Eluminae on mblaze repository

https://github.com/leahneukirchen/mblaze/issues/202#issuecomment-771617509

Comment:
Something like this seems enough to me

```
diff --git a/bin/mverify b/bin/mverify
index 1624d49..21e7e24 100755
--- a/bin/mverify
+++ b/bin/mverify
@@ -11,6 +11,13 @@ fi

 [ "$#" -eq 0 ] && set -- .

+if mshow -t "$1" | grep -q "multipart/encrypted"; then
+       tmp=$(mktemp -t mgpg.XXXXXX)
+       trap "rm -f '$tmp'" INT TERM EXIT
+       mshow -r "$1" | "$GPG" -d > "$tmp"
+       set -- "$tmp"
+fi
+
 mshow -t "$1" | DOS2UNIX='/^M$/!s/$/^M/' awk -v "msg=$1" '
 { match($0, "^ *"); indent = RLENGTH }
 $2 == "text/plain" { plain++ }
```

edit: we should add some `-n` args to some `mshow` to avoid linking the tmp file 

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2021-02-02 13:10 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-02 10:57 [ISSUE] Encrypt + Sign Eluminae
2021-02-02 11:05 ` leahneukirchen
2021-02-02 11:34 ` Eluminae
2021-02-02 11:37 ` Eluminae
2021-02-02 11:40 ` Eluminae
2021-02-02 11:41 ` Eluminae
2021-02-02 11:44 ` leahneukirchen
2021-02-02 11:46 ` leahneukirchen
2021-02-02 11:50 ` Eluminae
2021-02-02 11:51 ` Eluminae
2021-02-02 11:56 ` Eluminae
2021-02-02 11:57 ` leahneukirchen
2021-02-02 11:59 ` leahneukirchen
2021-02-02 12:00 ` leahneukirchen
2021-02-02 12:06 ` Eluminae
2021-02-02 12:07 ` Eluminae
2021-02-02 12:11 ` Eluminae
2021-02-02 12:59 ` Eluminae
2021-02-02 13:10 ` Eluminae

Github messages for mblaze

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.vuxu.org/mblaze-github

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V1 mblaze-github mblaze-github/ http://inbox.vuxu.org/mblaze-github \
		mblaze-github@inbox.vuxu.org
	public-inbox-index mblaze-github

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.github.mblaze


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git