ProtonMail / gluon

An IMAP server library written in Go
MIT License
455 stars 27 forks source link

fix(GODT-2929): Fix message hash when text transfer encoding differs #396

Closed LBeernaertProton closed 1 year ago

LBeernaertProton commented 1 year ago

It's possible for an IMAP client to send UTF8 encoded text with different transfer encodings to SMTP and IMAP. Since this hashing function is used to detect duplicates, we need to decode the text before hashing.