@shushed/helpers 0.0.174 → 0.0.175

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.
Files changed (2) hide show
  1. package/dist/index.js +1 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -106922,9 +106922,7 @@ var EnvEngine = class extends Runtime {
106922
106922
  return false;
106923
106923
  }
106924
106924
  if (meta.aud !== expectedAudience) {
106925
- const splittedReceived = meta.aud.split("-");
106926
- const splittedExpected = expectedAudience.split("-");
106927
- const receivedMoreSpecific = splittedExpected.length < splittedReceived.length && splittedExpected.length >= 2 && splittedExpected.every((x, i) => x === splittedReceived[i]) && (splittedExpected.length >= 3 || splittedReceived[2] === this.workflowId) && (splittedExpected.length >= 4 || splittedReceived[3] === this.triggerId);
106925
+ const receivedMoreSpecific = expectedAudience + "-" + this.workflowId + "-" + this.triggerId === meta.aud || expectedAudience + "-" + this.workflowId === meta.aud;
106928
106926
  if (!receivedMoreSpecific) {
106929
106927
  this.logging.error(`Authorization header - Wrong audience, got ${meta?.aud}, expected ${expectedAudience}`);
106930
106928
  return false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shushed/helpers",
3
- "version": "0.0.174",
3
+ "version": "0.0.175",
4
4
  "author": "",
5
5
  "license": "UNLICENSED",
6
6
  "description": "",