fix(managed): guard experimental authorization and startup requests
Reject explicit candidate-ID and inherited-policy CLI bypasses of the guarded native-circular operator path. Validate empty private runtime-owned request inodes without following links before state mutation, atomically claim and sync them before apply, retain failed claims, and never delete replacement requests. Keep internal journal reconciliation and legacy qualification unchanged. Co-authored-by: GPT-6 <gpt-6@openai.com>
This commit is contained in:
1 parent
371382c2c4
commit
f88c8e9c45
6 files changed
+294
-13
No files matched your search
@@ -57,7 +57,8 @@ for command, seconds in (("/usr/local/bin/zapret-autotune managed init", 45),
|
||||
("/opt/zapret2/init.d/sysv/zapret2 start", 30)):
|
||||
assert f"timeout -k 5 {seconds} {command} || exit 78" in entrypoint
|
||||
assert entrypoint.index("managed reconcile || exit 78") < entrypoint.index("zapret2 start || exit 78")
|
||||
experimental = 'managed apply --googlevideo-experiment native-circular --googlevideo-scope experimental_googlevideo_suffix || exit 78'
|
||||
experimental = 'managed apply --googlevideo-experiment native-circular --googlevideo-scope experimental_googlevideo_suffix --googlevideo-request startup || exit 78'
|
||||
assert entrypoint.index('zapret2 start || exit 78') < entrypoint.index(experimental)
|
||||
assert entrypoint.index(experimental) < entrypoint.index('setsid /bin/sh /opt/managed-target-supervision.sh --monitor')
|
||||
assert entrypoint.index(experimental) < entrypoint.index('rm "${ZAPRET_CONFIG%/*}/.autotune-experimental-suffix-request"')
|
||||
assert entrypoint.index('managed experimental-request-check || exit 78') < entrypoint.index('managed init || exit 78')
|
||||
assert 'rm "${ZAPRET_CONFIG%/*}/.autotune-experimental-suffix-request"' not in entrypoint
|
||||
Reference in new issue
Block a user