[PR #1747] [MERGED] Add persona CLI command with browser cookie import #4509

Closed
opened 2026-03-15 01:48:30 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ArchiveBox/ArchiveBox/pull/1747
Author: @pirate
Created: 12/31/2025
Status: Merged
Merged: 12/31/2025
Merged by: @pirate

Base: devHead: claude/archivebox-browser-cookies-import-F1ceB


📝 Commits (2)

  • 73425fa Add persona CLI command with browser cookie import
  • 3659ade Fix path traversal vulnerabilities in persona management

📊 Changes

4 files changed (+879 additions, -1 deletions)

View changed files

📝 archivebox/cli/__init__.py (+1 -0)
archivebox/cli/archivebox_persona.py (+623 -0)
📝 archivebox/plugins/chrome/chrome_utils.js (+1 -1)
archivebox/plugins/chrome/extract_cookies.js (+254 -0)

📄 Description

  • Add archivebox persona create/list/update/delete commands
  • Support --import=chrome|firefox|brave to copy browser profile
  • Extract cookies via CDP to generate cookies.txt for non-browser tools
  • Fix JSDoc comment parsing issue in chrome_utils.js

Summary by cubic

Adds a new persona CLI to manage browser profiles for archiving, with one-step import from Chrome/Firefox/Brave and automatic cookies.txt generation via CDP. Enables authenticated, headless archiving without manual cookie exports, and hardens persona management with strict path validation to prevent traversal.

  • New Features

    • New command: archivebox persona create/list/update/delete
    • --import=chrome|firefox|brave copies the default browser profile into the persona
    • Extracts cookies via CDP and writes Netscape cookies.txt per persona
    • JSONL I/O for list/update/delete with filters, limit, dry-run, and --yes
    • Detects browser profiles on macOS/Linux/Windows
  • Bug Fixes

    • Added input validation and path safety to block path traversal in create/rename/delete
    • Fixed JSDoc comment in chrome_utils.js to prevent parsing issues

Written for commit 3659adeb7e. Summary will update on new commits.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ArchiveBox/ArchiveBox/pull/1747 **Author:** [@pirate](https://github.com/pirate) **Created:** 12/31/2025 **Status:** ✅ Merged **Merged:** 12/31/2025 **Merged by:** [@pirate](https://github.com/pirate) **Base:** `dev` ← **Head:** `claude/archivebox-browser-cookies-import-F1ceB` --- ### 📝 Commits (2) - [`73425fa`](https://github.com/ArchiveBox/ArchiveBox/commit/73425fa984e9c935a32df4f2ac928878a4a769c3) Add persona CLI command with browser cookie import - [`3659ade`](https://github.com/ArchiveBox/ArchiveBox/commit/3659adeb7ea93ed5b57dcb8fe4bb3dbc517c36d8) Fix path traversal vulnerabilities in persona management ### 📊 Changes **4 files changed** (+879 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `archivebox/cli/__init__.py` (+1 -0) ➕ `archivebox/cli/archivebox_persona.py` (+623 -0) 📝 `archivebox/plugins/chrome/chrome_utils.js` (+1 -1) ➕ `archivebox/plugins/chrome/extract_cookies.js` (+254 -0) </details> ### 📄 Description - Add `archivebox persona create/list/update/delete` commands - Support `--import=chrome|firefox|brave` to copy browser profile - Extract cookies via CDP to generate cookies.txt for non-browser tools - Fix JSDoc comment parsing issue in chrome_utils.js <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Adds a new persona CLI to manage browser profiles for archiving, with one-step import from Chrome/Firefox/Brave and automatic cookies.txt generation via CDP. Enables authenticated, headless archiving without manual cookie exports, and hardens persona management with strict path validation to prevent traversal. - **New Features** - New command: archivebox persona create/list/update/delete - --import=chrome|firefox|brave copies the default browser profile into the persona - Extracts cookies via CDP and writes Netscape cookies.txt per persona - JSONL I/O for list/update/delete with filters, limit, dry-run, and --yes - Detects browser profiles on macOS/Linux/Windows - **Bug Fixes** - Added input validation and path safety to block path traversal in create/rename/delete - Fixed JSDoc comment in chrome_utils.js to prevent parsing issues <sup>Written for commit 3659adeb7ea93ed5b57dcb8fe4bb3dbc517c36d8. Summary will update on new commits.</sup> <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-15 01:48:30 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/ArchiveBox#4509
No description provided.