A PostgreSQL password file named .pgpass is attached from a mention
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 84/100
Research direction
Read credential_path in crates/formless-core/src/daemon.rs and builtin in crates/formless-runtime/src/sensitive_paths.rs; compare how both handle .netrc. Add the two named PostgreSQL password-file basenames to both checks. Done when mentions of either file are rejected and an MCP root pointing to one is refused; the issue names no tests.
Written by the indexing model from the issue text.
Description
What is wrong
A PostgreSQL password file is attached from an @ mention. Neither credential check knows the name.
@~/.pgpass and @~/pgpass.conf (the Windows file %APPDATA%\postgresql\pgpass.conf) both pass. The file is ordinary text, so it is inlined into the prompt. Each line is hostname:port:database:username:password.
.netrc is refused. .pgpass is the same kind of file and is not on either list. A copy that lives outside ~ is also attached, because the check is by basename and directory, not by “only in the home directory.”
Where
crates/formless-core/src/daemon.rs,credential_path. The filename list includes.netrc,.npmrc,.pypirc, and.git-credentials. It does not include.pgpassorpgpass.conf. The directory list (.ssh,.aws, …) does not cover a file that sits directly in the home directory or inpostgresql\.crates/formless-runtime/src/sensitive_paths.rs,builtin. The credential-store names include.netrcand_netrc, not.pgpassorpgpass.conf.- Mentions call both.
daemon.rsAttachPathreturns only whencredential_pathisSome, then whenpolicy.classifyis notOrdinary. MCP filesystem exposure usescredential_pathtoo (mcp_catalog.rs).
credential_path lowercases the filename, and builtin does the same, so the gap is the missing names, not case.
Why it matters
~/.pgpass exists so clients can log in without a prompt. Mentioning it sends every saved database password to the model. The guard already exists for .netrc so that kind of file is never attached from a mention.
This is not #2142 (id_ed25519.pub is refused because the private-key prefix also matches the .pub name). This is not #2058 (.env.example refused). This is not #863, which added the mention guard these lists belong to.
Suggested fix
Treat the basenames .pgpass and pgpass.conf like .netrc in both credential_path and sensitive_paths::builtin. @~/.pgpass and @~/AppData/Roaming/postgresql/pgpass.conf should fail the mention with the credential error, and an MCP root that is that file should be refused the same way.
- Dominant language
- Rust
- Stars
- 0
- Forks
- 0
- Avg merge
- 12h 10m
- Merged PRs (30d)
- 780
Getting set up
- Ships a Dockerfile or Docker Compose file
- No pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from athiwatc/formless
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
documentation
Difficulty 1/5 Under an hour Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Maintainers usually reply within 1 day
All issues in athiwatc/formless
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
symposium-dev/symposium#530 ·
Maintainers usually reply within 5 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
topgrade-rs/topgrade#2540 ·
Maintainers usually reply within 1 day
-
Invalid JSON options for ngram and edge_ngram silently use defaultsPossibly taken @Tilendlesa claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
noemaforge/vimanam#153 ·
Maintainers usually reply within 1 day