Closed
Bug 168629
Opened 23 years ago
Closed 19 years ago
Mozilla incorrectly prompts about submitting to an insecure location from a secure one with base href="https://..."
Categories
(Core Graveyard :: Security: UI, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: sgifford, Assigned: KaiE)
References
()
Details
(Keywords: fixed1.8.1, Whiteboard: [kerh-coz])
Attachments
(3 files, 1 obsolete file)
168 bytes,
text/html
|
Details | |
1.69 KB,
patch
|
rrelyea
:
review+
KaiE
:
superreview+
KaiE
:
approval-branch-1.8.1-
|
Details | Diff | Splinter Review |
1.70 KB,
patch
|
KaiE
:
superreview+
KaiE
:
approval-branch-1.8.1+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2a) Gecko/20020910
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2a) Gecko/20020910
When visiting:
http://redhat.rsc03.net/servlet/website/ResponseForm?koE7iHJoL8kHgKzNkOLRzLimVTTV
and submitting the form, Mozilla warns me that:
"Although this page is encrypted, the information you have entered is to be
sent over an unencrypted connection and could easily be read by a third party.
Are you sure you want to continue sending this information?"
It's clear from the URL, and the Page Info and padlock icon agree, that the page
I'm looking at isn't a secure page.
Reproducible: Always
Steps to Reproduce:
1. Visit:
http://redhat.rsc03.net/servlet/website/ResponseForm?koE7iHJoL8kHgKzNkOLRzLimVTTV
2. Scroll to bottom of page and hit Submit
3.
Actual Results:
The dialog described above comes up.
Expected Results:
Normal page submission.
![]() |
||
Comment 1•23 years ago
|
||
confirming; over to PSM.
Assignee: alexsavulov → ssaux
Severity: normal → major
Status: UNCONFIRMED → NEW
Component: Form Submission → Client Library
Ever confirmed: true
Product: Browser → PSM
QA Contact: vladimire → junruh
Version: other → 2.4
Comment 2•23 years ago
|
||
Evangelism. The same behavior occurs with Nav. 4.7X. It looks like the top line
- <base href="https://www.redhat.com"> needs to synch up with some lines further
down -
<form method="POST"
action="http://redhat.rsc03.net/servlet/campaignrespondent">
Assignee: ssaux → aruner
Component: Client Library → US Ecommerce
OS: Linux → All
Product: PSM → Tech Evangelism
QA Contact: junruh → bclary
Version: 2.4 → unspecified
Reporter | ||
Comment 3•23 years ago
|
||
Although the combination of <base href="https:..."> and <form action="http:...">
is certainly bizarre, I don't think it's illegal, and the error message
displayed by Mozilla is factually incorrect.
We loaded a standard HTTP page, and submitted data to a standard HTTP page. The
<base href="..."> shouldn't enter into things at all.
I don't mind evangelizing RedHat, but I still think this is a bug in Mozilla.
I'll move it back into the PSM component in a few days, unless somebody comes up
with a good reason why this behavior is correct.
Updated•23 years ago
|
Summary: Mozilla incorrectly prompts about submitting to an insecure location from a secure one → rsc03.net - Mozilla incorrectly prompts about submitting to an insecure location from a secure one
Reporter | ||
Comment 4•23 years ago
|
||
See comment #3.
Component: US Ecommerce → Client Library
Product: Tech Evangelism → PSM
Target Milestone: --- → 1.4
Version: unspecified → 2.3
Reporter | ||
Comment 5•22 years ago
|
||
Reporter | ||
Comment 6•22 years ago
|
||
Original Web site no longer exists, but unfortunately the bug still does. I've
created a small test case and attached it.
Summary: rsc03.net - Mozilla incorrectly prompts about submitting to an insecure location from a secure one → Mozilla incorrectly prompts about submitting to an insecure location from a secure one with base href="https://..."
Reporter | ||
Comment 7•22 years ago
|
||
Bug is still present in FireBird 20030703.
Comment 8•21 years ago
|
||
reassign former PSM engineers' bugs to nobody@mozilla.org
Assignee: aruner → nobody
QA Contact: bob → nobody
Target Milestone: 1.4 → ---
Assignee | ||
Comment 9•20 years ago
|
||
new testcase at URL (as bugzilla meanwhile uses https to display its content)
Whiteboard: [kerh-coz]
Comment 10•19 years ago
|
||
*** Bug 328295 has been marked as a duplicate of this bug. ***
![]() |
||
Comment 11•19 years ago
|
||
So... Kai, you have blame for this. Why is this using the baseURI of the document? Shouldn't this use the documentURI or better yet the URI of the document's principal? Using the baseURI here is bogus, imo.
Flags: blocking1.9a1+
Assignee | ||
Comment 12•19 years ago
|
||
We correctly warn that information will be submitted to an insecure destination, so I don't see this bug as critical.
> So... Kai, you have blame for this. Why is this using the baseURI of the
> document?
I don't know, I didn't write it, I probably just moved this code to a new file, if cvs blames me. But I'm ok to work on it.
> Using the baseURI here is bogus, imo.
I agree.
> Shouldn't this use the documentURI
I confirm changing
formURL = document->GetBaseURI();
to
formURL = document->GetDocumentURI();
fixes the bug.
> or better yet the URI of the document's principal?
Instead of the above, I also tried
nsIPrincipal *principal = formNode->GetNodePrincipal();
principal->GetURI(formURL);
and confirm it fixes the bug, too.
However, documentation says, the principal for a node might be null, "in that case the caller should assume that all same-origin checks against this node fail and that this node has no permissions to do anything."
What should we do if the principal is null?
Cancel submit? (which might break sites?)
Or fall back to document URI?
Flags: blocking1.7.13?
![]() |
||
Comment 13•19 years ago
|
||
The only way for a node to have a null principal is if the document it was in has already gone away or if there was an out-of-memory error creating a principal object. So cancelling the submit is the way to go, in my opinion.
On trunk we're going to change things so a node's principal is never null, fwiw.
Also, system principals have no URI; that might need to be accounted for.
Assignee | ||
Comment 14•19 years ago
|
||
> Also, system principals have no URI; that might need to be accounted for.
What does that mean in the context of this bug?
![]() |
||
Comment 15•19 years ago
|
||
That formURL would be null (if the form post is happening in a chrome document). No idea what you want the behavior to be in that case.
Assignee | ||
Comment 16•19 years ago
|
||
> The only way for a node to have a null principal is if the document it was in
> has already gone away or if there was an out-of-memory error creating a
> principal object. So cancelling the submit is the way to go, in my opinion.
If that's the only cases, I agree.
> System principals have no URI if the form post is happening in a chrome
> document. No idea what you want the behavior to be in that case.
I think we should not change current behaviour in that case,
and fall back to the document URI.
Assignee | ||
Comment 17•19 years ago
|
||
Assignee | ||
Updated•19 years ago
|
Attachment #213476 -
Flags: superreview? → superreview?(bzbarsky)
![]() |
||
Comment 18•19 years ago
|
||
Comment on attachment 213476 [details] [diff] [review]
Patch v1
Move the "||" up to the previous line, and sr=bzbarsky
Attachment #213476 -
Flags: superreview?(bzbarsky) → superreview+
Assignee | ||
Comment 19•19 years ago
|
||
Addressing review request, moving forward sr=bzbarsky
Bob, could you please do the peer review?
Attachment #213476 -
Attachment is obsolete: true
Attachment #213482 -
Flags: superreview+
Attachment #213482 -
Flags: review?(rrelyea)
Comment 20•19 years ago
|
||
Comment on attachment 213482 [details] [diff] [review]
Patch v1 b
r=relyea
code implements the recommendation discussed in the bug.
Attachment #213482 -
Flags: review?(rrelyea) → review+
Assignee | ||
Updated•19 years ago
|
Attachment #213482 -
Flags: approval-branch-1.8.1+
Assignee | ||
Comment 21•19 years ago
|
||
Comment on attachment 213482 [details] [diff] [review]
Patch v1 b
There is no nsIContent::GetNodePrincipal on MOZILLA_1_8_BRANCH, we need a different patch if we want to have a fix on that branch, too
Attachment #213482 -
Flags: approval-branch-1.8.1+ → approval-branch-1.8.1-
Assignee | ||
Comment 22•19 years ago
|
||
For the trunk patch we used
nsIPrincipal *principal = formNode->GetNodePrincipal();
For 1.8 branch, can we use this?
nsIPrincipal *principal = document->GetPrincipal();
(marking fixed on trunk)
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
![]() |
||
Comment 23•19 years ago
|
||
> For 1.8 branch, can we use this?
> nsIPrincipal *principal = document->GetPrincipal();
Can and should. ;)
Assignee | ||
Comment 24•19 years ago
|
||
The only difference between the trunk patch and this one is the line that Boris approved in comment 23, therefore I'm marking it as sr=bzbarsky
Approving for 1.8 branch.
Attachment #213691 -
Flags: superreview+
Attachment #213691 -
Flags: approval-branch-1.8.1+
Comment 26•19 years ago
|
||
Too late for a non-critical bug in 1.7.13, will consider for the next release. Does this not affect Firefox as well?
Flags: blocking1.9a1+
Flags: blocking1.7.14?
Flags: blocking1.7.13?
Flags: blocking-aviary1.0.9?
Comment 27•19 years ago
|
||
(In reply to comment #26)
> Does this not affect Firefox as well?
This does affect Firefox.
Updated•9 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•