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

bug: addressParser does not check for edge case with @ symbol in comment/name portion #1707

Open
titanism opened this issue Jan 6, 2025 · 2 comments

Comments

@titanism
Copy link
Contributor

titanism commented Jan 6, 2025

const addressParser = require('nodemailer/lib/addressparser');
console.log('addresses', addressParser('foo @ beep <foo@beep.com>'));
addresses [
  {
    parts: {
      name: null,
      address: [Object],
      local: [Object],
      domain: [Object],
      comments: [Array]
    },
    type: 'mailbox',
    name: null,
    address: 'foo@beep',
    local: 'foo',
    domain: 'beep',
    comments: '',
    groupName: null
  }
]

You can see the domain portion returns beep instead of beep.com. True, it does not contain surrounding quotes " but perhaps we should account for this edge case, as it appears it passes Gmail validation.

cc @andris9

Copy link
Contributor

github-actions bot commented Feb 6, 2025

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@titanism
Copy link
Contributor Author

titanism commented Feb 6, 2025

Bump

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

1 participant