Browser session based cookies were not cleared after closing Edge

Anonymous
2020-06-24T10:19:14+00:00

I was accessing one website that Expires / Max-Age of cookies are "Session", these cookies contain authentication information of the website.

Theoretically the cookies should be removed once I closed Edge, however after closing & re-opening the Edge and access again the website, I noticed that the cookies are still there.

I checked under both Firefox and Chrome which have no this issue, relevant cookies been cleared once I closed the browser.

I'm wondering whether it's an "optimization" of Edge or it's a defect?

Thanks

Microsoft Edge | Favorites, history, and downloads | Windows 10

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

8 answers

Sort by: Most helpful
  1. Anonymous
    2020-06-24T11:05:24+00:00

    Hi Bianca,

          According the set-cookie documentation https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie, the session cookie was expected to be removed when the browser was closed.

         And the session restore feature https://wiki.mozilla.org/Session\_Restore should only work when the browser crashed, and it was used to restore the tabs not only the session cookie.

    • Expires=<date> Optional
      • The maximum lifetime of the cookie as an HTTP-date timestamp. See Date for the required formatting.

    If unspecified, the cookie becomes a session cookie. A session finishes when the client shuts down, and session cookies will be removed.

    When an Expires date is set, the deadline is relative to the client the cookie is being set on, not the server. - Warning: Many web browsers have a session restorefeature that will save all tabs and restore them next time the browser is used. Session cookies will also be restored, as if the browser was never closed.

    Was this answer helpful?

    6 people found this answer helpful.
    0 comments No comments
  2. Anonymous
    2020-06-24T12:54:34+00:00

    Oh. My pleasure. I hope to help you fix this or answer any confusion you have.

    By default, Edge won't delete cookies when you close the browser so it would be best that you set Edge to what you wanted.

    Hi Bianca,

    When you mentioned "By default, Edge won't delete cookies", does it include cookieExpires / Max-Age = "Session"?

    In fact this property means the cookie won't be persistent and kept in memory of browser only and to be removed once user close the browser.

    The behavior right now is Edge does not delete this kind of cookie.

    Thanks.

    Was this answer helpful?

    3 people found this answer helpful.
    0 comments No comments
  3. Anonymous
    2020-06-28T08:40:19+00:00

    Hi Bianca,

    I tried to reset the settings of my Edge, now I get the expected result.

    What strange was I did not specify any cookie/history setting in Edge, but before it was not working.

    Thanks again for your support! We can close this session.

    Was this answer helpful?

    1 person found this answer helpful.
    0 comments No comments
  4. Anonymous
    2020-06-24T10:33:07+00:00

    Hi Bianca,

    Thanks for your prompt reply. In fact I did not set specific settings in the part you mentioned. Everything's just default.

    I did not set "Clear browsing data on close" for any site.

    I did a double check and I confirm :)

    Was this answer helpful?

    1 person found this answer helpful.
    0 comments No comments
  5. Anonymous
    2020-06-24T10:24:44+00:00

    Hi, I'm Bianca, an Independent Advisor for Microsoft, an expert and a Microsoft user like you. I'm happy to assist you.

    I understand that you wanted to have the cookies deleted when you close Edge but did not happen on your end. There are a lot of possibilities why but let's go over it one by one.

    First, check the Microsoft Edge settings if it is set properly. To do that, follow the steps on this link:

    https://support.microsoft.com/en-us/help/402794...

    I hope that helps, if not please let me know so we can work things out.

    Was this answer helpful?

    0 comments No comments