messenger: the ask-events entry's grant is the config value readers, as the events template takes it (K-24; ADR 0595; issue 1966)
This commit is contained in:
@@ -120,7 +120,7 @@ func TestItDeclaresTheSeatsOfAnAskAndHoldsTheOperatorChannel(t *testing.T) { //
|
||||
// The asks it says are a bus-state entry of the events template (ADR 0595), never a stream of its own (the manifest
|
||||
// validator refuses one that keeps no history, ADR 0619): offered and closed, kept seven days, readers by the grant.
|
||||
if len(m.Streams) != 0 || len(m.Requires) != 1 || m.Requires[0].Template != "events" || m.Requires[0].Storage != "stream" ||
|
||||
!reflect.DeepEqual(m.Requires[0].Options["events"], []any{"offered", "closed"}) || m.Requires[0].Options["max-age-days"] != float64(7) {
|
||||
!reflect.DeepEqual(m.Requires[0].Options["events"], []any{"offered", "closed"}) || m.Requires[0].Options["max-age-days"] != float64(7) || m.Requires[0].Options["grant"] != "readers" {
|
||||
t.Fatalf("streams %v, requires %+v", m.Streams, m.Requires)
|
||||
}
|
||||
// It holds no channel's secret: only its own bus account, read by its own account alone (ADR 0259 §8).
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
"events": ["offered", "closed"],
|
||||
"max-age-days": 7,
|
||||
"max-mib": 64,
|
||||
"grant": {"config": "readers", "events": "{key}"}
|
||||
"grant": "readers"
|
||||
}
|
||||
}
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user