Closed
Bug 197203
Opened 23 years ago
Closed 23 years ago
crash if no '@' in From field address
Categories
(MailNews Core :: Composition, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla1.4alpha
People
(Reporter: parish, Assigned: parish)
References
Details
(Keywords: crash, stackwanted)
Attachments
(1 file, 1 obsolete file)
|
661 bytes,
patch
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4a) Gecko/20030313 Netscape6/6.5
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4a) Gecko/20030313
If you use a munged anti-spam address without a '@' in it, Mozilla crashes shen
you click Send.
Reproducible: Always
Steps to Reproduce:
1. Edit your mail account e-mail address, or create a dummy account, and
replace/remove the '@', e.g. parish_AT_ntlworld.com
2. Compose a mail using the munged address for the From
3. Click Send or Send Later.
Actual Results:
Mozilla crashes with an Access violation in msgcompo.dll
Note, this does not happen if you use such an address in the To:/Cc: fields.
Expected Results:
Mail should be sent or saved in Unsent Messages.
Patch on it's way
In msg_generate_message_id(), PL_strchr() returns a null ptr if no '@' in From
address. We don't check for this before incrementing it and passing to
isValidHost() where it crashes.
Attachment #117085 -
Flags: review?(ducarroz)
Comment 2•23 years ago
|
||
Marking NEW since it has a patch.
Severity: normal → critical
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: crash,
stackwanted
Comment 4•23 years ago
|
||
Comment on attachment 117085 [details] [diff] [review]
Check for PL_strchr() returning a null ptr.
R=ducarroz
Attachment #117085 -
Flags: review?(ducarroz) → review+
Attachment #117085 -
Flags: superreview?(sspitzer)
Comment 5•23 years ago
|
||
re-assign to parish@ntlworld.com, since he as a patch.
I'll review and drive this in today, since it is a crasher.
Assignee: ssu → parish
Comment 6•23 years ago
|
||
actually, the patch could just be:
if (host)
++host;
because right after that, we call if (!isValidHost(host)) and return if it
isn't valid, and it will do the right thing if host is null.
I'll attach a modified patch.
Comment 7•23 years ago
|
||
also, use strchr(), instead of PL_strchr() for performance reasons.
Attachment #117085 -
Attachment is obsolete: true
Updated•23 years ago
|
Attachment #117085 -
Flags: superreview?(sspitzer) → superreview-
Comment 8•23 years ago
|
||
parish, thanks for logging the bug and finding the fix.
I'll land the modified patch today.
assigning to 1.4 alpha, and marking "accepted" on parish's behalf.
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla1.4alpha
Comment 9•23 years ago
|
||
I've checked in the patch based on parish's initial patch.
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Summary: Mozilla crashes if no '@' in From field address → crash if no '@' in From field address
Comment 10•23 years ago
|
||
*** Bug 198256 has been marked as a duplicate of this bug. ***
Comment 11•23 years ago
|
||
*** Bug 203375 has been marked as a duplicate of this bug. ***
Comment 12•23 years ago
|
||
*** Bug 205619 has been marked as a duplicate of this bug. ***
Updated•21 years ago
|
Product: MailNews → Core
Updated•17 years ago
|
Product: Core → MailNews Core
You need to log in
before you can comment on or make changes to this bug.
Description
•