Adding support for fetching GPG key using WKD protocol

Wiktor Kwapisiewicz wiktor at metacode.biz
Fri Jul 6 08:29:52 UTC 2018


>> Does this mean that WKD would always be enabled?
> 
> The quadoption would allow the user to set to automatic (yes), prompt
> (ask-yes/ask-no), or disable (no).  I'd like feedback from everyone, but
> I am disinclined to default-enable something that send http requests
> out without the user fully understanding what's going on.
> 

Yes, I agree. I think it's safe to say that it will never be enabled by 
default.

I'm thinking about how would get_candidates be modified.

Currently it's (pseudocode):

get_candidates() {
   // searches only locally by default
   keys = keylist_search();
   return keys;
}

After the change it would be (assuming wkd_search would be the option):

get_candidates() {
   if (wkd_search == "automatic") {
     keylist_mode(LOCAL | EXTERNAL); // enables auto WKD
   }
   keys = keylist_search();
   if (!keys) {
     if (wkd_search == "ask") {
       answer = ask("Key not found locally, do you want to search user's 
domain for their key?")
       if (answer == "yes") {
          keylist_mode(LOCAL | EXTERNAL);
          keys = keylist_search();
       }
     }
   }
   return keys;
}

The text to ask is up for discussion, I'm just asking if this general 
flow of code sounds good.

Another question: what would be the default value for "wkd_search" - 
"ask" or "no"?

Kind regards,
Wiktor

-- 
https://metacode.biz/@wiktor

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 862 bytes
Desc: OpenPGP digital signature
URL: <http://lists.mutt.org/pipermail/mutt-dev/attachments/20180706/0c2117f4/attachment.asc>


More information about the Mutt-dev mailing list