nix: the hive's leaf does not read every secret in the store
Six more comments and option descriptions across five modules said the hive's leaf or grant reads every secret in the store. It reads swarm/agents/* and swarm/hives/<hive>/* and nothing else, so they now say that, in the wording the clientCertFile option already used. Also the matrix-ctl check's label no longer calls the hive's leaf store-wide.
This commit is contained in:
parent
f892dc6a19
commit
d39ad6c465
7 changed files with 22 additions and 20 deletions
|
|
@ -193,8 +193,8 @@ in
|
|||
# local reads.
|
||||
#
|
||||
# Its own CN, not the reader's: the reader's leaf carries this hive's
|
||||
# name and its policy reads the whole store, while this principal may
|
||||
# only write one path — which is the entire point of giving the
|
||||
# name and its policy reads every agent credential in the swarm, while this
|
||||
# principal may only write one path — which is the entire point of giving the
|
||||
# container an identity instead of lending it the hive's.
|
||||
[ -s ${pkiDir}/matrix-ctl.pem ] || ${signLeaf} ${pkiDir} matrix-ctl \
|
||||
${lib.escapeShellArg deployCfg.bao.matrixCtlCommonName} "" clientAuth
|
||||
|
|
|
|||
|
|
@ -141,10 +141,10 @@ in
|
|||
a hive that reads the store at all is a hive that needs this pair.
|
||||
|
||||
⚠️ This reader's OWN leaf, not deploy.bao.clientCertFile. That one
|
||||
is the hive's, and its grant reads every secret in the store; this
|
||||
role reads the one queue-credential path. Pointing this option at
|
||||
the hive's leaf would evaluate, deploy and log in — and undo the
|
||||
split.
|
||||
is the hive's, and its grant reads every agent credential in the
|
||||
swarm and this hive's own secrets; this role reads the one
|
||||
queue-credential path. Pointing this option at the hive's leaf
|
||||
would evaluate, deploy and log in — and undo the split.
|
||||
|
||||
On a hive that runs the store, glue-bao-tls.nix supplies both as
|
||||
defaults and there is nothing to do. Elsewhere the leaf is issued
|
||||
|
|
|
|||
|
|
@ -412,7 +412,7 @@ in
|
|||
|
||||
⚠️ **Not the hive's own leaf**, and that is the whole deliverable of
|
||||
giving this container an identity: the hive's certificate reads every
|
||||
secret in the store, while this one may write a single path. Pointing
|
||||
agent credential in the swarm, while this one may write a single path. Pointing
|
||||
this at `deploy.bao.clientCertFile` would evaluate, deploy and work —
|
||||
and give away the separation in one line.
|
||||
|
||||
|
|
|
|||
|
|
@ -1583,8 +1583,9 @@ in
|
|||
the narrowest of the three: its grant is one path, that
|
||||
credential itself. The point of the whole arrangement is that the
|
||||
process holding the appservice token is not the hive, so handing it
|
||||
the hive's own leaf — which reads every secret in the store — would
|
||||
give the separation away in one line.
|
||||
the hive's own leaf — which reads every agent credential in the swarm
|
||||
and this hive's own secrets — would give the separation away in one
|
||||
line.
|
||||
|
||||
⚠️ Same collision as its siblings, and the same answer: ./swarm.nix
|
||||
feeds this value into the guard on
|
||||
|
|
@ -2282,7 +2283,8 @@ in
|
|||
normally gets both from ./glue-bao-tls.nix.
|
||||
|
||||
⚠️ Not deploy.bao.clientCertFile. That one is the hive's, and its
|
||||
grant reads every secret in the store; this role reads one path.
|
||||
grant reads every agent credential in the swarm and this hive's
|
||||
own secrets; this role reads one path.
|
||||
'';
|
||||
}
|
||||
{
|
||||
|
|
|
|||
|
|
@ -432,10 +432,10 @@ in
|
|||
band, and every other secret comes from the store with it.
|
||||
|
||||
⚠️ Grafana's OWN leaf, not deploy.bao.clientCertFile. That one is the
|
||||
hive's, and its grant reads every secret in the store; this role
|
||||
reads the one path Grafana's client secret lives at. Pointing this
|
||||
option at the hive's leaf would evaluate, deploy and log in — and
|
||||
undo the split.
|
||||
hive's, and its grant reads every agent credential in the swarm and
|
||||
this hive's own secrets; this role reads the one path Grafana's
|
||||
client secret lives at. Pointing this option at the hive's leaf would
|
||||
evaluate, deploy and log in — and undo the split.
|
||||
|
||||
On a hive that runs the store, glue-bao-tls.nix supplies both as
|
||||
defaults and there is nothing to do. Elsewhere the leaf is issued
|
||||
|
|
|
|||
|
|
@ -576,10 +576,10 @@ in
|
|||
telemetry. That is not this host.
|
||||
|
||||
⚠️ The collector's OWN leaf, not deploy.bao.clientCertFile. That one
|
||||
is the hive's, and its grant reads every secret in the store; this
|
||||
role reads the one path this collector's client secret lives at.
|
||||
Pointing this option at the hive's leaf would evaluate, deploy and
|
||||
log in — and undo the split.
|
||||
is the hive's, and its grant reads every agent credential in the
|
||||
swarm and this hive's own secrets; this role reads the one path this
|
||||
collector's client secret lives at. Pointing this option at the
|
||||
hive's leaf would evaluate, deploy and log in — and undo the split.
|
||||
|
||||
On a hive that runs the store, glue-bao-tls.nix supplies both as
|
||||
defaults and there is nothing to do. Elsewhere the leaf is issued
|
||||
|
|
|
|||
|
|
@ -285,9 +285,9 @@ let
|
|||
# 🩸 The identity separation this whole arrangement buys, stated as the
|
||||
# one thing that would silently undo it. The container gets MATRIX-CTL's
|
||||
# leaf — whose grant is a single path — and not the hive's, which reads
|
||||
# every secret in the store. Both files exist in the same directory and
|
||||
# every agent credential in the swarm and this hive's own secrets. Both files exist in the same directory and
|
||||
# both would evaluate, deploy and work.
|
||||
name = "matrix-ctl presents its own leaf, never the hive's store-wide one";
|
||||
name = "matrix-ctl presents its own leaf, never the hive's";
|
||||
ok =
|
||||
let
|
||||
env =
|
||||
|
|
|
|||
Loading…
Reference in a new issue