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

Fix #25; Skip empty continuation lines #145

Conversation

AdrienClairembault
Copy link
Contributor

Q A
Documentation no
Bugfix yes
BC Break no
New Feature no
RFC no
QA no

Description

The fix introduced in zendframework/zend-mail#196 allow a single empty continuation line in the headers.

The following example will be considered as valid:

From: user@example.com
To: userpal@example.net
Subject: This is your reminder
[SPACE]
  about the football game tonight 
Date: Wed, 20 Oct 2010 20:53:35 -0400 

But not these two:

From: user@example.com
To: userpal@example.net
Subject: This is your reminder
[SPACE]
  about the football 
[SPACE]
  game tonight 
Date: Wed, 20 Oct 2010 20:53:35 -0400 
From: user@example.com
To: userpal@example.net
Subject: This is your reminder
[SPACE]
[SPACE]
  about the football game tonight 
Date: Wed, 20 Oct 2010 20:53:35 -0400 

While the RFC indicate these empty continuation lines are no longer legal, it also recommend that they should just be ignored and not stop the message from being parsed:

The best handling of this example is for a message parsing engine to behave as if line {4}
were not present in the message

With these changes all empty continuation lines will be ignored so that the 3 example above will all be considered as valid and parsed accordingly.

@AdrienClairembault AdrienClairembault marked this pull request as draft March 11, 2021 14:48
@AdrienClairembault AdrienClairembault force-pushed the fix/multiple-empty-continuation-lines branch 2 times, most recently from 9d8382d to 043e977 Compare March 11, 2021 14:57
Signed-off-by: AdrienClairembault <aclairembault@teclib.com>
@AdrienClairembault AdrienClairembault force-pushed the fix/multiple-empty-continuation-lines branch from 043e977 to fc002f8 Compare March 11, 2021 15:00
@AdrienClairembault AdrienClairembault marked this pull request as ready for review March 11, 2021 15:01
@glensc
Copy link
Contributor

glensc commented Mar 11, 2021

@AdrienClairembault (for the future): avoid references in commit messages. Especially if you rebase and force push. These create reference noise for every push:

better keep ticket, commit, PR references in PR body itself.

@glensc
Copy link
Contributor

glensc commented Mar 12, 2021

@Slamdunk do you have a timeline or power to make this into releases? for this and #140?

@Slamdunk
Copy link
Contributor

Yes I do, but I need to have a chat with @laminas TSC on how to maintain laminas repos, as I already saw myself having different opinion on how releases should be managed.
I have to say this will take time, sorry

@Slamdunk Slamdunk added this to the 2.14.0 milestone Mar 15, 2021
@Slamdunk Slamdunk added the Bug Something isn't working label Mar 15, 2021
@Slamdunk Slamdunk merged commit 9a2d989 into laminas:2.14.x Mar 15, 2021
@glensc
Copy link
Contributor

glensc commented Mar 15, 2021

Thanks, @Slamdunk! 🥳 🎉

DominicFath added a commit to casasoftch/laminas-mail that referenced this pull request Sep 17, 2021
artemii-karkusha pushed a commit to artemii-karkusha/laminas-mail that referenced this pull request May 24, 2023
…mpty-continuation-lines

Fix laminas#25; Skip empty continuation lines
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants