1
0
mirror of https://github.com/bitwarden/browser synced 2026-02-01 17:23:37 +00:00

testing setting permissions on chrome-sandbox via electron builder hook

This commit is contained in:
AJ Mabry
2025-11-17 11:06:07 -05:00
parent c67715ea29
commit eb612bc4bb

View File

@@ -30,6 +30,15 @@ async function run(context) {
fse.copyFileSync(wrapperScript, wrapperBin);
fse.chmodSync(wrapperBin, "755");
console.log("Copied memory-protection wrapper script");
// TEST: Set SUID on chrome-sandbox during build
const chromeSandbox = path.join(appOutDir, "chrome-sandbox");
if (fse.existsSync(chromeSandbox)) {
fse.chmodSync(chromeSandbox, "4755");
console.log("✓ Set SUID permissions on chrome-sandbox (mode 4755)");
} else {
console.warn("⚠ chrome-sandbox not found at:", chromeSandbox);
}
}
if (["darwin", "mas"].includes(context.electronPlatformName)) {