@standardagents/builder 0.40.1 → 0.40.3

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.
@@ -68899,7 +68899,7 @@ var config_get_default = defineController2(async ({ config, env: env2, req }) =>
68899
68899
  });
68900
68900
 
68901
68901
  // src/version.ts
68902
- var BUILDER_VERSION = "0.40.1".length > 0 ? "0.40.1" : "dev";
68902
+ var BUILDER_VERSION = "0.40.3".length > 0 ? "0.40.3" : "dev";
68903
68903
 
68904
68904
  // src/api/diagnostics.get.ts
68905
68905
  init_LLMRequest();
@@ -76507,13 +76507,6 @@ async function verifyDeviceConfirmationToken(env2, code, confirmationSubject, to
76507
76507
  return false;
76508
76508
  }
76509
76509
  }
76510
- function isSameOriginApprovalPost(req) {
76511
- const url = new URL(req.url);
76512
- const origin = req.headers.get("Origin");
76513
- if (origin && origin !== url.origin) return false;
76514
- const fetchSite = req.headers.get("Sec-Fetch-Site");
76515
- return !fetchSite || fetchSite === "same-origin" || fetchSite === "none";
76516
- }
76517
76510
 
76518
76511
  // src/api/auth/device/[code]/approve.get.ts
76519
76512
  var approve_get_default = defineController2(async ({ req, env: env2, params, config }) => {
@@ -76550,7 +76543,7 @@ var approve_post_default = defineController2(async ({ req, env: env2, params })
76550
76543
  body: "This device link is malformed."
76551
76544
  });
76552
76545
  }
76553
- if (!isSameOriginApprovalPost(req)) {
76546
+ if (!isSameOriginBrowserRequest(req)) {
76554
76547
  return Response.json({ error: "Cross-origin device approval refused" }, { status: 403 });
76555
76548
  }
76556
76549
  const form = await req.clone().formData().catch(() => null);