Overview
Small toolkit for capturing and dumping browser cookies via an embedded browser and then being able to use them from cURL or any way you see fit.
This supports crawling or capturing authenticated web content.
Requirements
Python 3.10 or newer (requires-python in pyproject.toml, aligned with PySide6).
Install
From the repository root:
pip install .
Build
From the repository root, install the build tooling (for example the dev extra, which includes build and twine), then run the packaging script:
pip install -e '.[dev]'
./infrastructure/build.sh
That runs python -m build and writes the wheel and sdist under dist/.
To publish those artifacts to PyPI (after configuring twine credentials), use:
./infrastructure/upload.sh
Tools
-
ct_authenticate: Opens an embedded Chromium window to the given URL. The output should be redirected. Login as necessary and press the "Done" button. -
ct_to_curl: Reads the JSON output fromct_authenticateand printscurlcookie arguments
Example
ct_authenticate https://example.com > session.json
curl -s $(ct_to_curl < session.json) 'https://example.com/'
Tests
pytest
Metadata
Release files for cookietruck 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| cookietruck-0.1.3.tar.gz | 16.8 kB | Without provenance | Details for cookietruck-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| cookietruck-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for cookietruck-0.1.3-py3-none-any.whl |
Total release size: 31.2 kB
Security for cookietruck 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.