5

We have a number of sites hanging off a root domain. E.g:

dev.mydomain.co.nz
test.mydomain.co.nz
www.mydomain.co.nz

I monitor my connection to dev.mydomain.co.nz with Fiddler and receive a cookie with a header like:

Set-Cookie: mytest=blah; domain=dev.mydomain.co.nz; path=/

Then in IE10 I use F12 Developer Tools, then select Cache - View cookie information.

It shows me this:

NAME  mytest
VALUE  blah
DOMAIN  mydomain.co.nz 
PATH  / 
EXPIRES  At the end of the Session 

Where'd the "dev" subdomain go?

The weird thing is, if I then make request to test.mydomain.co.nz, it does NOT send the cookie, but a request to dev.mydomain.co.nz DOES send the mytest cookie.

The Resources - Cookies developer tool in Chrome represents the cookies exactly as I'd expect. IE BEHAVES correctly like Chrome, but the developer tools seem to garble the session cookie details.

Is this an IE problem or am I missing something?

Paul Sweatte
  • 24,148
  • 7
  • 127
  • 265
Michael12345
  • 2,520
  • 5
  • 23
  • 41
  • There's no distinction between domains and subdomains in [IE Developer Tools](http://msdn.microsoft.com/en-us/library/dd565626%28VS.85%29.aspx) – Paul Sweatte Aug 26 '13 at 22:27
  • I'm not sure if that is a fact that should be obvious to me from following the link, I can't see anything stating that IE Developer Tools doesn't distinguish between domains and subdomains. However, this has pretty much answered my question so if you want to propose it as an answer I'll accept it. – Michael12345 Sep 12 '13 at 01:16

2 Answers2

3

There's no distinction between domains and subdomains in IE Developer Tools.

References

Paul Sweatte
  • 24,148
  • 7
  • 127
  • 265
  • In my case I'm comfortable that IE itself is behaving correctly, it's just this quirk around subdomains in IE Developer Tools that causes me to load Chrome up if I want to debug cookie handling. – Michael12345 Sep 12 '13 at 02:10
  • Sadly, the links you provided in your answer are dead :( – Euli Feb 21 '20 at 13:10
0

I had a problem vers Domain was localhost or when domain didn't contain TLD.

For IE your domain should have a valid TLD, or leave Domain empty

nmeylan
  • 163
  • 7