@calimero-network/mero-js 26.7.0 → 26.8.0
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/agent-gate/policy.d.ts +7 -1
- package/dist/agent-gate/policy.js +4 -3
- package/dist/index.browser.mjs +1 -1
- package/dist/index.browser.mjs.map +3 -3
- package/dist/index.cjs +3 -2
- package/dist/index.cjs.map +3 -3
- package/dist/index.mjs +3 -2
- package/dist/index.mjs.map +3 -3
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -13135,8 +13135,9 @@ async function verifySignedAgentPolicy(policy, bundle, options = {}) {
|
|
|
13135
13135
|
} catch {
|
|
13136
13136
|
throw new Error("The signed agent policy is not JSON");
|
|
13137
13137
|
}
|
|
13138
|
-
|
|
13139
|
-
|
|
13138
|
+
const role2 = options.role ?? "agent";
|
|
13139
|
+
if (parsed?.role !== role2) {
|
|
13140
|
+
throw new Error(`The signed file is a ${JSON.stringify(parsed?.role)} policy, not an ${role2} one`);
|
|
13140
13141
|
}
|
|
13141
13142
|
const profile = options.profile ?? PRODUCTION_PROFILE;
|
|
13142
13143
|
if (parsed.profile !== profile) {
|