# securo-finance/securo — AlpLab Radar Static Code Audit

- Ring: `adopt`
- Category: `other`
- Overall score: `4.0/5`
- Implementation check: `verified`
- Maturity: `active`
- Audited commit: `b910018bab4a` (read-only; nothing from the repository was executed)
- Reviewed at: 2026-12-01T20:26:55Z
- Repository: https://github.com/securo-finance/securo
- Radar entry: https://radar.alplab.co/#repo/securo-finance/securo
- License: `AGPL-3.0`
- CI workflows: `.github/workflows`
- Tags: `self-hosted`, `personal-finance`, `fastapi`, `react`, `postgres`, `mcp`

## Summary

A self-hosted personal finance manager (FastAPI/SQLAlchemy + React/Vite, PostgreSQL+pgvector, Redis, Celery, Docker Compose/Helm) covering accounts, transactions, imports, rules, budgets, assets/portfolio performance, invoicing, multi-workspace auth (passkeys, TOTP, OIDC), bank sync via Pluggy/Enable Banking/SimpleFIN, and an opt-in MCP-gated AI agents module.

## Implementation Check

Every README feature I traced exists in working code: import parsers parse_ofx/parse_qif/parse_camt/parse_csv in backend/app/services/import_service.py, the pure rule engine evaluate_conditions/apply_rule_actions in backend/app/services/rule_engine.py, OIDC/passkeys/2FA in backend/app/api/oidc_auth.py, passkeys.py, two_factor.py, bank providers in backend/app/providers/pluggy.py, enable_banking.py, simplefin.py, and the AGENTS_ENABLED-gated agent runtime in backend/app/agents/runtime/executor.py mounted from backend/app/main.py lifespan.

## When to Use

Use it when you want full ownership of your financial data on your own Docker/Podman infrastructure — transactions, budgets, investments, invoicing, bank sync, and local LLM assistants over MCP. Not when you need a hosted zero-ops product, cannot run Postgres+Redis, or want to build a closed-source SaaS on top (AGPL-3.0).

## Sub-scores

| Dimension | Score |
|---|---|
| quality | 4.5/5 |
| usability | 4.0/5 |
| reliability | 3.0/5 |
| security | 4.5/5 |
| integration | 4.0/5 |

## Code Evidence

backend/app/main.py wires 60+ routers and mounts the agents module only when AGENTS_ENABLED is set, refusing unsafe MCP secrets at startup; backend/app/core/auth.py SessionJWTStrategy.read_token invalidates sessions on password change and UserManager.forgot_password binds recovery tokens to email+password fingerprint; backend/app/core/config.py resolve_secret_key refuses public/default SECRET_KEYs and generates a stored instance key; backend/app/agents/mcp/keys.py resolve_mcp_jwt_secret raises UnsafeMCPSecret on public defaults; backend/mcp_server/auth.py authorize_call re-checks workspace membership and role on every tool call; backend/plugin_runner/sandbox.py run/_prepare gives each plugin its own uid with rlimits and process-group kill, backend/plugin_runner/egress.py EgressProxy._open refuses any host resolving to a private address, and backend/plugin_runner/store.py unpack refuses symlinks/traversal and _check_lockfile permits hash-pinned wheels only; backend/app/services/csv_safety.py csv_safe mitigates CSV formula injection on exports; backend/app/services/attachment_service.py served_headers serves extension-derived content types with X-Content-Type-Options: nosniff; backend/tests/ holds hundreds of test files (SQLite + dedicated Postgres-sharded suites) and .github/workflows/ci.yml backend-shard runs pytest -W error across 4 pgvector-backed shards with a coverage floor of --fail-under=60 plus migration-chain, installer, nginx-config and Helm checks; install.sh generate_env provisions random SECRET_KEY and AGENTS_MCP_JWT_SECRET.

## Issues Found

Minor supply-chain hardening gap: 43 GitHub Actions across .github/workflows/* are tag-pinned rather than SHA-pinned (e.g. actions/checkout@v7 in ci.yml, only astral-sh/setup-uv is commit-pinned); install.sh is a curl|bash pipe installer, though it is tested with stubs in .github/ci/test_install_sh.py and generates random secrets.

## Key Risks

Nothing was executed: the test suite's greenness is inferred from CI configuration and suite size, not observed. Self-hosting needs Docker/Podman, PostgreSQL (pgvector), Redis and Celery; bank sync, FX rates, benchmarks, email and LLM agents each need their own provider keys and are off by default. The plugins feature intentionally runs third-party code, albeit in a well-sandboxed runner (per-plugin uid, egress allowlist, no secrets) that only starts under a compose profile. Frontend locale coverage beyond en/pt and the docs.usesecuro.com guides could not be verified statically.

## Reviewed Files

- `README.md`
- `SECURITY.md`
- `install.sh`
- `docker-compose.prod.yml`
- `.github/workflows/ci.yml`
- `backend/pyproject.toml`
- `backend/app/main.py`
- `backend/app/core/auth.py`
- `backend/app/core/config.py`
- `backend/app/core/row_security.py`
- `backend/app/agents/mcp/keys.py`
- `backend/app/agents/runtime/executor.py`
- `backend/mcp_server/main.py`
- `backend/mcp_server/auth.py`
- `backend/plugin_runner/sandbox.py`
- `backend/plugin_runner/egress.py`
- `backend/plugin_runner/store.py`
- `backend/app/services/transaction_service.py`
- `backend/app/services/rule_engine.py`
- `backend/app/services/csv_safety.py`
- `backend/app/services/attachment_service.py`
- `backend/app/api/transactions.py`
- `backend/tests/conftest.py`
- `frontend/package.json`
- `frontend/vitest.config.ts`
- `frontend/src/App.tsx`
