Rayrun
← Back to Discord Forum

Identifying cookies placed via Javascript

Hi all,

I'm currently busy creating a script in Python to identify all cookies of a website. While using the BrowserContext, StorageState and request header functionalities, I'm able to retrieve the cookies set via http headers. However, cookies placed via Javascript files are displayed as cookies set by the host itself (e.g. _gid cookies loaded via https://www.google-analytics.com/analytics.js are displayed as if they are initiated by the root domain, while they are loaded via external resources)

Is there a way to identify all the script files which place cookies in browsers?

This thread is trying to answer question "Is there a way to identify all the script files which place cookies in browsers?"

3 replies

Related Discord Threads

TwitterGitHubLinkedIn
AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email luc@ray.run.