@rosthq/cli 0.7.49 → 0.7.50
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/dist/index.js +5 -9
- package/dist/index.js.map +2 -2
- package/dist/runner-sandbox.d.ts +0 -1
- package/dist/runner-sandbox.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -52647,6 +52647,7 @@ function subpath(value) {
|
|
|
52647
52647
|
function literal2(value) {
|
|
52648
52648
|
return `(literal ${sbplString(value)})`;
|
|
52649
52649
|
}
|
|
52650
|
+
var CLAUDE_TEMP_SBPL_REGEX = '(regex #"^/private/tmp/claude-[^/]+")';
|
|
52650
52651
|
var STRICT_SYSTEM_READ_SUBPATHS = [
|
|
52651
52652
|
"/usr",
|
|
52652
52653
|
"/bin",
|
|
@@ -52693,7 +52694,7 @@ function buildSeatbeltProfile(input) {
|
|
|
52693
52694
|
if (denyReadBaseSubpaths.length > 0) {
|
|
52694
52695
|
lines.push(`(deny file-read* ${denyReadBaseSubpaths.join(" ")})`);
|
|
52695
52696
|
}
|
|
52696
|
-
const workspaceReads = [subpath(input.workspaceDir), ...input.allowWritePaths.map(subpath)];
|
|
52697
|
+
const workspaceReads = [subpath(input.workspaceDir), ...input.allowWritePaths.map(subpath), CLAUDE_TEMP_SBPL_REGEX];
|
|
52697
52698
|
lines.push(`(allow file-read* ${workspaceReads.join(" ")})`);
|
|
52698
52699
|
lines.push("(deny file-write*)");
|
|
52699
52700
|
const allowWrites = [
|
|
@@ -52702,6 +52703,8 @@ function buildSeatbeltProfile(input) {
|
|
|
52702
52703
|
subpath(`${home}/.claude`),
|
|
52703
52704
|
subpath(`${home}/.codex`),
|
|
52704
52705
|
...input.allowWritePaths.map(subpath),
|
|
52706
|
+
CLAUDE_TEMP_SBPL_REGEX,
|
|
52707
|
+
// DER-1398: Claude Code's per-session + per-command temp dirs.
|
|
52705
52708
|
subpath("/dev/fd"),
|
|
52706
52709
|
literal2("/dev/null"),
|
|
52707
52710
|
literal2("/dev/stdout"),
|
|
@@ -52747,9 +52750,6 @@ function isSandboxExecAvailable() {
|
|
|
52747
52750
|
return false;
|
|
52748
52751
|
}
|
|
52749
52752
|
}
|
|
52750
|
-
function claudeBashTempRoot(uid) {
|
|
52751
|
-
return `/private/tmp/claude-${uid}`;
|
|
52752
|
-
}
|
|
52753
52753
|
function resolveSandboxSpec(options) {
|
|
52754
52754
|
if (options.mode === "off") {
|
|
52755
52755
|
return { kind: "none", reason: "RUNNER_SANDBOX=off (loosened fallback - OS confinement disabled)" };
|
|
@@ -52772,11 +52772,7 @@ function resolveSandboxSpec(options) {
|
|
|
52772
52772
|
const denyWritePaths = (options.denyWritePaths ?? []).map(
|
|
52773
52773
|
(p) => p.endsWith("/") ? `${canonical(p.replace(/\/+$/, ""))}/` : canonicalFile(p)
|
|
52774
52774
|
);
|
|
52775
|
-
const
|
|
52776
|
-
const allowWritePaths = [
|
|
52777
|
-
...(options.allowWritePaths ?? []).map(canonical),
|
|
52778
|
-
...uid !== null ? [canonicalFile(claudeBashTempRoot(uid))] : []
|
|
52779
|
-
];
|
|
52775
|
+
const allowWritePaths = (options.allowWritePaths ?? []).map(canonical);
|
|
52780
52776
|
const profile = buildSeatbeltProfile({
|
|
52781
52777
|
workspaceDir,
|
|
52782
52778
|
tmpDir,
|