Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6897397
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T07:09:50+00:00 2026-05-27T07:09:50+00:00

We have multiple copies of a web-app that is deployed on multiple paths on

  • 0

We have multiple copies of a web-app that is deployed on multiple paths on the same domain.
Example:

  • http://mydomain.com/abc
  • http://mydomain.com/xyz
  • http://mydomain.com/abc123

Each instance maintains a set of cookies each one defines its path as "/" + .getWebDirRoot() – i.e. /abc, /xyz, /abc123

When performing the following flow:

  • Login to http://mydomain.com/abc
  • Perform some activity
  • Logout
  • Login to http://mydomain.com/abc123
  • Perform some activity <– Failure

The last step fails since IE sent us the incorrect cookie – it sends the one for http://mydomain.com/abc instead of the one for http://mydomain.com/abc123

This does not happen in FireFox. (And I haven’t tried any other browser).

Is this a known behavior of IE (I tested IE9 and IE8)?
Is there a way to overcome it (in a programmatic manner)?

Note: Just to clarify, this does not happen when switching from http://mydomain.com/abc to http://mydomain.com/xyz – the behavior is strictly restricted to flows where currentUrl.startswith(urlAssociatedWithCookie) == true

I checked the behavior using Fiddler – I clearly see the HTTP request for abc123 sent with the value of the cookie belonging to abc.

I also checked the cookies on FireFox and they are as expected – one created per path.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T07:09:51+00:00Added an answer on May 27, 2026 at 7:09 am

    After investigating for more than a day and looking everywhere for specification on IE’s behaviour I came up with nothing – apart from the understanding that when IE sees a cookie from domain xyz and path abc, it will send it on any request sent to any URL starting with the same domain and path, e.g. `http://xyz/abc123′.

    So eventually what I did was change my cookie creation, and instead of:

    Name: mycookie
    Path: /abc
    

    I now create the following:

    Name: mycookie
    Path: /abc/
    

    This solved the problem with no ricochetes – the cookie is saved succesfuly on the client and the correct cookie is always sent to the server.


    Note: I checked the RFC for HTTP Cookies and found this:

    A request-path path-matches a given cookie-path if at least one of
    the following conditions holds:

    o The cookie-path and the request-path are identical.

    o The cookie-path is a prefix of the request-path, and the last
    character of the cookie-path is %x2F ("/").

    o The cookie-path is a prefix of the request-path, and the first
    character of the request-path that is not included in the cookie-
    path is a %x2F ("/") character.

    The scenario that should have applied here is the 3rd, but it looks like IE does not comply with the RFC on this case …

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have multiple config files (app.DEV.config, app.TEST.config, etc) and a pre-build event that copies
I usually have multiple copies of a project, for example: a copy of the
I have a web page that sends email to multiple users (online distribution list).
I would like to deploy multiple independent copies of a particular web-app on the
So I have multiple copies of the same database. Some of the tables are
If I have multiple SVN working copies checked out to my local PC, what's
I have multiple classes that all derive from a base class, now some of
I have multiple threads (C# application running on IIS) running that all need to
We have a desktop app that allows users to fill in a questionnaire. For
I have an API that services a web-based plugin for processing email. The API

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.