This is a wierd bug and I wouldn't have believed the symptoms if I hadn't seen it with my own eyes. Consider the following html code: <html> <body> <form> <input value="y"> </form> <a href="http://home.pacbell.net/spmorse/ellis/ellisattack/attack.htm"> click me </a> </body> </html> and the code that it links to (attack.htm) is: <html> <body> <script> document.cookie = "a=b;path=/spmorse/ellis"; alert("cookie="+document.cookie); </script> Cookie Setting Test </body> </html> If you go to attack.htm by clicking on the link, the "a=b" cookie does not get set. You can verify this by using the cookie manager after you get to that page. On the other hand, if you go to it by typing the URL directly into the url line, the cookie does get set. Of course all cookies should be removed (with the cookie manager) prior to each test, otherwise you won't know if a cookie just got set or if you were seeing a previous cookie. Now some clues. 1. If you remove the value= attribute from the input tag (or set the value to ""), then the cookie does get set when the link is clicked. 2. From the debugger I see that the cookie is supposed to be set from the routine nsHTMLDocument::SetCookie. However in the bad case, that routine is never being entered. This is in nsHTMLDocument.cpp which is upstream from the cookie module. Assigning to DOM HTML for starters.
I tested with 07-30-15 build and the cookie is stored in both the cases. 1. load the URL directly. 2. Click on the link to load the URL.
tever, can you reproduce? You were the one who saw the original problem when you tried to verify a different bug.
Steve, I am not able to reproduce this with todays branch on winNT, or todays branch and trunk on linux. But with my experimental mozilla build from the other day (where we originally saw the problem), I can reproduce this. This is running from the linux based g server. Also, I am noticing that I have clipping and pasting the url and pressing enter will cause the cookie not to be set. I actually have to edit the url after clipping in order to get it to set the cookie.
sorry about the typos, what I meant to say was ... Also, I am noticing that if I clip and paste the url and then press enter, the cookie will still not get set. I actually have to edit the url after pasting in order for the cookie to be set
The URL testcase doesn't work anymore.
I think you will need to host the content on your own server to get the right effect. All the info needed is here in the bug.