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

update mail parsing

parent 0143eb54
Branches
Tags
No related merge requests found
......@@ -317,23 +317,10 @@ class IncomingMail {
else if signedStrings.count > 1 {
text = signedStrings.joined(separator: "\r\n")
}
text = text?.replacingOccurrences(of: " =\r\n", with: "\r\n")
text = text?.replacingOccurrences(of: "=\r\n", with: "\r\n")
if let t = text {
var newText = t
while newText.hasSuffix("\r\n") {
newText = String(newText.dropLast())
}
newText = newText + "\r\n"
print(newText)
text = newText
}
print(text)
if let signedData = text?.data(using: .utf8){
for sig in signaturesRaw {
if let signature = sig.data(using: .utf8), let adr = from?.mailbox {
for id in fromKeyIds {
print("Verify for id: \(id)")
if inlineSigned {
signedObject = pgp.verify(data: signedData, attachedSignature: nil, verifyId: id, fromAdr: adr)
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment