@ouro.bot/cli 0.1.0-alpha.817 → 0.1.0-alpha.818
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/changelog.json
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_note": "This changelog is maintained as part of the PR/version-bump workflow. Agent-curated, not auto-generated. Agents read this file directly via read_file to understand what changed between versions.",
|
|
3
3
|
"versions": [
|
|
4
|
+
{
|
|
5
|
+
"version": "0.1.0-alpha.818",
|
|
6
|
+
"changes": [
|
|
7
|
+
"Keep private execution claims owner-only and check Sanctuary upgrade permissions with the predecessor stopped."
|
|
8
|
+
]
|
|
9
|
+
},
|
|
4
10
|
{
|
|
5
11
|
"version": "0.1.0-alpha.817",
|
|
6
12
|
"changes": [
|
package/deploy/unraid/README.txt
CHANGED
|
@@ -1667,9 +1667,14 @@ NODE
|
|
|
1667
1667
|
TELEGRAM_READINESS_IMAGE_ID=$1
|
|
1668
1668
|
validate_exact_image_id "$TELEGRAM_READINESS_IMAGE_ID" || return $?
|
|
1669
1669
|
TELEGRAM_READINESS_CONTRACT=$(sanctuary_image_mount_contract "$TELEGRAM_READINESS_IMAGE_ID") || return $?
|
|
1670
|
+
TELEGRAM_READINESS_CONTEXT=${2-}
|
|
1670
1671
|
case "$TELEGRAM_READINESS_CONTRACT" in
|
|
1671
|
-
canonical-gateway) set -- --mount "type=bind,src=/run/ouro-authority,dst=/run/ouro-authority,readonly" ;;
|
|
1672
|
-
canonical-pre-gateway) set -- ;;
|
|
1672
|
+
canonical-gateway) TELEGRAM_READINESS_CONTEXT=${TELEGRAM_READINESS_CONTEXT:-strict}; set -- --mount "type=bind,src=/run/ouro-authority,dst=/run/ouro-authority,readonly" ;;
|
|
1673
|
+
canonical-pre-gateway) TELEGRAM_READINESS_CONTEXT=${TELEGRAM_READINESS_CONTEXT:-live-precutover}; set -- ;;
|
|
1674
|
+
*) return 1 ;;
|
|
1675
|
+
esac
|
|
1676
|
+
case "$TELEGRAM_READINESS_CONTRACT:$TELEGRAM_READINESS_CONTEXT" in
|
|
1677
|
+
canonical-gateway:strict|canonical-pre-gateway:strict|canonical-pre-gateway:live-precutover) ;;
|
|
1673
1678
|
*) return 1 ;;
|
|
1674
1679
|
esac
|
|
1675
1680
|
TELEGRAM_READINESS_RUNTIME_ROOT=/mnt/user/appdata/ouro-butler/runtime/.ouro-cli
|
|
@@ -1683,11 +1688,7 @@ NODE
|
|
|
1683
1688
|
"$@" "$TELEGRAM_READINESS_IMAGE_ID" telegram-readiness >/dev/null || return $?
|
|
1684
1689
|
! docker container inspect ouro-butler-telegram-readiness >/dev/null 2>&1 || return 1
|
|
1685
1690
|
normalize_sanctuary_private_permissions "$TELEGRAM_READINESS_RUNTIME_ROOT" "$TELEGRAM_READINESS_AGENT_ROOT" "$TELEGRAM_READINESS_IMAGE_ID" || return $?
|
|
1686
|
-
|
|
1687
|
-
validate_sanctuary_roots "$TELEGRAM_READINESS_RUNTIME_ROOT" "$TELEGRAM_READINESS_AGENT_ROOT" || return $?
|
|
1688
|
-
else
|
|
1689
|
-
validate_sanctuary_roots "$TELEGRAM_READINESS_RUNTIME_ROOT" "$TELEGRAM_READINESS_AGENT_ROOT" live-precutover || return $?
|
|
1690
|
-
fi
|
|
1691
|
+
validate_sanctuary_roots "$TELEGRAM_READINESS_RUNTIME_ROOT" "$TELEGRAM_READINESS_AGENT_ROOT" "$TELEGRAM_READINESS_CONTEXT" || return $?
|
|
1691
1692
|
}
|
|
1692
1693
|
read_sanctuary_authority_state() {
|
|
1693
1694
|
(
|
|
@@ -2161,9 +2162,8 @@ Update:
|
|
|
2161
2162
|
(exit "$UPDATE_PREFLIGHT_STATUS")
|
|
2162
2163
|
fi
|
|
2163
2164
|
assert_update_source "$ROLLBACK_IMAGE_ID" "$AUDIT_RUNNER_IMAGE_ID"
|
|
2164
|
-
if provision_sanctuary_sab_credential "$IMAGE_ID" \
|
|
2165
|
-
&& verify_sanctuary_sab_readiness "$IMAGE_ID"
|
|
2166
|
-
&& verify_sanctuary_telegram_readiness "$ROLLBACK_IMAGE_ID"; then
|
|
2165
|
+
if ( provision_sanctuary_sab_credential "$IMAGE_ID" ) \
|
|
2166
|
+
&& verify_sanctuary_sab_readiness "$IMAGE_ID"; then
|
|
2167
2167
|
:
|
|
2168
2168
|
else
|
|
2169
2169
|
PRECUTOVER_READINESS_STATUS=$?
|
|
@@ -2182,7 +2182,21 @@ Update:
|
|
|
2182
2182
|
/usr/local/bin/node "$STAGED_DOCKERMAN_TRANSACTION" rollback >/dev/null
|
|
2183
2183
|
(exit "$AUTOSTART_DISABLE_STATUS")
|
|
2184
2184
|
fi
|
|
2185
|
-
|
|
2185
|
+
Stop the exact predecessor before its final Telegram and filesystem readiness check. Otherwise a concurrent private-runtime receipt can appear between permission normalization and strict validation. The full package and durable transaction are already prepared, and autostart is disabled. Keep the stopped-resident mode strict: no live control socket or mode exception is allowed. Before token rotation, any failure restores the same policy-aware predecessor and propagates the failure; an interrupted stop remains recoverable from the prepared transaction:
|
|
2186
|
+
if docker stop --time 30 ouro-butler \
|
|
2187
|
+
&& assert_only_running_butler - \
|
|
2188
|
+
&& verify_sanctuary_telegram_readiness "$ROLLBACK_IMAGE_ID" strict; then
|
|
2189
|
+
:
|
|
2190
|
+
else
|
|
2191
|
+
PRECUTOVER_QUIESCENCE_STATUS=$?
|
|
2192
|
+
assert_update_source "$ROLLBACK_IMAGE_ID" "$AUDIT_RUNNER_IMAGE_ID"
|
|
2193
|
+
start_only_butler_for_recovery
|
|
2194
|
+
wait_butler_ready ouro-butler
|
|
2195
|
+
enable_butler_autostart
|
|
2196
|
+
/usr/local/bin/node "$STAGED_DOCKERMAN_TRANSACTION" rollback >/dev/null
|
|
2197
|
+
(exit "$PRECUTOVER_QUIESCENCE_STATUS")
|
|
2198
|
+
fi
|
|
2199
|
+
Only after pinned stopped-image readiness, full-package preparation, durable transaction preparation and autostart disabling pass, the human rotates MendelowCloudButlerBot's token for that same numeric bot and uses the hidden root-terminal input helper. Do not echo the token, put it in argv/environment/history, copy it into the resident, or replace retained incoming-token during recovery. A failed or interrupted paste must be reconciled by the human before retry; retain the journal and disabled autostart, and do not invent a token:
|
|
2186
2200
|
receive_sanctuary_authority_token
|
|
2187
2201
|
test "$(stat -c '%u:%g:%a' /mnt/user/appdata/ouro-authority/incoming-token)" = 0:0:600
|
|
2188
2202
|
Gateway installation and its tokenless readiness belong inside the stopped-resident transaction, never in the old live precheck. A failure attempts retirement and exact old-image restoration; failure of either keeps autostart disabled and the journals/root inputs intact:
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<?xml version="1.0"?>
|
|
2
2
|
<Container version="2">
|
|
3
3
|
<Name>ouro-butler</Name>
|
|
4
|
-
<Repository>ghcr.io/ourostack/ouroboros-butler:0.1.0-alpha.
|
|
4
|
+
<Repository>ghcr.io/ourostack/ouroboros-butler:0.1.0-alpha.818</Repository>
|
|
5
5
|
<Registry>https://github.com/ourostack/ouroboros/pkgs/container/ouroboros-butler</Registry>
|
|
6
6
|
<Network>host</Network>
|
|
7
7
|
<Shell>sh</Shell>
|
|
@@ -491,14 +491,14 @@ function privateTurnExecutionPath(decision) {
|
|
|
491
491
|
}
|
|
492
492
|
function claimPrivateTurnExecution(decision, now) {
|
|
493
493
|
const executionPath = privateTurnExecutionPath(decision);
|
|
494
|
-
fs.mkdirSync(path.dirname(executionPath), { recursive: true });
|
|
494
|
+
fs.mkdirSync(path.dirname(executionPath), { recursive: true, mode: 0o700 });
|
|
495
495
|
try {
|
|
496
496
|
fs.writeFileSync(executionPath, JSON.stringify({
|
|
497
497
|
receiptId: decision.receiptId,
|
|
498
498
|
idempotencyKey: decision.idempotencyKey,
|
|
499
499
|
requestFingerprint: decision.requestFingerprint,
|
|
500
500
|
claimedAt: now().toISOString(),
|
|
501
|
-
}), { encoding: "utf-8", flag: "wx" });
|
|
501
|
+
}), { encoding: "utf-8", flag: "wx", mode: 0o600 });
|
|
502
502
|
return true;
|
|
503
503
|
}
|
|
504
504
|
catch (error) {
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ouro.bot/cli",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.818",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@ouro.bot/cli",
|
|
9
|
-
"version": "0.1.0-alpha.
|
|
9
|
+
"version": "0.1.0-alpha.818",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@anthropic-ai/sdk": "^0.78.0",
|
|
12
12
|
"@azure/identity": "^4.13.0",
|