@@ -257,7 +257,8 @@ baseline runtime paths when the policy can permit a network connection, and a
257257live update can add paths but not remove them. File policies must be plain
258258subtree permits: a file ` forbid ` , a condition other than ` || ` -joined
259259` resource in ` tests, or a principal constraint is rejected, because Landlock
260- cannot express it.
260+ cannot express it, and a permit that lists only ` WriteFile ` is rejected, since
261+ a Landlock write grant includes read; list both actions.
261262
262263#### Step 2: the connection
263264
@@ -307,7 +308,8 @@ the YAML glob means while Cedar still sees literal set membership.
307308Naming the endpoint in the scope also makes ` api.github.com ` resolvable
308309through policy DNS, as listing it in YAML does. A host that only appears in a
309310` when ` condition is eligible when the condition requires both ` resource.host `
310- (exact or delimited glob) and ` resource.port ` ; any other form fails closed.
311+ (exact or delimited glob) and ` resource.port ` , or names the endpoint with
312+ ` resource.host_port == "host:port" ` ; any other form fails closed.
311313
312314#### Step 3: per-request rules
313315
@@ -602,7 +604,9 @@ host resolves, with the address condition assumed to hold, and again for each
602604resolved address, all of which must pass. Write the
603605address condition as top-level `when` conjuncts (`context has destination_ip`
604606and an `||` of `isInRange` tests) so OpenShell can read the ranges exactly;
605- other forms are rejected. Loopback, link-local, and unspecified addresses
607+ other forms are rejected. A `forbid` may read the address in any form : it is
608+ evaluated before resolution with the address absent, so its other conditions
609+ still apply, and again for each resolved address. Loopback, link-local, and unspecified addresses
606610stay blocked regardless of policy, and a host matched by a glob may not
607611resolve to a private address unless a permit names it exactly or restricts
608612its addresses, as in YAML.
@@ -811,7 +815,10 @@ settings do not grant or deny anything; they configure how allowed traffic is
811815handled. Keeping them out of the `.cedar` file keeps the Cedar text pure
812816access control, which is what the analysis tools reason about, and lets the
813817same `network_middlewares` format serve both policy languages. The cost is a
814- second file for sandboxes that need them.
818+ second file for sandboxes that need them. `endpoint_settings` reuses the YAML
819+ ` NetworkEndpoint` message, and its validation classifies every field of that
820+ message explicitly, so a field added to `NetworkEndpoint` later fails the build
821+ until it is classified rather than being accepted as a setting.
815822
816823**Providers supply credentials, never access.** On YAML sandboxes the gateway
817824composes attached providers' rules into `network_policies`, so attaching a
@@ -965,9 +972,12 @@ cross-compile; and the first CI run.
965972
966973# # Open questions
967974
968- - Should `NetworkConnect` drop its always-empty `method`, `path`, and
969- ` command` context fields? They exist for symmetry with `HttpRequest`, and a
970- permit that conditions on them silently never matches.
975+ - A gateway-wide YAML policy (`openshell policy set --global`) cannot be
976+ applied to a running Cedar sandbox, because a sandbox never switches format.
977+ Under `fail_closed` the Cedar sandbox is quarantined; under
978+ ` retain_last_valid` it keeps its own policy. Should the supervisor quarantine
979+ regardless of the failure mode, since the operator asked for the global
980+ policy to win, and should the gateway warn when Cedar sandboxes exist?
971981- Should `@protocol` become an attribute of `NetworkEndpoint` instead of an
972982 annotation?
973983- Can Cedar add a narrow "any member matches" form over sets? It would cover
0 commit comments