Skip to content
Snippets Groups Projects
Commit e25531cd authored by Oliver Wiese's avatar Oliver Wiese
Browse files

fix matching to lastsignedMail

parent 3605642e
Branches
No related tags found
No related merge requests found
...@@ -267,8 +267,8 @@ class IncomingMail { ...@@ -267,8 +267,8 @@ class IncomingMail {
} }
let encState = self.cryptoObj?.encryptionState.rawValue ?? 0 let encState = self.cryptoObj?.encryptionState.rawValue ?? 0
var lastsignedDate: Date? = nil // TODO: Remove from PublicKeyProperty -> Update this in Record file... var lastsignedDate: Date? = nil
if let sigState = self.cryptoObj?.signatureState, sigState == .ValidSignature { if let sigState = self.cryptoObj?.signatureState, sigState == .ValidSignature{
lastsignedDate = self.date lastsignedDate = self.date
} }
var usedAddr = [AddressProperties]() var usedAddr = [AddressProperties]()
...@@ -278,7 +278,11 @@ class IncomingMail { ...@@ -278,7 +278,11 @@ class IncomingMail {
var autocryptPK = [PublicKeyProperties]() var autocryptPK = [PublicKeyProperties]()
for fpr in newAutocrypPublicKeys { for fpr in newAutocrypPublicKeys {
let pk = PublicKeyProperties(fingerprint: fpr, cryptoProtocol: .PGP, origin: .AutocryptHeader, preferEncryption: autocrypt?.prefer_encryption, lastSeenInAutocryptHeader: date, lastSeenSignedMail: nil, secretKeyProperty: nil, usedAddresses: usedAddr) var signed: Date? = nil
if let sigendKeys = self.cryptoObj?.signedKeys, sigendKeys.contains(fpr) {
signed = lastsignedDate
}
let pk = PublicKeyProperties(fingerprint: fpr, cryptoProtocol: .PGP, origin: .AutocryptHeader, preferEncryption: autocrypt?.prefer_encryption, lastSeenInAutocryptHeader: date, lastSeenSignedMail: signed, secretKeyProperty: nil, usedAddresses: usedAddr)
autocryptPK.append(pk) autocryptPK.append(pk)
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment