Temporary-containers: v0.51 - Cookies feature not working?

Created on 17 Feb 2018  路  4Comments  路  Source: stoically/temporary-containers

  • Temporary Containers Version: 0.51 0.53 (still happens on this version)
  • Firefox Version: 58.0.2
  • Operating System + Version: Windows 10
  • Non-default Options/Preferences in Temporary Containers: Automatic Mode on
  • Other installed Add-ons + Version: Multi-Account Containers

Actual behavior

When attempting to use the "Advanced > Set Cookies" feature, I'm finding that this isn't working correctly, even though the cookie values are stored successfully in the extension's storage.js file.

I'm hoping I am entering the cookie values correctly.

Expected behavior

See steps to reproduce.

Steps to reproduce

  1. Go to the Temporary Containers options page, followed by "Advanced > Set Cookies"
  2. Enter the following values:

Website Pattern: searx.me
expirationDate: 2429913600
name: oscar-style
url: https://searx.me/
value: pointhi

The rest of the fields were unaltered.

  1. Click "Add Rule"
  2. Now, visit https://searx.me. On the homepage, you shouldn't see a black top border and a green X in the middle, but rather a gray top border and a large searx icon. You might need to refresh the page so the cookie takes effect.
  3. In the web inspector's "Storage" tab, no cookies have been written.

Notes

I use similar cookie values in a custom webextension I wrote for Chrome and it works correctly with the following:

    browser.cookies.set({
        url: urlDetails.url,
        name: cookieName,
        value: cookieValue,
        expirationDate: cookieExpiration
    });

So my cookie values should be correct.

Let me know if you need any more info from me.

bug

All 4 comments

Hey, thanks for reporting! You did everything right - but I didn't test expirationDate and it turns out that cookies.set requires a number and it didn't like strings.

Just published version 0.54 - should now work without any changes from your side. Let me know if not.

What's interesting is, that it seems if you directly enter https://searx.me into the addressbar the cookie isn't set fast enough or something and hence a refresh is needed. Did you find a fix for that in your custom webextension? Surfing to http://searx.me works, because then a redirect happens and setting the cookie is fast enough.

Just published version 0.55 and Set Cookies will now modify the request headers too and add the cookie there. This way websites directly see the cookie and act accordingly (like showing the correct style in case of searx.me). Let me know if something doesn't work as expected.

Latest version is working as expected.

Really love this feature! I was thinking about this idea myself, but thought it might be complicated to get this working with Temporary Containers.

Thanks stoically!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Sntchown picture Sntchown  路  4Comments

Gitoffthelawn picture Gitoffthelawn  路  3Comments

anonymous133 picture anonymous133  路  6Comments

mkruer picture mkruer  路  5Comments

Gitoffthelawn picture Gitoffthelawn  路  5Comments