Reverting 1d3c2c48, as neal fixed the issue in the latest sequoia. UPDATE SEQUOIA, PEOPLES OF PEP! :) sync
authorKrista 'DarthMama' Bennett <krista@pep.foundation>
Tue, 09 Jul 2019 11:04:40 +0200
branchsync
changeset 39101e9cd9e6cd29
parent 3907 7c8cdcdd8a34
child 3911 7505db47bc5f
child 3912 506818fe8cbd
child 3914 eec042946bec
child 3918 45ece20f07fb
Reverting 1d3c2c48, as neal fixed the issue in the latest sequoia. UPDATE SEQUOIA, PEOPLES OF PEP! :)
src/pEpEngine.c
     1.1 --- a/src/pEpEngine.c	Tue Jul 09 10:26:17 2019 +0200
     1.2 +++ b/src/pEpEngine.c	Tue Jul 09 11:04:40 2019 +0200
     1.3 @@ -4247,27 +4247,8 @@
     1.4      if (!(session && pattern && keylist))
     1.5          return PEP_ILLEGAL_VALUE;
     1.6  
     1.7 -    PEP_STATUS status = session->cryptotech[PEP_crypt_OpenPGP].find_keys(session, pattern,
     1.8 -                                                                         keylist);
     1.9 -                                                                         
    1.10 -#ifndef USE_GPG
    1.11 -    if (*keylist == NULL) {
    1.12 -        // we have a problem, in that older GPG keys with no username associated don't 
    1.13 -        // quote out the address-as-username, meaning the uid is non-standard.
    1.14 -        // sequoia then stores the whole uid string for lookup, so we try again here with 
    1.15 -        // a whole-uid-pattern:
    1.16 -        if (strchr(pattern, '@')) {
    1.17 -            char* new_pattern = calloc(2*strlen(pattern) + 4, 1);
    1.18 -            int n = sprintf(new_pattern, "%s <%s>", pattern, pattern);
    1.19 -            if (n > 0)
    1.20 -                status = session->cryptotech[PEP_crypt_OpenPGP].find_keys(session, new_pattern,
    1.21 -                                                                          keylist);
    1.22 -            free(new_pattern);                                                                      
    1.23 -        }    
    1.24 -    }
    1.25 -#endif 
    1.26 -    
    1.27 -    return status;
    1.28 +    return session->cryptotech[PEP_crypt_OpenPGP].find_keys(session, pattern,
    1.29 +            keylist);
    1.30  }
    1.31  
    1.32