eve-hub 0.16.234 → 0.16.235
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/hub/functions/.well-known/workflow/v1/flow.func/__step_registrations.mjs +46 -1
- package/hub/functions/.well-known/workflow/v1/flow.func/hub/hub.mjs +235 -148
- package/hub/functions/.well-known/workflow/v1/flow.func/index.mjs +47 -1
- package/hub/functions/.well-known/workflow/v1/flow.func/migrations/control/0008_control_rls.sql +74 -0
- package/hub/functions/.well-known/workflow/v1/flow.func/migrations/control/meta/_journal.json +7 -0
- package/hub/functions/.well-known/workflow/v1/flow.func/migrations/workspace/0030_upload_keys.sql +7 -0
- package/hub/functions/.well-known/workflow/v1/flow.func/migrations/workspace/meta/_journal.json +7 -0
- package/hub/functions/api/index.func/api/index.mjs +235 -148
- package/hub/functions/api/index.func/migrations/control/0008_control_rls.sql +74 -0
- package/hub/functions/api/index.func/migrations/control/meta/_journal.json +7 -0
- package/hub/functions/api/index.func/migrations/workspace/0030_upload_keys.sql +7 -0
- package/hub/functions/api/index.func/migrations/workspace/meta/_journal.json +7 -0
- package/hub/migrate/migrate.mjs +27 -1
- package/hub/migrations/control/0008_control_rls.sql +74 -0
- package/hub/migrations/control/meta/_journal.json +7 -0
- package/hub/migrations/workspace/0030_upload_keys.sql +7 -0
- package/hub/migrations/workspace/meta/_journal.json +7 -0
- package/hub-shared/functions/.well-known/workflow/v1/flow.func/__step_registrations.mjs +46 -1
- package/hub-shared/functions/.well-known/workflow/v1/flow.func/hub/hub.mjs +246 -154
- package/hub-shared/functions/.well-known/workflow/v1/flow.func/index.mjs +47 -1
- package/hub-shared/functions/.well-known/workflow/v1/flow.func/migrations/control/0008_control_rls.sql +74 -0
- package/hub-shared/functions/.well-known/workflow/v1/flow.func/migrations/control/meta/_journal.json +7 -0
- package/hub-shared/functions/.well-known/workflow/v1/flow.func/migrations/workspace/0030_upload_keys.sql +7 -0
- package/hub-shared/functions/.well-known/workflow/v1/flow.func/migrations/workspace/meta/_journal.json +7 -0
- package/hub-shared/functions/api/index.func/api/index.mjs +246 -154
- package/hub-shared/functions/api/index.func/migrations/control/0008_control_rls.sql +74 -0
- package/hub-shared/functions/api/index.func/migrations/control/meta/_journal.json +7 -0
- package/hub-shared/functions/api/index.func/migrations/workspace/0030_upload_keys.sql +7 -0
- package/hub-shared/functions/api/index.func/migrations/workspace/meta/_journal.json +7 -0
- package/hub-shared/migrations/control/0008_control_rls.sql +74 -0
- package/hub-shared/migrations/control/meta/_journal.json +7 -0
- package/hub-shared/migrations/workspace/0030_upload_keys.sql +7 -0
- package/hub-shared/migrations/workspace/meta/_journal.json +7 -0
- package/onboarding/SKILL.md +3 -1
- package/package.json +1 -1
- package/skills/onboarding-profile.gen.mjs +1 -1
- package/tenant-env.mjs +8 -3
|
@@ -68369,12 +68369,57 @@ init_util2();
|
|
|
68369
68369
|
init_context_storage();
|
|
68370
68370
|
|
|
68371
68371
|
// src/telemetry.ts
|
|
68372
|
+
var MAX_DEPTH = 8;
|
|
68373
|
+
var SECRET_KEY = /token|secret|password|authorization|dburl|db_url|sealed/i;
|
|
68374
|
+
var SEALED = /^(?![0-9a-f]+$)[A-Za-z0-9+/]{40,}={0,2}$/;
|
|
68375
|
+
var PATTERNS = [
|
|
68376
|
+
[
|
|
68377
|
+
/Bearer\s+[^\s"']+/g,
|
|
68378
|
+
"Bearer [REDACTED]"
|
|
68379
|
+
],
|
|
68380
|
+
[
|
|
68381
|
+
/postgres(?:ql)?:\/\/[^\s"']+/g,
|
|
68382
|
+
"[REDACTED_DB_URL]"
|
|
68383
|
+
],
|
|
68384
|
+
[
|
|
68385
|
+
/\b(?:hub_bot_[A-Za-z0-9_-]+|hub_[A-Za-z0-9_-]{16,}|vca_[A-Za-z0-9_-]+|vercel_blob_rw_[A-Za-z0-9_-]+)/g,
|
|
68386
|
+
"[REDACTED_TOKEN]"
|
|
68387
|
+
]
|
|
68388
|
+
];
|
|
68389
|
+
function redactIn(value, depth, seen) {
|
|
68390
|
+
if (typeof value === "string") {
|
|
68391
|
+
if (value.length % 4 === 0 && SEALED.test(value)) return "[REDACTED_SEALED]";
|
|
68392
|
+
return PATTERNS.reduce((text, [pattern, replacement]) => text.replace(pattern, replacement), value);
|
|
68393
|
+
}
|
|
68394
|
+
if (typeof value !== "object" || value === null) return value;
|
|
68395
|
+
if (seen.has(value) || depth >= MAX_DEPTH) return "[REDACTED_DEPTH]";
|
|
68396
|
+
seen.add(value);
|
|
68397
|
+
try {
|
|
68398
|
+
if (value instanceof Error) return {
|
|
68399
|
+
name: value.name,
|
|
68400
|
+
message: redactIn(value.message, depth + 1, seen),
|
|
68401
|
+
...value.stack ? {
|
|
68402
|
+
stack: redactIn(value.stack, depth + 1, seen)
|
|
68403
|
+
} : {}
|
|
68404
|
+
};
|
|
68405
|
+
if (typeof value.toJSON === "function") return redactIn(value.toJSON(), depth + 1, seen);
|
|
68406
|
+
if (Array.isArray(value)) return value.map((item) => redactIn(item, depth + 1, seen));
|
|
68407
|
+
return Object.fromEntries(Object.entries(value).map(([key, item]) => [
|
|
68408
|
+
key,
|
|
68409
|
+
SECRET_KEY.test(key) && (typeof item === "string" || typeof item === "object" && item !== null) ? "[REDACTED]" : redactIn(item, depth + 1, seen)
|
|
68410
|
+
]));
|
|
68411
|
+
} finally {
|
|
68412
|
+
seen.delete(value);
|
|
68413
|
+
}
|
|
68414
|
+
}
|
|
68415
|
+
__name(redactIn, "redactIn");
|
|
68416
|
+
var redact = /* @__PURE__ */ __name((value) => redactIn(value, 0, /* @__PURE__ */ new WeakSet()), "redact");
|
|
68372
68417
|
function emit(event, fields = {}, level = "info") {
|
|
68373
68418
|
const line = JSON.stringify({
|
|
68374
68419
|
event,
|
|
68375
68420
|
level,
|
|
68376
68421
|
at: Date.now(),
|
|
68377
|
-
...fields
|
|
68422
|
+
...redact(fields)
|
|
68378
68423
|
});
|
|
68379
68424
|
if (level === "error") console.error(line);
|
|
68380
68425
|
else console.log(line);
|