kooky icon indicating copy to clipboard operation
kooky copied to clipboard

Firefox cookies unable to be found with domain filter

Open DP19 opened this issue 2 years ago • 0 comments

Finding cookies via chrome was working but once I switched to firefox it no longer works.

The sites i'm reading cookies for will set these cookies at a sub-domain like .$env.$tld

When ReadCookies is called for chrome it uses the host_key as the domain which is that sub domain shown above https://github.com/browserutils/kooky/blob/master/internal/chrome/chrome.go#L45

However in the Firefox implementation it's doing a tld domain lookup which only returns and sets the tld on the cookie, which fails the domain filter https://github.com/browserutils/kooky/blob/master/internal/firefox/firefox.go#L51

This is also stored in firefox's sql lite at the sub domain level.

Why do the TLD look-up there? Should this not just return the host as the domain?

DP19 avatar Nov 05 '23 04:11 DP19