Skip to content

bitcoin-core-sv2: document IPC socket trust assumptions and log the serving uid - #838

Open
plebhash wants to merge 3 commits into
stratum-mining:mainfrom
plebhash:2026-09-07-doc-bitcoin-core-assumptions
Open

bitcoin-core-sv2: document IPC socket trust assumptions and log the serving uid#838
plebhash wants to merge 3 commits into
stratum-mining:mainfrom
plebhash:2026-09-07-doc-bitcoin-core-assumptions

Conversation

@plebhash

@plebhash plebhash commented Sep 7, 2026

Copy link
Copy Markdown
Member

close #835

The Bitcoin Core IPC transport carries no authentication: the runtimes
trust whatever process listens at the configured node.sock path. Read
the peer credentials right after connecting and log the uid, so an
operator can confirm from the logs that the socket is served by the
user running their node.

The line is informational only. Securing the socket directory remains
a deployment requirement, now stated in the unix_capnp module docs.
State once, in the crate README, what the IPC connection assumes: the
directory holding node.sock must be owned by the user running Bitcoin
Core and not writable by others, and the application should run as
that user.

Bitcoin Core's defaults already guarantee this and its own IPC clients
rely on the same invariant, so no client-side check is added. A local
user who can write to the data directory already controls the node
through settings.json, wallets and the chainstate. Mention the uid log
line as the way to verify a deployment.
Every place an operator chooses a Bitcoin Core data directory for IPC
now points at the Socket Trust section of the bitcoin-core-sv2 README:
the data_dir comments in the Pool, JDC and JDS config examples, the
matching README parameter lists, the JDS README, and the Docker README,
which also explains why the logged uid differs from the container's
root uid.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

authenticate or reject replaceable Bitcoin Core IPC endpoints

1 participant