Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Fix not allowed encoding of content-transfer-encoding and content-type headers in single part encoded mails #5140

Closed
wants to merge 10 commits into from

Conversation

2DivisionsByZero
Copy link
Contributor

for single-part mime mails.

See #5128

Requires #5303
Needs to be adapted if #5291 is merged.

2DivisionsByZero added 2 commits September 19, 2013 22:35
*
* @param string $transferEncoding
* @throws Exception\InvalidArgumentException
* @return ContentTransferEncoding
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@return self

* @link http://github.com/zendframework/zf2 for the canonical source repository
* @copyright Copyright (c) 2005-2013 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
* @package Zend_Mail
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@samsonasik You are missing capabalities :) Where are you comment about @package ...

@2DivisionsByZero Please remove package, subpackage and category

@2DivisionsByZero
Copy link
Contributor Author

@Maks3w @samsonasik Is the request OK now?

@samsonasik
Copy link
Contributor

👍


public function setEncoding($encoding)
{
// This header must be always in US-ASCII
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather throw an exception here, instead of silently ignoring the setting (if possible).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not changed because it should not be changed regardless what encoding the rest of the message is changed to.
Similar to ContentType.

- do simple in_array comparison for transfer encoding
- remove to many spaces befor equal sign
- use camelCase var names
@2DivisionsByZero
Copy link
Contributor Author

@DASPRiD @Maks3w OK now?

@ghost ghost assigned Maks3w Oct 18, 2013
@2DivisionsByZero
Copy link
Contributor Author

@DASPRiD @Maks3w ping?


namespace Zend\Mail\Header;

use Zend\Mail\Headers;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unused

@Maks3w
Copy link
Member

Maks3w commented Oct 20, 2013

I've open #5303 for fix the main issue related with the cast to string. That PR makes unnecessary the changes of this PR in Zend\Mail\Message.

Obviously #5303 needs to be merged before this PR.

@Maks3w
Copy link
Member

Maks3w commented Oct 20, 2013

Finally header classes needs to be adapted for the future #5291 since introduce the same bug about headerline split

Maks3w added a commit that referenced this pull request Oct 20, 2013
@Maks3w Maks3w closed this Oct 20, 2013
weierophinney pushed a commit to zendframework/zend-mail that referenced this pull request May 14, 2015
weierophinney pushed a commit to zendframework/zend-mail that referenced this pull request May 14, 2015
weierophinney pushed a commit to zendframework/zend-mail that referenced this pull request May 14, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants