@ai-ecoverse/slicc-kernel 1.196.15 → 1.196.16

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.
@@ -5237,7 +5237,7 @@ function satisfies(version, range2) {
5237
5237
  }
5238
5238
 
5239
5239
  // src/version.ts
5240
- var KERNEL_VERSION = true ? "1.196.15" : "0.0.0-dev";
5240
+ var KERNEL_VERSION = true ? "1.196.16" : "0.0.0-dev";
5241
5241
  var OS_RELEASE = "6.0.0-slicc";
5242
5242
  function procVersion() {
5243
5243
  return `Linux version ${OS_RELEASE} (slicc-kernel ${KERNEL_VERSION}) #1 SMP PREEMPT_DYNAMIC
@@ -13223,7 +13223,7 @@ var MountFs = class _MountFs {
13223
13223
  async mkfifo(found, real2, owner) {
13224
13224
  const { mount, rel: rel2 } = found;
13225
13225
  if (!mount.caps.fifos) throw errnoError("EPERM", `${real2}: this mount has no FIFOs`);
13226
- const made2 = await this.driverOwner(found, real2, owner, false);
13226
+ const made2 = await this.driverOwner(found, real2, owner, false) ?? { mode: owner.mode };
13227
13227
  await this.table.commit(real2);
13228
13228
  this.table.forget(mount, real2);
13229
13229
  try {
@@ -14537,7 +14537,12 @@ async function run(entry, path, req) {
14537
14537
  case "copy":
14538
14538
  return copyOp(entry, path, req);
14539
14539
  case "mkfifo": {
14540
- const owner = ownerFor(entry, req.mode ?? 438) ?? { uid: 0, gid: 0 };
14540
+ const mode = (req.mode ?? 438) & 4095;
14541
+ const owner = ownerFor(entry, mode) ?? {
14542
+ uid: 0,
14543
+ gid: 0,
14544
+ mode: mode & ~(entry.umask?.() ?? 18)
14545
+ };
14541
14546
  await createExclusive(fs, path, { ...owner, fifo: true });
14542
14547
  entry.fresh?.(path);
14543
14548
  return done;
@@ -20529,7 +20534,13 @@ ${SCRIPT_HELP}
20529
20534
  const bound3 = await this.bound(path, r.cwd, asked, void 0, reads);
20530
20535
  if (!bound3) return failed2("EPERM", requestedText(await this.missingBacking(r.bound) ?? path));
20531
20536
  const changed2 = changedDecision(r.bound, r, bound3, path);
20532
- if (changed2 !== void 0) return failed2("EPERM", requestedText(changed2));
20537
+ if (changed2 !== void 0) {
20538
+ const missing7 = ["chainSha256", "routeSha256"].filter(
20539
+ (key) => bound3[key] !== void 0 && r[key] === void 0
20540
+ );
20541
+ const hint = missing7.length && changedFile(r.bound, bound3.hashes) === void 0 ? `; the saved request lacks ${missing7.join(" and ")}; pass back the whole request from approve unchanged` : "";
20542
+ return failed2("EPERM", requestedText(changed2) + hint);
20543
+ }
20533
20544
  const now = await this.rootOnly(r.cwd, args);
20534
20545
  const flipped = Object.keys(r.rootOnly).find((at) => r.rootOnly[at] && now[at] !== true);
20535
20546
  if (flipped !== void 0) return failed2("EPERM", `sudo: ${flipped} is no longer root-only`);
@@ -33717,7 +33728,8 @@ var OpfsFs = class {
33717
33728
  if (owner?.socket && owner.fifo) throw new Error("a new node is a socket or a FIFO, not both");
33718
33729
  const kind = directory2 ? void 0 : owner?.socket ? "socket" : owner?.fifo ? "fifo" : void 0;
33719
33730
  const unique = kind === "fifo" ? { ino: inodeOf(`${path}\0${crypto.randomUUID()}`) } : {};
33720
- const fields2 = kind ? { ...owned4, ...unique, [kind]: true } : owned4;
33731
+ const fifoMode = owner?.fifo && owner.mode !== void 0 ? { mode: owner.mode & PERM_MASK } : {};
33732
+ const fields2 = kind ? { ...owned4, ...fifoMode, ...unique, [kind]: true } : owned4;
33721
33733
  if (fields2) await this.meta.update(path, (entry) => ({ ...occupied(entry), path, ...fields2 }));
33722
33734
  }
33723
33735
  guarded = [];