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

Escape quotation marks when logging SMTP strings #88

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nomis
Copy link
Contributor

@nomis nomis commented Nov 8, 2022

The SMTP command buffer and various other messages logged inside smtp_in.c are wrapped in quotes. If the content contains quotes it becomes very difficult to parse the log correctly because the quoted section can be ended prematurely.

This happens if someone sends JSON to Exim (attempting to exploit a non-SMTP service) with a string like:

{"hello": ["world"]}

The distinguished name and possibly other externally supplied strings enclosed in quotes could also contain quotes.

The SMTP command buffer and various other messages logged inside smtp_in.c
are wrapped in quotes. If the content contains quotes it becomes very
difficult to parse the log correctly because the quoted section can be
ended prematurely.

This happens if someone sends JSON to Exim (attempting to exploit a
non-SMTP service) with a string like:
{"hello": ["world"]}

The distinguished name and possibly other externally supplied strings
enclosed in quotes could also contain quotes.
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

Successfully merging this pull request may close these issues.

1 participant