Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

header key contains invalid characters #478

Open
digrouz opened this issue May 23, 2024 · 3 comments
Open

header key contains invalid characters #478

digrouz opened this issue May 23, 2024 · 3 comments

Comments

@digrouz
Copy link

digrouz commented May 23, 2024

Hello,

I'm trying to move some email from other accounts into my proton account using Thunderbird / Evolution through proton-bridge 3.11.0.

For some emails I get the following error:

ERRO[May 23 18:26:58.058] Command failed                                cmd="APPEND 
'3fMafAzf09roX8CpZDkW+Y7VCzJd7XNbG6/8S2Y5N3A=' Flags='[\\SEEN]' DateTime='2005-03-26 20:55:42 +0000 zone'" 
error="header key contains invalid characters" pkg=gluon/session session=295

Here are headers of one by example:

  From HIDDENSENDER sat mar 26 20: 55:42 2005
  X-Mozilla-Keys:
  Message-Id: <[[email protected]](mailto:[email protected])>
  Reçu: from 82.174.205.189 by by10fd.bay10.hotmail.msn.com with HTTP; Sat, 26 Mar 2005 20:55:42 GMT
  Content-Transfer-Encoding: 8bit
  X-Originating-Ip: [82.174.205.189]
  X-Priority: 3
  X-Msmail-Priority: Normal
  X-Originating-Email: [[HIDDENSENDER](mailto:HIDDENSENDER)]
  X-Mimeole: Produced By Microsoft MimeOLE V6.00.2900.2180
  X-Sender: [HIDDENSENDER](mailto:HIDDENSENDER)
  De: 
  À:
  Objet: ezfezrfdezrd
  Date: Sat, 26 Mar 2005 20:55:42 +0000 (26/03/2005 21:55:42)
  Mime-Version: 1.0
  Content-Type: text/plain; format=flowed; charset="iso-8859-1"
  X-Stn-Info:
  X-Evolution-Source: a4ce216a997c7574a20970c4926556d9d4cd5a5a

How can I solve it ?

@digrouz
Copy link
Author

digrouz commented May 23, 2024

just tested with 3.11.1, i have the same behavior

@zwets
Copy link

zwets commented May 23, 2024

I would guess the cedille in Reçu and the grave in À are the culprits. As far as I can tell, the keys of email headers must still be 7-bit ASCII, even if the header values can be UTF-8 (provided all SMTP relays in the chain support this).

I'm especially surprised to see that "À:" header, because the "To:" header (with the literal key To:) is governed by several (age old) RFCs. Just out of curiosity, where do these translated headers come from?

@digrouz
Copy link
Author

digrouz commented May 23, 2024

seems like it's Evolution that translates some headers, looking at the same email inside thunderbird, headers looks like following:

    X-Mozilla-Keys:                                                                                 
    Message-ID: <[email protected]>
    Received: from 82.174.205.189 by by10fd.bay10.hotmail.msn.com with HTTP; Sat, 26 Mar 2005 20:55:42 GMT
    Content-Transfer-Encoding: 8bit
    X-Originating-IP: [82.174.205.189]
    X-Priority: 3
    X-MSMail-Priority: Normal
    X-Originating-Email: [HiddenSender]
    X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
    X-Sender: HiddenSender
    From: "HiddenSender" <HiddenSender>
    To: HIDDENRECEIVER
    Subject: ezfezrfdezrd
    Date: Sat, 26 Mar 2005 20:55:42 +0000
    MIME-Version: 1.0
    Content-Type: text/plain;
        format=flowed;
        charset="iso-8859-1"
    X-Stn-Info:  

there, no "ç" neither "à".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants