@tinycloud/node-sdk 3.8.0-beta.15 → 3.8.0-beta.17

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/core.js CHANGED
@@ -1031,7 +1031,8 @@ var NodeUserAuthorization = class {
1031
1031
  return true;
1032
1032
  }
1033
1033
  const parsed = entry.path.includes("/") ? parseEncryptionResource(entry.path) : { ...parseNetworkId(entry.path), kind: "network" };
1034
- if (parsed.kind !== "network") {
1034
+ const sharePrefix = parsed.kind === "prefix" && parsed.network === "default" && parsed.prefix === "share" && entry.actions.length === 1 && entry.actions[0] === DECRYPT_ACTION && didPrincipalMatches(parsed.ownerDid, currentDid);
1035
+ if (parsed.kind !== "network" && !sharePrefix) {
1035
1036
  throw new ManifestValidationError("named keys go in manifest.keys");
1036
1037
  }
1037
1038
  for (const action of entry.actions) {
@@ -7344,7 +7345,7 @@ var _TinyCloudNode = class _TinyCloudNode {
7344
7345
  graph.assertActive();
7345
7346
  const signed = await this.signRawNetworkAuthorization({
7346
7347
  targetNode: input.targetNode,
7347
- networkId: input.networkId,
7348
+ networkId: input.body.keyPath === void 0 ? input.networkId : `${input.networkId}/${input.body.keyPath}`,
7348
7349
  action: DECRYPT_ACTION2,
7349
7350
  facts: input.facts
7350
7351
  }, { graph, session });