- All dependencies to current releases (97 known vulnerabilities -> 0), Python 3.14, uv pinned, requirements-test.txt, lxml/dateutil pinned - CSRF tokens on admin forms, logout and IndieAuth consent - IndieAuth client and crosspost link-card fetches via safe_get - FLASK_DEBUG/FLASK_ENV default off/production; image sets them - Foreign keys enforced on pooled connections; migration 018 removes orphans - Rate limits shared across processes (rate_limits, migration 019) - datetime.utcnow() and sqlite3 default adapters replaced - compose.yaml fixed; duplicate dev_auth.py and test.ini removed Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
3.0 KiB
v2.11.0: Maintenance release
Dependency upgrades and the five High items in the backlog (all re-checked against the code first and still present).
Dependencies
pip-audit on the v2.10.2 set found 97 published vulnerabilities in eight
packages (Pillow 64, PyJWT 22, gunicorn 4, Flask 2, Markdown 2,
python-dotenv 2, pytest 2, pillow-heif 1). All direct dependencies were moved
to their current minor series (requirements.txt); the new set has no known
vulnerabilities. Python moved from 3.11 to 3.14 (python:3.14-slim); the
whole suite passes with -W error::DeprecationWarning.
requirements-test.txt(pytest, pytest-mock) is installed by the Containerfile test stage; pytest left the runtime requirements.lxmlandpython-dateutilare pinned (used directly, previously only transitive).uvis pinned to 0.9.28 in the Containerfile.datetime.utcnow()(34 calls instarpunk/, more in tests) becamedatetime.now(timezone.utc).replace(tzinfo=None): same naive-UTC values. sqlite3's default datetime adapters, deprecated in 3.12, are registered explicitly instarpunk/database/__init__.pywith the same output.
High backlog items
- Foreign keys.
PRAGMA foreign_keys=ONon every pooled connection (database/pool.py); all deletes of notes, media and WebSub subscriptions go through the pool. Every foreign key isCASCADEorSET NULL, so no delete can be blocked. Migration 018 removes orphans (production: threenote_tagsrows from hard-deleted notes). Crosspost rows still have no foreign key on purpose. - CSRF.
starpunk/csrf.py: token = HMAC-SHA256(SECRET_KEY, "csrf:" + starpunk_session cookie);before_requestchecks thecsrf_tokenfield orX-CSRF-Tokenheader on every admin POST,auth.logoutandindieauth.approve; 400 otherwise. All 12 POST forms carry it.CSRF_ENABLED(default true); test apps turn it off unless they set it. - Fetchers.
indieauth.fetch_client_redirect_urisandsyndication._fetch_publicusewebmention_ssrf.safe_get(per-hop checks, DNS pinning, hard deadline).safe_getgainedtruncatefor reads that stop at the size limit. - Debug default.
FLASK_DEBUGdefaults to 0 andFLASK_ENVto production; the runtime image sets both. - Shared rate limits.
SharedRateLimiterkeeps sliding-window counters inrate_limits(migration 019): current window plus the previous one weighted by overlap. Used by/webmention(per IP and per source domain) and/websub; old windows are pruned every 200 calls.
Housekeeping
compose.yaml no longer pins 0.6.0 or sets VERSION/ENVIRONMENT; the
unused root dev_auth.py and the committed test.ini were removed.
Tests
New: tests/test_csrf.py, tests/test_foreign_keys.py,
tests/test_shared_rate_limit.py, IndieAuth client-metadata tests through the
fetcher (including a redirect to a private address). Crosspost tests route
link-card fetches through the fetcher's transport. Full suite: 1264 passed
on Python 3.14.