core icon indicating copy to clipboard operation
core copied to clipboard

Setup code of "Send Autocrypt Setup Message" from K-9 Mail not accepted

Open notYetLost opened this issue 3 years ago • 8 comments

  1. In OpenKeyChain vorkandenen Schlüssel durch K-9 Mails Autocrypt-Unterstützung via "Autocrypt-Setup-Nachricht senden" in DeltaChat zu verwenden, schlägt fehl: der von K-9 Mail angezeigte Setup-Code wird in DeltaChat nicht akzeptiert.

  2. In Thunderbird erzeugte geheime Schlüssel lassen sich nur mit Passwortschutz in eine Datei sichern. Zwar lässt sich diese Datei in OpenKeyChain importieren, aber auch der Setup-Code dieses Schlüssels wird nach K-9 Mail "Autocrypt-Setup-Nachricht senden" in DeltaChat nicht akzeptiert

Gibt es eine Lösung, wie für einen Schlüssel der sowohl in Thunderbird, OpenKeyChain/K-9 Mail, und DeltaChat benutzt werden kann?

notYetLost avatar Jun 06 '22 22:06 notYetLost

This is a place to report and fix issues in the Delta Chat source code. For general support in German please visit the German Delta Chat forum at https://support.delta.chat/c/de/12 Thank you for your understanding! :)

gerryfrancis avatar Jun 07 '22 11:06 gerryfrancis

It is a huge issue that you do not use openkeychain. Here is the english translation:

  1. Using keys pre-created in OpenKeyChain by K-9 Mails autocrypt support via "Send autocrypt setup message" in DeltaChat fails: the setup code displayed by K-9 Mail is not accepted in DeltaChat.
  2. Secret keys generated in Thunderbird can only be saved to a file with password protection. Although this file can be imported in OpenKeyChain, but also the setup code of this key is not accepted in DeltaChat after K-9 Mail "Send autocrypt setup message". Is there a solution how for a key that can be used in both Thunderbird, OpenKeyChain/K-9 Mail, and DeltaChat?

autocrypt is not something you are allowed to model as you like.

ecxod avatar Apr 08 '23 12:04 ecxod

@ecxod I am sorry, this is not the appropriate place to argue. Let's discuss about these and other topics in the Delta Chat forum: https://support.delta.chat/ Thank you! :)

gerryfrancis avatar Apr 08 '23 12:04 gerryfrancis

So when autocrypt setup does not work that is a bug that should be reported in the core repo https://github.com/deltachat/deltachat-core-rust

For feature requests/proposals such as using openkeychain, please discuss this in our forum as @gerryfrancis mentioned. also openkeychain and k9mail are both on android, so it does not make sense to open an issue on the desktop repo anyway.

Simon-Laux avatar Apr 08 '23 19:04 Simon-Laux

The problem in regard to Autocrypt most likely is with K-9 Mail: https://github.com/thundernest/k-9/issues/4867

Their current issue, as far as I understood, is that emails that are sent to self do not contain prefer-encrypt=mutual in the Autocrypt header. However, Delta Chat seems to depend on that information, as explained here: https://github.com/deltachat/deltachat-core-rust/blob/f0249096119ad56c2f3751560dc9341f904956c9/src/peerstate.rs#L323-L341

I installed the latest build (version 6.511) of K-9 Mail from F-Droid, and I tried to sync the client with Delta Chat, which failed, too. Then, after reading this and that about how Delta Chat and K-9 Mail handle Autocrypt, I enabled to force mutual mode in K-9 for all emails. Unfortunately prefer-encrypt=mutual seems to be included in the Autocrypt header only for emails that are not sent to the own address, because it is missing in emails which I sent to myself (sender's address = recipient's address).

As the Autocrypt setup message is sent to the own address, but lacks the mutual Autocrypt encryption value in the header, this might be the cause why it does not work. Therefore I believe that as soon as the issue which I have mentioned before is solved in K-9 Mail, it might play nicely with Delta Chat, too. Someone may open a new issue in the Delta Chat core repository to officially document, of course, but I think there is not much we can do at the moment.

gerryfrancis avatar Apr 09 '23 00:04 gerryfrancis

If it is possible to decrypt the Autocrypt Setup Message sent by K-9, I think it would be nice to do this on the Delta Chat side. Better compatibility is always nice to have, even if there is a bug on the other side.

The comment about how we treat Autocrypt-Gossip is not related, it is to prevent new group members from thinking that everyone else does not prefer encryption simply because they have not seen any messages from them.

link2xt avatar Apr 09 '23 22:04 link2xt

@link2xt Thank you for chiming in, much appreciated! :)

gerryfrancis avatar Apr 09 '23 22:04 gerryfrancis

3aa1cc00-2b58-430e-8f10-a4c832deb89c I have the same problem when sending the autocrypt message from k9mail version 6.511 on android

pablo03v avatar Apr 17 '23 14:04 pablo03v

Just tested with K-9 version 6.802 to confirm the problem is still there: autocrypt-setup-messsage

link2xt avatar Apr 23 '24 16:04 link2xt