FlowCrypt / flowcrypt-android

FlowCrypt Android App
https://flowcrypt.com
Other
93 stars 11 forks source link

improve warnings when importing a public key manually #1543

Open tomholub opened 3 years ago

tomholub commented 3 years ago

When importing a public key received through email, currently, we compare the fingerprint of the new public key with fingerprint(s) we already have recorded internally, and based on that we say either import public key or replace public key or similar.

(in the below steps, recipient email is the primary uid of the received key)

We should update this as follows: before any of the below, refetch public keys from remote sources (PubLookup by email) and update the local storage if needed, similar to when writing to a new recipient. After that fetch and update is done, compare the received public key in question to our local storage that was updated from remote sources:

tomholub commented 3 years ago

A simpler version of this issue: leave everything as is and always add Manually importing Public Keys received over email can be dangerous. Contact the sender to verify that the fingerprint matches.