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
cognito/ses: "Provided From email address is invalid" when using email address for from_name #18903
Labels
Comments
ekeyser
added
bug
This issue is a bug.
needs-triage
This issue or PR still needs to be triaged.
labels
Feb 9, 2022
NGL321
added
p1
and removed
needs-triage
This issue or PR still needs to be triaged.
labels
Feb 14, 2022
4 tasks
mergify bot
pushed a commit
that referenced
this issue
Dec 19, 2022
) Closes #18903 When `fromName` of `UserPoolEmail.withSES()` does not comply RFC 5322 atom or quoted-string, it will be quoted or mime-encoded. For example: |`fromName`|Template|Description| |-|-|-| |`'simple atom'`|`"simple atom <address@example.com>"`|as is| |`'"quoted string"'`|`"\"quoted string\" <address@example.com>"`|as is| |`'あいう'`|`"=?UTF-8?B?44GC44GE44GG?= <address@example.com>"`|mime encode (RFC 2047)| |`'name@company'`|`"\"name@company\" <address@example.com>"`|make quoted-string| For details, see [RFC 5322 Section 3.4](https://www.rfc-editor.org/rfc/rfc5322#section-3.4) and [RFC 2047](https://www.rfc-editor.org/rfc/rfc2047) ---- ### All Submissions: * [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) ### Adding new Construct Runtime Dependencies: * [ ] This PR adds new construct runtime dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-construct-runtime-dependencies) ### New Features * [ ] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)? * [ ] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)? *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
|
brennanho
pushed a commit
to brennanho/aws-cdk
that referenced
this issue
Jan 20, 2023
…#23227) Closes aws#18903 When `fromName` of `UserPoolEmail.withSES()` does not comply RFC 5322 atom or quoted-string, it will be quoted or mime-encoded. For example: |`fromName`|Template|Description| |-|-|-| |`'simple atom'`|`"simple atom <address@example.com>"`|as is| |`'"quoted string"'`|`"\"quoted string\" <address@example.com>"`|as is| |`'あいう'`|`"=?UTF-8?B?44GC44GE44GG?= <address@example.com>"`|mime encode (RFC 2047)| |`'name@company'`|`"\"name@company\" <address@example.com>"`|make quoted-string| For details, see [RFC 5322 Section 3.4](https://www.rfc-editor.org/rfc/rfc5322#section-3.4) and [RFC 2047](https://www.rfc-editor.org/rfc/rfc2047) ---- ### All Submissions: * [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) ### Adding new Construct Runtime Dependencies: * [ ] This PR adds new construct runtime dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-construct-runtime-dependencies) ### New Features * [ ] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)? * [ ] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)? *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
brennanho
pushed a commit
to brennanho/aws-cdk
that referenced
this issue
Feb 22, 2023
…#23227) Closes aws#18903 When `fromName` of `UserPoolEmail.withSES()` does not comply RFC 5322 atom or quoted-string, it will be quoted or mime-encoded. For example: |`fromName`|Template|Description| |-|-|-| |`'simple atom'`|`"simple atom <address@example.com>"`|as is| |`'"quoted string"'`|`"\"quoted string\" <address@example.com>"`|as is| |`'あいう'`|`"=?UTF-8?B?44GC44GE44GG?= <address@example.com>"`|mime encode (RFC 2047)| |`'name@company'`|`"\"name@company\" <address@example.com>"`|make quoted-string| For details, see [RFC 5322 Section 3.4](https://www.rfc-editor.org/rfc/rfc5322#section-3.4) and [RFC 2047](https://www.rfc-editor.org/rfc/rfc2047) ---- ### All Submissions: * [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) ### Adding new Construct Runtime Dependencies: * [ ] This PR adds new construct runtime dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-construct-runtime-dependencies) ### New Features * [ ] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)? * [ ] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)? *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What is the problem?
specifying an email address for a from_name parameter results in a broken Cfn parameter for
"From"
.Reproduction Steps
the following python code (but specific to cognito construct):
This results in the below behavior.
What did you expect to happen?
Simply use the email address as the name.
What actually happened?
resulted in the following Cfn template output:
As you can see the
"From"
param is malformed likely due to a string manipulation/prune on the from_name cdk value.CDK CLI Version
1.142.0
Framework Version
No response
Node.js Version
v14.18.1
OS
Linux/Ubuntu 20.04
Language
Python
Language Version
3.8.10
Other information
Now, I know what you're going to say, "Don't put an email address where a name is expected", to which I will direct your attn to exhibit 1: in the AWS console if you navigate to the Messaging tab of the cognito user pool, the
FROM sender name
clearly shows an email address when configured manually. So, regardless of how strict the heuristics are for CDK/Cfn, they should align with what is allowable in the console. :-)The text was updated successfully, but these errors were encountered: