A Firefox browser extension that extracts cookies from LeetCode and saves them to a file.
- Only runs on the LeetCode website (https://leetcode.com/)
- Extracts cookies from the site
- Prints cookie key-value pairs to the console
- Saves cookies to a file named
leetcode_cookie_{current_date_time}.txt
- Open Firefox and navigate to
about:debugging
- Click on "This Firefox" in the left sidebar
- Click on "Load Temporary Add-on..."
- Navigate to the directory containing this extension and select the
manifest.json
file - The extension will be loaded temporarily and will be removed when Firefox is closed
- Zip the contents of this directory (manifest.json, cookie.js, and any other files)
- Open Firefox and navigate to
about:addons
- Click the gear icon and select "Install Add-on From File..."
- Select the zip file you created
- Follow the prompts to complete installation
If you'd like to add an icon to the extension:
- Create a 48x48 pixel PNG image named
icon.png
- Place it in the same directory as the manifest.json file
- Update the manifest.json file to include an "icons" section with a reference to your icon file
- Navigate to any page on https://leetcode.com/
- The extension will automatically:
- Extract cookies from the site
- Print them to the console (View > Browser Tools > Web Developer Tools > Console)
- Save them to a file named
leetcode_cookie_{current_date_time}.txt
in your downloads folder
This extension requires the following permissions:
cookies
: To access and extract cookies from LeetCodestorage
: To access localStorage for any cookie-related datadownloads
: To save the extracted cookies to a file*://leetcode.com/*
: To only run on LeetCode website
This extension extracts and saves cookies which may contain sensitive information. The data is saved locally to your computer and is not transmitted to any external servers. However, be cautious about sharing the saved cookie files as they may contain your session information.