Rob--W / cookie-manager

Cookie Manager for Firefox (Desktop/Android), Chrome. Supports viewing and editing of cookies and private cookies.
Mozilla Public License 2.0
105 stars 24 forks source link

Feature Request: Search by Creation Date #9

Open Grossdm opened 6 years ago

Grossdm commented 6 years ago

Being able to search for recently created cookies would be very helpful.

You could;

Those are just a couple ideas that come to mind.

TIA

Rob--W commented 6 years ago

Firefox does not tell when a cookie was created. The use case of searching for recently created cookies could be addressed by offering the ability to save cookies, and then the ability to show cookies that differ from the list of saved cookies. You can get a feeling for how this feature could work by using the existing Whitelist feature: Whitelist all cookies, and then search again (with the option Whitelist = no before the "Search" button). Does that address your needs? What's your preferred user interface for this feature?

Test whether private browsing was working properly.

I don't understand what you mean by this?

Grossdm commented 6 years ago

I'm not sure about your whitelist procedure; I'd have to spend some time trying it.

I don't understand your statement that Firefox does not tell when a cookie was created. Within cookies.sqlite I checked the create statement for moz_cookies: CREATE TABLE "moz_cookies" (id INTEGER PRIMARY KEY, baseDomain TEXT, originAttributes TEXT NOT NULL DEFAULT '', name TEXT, value TEXT, host TEXT, path TEXT, expiry INTEGER, lastAccessed INTEGER, creationTime INTEGER, isSecure INTEGER, isHttpOnly INTEGER, inBrowserElement INTEGER DEFAULT 0, CONSTRAINT moz_uniqueid UNIQUE (name, host, path, originAttributes))

So you can see that there is a creationTime column in the moz_cookies table. I tried a little SQLite and made a query that will list the cookies created within an arbitrary time (I chose 10 minutes): SELECT * FROM moz_cookies WHERE datetime(creationtime/1000000, 'UnixEpoch') >= datetime('now', '-10 minutes');

I know that this doesn't fully answer your questions, but I think it's a "proof of concept" for searching cookies by creation time. WRT private browsing I was thinking of looking for cookies created in a private session, and then checking when - or whether - the cookies were deleted.

Grossdm commented 6 years ago

If you don't see a need for my feature request, or if the WebEx APIs are preventing access to the data - should we close this issue? Just trying to keep your repo tidy. 👍

Rob--W commented 6 years ago

@Grossdm Sorry, I forgot to follow up. Please don't close it. Your feature request and suggestions are useful.

I have opened a new feature request at: https://bugzilla.mozilla.org/show_bug.cgi?id=1480046

Grossdm commented 6 years ago

Ah, thank you for your kind words.

😆