Skip to content

Commit

Permalink
Work-around Message-IDs that are brokenly in the form <id@@Domain>
Browse files Browse the repository at this point in the history
Fixes issue #962
  • Loading branch information
jstedfast committed Oct 15, 2023
1 parent 7dc832b commit 79046cd
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions MimeKit/Utils/ParseUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -493,6 +493,12 @@ public static bool TryParseMsgId (byte[] text, ref int index, int endIndex, bool
token.Append ('@');
index++;

// Note: some Message-Id's are broken and in the form "<local-part@@domain>"
//
// See https://github.com/jstedfast/MimeKit/issues/962 for details.
while (index < endIndex && text[index] == (byte) '@')
index++;

if (!SkipCommentsAndWhiteSpace (text, ref index, endIndex, throwOnError))
return false;

Expand Down

0 comments on commit 79046cd

Please sign in to comment.