Skip to content

feat: add macOS and Linux support for browser cookie extraction #17

Description

@Jatin-Shihora

The browser cookie extraction currently only works on Windows. macOS and Linux users are forced to use manual cookie entry, which requires opening DevTools, finding the cookies tab, and copy-pasting two values. This is the biggest friction point for non-Windows users.

What should happen
Extend browser_cookies.py to support Chrome/Edge/Brave cookie extraction on macOS and Linux.

Things to consider

  • Cookie storage locations differ per OS:
    • macOS: ~/Library/Application Support/Google/Chrome/Default/Cookies (SQLite, encrypted with Keychain)
    • Linux: ~/.config/google-chrome/Default/Cookies (SQLite, encrypted with GNOME Keyring or KWallet)
  • macOS encryption uses the system Keychain. You'll need security find-generic-password or the keyring Python package to get the decryption key
  • Linux encryption uses PBKDF2 with a key from the system keyring (GNOME Keyring, KWallet, or a hardcoded fallback key)
  • The current Windows implementation uses Chrome DevTools Protocol (CDP) to grab cookies from a running browser. This approach also works on macOS/Linux and might be simpler than dealing with encrypted SQLite databases
  • Test on actual macOS and Linux machines. Cookie formats and encryption change between browser versions
  • Consider adding this as a separate module per platform to keep the code organized

Note: I have tested things out in windows. So support from other OS users will help a lot to make sure things are proper in Mac and Linux!

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestgood first issueGood for newcomershelp wantedExtra attention is neededhigh priorityThese types of issues are important and will get priority review.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions