mirror of
				https://gitee.com/gitea/gitea
				synced 2025-11-04 00:20:25 +08:00 
			
		
		
		
	Keys should not verify revoked email addresses (#12486)
Fix #6778 Signed-off-by: Andrew Thornton <art27@cantab.net>
This commit is contained in:
		@@ -286,6 +286,9 @@ func parseGPGKey(ownerID int64, e *openpgp.Entity) (*GPGKey, error) {
 | 
			
		||||
 | 
			
		||||
	emails := make([]*EmailAddress, 0, len(e.Identities))
 | 
			
		||||
	for _, ident := range e.Identities {
 | 
			
		||||
		if ident.Revocation != nil {
 | 
			
		||||
			continue
 | 
			
		||||
		}
 | 
			
		||||
		email := strings.ToLower(strings.TrimSpace(ident.UserId.Email))
 | 
			
		||||
		for _, e := range userEmails {
 | 
			
		||||
			if e.Email == email {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user