2026-04-16 17:32:22 +05:30
|
|
|
[build-system]
|
|
|
|
|
requires = ["hatchling"]
|
|
|
|
|
build-backend = "hatchling.build"
|
|
|
|
|
|
|
|
|
|
[project]
|
|
|
|
|
name = "authsome"
|
2026-06-09 13:43:22 +05:30
|
|
|
version = "0.6.3"
|
2026-04-16 17:32:22 +05:30
|
|
|
description = "A portable local authentication library for AI agents and developer tools"
|
|
|
|
|
readme = "README.md"
|
|
|
|
|
license = "MIT"
|
2026-04-17 14:22:10 +05:30
|
|
|
license-files = ["LICENSE"]
|
|
|
|
|
requires-python = ">=3.13"
|
2026-04-16 17:32:22 +05:30
|
|
|
authors = [
|
2026-04-17 14:22:10 +05:30
|
|
|
{ name = "Manoj Bajaj", email = "manojbajaj95@gmail.com" },
|
2026-04-16 17:32:22 +05:30
|
|
|
]
|
|
|
|
|
keywords = ["auth", "credentials", "oauth2", "api-key", "mcp", "agents"]
|
|
|
|
|
classifiers = [
|
|
|
|
|
"Development Status :: 3 - Alpha",
|
|
|
|
|
"Intended Audience :: Developers",
|
|
|
|
|
"License :: OSI Approved :: MIT License",
|
|
|
|
|
"Programming Language :: Python :: 3",
|
2026-04-17 14:22:10 +05:30
|
|
|
"Programming Language :: Python :: 3.13",
|
2026-04-16 17:32:22 +05:30
|
|
|
"Topic :: Security",
|
|
|
|
|
"Topic :: Software Development :: Libraries",
|
|
|
|
|
]
|
|
|
|
|
dependencies = [
|
|
|
|
|
"pydantic>=2.0",
|
2026-05-31 01:41:05 +05:30
|
|
|
"pydantic-settings>=2.0",
|
2026-04-16 17:32:22 +05:30
|
|
|
"requests>=2.28",
|
|
|
|
|
"cryptography>=41.0",
|
|
|
|
|
"keyring>=24.0",
|
2026-04-17 12:43:43 +05:30
|
|
|
"click>=8.0",
|
2026-04-27 14:19:10 +05:30
|
|
|
"loguru>=0.7",
|
2026-04-24 14:49:48 +05:30
|
|
|
"mitmproxy>=11.0",
|
2026-05-05 23:26:14 +05:30
|
|
|
"fastapi>=0.115",
|
|
|
|
|
"uvicorn>=0.30",
|
2026-05-06 15:54:20 +05:30
|
|
|
"python-multipart>=0.0.27",
|
2026-05-12 12:57:01 +05:30
|
|
|
"py-key-value-aio[disk]",
|
2026-05-27 16:02:24 +05:30
|
|
|
"aiosqlite>=0.20",
|
|
|
|
|
"asyncpg>=0.30",
|
2026-05-12 19:18:25 +05:30
|
|
|
"pyjwt>=2.12.1",
|
2026-05-22 18:13:06 +05:30
|
|
|
"argon2-cffi>=25.1.0",
|
2026-05-12 19:18:25 +05:30
|
|
|
"base58>=2.1.1",
|
2026-05-19 12:45:59 +05:30
|
|
|
"posthog>=3.0",
|
feat: add browser SSO via Chrome cookie reading (browser-cookie3)
Enables authenticated access to sites like X/Twitter and LinkedIn that
use browser session cookies rather than OAuth or API keys.
Core logic lives entirely in auth/ — BrowserFlow.run_login() reads
Chrome's on-disk SQLite cookie database via browser-cookie3 (macOS
Keychain / Linux GNOME Keyring / Windows DPAPI), opens the site in the
user's default browser if no valid session exists, then polls until the
required auth cookies appear. No separate Chrome profile, no Playwright.
- auth/browser_cookies.py: read_chrome_cookies(), cookies_are_valid(),
normalize_jsessionid() with lazy browser-cookie3 import
- auth/flows/browser.py: BrowserFlow (begin/resume/refresh) + static
run_login() for CLI use
- auth/models/: AuthType.BROWSER, FlowType.BROWSER, BrowserConfig,
ExtractRule, ConnectionRecord.credentials field
- server/: register flow, header rendering, export branch, BrowserAction
schema, _session_response wiring (~35 lines total)
- cli/main.py: 8-line elif block calling BrowserFlow.run_login()
- Bundled providers: x-browser, linkedin-browser
- 30 new tests in tests/auth/
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Entire-Checkpoint: 3753e27e5941
2026-05-27 12:27:28 +05:30
|
|
|
"browser-cookie3>=0.19",
|
2026-05-28 15:13:56 +05:30
|
|
|
"opentelemetry-api>=1.42.1",
|
|
|
|
|
"opentelemetry-sdk>=1.42.1",
|
2026-06-04 16:14:00 +05:30
|
|
|
"httpx>=0.28.1",
|
2026-04-16 17:32:22 +05:30
|
|
|
]
|
|
|
|
|
|
|
|
|
|
[project.optional-dependencies]
|
|
|
|
|
dev = [
|
|
|
|
|
"pytest>=7.0",
|
2026-05-12 16:14:21 +05:30
|
|
|
"pytest-asyncio>=1.3.0",
|
2026-04-16 17:32:22 +05:30
|
|
|
"pytest-cov>=4.0",
|
2026-06-09 09:06:58 +05:30
|
|
|
"pytest-timeout>=2.4.0",
|
2026-04-17 16:48:24 +05:30
|
|
|
"ruff>=0.9",
|
2026-04-22 16:14:39 +05:30
|
|
|
"ty",
|
2026-05-27 16:09:57 +05:30
|
|
|
"pre-commit>=4.6.0",
|
2026-04-16 17:32:22 +05:30
|
|
|
]
|
|
|
|
|
|
2026-04-17 12:43:43 +05:30
|
|
|
[project.scripts]
|
2026-05-05 23:26:14 +05:30
|
|
|
authsome = "authsome.cli.main:cli"
|
2026-04-17 12:43:43 +05:30
|
|
|
|
2026-04-16 17:32:22 +05:30
|
|
|
[tool.hatch.build.targets.wheel]
|
|
|
|
|
packages = ["src/authsome"]
|
2026-06-09 13:36:17 +05:30
|
|
|
artifacts = ["src/authsome/ui/web/**"]
|
2026-04-16 17:32:22 +05:30
|
|
|
|
2026-06-01 15:43:15 +05:30
|
|
|
[tool.hatch.build.targets.sdist.force-include]
|
|
|
|
|
"src/authsome/ui/web" = "src/authsome/ui/web"
|
|
|
|
|
|
2026-04-16 17:32:22 +05:30
|
|
|
[tool.pytest.ini_options]
|
|
|
|
|
testpaths = ["tests"]
|
|
|
|
|
pythonpath = ["src"]
|
2026-06-09 09:06:58 +05:30
|
|
|
timeout = 30
|
|
|
|
|
timeout_method = "signal"
|
2026-04-17 14:22:10 +05:30
|
|
|
|
|
|
|
|
[tool.coverage.run]
|
|
|
|
|
source = ["authsome"]
|
|
|
|
|
branch = true
|
|
|
|
|
|
|
|
|
|
[tool.coverage.report]
|
|
|
|
|
show_missing = true
|
|
|
|
|
skip_covered = false
|
|
|
|
|
|
|
|
|
|
[tool.ruff]
|
|
|
|
|
line-length = 120
|
|
|
|
|
target-version = "py313"
|
|
|
|
|
|
|
|
|
|
[tool.ruff.lint]
|
2026-06-04 22:22:50 +05:30
|
|
|
select = [
|
|
|
|
|
# pycodestyle
|
2026-06-04 11:50:56 +05:30
|
|
|
"E",
|
|
|
|
|
# Pyflakes
|
|
|
|
|
"F",
|
|
|
|
|
# pyupgrade
|
|
|
|
|
"UP",
|
|
|
|
|
# flake8-bugbear
|
|
|
|
|
"B",
|
|
|
|
|
# flake8-simplify
|
|
|
|
|
"SIM",
|
|
|
|
|
# isort
|
2026-06-04 22:22:50 +05:30
|
|
|
"I",
|
|
|
|
|
# pylint
|
|
|
|
|
"PL"]
|
2026-06-04 11:50:56 +05:30
|
|
|
ignore = ['B008']
|
2026-05-08 13:51:36 +05:30
|
|
|
|
2026-06-04 22:22:50 +05:30
|
|
|
[tool.ruff.lint.per-file-ignores]
|
|
|
|
|
"tests/**/*.py" = ["PLC0415"]
|
|
|
|
|
|
2026-05-08 13:51:36 +05:30
|
|
|
[tool.ruff.lint.mccabe]
|
2026-05-12 19:18:25 +05:30
|
|
|
max-complexity = 20
|
2026-05-17 14:20:56 +05:30
|
|
|
|
|
|
|
|
[dependency-groups]
|
2026-05-17 17:06:44 +05:30
|
|
|
dev = []
|