@jini-ai/core 0.7.2 → 0.7.3-next.1
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/CHANGELOG.md +0 -2
- package/README.md +40 -12
- package/dist/admin-runtime/admin-api-error.d.ts +68 -0
- package/dist/admin-runtime/admin-api-error.js +72 -0
- package/dist/admin-runtime/admin-config-error.d.ts +8 -0
- package/dist/admin-runtime/admin-config-error.js +11 -0
- package/dist/admin-runtime/controller-store.d.ts +20 -0
- package/dist/admin-runtime/controller-store.js +32 -0
- package/dist/admin-runtime/index.d.ts +13 -0
- package/dist/admin-runtime/index.js +12 -0
- package/dist/admin-runtime/panel-access.d.ts +88 -0
- package/dist/admin-runtime/panel-access.js +76 -0
- package/dist/admin-runtime/query-suffix.d.ts +5 -0
- package/dist/admin-runtime/query-suffix.js +5 -0
- package/dist/agent-handles/element-handles.d.ts +134 -0
- package/dist/agent-handles/element-handles.js +45 -0
- package/dist/agent-handles/field-descriptor.d.ts +28 -0
- package/dist/agent-handles/field-descriptor.js +3 -0
- package/dist/agent-handles/handle.d.ts +109 -0
- package/dist/agent-handles/handle.js +109 -0
- package/dist/agent-handles/index.d.ts +9 -0
- package/dist/agent-handles/index.js +6 -0
- package/dist/agent-handles/list-handles.d.ts +46 -0
- package/dist/agent-handles/list-handles.js +67 -0
- package/dist/agent-handles/secret-attrs.d.ts +14 -0
- package/dist/agent-handles/secret-attrs.js +13 -0
- package/dist/approval-batch-chain.d.ts +45 -0
- package/dist/approval-batch-chain.js +75 -0
- package/dist/approval.d.ts +33 -14
- package/dist/approval.js +57 -43
- package/dist/batch-tool-inputs.js +24 -20
- package/dist/contracts/admin-module.d.ts +166 -0
- package/dist/contracts/admin-module.js +14 -0
- package/dist/contracts/agents/definition.d.ts +459 -0
- package/dist/contracts/agents/definition.js +2 -0
- package/dist/contracts/agents/index.d.ts +7 -0
- package/dist/contracts/agents/index.js +2 -0
- package/dist/contracts/agents/launch.d.ts +64 -0
- package/dist/contracts/agents/launch.js +2 -0
- package/dist/contracts/agents/model-catalog.d.ts +213 -0
- package/dist/contracts/agents/model-catalog.js +4 -0
- package/dist/contracts/agents/native-tool-policy.d.ts +42 -0
- package/dist/contracts/agents/native-tool-policy.js +2 -0
- package/dist/contracts/ai-trace/capture.d.ts +17 -0
- package/dist/contracts/ai-trace/capture.js +43 -0
- package/dist/contracts/ai-trace/classify.d.ts +12 -0
- package/dist/contracts/ai-trace/classify.js +16 -0
- package/dist/contracts/ai-trace/index.d.ts +13 -0
- package/dist/contracts/ai-trace/index.js +6 -0
- package/dist/contracts/ai-trace/recorder.d.ts +64 -0
- package/dist/contracts/ai-trace/recorder.js +283 -0
- package/dist/contracts/ai-trace/sinks.d.ts +51 -0
- package/dist/contracts/ai-trace/sinks.js +153 -0
- package/dist/contracts/ai-trace/types.d.ts +123 -0
- package/dist/contracts/ai-trace/types.js +17 -0
- package/dist/contracts/ai-trace/usage.d.ts +16 -0
- package/dist/contracts/ai-trace/usage.js +45 -0
- package/dist/contracts/blob.d.ts +31 -0
- package/dist/contracts/blob.js +10 -0
- package/dist/contracts/capabilities.d.ts +95 -0
- package/dist/contracts/capabilities.js +111 -0
- package/dist/contracts/charts.d.ts +75 -0
- package/dist/contracts/charts.js +4 -0
- package/dist/contracts/env.d.ts +96 -0
- package/dist/contracts/env.js +6 -0
- package/dist/contracts/events/change-set.d.ts +106 -0
- package/dist/contracts/events/change-set.js +2 -0
- package/dist/contracts/events/command.d.ts +118 -0
- package/dist/contracts/events/command.js +2 -0
- package/dist/contracts/events/ports.d.ts +172 -0
- package/dist/contracts/events/ports.js +2 -0
- package/dist/contracts/events.d.ts +5 -0
- package/dist/contracts/events.js +2 -0
- package/dist/contracts/forms.d.ts +110 -0
- package/dist/contracts/forms.js +4 -0
- package/dist/contracts/hosted-mcp/config.d.ts +19 -0
- package/dist/contracts/hosted-mcp/record.d.ts +61 -4
- package/dist/contracts/mail/email-sender.d.ts +118 -0
- package/dist/contracts/mail/email-sender.js +20 -0
- package/dist/contracts/mail/smtp-payload.d.ts +32 -0
- package/dist/contracts/mail/smtp-payload.js +2 -0
- package/dist/contracts/mail.d.ts +2 -0
- package/dist/contracts/mail.js +1 -1
- package/dist/contracts/observability.d.ts +232 -0
- package/dist/contracts/observability.js +27 -0
- package/dist/contracts/plugin-sdk.d.ts +186 -0
- package/dist/contracts/plugin-sdk.js +39 -0
- package/dist/contracts/runtime/command.d.ts +41 -0
- package/dist/contracts/runtime/command.js +60 -0
- package/dist/contracts/runtime/environment.d.ts +18 -0
- package/dist/contracts/runtime/environment.js +26 -0
- package/dist/contracts/runtime/file-lock.d.ts +94 -0
- package/dist/contracts/runtime/file-lock.js +25 -0
- package/dist/contracts/runtime/fs.d.ts +33 -0
- package/dist/contracts/runtime/fs.js +2 -0
- package/dist/contracts/runtime/http.d.ts +89 -0
- package/dist/contracts/runtime/http.js +2 -0
- package/dist/contracts/runtime/platform.d.ts +3 -0
- package/dist/contracts/runtime/platform.js +2 -0
- package/dist/contracts/runtime/process.d.ts +40 -0
- package/dist/contracts/runtime/process.js +31 -0
- package/dist/contracts/runtime/reader.d.ts +11 -0
- package/dist/contracts/runtime/reader.js +2 -0
- package/dist/contracts/runtime/terminal.d.ts +99 -0
- package/dist/contracts/runtime/terminal.js +2 -0
- package/dist/contracts/runtime/testing.d.ts +84 -0
- package/dist/contracts/runtime/testing.js +116 -0
- package/dist/contracts/runtime.d.ts +10 -0
- package/dist/contracts/runtime.js +10 -0
- package/dist/contracts/server/api-error.d.ts +43 -0
- package/dist/contracts/server/api-error.js +49 -0
- package/dist/contracts/server/auth.d.ts +20 -0
- package/dist/contracts/server/auth.js +21 -0
- package/dist/contracts/server/conformance.d.ts +25 -0
- package/dist/contracts/server/conformance.js +50 -0
- package/dist/contracts/server/json-route.d.ts +176 -0
- package/dist/contracts/server/json-route.js +155 -0
- package/dist/contracts/server/middleware.d.ts +35 -0
- package/dist/contracts/server/middleware.js +56 -0
- package/dist/contracts/server/origin.d.ts +44 -0
- package/dist/contracts/server/origin.js +32 -0
- package/dist/contracts/server/query.d.ts +16 -0
- package/dist/contracts/server/query.js +69 -0
- package/dist/contracts/server/rate-limit.d.ts +20 -0
- package/dist/contracts/server/rate-limit.js +8 -0
- package/dist/contracts/server/request-body.d.ts +26 -0
- package/dist/contracts/server/request-body.js +82 -0
- package/dist/contracts/server/result.d.ts +17 -0
- package/dist/contracts/server/result.js +5 -0
- package/dist/contracts/server/route-table.d.ts +54 -0
- package/dist/contracts/server/route-table.js +119 -0
- package/dist/contracts/server/same-origin-write.d.ts +18 -0
- package/dist/contracts/server/same-origin-write.js +31 -0
- package/dist/contracts/server/security-headers.d.ts +30 -0
- package/dist/contracts/server/security-headers.js +35 -0
- package/dist/contracts/server/sse.d.ts +82 -0
- package/dist/contracts/server/sse.js +103 -0
- package/dist/contracts/server/testing.d.ts +59 -0
- package/dist/contracts/server/testing.js +68 -0
- package/dist/contracts/server/verified-origin/configured-origin.d.ts +37 -0
- package/dist/contracts/server/verified-origin/configured-origin.js +103 -0
- package/dist/contracts/server/verified-origin/index.d.ts +7 -0
- package/dist/contracts/server/verified-origin/index.js +6 -0
- package/dist/contracts/server/verified-origin/loopback-host.d.ts +9 -0
- package/dist/contracts/server/verified-origin/loopback-host.js +17 -0
- package/dist/contracts/server/verified-origin/origin.d.ts +64 -0
- package/dist/contracts/server/verified-origin/origin.js +162 -0
- package/dist/contracts/server/verified-origin/ports.d.ts +38 -0
- package/dist/contracts/server/verified-origin/ports.js +2 -0
- package/dist/contracts/server/verified-origin/repo.memory.d.ts +32 -0
- package/dist/contracts/server/verified-origin/repo.memory.js +34 -0
- package/dist/contracts/server/verified-origin/site-path.d.ts +113 -0
- package/dist/contracts/server/verified-origin/site-path.js +188 -0
- package/dist/contracts/server/verified-origin/types.d.ts +33 -0
- package/dist/contracts/server/verified-origin/types.js +30 -0
- package/dist/contracts/server.d.ts +46 -2
- package/dist/contracts/server.js +17 -3
- package/dist/contracts/storage/kernel.d.ts +86 -0
- package/dist/contracts/storage/kernel.js +38 -0
- package/dist/contracts/storage/migration.d.ts +32 -0
- package/dist/contracts/storage/migration.js +2 -0
- package/dist/contracts/storage/rows.d.ts +33 -0
- package/dist/contracts/storage/rows.js +42 -0
- package/dist/contracts/storage/sqlite.d.ts +113 -0
- package/dist/contracts/storage/sqlite.js +8 -0
- package/dist/contracts/storage/values.d.ts +25 -0
- package/dist/contracts/storage/values.js +25 -0
- package/dist/contracts/storage.d.ts +8 -0
- package/dist/contracts/storage.js +6 -0
- package/dist/contracts/vault/invariants.d.ts +26 -0
- package/dist/contracts/vault/invariants.js +49 -0
- package/dist/contracts/vault.d.ts +1 -0
- package/dist/contracts/vault.js +1 -1
- package/dist/env/coercers.d.ts +21 -0
- package/dist/env/coercers.js +68 -0
- package/dist/env/describe-env-for-diagnostics.d.ts +16 -0
- package/dist/env/describe-env-for-diagnostics.js +23 -0
- package/dist/env/format-env-issue.d.ts +13 -0
- package/dist/env/format-env-issue.js +22 -0
- package/dist/env/parse-env.d.ts +24 -0
- package/dist/env/parse-env.js +102 -0
- package/dist/env/value-echo.d.ts +17 -0
- package/dist/env/value-echo.js +42 -0
- package/dist/errors/approved-cause.d.ts +36 -0
- package/dist/errors/approved-cause.js +17 -0
- package/dist/errors/bindings.d.ts +61 -0
- package/dist/errors/bindings.js +57 -0
- package/dist/errors/catalog.d.ts +84 -0
- package/dist/errors/catalog.js +151 -0
- package/dist/errors/disclosure.d.ts +48 -0
- package/dist/errors/disclosure.js +27 -0
- package/dist/errors/error-id.d.ts +26 -0
- package/dist/errors/error-id.js +23 -0
- package/dist/errors/idioms.d.ts +73 -0
- package/dist/errors/idioms.js +85 -0
- package/dist/errors/incident-text.d.ts +16 -0
- package/dist/errors/incident-text.js +77 -0
- package/dist/errors/reporter.d.ts +94 -0
- package/dist/errors/reporter.js +152 -0
- package/dist/errors/sentences.d.ts +68 -0
- package/dist/errors/sentences.js +93 -0
- package/dist/errors/testing.d.ts +50 -0
- package/dist/errors/testing.js +44 -0
- package/dist/fetch/cache.d.ts +12 -5
- package/dist/fetch/cache.js +46 -47
- package/dist/fetch/index.d.ts +1 -1
- package/dist/fetch/loader-read.d.ts +6 -2
- package/dist/fetch/loader-read.js +4 -4
- package/dist/format-error-for-log.d.ts +15 -0
- package/dist/format-error-for-log.js +55 -0
- package/dist/host-read-vocabulary.d.ts +47 -0
- package/dist/host-read-vocabulary.js +44 -0
- package/dist/index.d.ts +5 -1
- package/dist/index.js +4 -0
- package/dist/list-page.d.ts +93 -0
- package/dist/list-page.js +154 -0
- package/dist/model-facing-tool-errors.d.ts +67 -5
- package/dist/model-facing-tool-errors.js +155 -19
- package/dist/net/endpoint-policy.d.ts +39 -0
- package/dist/net/endpoint-policy.js +218 -0
- package/dist/net/fetch-timeouts.d.ts +38 -0
- package/dist/net/fetch-timeouts.js +31 -0
- package/dist/net/index.d.ts +4 -0
- package/dist/net/index.js +4 -0
- package/dist/net/loopback.d.ts +13 -0
- package/dist/net/loopback.js +39 -0
- package/dist/optimistic-concurrency.d.ts +183 -0
- package/dist/optimistic-concurrency.js +222 -0
- package/dist/primitives/errors.d.ts +9 -0
- package/dist/primitives/errors.js +12 -0
- package/dist/primitives/ids.d.ts +0 -2
- package/dist/primitives/ids.js +1 -4
- package/dist/primitives/index.d.ts +3 -0
- package/dist/primitives/index.js +2 -0
- package/dist/primitives/logger.d.ts +36 -1
- package/dist/primitives/logger.js +125 -9
- package/dist/primitives/node-shape.d.ts +24 -0
- package/dist/primitives/node-shape.js +21 -0
- package/dist/primitives/time.d.ts +9 -2
- package/dist/primitives/time.js +4 -3
- package/dist/provider-registry.js +26 -20
- package/dist/records.d.ts +40 -7
- package/dist/records.js +37 -3
- package/dist/redact.d.ts +1 -84
- package/dist/redact.js +2 -826
- package/dist/redaction-collectors.d.ts +7 -0
- package/dist/redaction-collectors.js +152 -0
- package/dist/redaction-exact-secrets.d.ts +14 -0
- package/dist/redaction-exact-secrets.js +115 -0
- package/dist/redaction-labels.d.ts +14 -0
- package/dist/redaction-labels.js +156 -0
- package/dist/redaction-patterns.d.ts +54 -0
- package/dist/redaction-patterns.js +178 -0
- package/dist/redaction-spans.d.ts +31 -0
- package/dist/redaction-spans.js +83 -0
- package/dist/registration-kit.d.ts +1 -1
- package/dist/revision-conflict-error.d.ts +18 -0
- package/dist/revision-conflict-error.js +20 -0
- package/dist/secret-shapes.d.ts +50 -0
- package/dist/secret-shapes.js +105 -0
- package/dist/settings/agent-tools.js +22 -8
- package/dist/settings/agent-value-write-tools.d.ts +4 -1
- package/dist/settings/agent-value-write-tools.js +7 -6
- package/dist/settings/agent-writable-preferences.d.ts +3 -1
- package/dist/settings/agent-writable-preferences.js +1 -1
- package/dist/settings/agent-write-denylist.d.ts +7 -4
- package/dist/settings/agent-write-denylist.js +1 -1
- package/dist/settings/{express/cms-adapter.d.ts → cms-adapter.d.ts} +3 -2
- package/dist/settings/{express/cms-adapter.js → cms-adapter.js} +21 -11
- package/dist/settings/definitions-dispatch.js +3 -1
- package/dist/settings/ensure-definitions.js +3 -1
- package/dist/settings/errors.d.ts +1 -13
- package/dist/settings/errors.js +2 -15
- package/dist/settings/index.d.ts +11 -2
- package/dist/settings/index.js +10 -2
- package/dist/settings/purge-service.js +63 -86
- package/dist/settings/{express/contracts.d.ts → route-policy.d.ts} +53 -47
- package/dist/settings/{express/shared.js → route-policy.js} +1 -16
- package/dist/settings/settings.d.ts +19 -11
- package/dist/settings/settings.js +9 -11
- package/dist/settings/tool-registrations.d.ts +3 -3
- package/dist/settings/tool-registrations.js +130 -125
- package/dist/settings/types.d.ts +1 -1
- package/dist/settings/write-definition-rename.d.ts +37 -0
- package/dist/settings/write-definition-rename.js +119 -0
- package/dist/settings/write-definition-retype.d.ts +61 -0
- package/dist/settings/write-definition-retype.js +109 -0
- package/dist/settings/write-definition-status.d.ts +81 -0
- package/dist/settings/write-definition-status.js +121 -0
- package/dist/settings/write-reset.d.ts +34 -0
- package/dist/settings/write-reset.js +73 -0
- package/dist/settings/write-service.d.ts +16 -287
- package/dist/settings/write-service.js +49 -681
- package/dist/settings/write-value-revisions.d.ts +68 -0
- package/dist/settings/write-value-revisions.js +124 -0
- package/dist/settings/write-values.d.ts +96 -0
- package/dist/settings/write-values.js +83 -0
- package/dist/surface-exchanges.d.ts +2 -2
- package/dist/text/dictionary-translator.d.ts +19 -0
- package/dist/text/dictionary-translator.js +14 -0
- package/dist/text/format-byte-size.d.ts +25 -0
- package/dist/text/format-byte-size.js +25 -0
- package/dist/text/format-timestamp.d.ts +22 -0
- package/dist/text/format-timestamp.js +57 -0
- package/dist/text/index.d.ts +12 -0
- package/dist/text/index.js +9 -0
- package/dist/text/is-abort-error.d.ts +5 -0
- package/dist/text/is-abort-error.js +5 -0
- package/dist/text/mime.d.ts +5 -0
- package/dist/text/mime.js +21 -0
- package/dist/text/redact-urls.d.ts +7 -0
- package/dist/text/redact-urls.js +5 -0
- package/dist/text/resolve-active-tab-id.d.ts +13 -0
- package/dist/text/resolve-active-tab-id.js +15 -0
- package/dist/text/sanitize-untrusted-text.d.ts +1 -1
- package/dist/text/sanitize-untrusted-text.js +2 -1
- package/dist/text/tagged-text-suppression.d.ts +103 -0
- package/dist/text/tagged-text-suppression.js +143 -0
- package/dist/text/template-i18n.d.ts +37 -0
- package/dist/text/template-i18n.js +48 -0
- package/dist/tool-call-text.d.ts +59 -0
- package/dist/tool-call-text.js +62 -0
- package/dist/tool-input-envelope.js +8 -4
- package/dist/tool-input-normalization.js +8 -1
- package/dist/tool-input-repairs.d.ts +58 -0
- package/dist/tool-input-repairs.js +154 -0
- package/dist/tool-tokens.js +1 -1
- package/dist/user-facing-error.d.ts +1 -1
- package/dist/user-facing-error.js +3 -1
- package/package.json +234 -13
- package/dist/settings/express/contracts.js +0 -2
- package/dist/settings/express/http-request.d.ts +0 -33
- package/dist/settings/express/http-request.js +0 -50
- package/dist/settings/express/http.d.ts +0 -10
- package/dist/settings/express/http.js +0 -196
- package/dist/settings/express/index.d.ts +0 -5
- package/dist/settings/express/index.js +0 -4
- package/dist/settings/express/shared.d.ts +0 -68
- package/dist/settings/express/stream.d.ts +0 -24
- package/dist/settings/express/stream.js +0 -171
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
// Order matters: list specific rules before more general ones. Langfuse
|
|
2
|
+
// keys (`sk-lf-...`) would otherwise be eaten by the generic `sk-...`
|
|
3
|
+
// rule and labeled as a generic OpenAI-style key.
|
|
4
|
+
// One IPv4 octet, 0-255, so junk shapes like 999.1.1.1 do not count.
|
|
5
|
+
const IPV4_OCTET = '(?:25[0-5]|2[0-4]\\d|[01]?\\d?\\d)';
|
|
6
|
+
// Optional +country code, then a bare or parenthesized area code, with optional separators.
|
|
7
|
+
const PHONE_SEPARATOR = '[\\s.-]?';
|
|
8
|
+
const PHONE_COUNTRY_CODE = /(?:\+?\d{1,3}[\s.-]?)?/;
|
|
9
|
+
const PHONE_AREA_CODE = /(?:\(\d{3}\)|\d{3})/;
|
|
10
|
+
export const PATTERNS = [
|
|
11
|
+
// Langfuse public/secret keys (pk-lf- / sk-lf-). Must run before the
|
|
12
|
+
// generic sk- rule so the more specific label wins.
|
|
13
|
+
{ name: 'langfuse_key', regex: /\b(?:pk|sk)-lf-[A-Za-z0-9-]{16,}\b/g },
|
|
14
|
+
// Anthropic / OpenAI-style keys: 'sk-' + optional sub-prefix + base64-ish.
|
|
15
|
+
// Both vendors plus a long tail of OpenAI-compatible providers (DeepSeek,
|
|
16
|
+
// MiniMax, Together, etc.) ship keys in this shape, so a single rule
|
|
17
|
+
// covers most "sk-..." secrets a user might paste into a prompt.
|
|
18
|
+
{ name: 'sk_key', regex: /\bsk-(?:proj-|live-|test-|ant-)?[A-Za-z0-9_-]{20,}\b/g },
|
|
19
|
+
// GitHub personal / OAuth / server / user-server / refresh tokens.
|
|
20
|
+
{ name: 'github_token', regex: /\bgh[opsur]_[A-Za-z0-9]{36,}\b/g },
|
|
21
|
+
// GitHub legacy 40-hex personal access tokens that ship with no prefix
|
|
22
|
+
// are indistinguishable from a sha1 hash, so we don't try to match them
|
|
23
|
+
// here — false positives would be brutal in commit logs / artifact slugs.
|
|
24
|
+
// AWS access key id. The matching secret access key is just 40 base64
|
|
25
|
+
// chars with no fixed shape, so we cannot reliably redact it without
|
|
26
|
+
// huge collateral damage; flagging the access key id at least
|
|
27
|
+
// signals a paste happened.
|
|
28
|
+
{ name: 'aws_access_key', regex: /\bAKIA[0-9A-Z]{16}\b/g },
|
|
29
|
+
// Google API keys — legacy AIza… (Maps / AI Studio) and service-account-
|
|
30
|
+
// bound AQ.… keys AI Studio now issues. AQ. must run before the generic
|
|
31
|
+
// sk_ rule would mis-label unrelated tokens.
|
|
32
|
+
{ name: 'google_api_key', regex: /\bAQ\.[A-Za-z0-9_-]{20,}\b/g },
|
|
33
|
+
{ name: 'google_api_key', regex: /\bAIza[0-9A-Za-z_-]{35}\b/g },
|
|
34
|
+
// Slack tokens.
|
|
35
|
+
{ name: 'slack_token', regex: /\bxox[abprs]-[0-9A-Za-z-]{10,}\b/g },
|
|
36
|
+
// Stripe keys.
|
|
37
|
+
{ name: 'stripe_key', regex: /\b(?:sk|pk|rk)_(?:live|test)_[0-9a-zA-Z]{16,}\b/g },
|
|
38
|
+
// JSON Web Tokens. The "header.payload.signature" triple is distinctive
|
|
39
|
+
// enough that false positives are rare (the literal "eyJ" prefix is the
|
|
40
|
+
// base64 encoding of '{"' which is how every JOSE header starts).
|
|
41
|
+
{ name: 'jwt', regex: /(?<!\w)(?<!(?<!\w)eyJ[A-Za-z0-9_-]*?)eyJ[A-Za-z0-9_-]+\.eyJ[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+\b/g },
|
|
42
|
+
// Bearer tokens in HTTP Authorization header copy/paste. We only match
|
|
43
|
+
// the value, not the literal 'Bearer ', so the marker stays readable in
|
|
44
|
+
// the redacted output ("Authorization: Bearer [REDACTED:bearer_token]").
|
|
45
|
+
// The leading lookahead only lets the lookbehind run where a value can start, so a long
|
|
46
|
+
// whitespace run is not rescanned from every position inside it.
|
|
47
|
+
{ name: 'bearer_token', regex: /(?=[A-Za-z0-9._~+/-])(?<=\bBearer\s+)[A-Za-z0-9._~+/-]{16,}={0,2}/g },
|
|
48
|
+
// Email addresses. Conservative enough to require a TLD-like trailer. The local part is
|
|
49
|
+
// bounded at the RFC 5321 limit of 64: an unbounded run rescanned the suffix from every word
|
|
50
|
+
// boundary, so `'a.'.repeat(20000)` blocked ~3 s on a large tool response. Matching starts at
|
|
51
|
+
// the `@` and reads the local part in a lookbehind (captured as `local`): starting at every word
|
|
52
|
+
// boundary still cost up to 64 steps per position, ~2.5 s on 10 MiB of `'eyJ-'`.
|
|
53
|
+
// Alphabetic TLDs preserve versioned package paths in error stacks (e.g. pkg@1.2.3).
|
|
54
|
+
{ name: 'email', regex: /@(?<=\b(?<local>[\w.+-]{1,64})@)(?:[\w-]+\.)+[A-Za-z]{2,}\b/g },
|
|
55
|
+
// IPv4. Reject all-zero / 255.255.255.255-ish junk shapes by gating on
|
|
56
|
+
// each octet being 0-255.
|
|
57
|
+
{
|
|
58
|
+
name: 'ipv4',
|
|
59
|
+
regex: new RegExp(`\\b(?:${IPV4_OCTET}\\.){3}${IPV4_OCTET}\\b`, 'g'),
|
|
60
|
+
},
|
|
61
|
+
// Phone numbers. Tight US-leaning shape; a global PII detector would
|
|
62
|
+
// need a real lib. We keep this so US-based test prompts ('call me at
|
|
63
|
+
// (415) 555-...') don't ship. Note: no leading \b — '(' isn't a word
|
|
64
|
+
// char, so a starting boundary would refuse to match `(415)`. Reject
|
|
65
|
+
// adjacent word characters or hyphens so digit segments of UUIDs,
|
|
66
|
+
// hashes and identifiers stay readable; separators within phones still match.
|
|
67
|
+
{
|
|
68
|
+
name: 'phone',
|
|
69
|
+
regex: new RegExp(`(?<![\\w-])${PHONE_COUNTRY_CODE.source}${PHONE_AREA_CODE.source}${PHONE_SEPARATOR}\\d{3}${PHONE_SEPARATOR}\\d{4}(?![\\w-])`, 'g'),
|
|
70
|
+
},
|
|
71
|
+
];
|
|
72
|
+
// Categories the pipeline names directly; pattern rules carry their own names. Masked-value
|
|
73
|
+
// checks and exact-secret masking derive the set of markers redact can generate from these
|
|
74
|
+
// plus the pattern names.
|
|
75
|
+
export const CATEGORY = {
|
|
76
|
+
exactSecret: 'exact_secret',
|
|
77
|
+
credential: 'credential',
|
|
78
|
+
urlCredentials: 'url_credentials',
|
|
79
|
+
signedQuery: 'signed_query',
|
|
80
|
+
apiKeyHeader: 'api_key_header',
|
|
81
|
+
apiKeyQuery: 'api_key_query',
|
|
82
|
+
bearerToken: 'bearer_token',
|
|
83
|
+
labeledSecret: 'labeled_secret',
|
|
84
|
+
urlSecretParam: 'url_secret_param',
|
|
85
|
+
opaqueToken: 'opaque_token',
|
|
86
|
+
creditCard: 'credit_card',
|
|
87
|
+
};
|
|
88
|
+
// Only markers redact itself generates count as masked: arbitrary `[REDACTED:<text>]` would let
|
|
89
|
+
// echoed input such as `[REDACTED:<secret>]` keep the real secret. A fixed category alternation
|
|
90
|
+
// also bounds each marker attempt; `[^\]]*` rescanned the suffix after every unterminated
|
|
91
|
+
// `[REDACTED:`, which was quadratic on large tool responses.
|
|
92
|
+
const GENERATED_CATEGORIES = [...PATTERNS.map(({ name }) => name), ...Object.values(CATEGORY)];
|
|
93
|
+
function escapeRegExp(text) {
|
|
94
|
+
return text.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
|
95
|
+
}
|
|
96
|
+
function markerSource(categories) {
|
|
97
|
+
return `\\[REDACTED:(?:${[...new Set(categories)].map(escapeRegExp).join('|')})\\]`;
|
|
98
|
+
}
|
|
99
|
+
export const GENERATED_MARKER = markerSource(GENERATED_CATEGORIES);
|
|
100
|
+
/** Every marker redact can generate from its built-in categories; consumers normalize only these. */
|
|
101
|
+
export const GENERATED_MARKER_RE = new RegExp(GENERATED_MARKER, 'g');
|
|
102
|
+
// Credit card sweep is special: a naive 13-19 digit run matches a lot of
|
|
103
|
+
// non-card numbers (timestamps, IDs, hashes). We isolate the candidate
|
|
104
|
+
// then run a Luhn check before redacting.
|
|
105
|
+
export const CARD_CANDIDATE = /\b(?:\d[ -]?){12,18}\d\b/g;
|
|
106
|
+
// Inspect/JSON credentials can contain spaces and escaped quotes; consume the entire value.
|
|
107
|
+
export const QUOTED_SECRET_VALUE = String.raw `"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'`;
|
|
108
|
+
export const API_KEY_HEADER = new RegExp(`(^|[^?&\\w])(["']?)(x-api-key|api-key|x-goog-api-key)\\2(\\s*[:=]\\s*)(${QUOTED_SECRET_VALUE}|[^\\s,;"'#}]+)`, 'gi');
|
|
109
|
+
export const API_KEY_QUERY = /([?&](?:key|api_key|api-key)=)[^&#\s,;"']+/gi;
|
|
110
|
+
// A labeled credential has its value masked even when too short to have a vendor token shape.
|
|
111
|
+
// Bare long opaque runs are opt-in CLI heuristics: UUIDs, hashes, model IDs and path segments
|
|
112
|
+
// share that alphabet, so the default telemetry policy must leave them readable. Whole
|
|
113
|
+
// correlation IDs, UPPER_SNAKE diagnostic codes and the delegated-tool route stay readable even in aggressive mode;
|
|
114
|
+
// appending secret characters defeats that exception. The host's ERR-XXXX-XXXX-XXXX-XXXX
|
|
115
|
+
// correlation ID uses uppercase hex and is meant to reach the model and be quoted to an
|
|
116
|
+
// operator; delegated-tool-calls is the route segment named in delegated tool failures.
|
|
117
|
+
// Matching the ENTIRE run keeps a secret glued onto either spelling redactable.
|
|
118
|
+
const SECRET_LABELS = 'authorization|bearer|api[-_]?key|access[-_]?token|refresh[-_]?token|client[-_]?secret|password|secret|cookie';
|
|
119
|
+
// Keep historical URL categories and the bounded sanitizer's vocabulary stable.
|
|
120
|
+
const SERIALIZED_SECRET_LABELS = `${SECRET_LABELS}|x[-_](?:goog[-_])?api[-_]?key|api key|token|set[-_]cookie|private[-_]?key`;
|
|
121
|
+
export const EMPTY_QUOTED_ASSIGNMENT_RE = new RegExp(`\\b(?:${SERIALIZED_SECRET_LABELS})\\s*[:=]\\s*$`, 'i');
|
|
122
|
+
export const LABELED_SECRET_RE = new RegExp(`\\b(${SECRET_LABELS})\\b\\s*[:=]\\s*\\S+`, 'gi');
|
|
123
|
+
export const OPAQUE_TOKEN_RE = /[A-Za-z0-9_-]{20,}/g;
|
|
124
|
+
// Pattern parts, only ever used inside the anchored NON_SECRET_TOKEN_RE.
|
|
125
|
+
const CORRELATION_ID = 'ERR-[0-9A-F]{4}(?:-[0-9A-F]{4}){3}';
|
|
126
|
+
const UPPER_SNAKE_DIAGNOSTIC = '[A-Z][A-Z0-9]*(?:_[A-Z0-9]+)+';
|
|
127
|
+
export const NON_SECRET_TOKEN_RE = new RegExp(`^(?:${CORRELATION_ID}|delegated-tool-calls|${UPPER_SNAKE_DIAGNOSTIC})$`);
|
|
128
|
+
// Runtime markers must survive a second pass; the bounded sanitizer deliberately retains
|
|
129
|
+
// its historical lowercase marker contract and uses the unmodified lexical vocabulary.
|
|
130
|
+
// Reject a masked header/query value before matching, so a following field's credential
|
|
131
|
+
// remains available to the global scan rather than being consumed beside the marker.
|
|
132
|
+
// Only the value's first character is matched; forward-only finders supply its end (see
|
|
133
|
+
// labelValueExtents). Matching `\S+` and rewinding to skip a covered field rescanned the rest of
|
|
134
|
+
// the run per label: quadratic on `'api-key=x;'.repeat(n)`.
|
|
135
|
+
// Bare URL key/token parameters already have owners; leave their empty values and categories
|
|
136
|
+
// to those collectors instead of treating the following `&page=...` as a label's value.
|
|
137
|
+
const RUNTIME_SECRET_LABELS = `${SERIALIZED_SECRET_LABELS}|(?<![?&])(?:key)`;
|
|
138
|
+
export const MASK_AWARE_LABELED_SECRET_RE = new RegExp(`(?<![\\w-])(["']?)(${RUNTIME_SECRET_LABELS})\\1\\s*[:=]\\s*`
|
|
139
|
+
+ `(?!Bearer\\s+\\S)(?!${GENERATED_MARKER}[;&])((?!&)\\S)`, 'gi');
|
|
140
|
+
// A label can name another label; resume at it instead of consuming `token:` and leaking its value.
|
|
141
|
+
export const CHAINED_LABEL_RE = new RegExp(`(?:${RUNTIME_SECRET_LABELS})\\b["']?\\s*[:=]\\s*(?=\\S)`, 'iy');
|
|
142
|
+
// Provider failures also echo short bearer values. Exclude our own marker on subsequent passes.
|
|
143
|
+
// The value is read in a lookahead so the scan resumes at it (`Bearer Bearer x` masks both),
|
|
144
|
+
// as the earlier lookbehind form did, without a lookbehind test at every position.
|
|
145
|
+
// Quotes and field delimiters end the value; punctuation such as `!` remains credential text.
|
|
146
|
+
export const SHORT_BEARER_RE = new RegExp(`Bearer\\s+["']?(?!${GENERATED_MARKER}(?=$|[\\s"',;<>}]))(?=([^\\s"',;<>}]+))`, 'gi');
|
|
147
|
+
export const BASIC_AUTH_RE = /\bauthorization["']?\s*[:=]\s*["']?(Basic\s+[^\s"',;}]+)/gi;
|
|
148
|
+
// Cookie pairs belong to one header value, including pairs after a semicolon and a space.
|
|
149
|
+
export const COOKIE_HEADER_RE = /\bcookie\s*:\s*([^\r\n]+)/gi;
|
|
150
|
+
export const PROVIDER_API_KEY_QUERY = /([?&]key=)([^&\s"']+)/gi;
|
|
151
|
+
// URL userinfo and signed query values have explicit credential context; unlike opaque runs,
|
|
152
|
+
// they are safe to recognize in the conservative policy. Keep scheme/host and query names
|
|
153
|
+
// readable for debugging without exposing credentials that authorize access to the resource.
|
|
154
|
+
// Matching starts at `//` and reads the userinfo forward to `@` within the authority. No scheme
|
|
155
|
+
// scan is needed, so a scheme of any length (glued text included) cannot hide its userinfo:
|
|
156
|
+
// an unbounded scheme run rescanned the suffix from every start
|
|
157
|
+
// (`'a.'.repeat(20000)` blocked ~3.6 s), trying a bounded scheme at every position cost ~2 s on
|
|
158
|
+
// 10 MiB of `'eyJ-'`, and a 32-character scheme lookbehind missed longer schemes.
|
|
159
|
+
// The same authority syntax also appears in scheme-relative URLs (`//user:pw@host`).
|
|
160
|
+
export const URL_CREDENTIALS_RE = /\/\/([^/\s?#@]+)@/g;
|
|
161
|
+
export const SIGNED_QUERY_RE = /([?&](?:signature|sig|x-amz-signature|x-goog-signature|access_token|refresh_token)=)([^&#\s,;"']+)/gi;
|
|
162
|
+
// A secret word must END a name segment (split at . _ - or the name's end): api_key, apiKey,
|
|
163
|
+
// authtoken, X-Amz-Signature and custom.Token-value are masked, while author, keyword, design,
|
|
164
|
+
// signup and page stay readable. Names that merely end in a secret word (zipcode, error_code,
|
|
165
|
+
// monkey) are masked too; over-masking a URL value is the cheaper failure. Empty values stay.
|
|
166
|
+
// Match through a trailing fragment; field separators (&/;), quotes, parentheses or whitespace end it.
|
|
167
|
+
// Both name runs are bounded so a long separator-free run costs linear time, not quadratic.
|
|
168
|
+
const URL_SECRET_WORDS = 'token|key|secret|signature|sig|code|password|passwd|pwd|auth|authorization|credential';
|
|
169
|
+
export const URL_SECRET_PARAM_RE = new RegExp(`[?&#;]([\\w.-]{0,128}?(?:${URL_SECRET_WORDS})s?(?=[._=-])[\\w.-]{0,128})=[^&;\\s"'<>()]+`, 'gi');
|
|
170
|
+
// A parameter the labeled rule already names (password, client_secret, ...) keeps that category.
|
|
171
|
+
export const LABELED_URL_PARAM_NAME_RE = new RegExp(`(?:^|[.-])(?:${SECRET_LABELS})$`, 'i');
|
|
172
|
+
// Only an entire generated marker is already masked. A secret glued onto marker-like text still
|
|
173
|
+
// needs masking; a substring check would preserve credential suffixes in echoed header/query values.
|
|
174
|
+
const MASKED_VALUE_RE = new RegExp(`^["']?${GENERATED_MARKER}["']?$`);
|
|
175
|
+
export function isMaskedValue(value) {
|
|
176
|
+
return MASKED_VALUE_RE.test(value);
|
|
177
|
+
}
|
|
178
|
+
//# sourceMappingURL=redaction-patterns.js.map
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/** A half-open `[start, end)` range of the original input that one rule masks. */
|
|
2
|
+
export interface Span {
|
|
3
|
+
start: number;
|
|
4
|
+
end: number;
|
|
5
|
+
category: string;
|
|
6
|
+
suffix?: string | undefined;
|
|
7
|
+
}
|
|
8
|
+
/** Records a span; empty ranges are dropped. */
|
|
9
|
+
export type AddSpan = (start: number, end: number, category: string, suffix?: string) => void;
|
|
10
|
+
export interface SpanPass {
|
|
11
|
+
text: string;
|
|
12
|
+
add: AddSpan;
|
|
13
|
+
}
|
|
14
|
+
/** Orders spans and merges overlapping or adjacent ones; masking whole merged runs means no rule's
|
|
15
|
+
* leftover can expose part of another rule's value.
|
|
16
|
+
* Category rule: the longest constituent span names the merged span; on a tie the earlier rule in
|
|
17
|
+
* {@link collectSpans} wins, so an exact rule labels a known secret it matches exactly
|
|
18
|
+
* (`t=<known-token>` stays `exact_secret`) and the exact-secret category marks what only it covers.
|
|
19
|
+
* @complexity O(k) time and space for k spans (string offsets fit in unsigned 32 bits). */
|
|
20
|
+
export declare function mergeSpans(spans: readonly Span[], { keepAdjacent }?: {
|
|
21
|
+
keepAdjacent?: boolean | undefined;
|
|
22
|
+
}): Span[];
|
|
23
|
+
/** Adds one span per match of `regex`; `spanOf` maps a match to its value range, or skips it. */
|
|
24
|
+
export declare function collectMatches({ text, add }: SpanPass, regex: RegExp, spanOf: (match: RegExpMatchArray, index: number) => Span | undefined): void;
|
|
25
|
+
/** Span of the match's trailing capture `group`, unless that value is already a generated marker
|
|
26
|
+
* (already masked values are not new credentials and should not inflate the audit count). */
|
|
27
|
+
export declare function trailingValue({ category, group }: {
|
|
28
|
+
category: string;
|
|
29
|
+
group: number;
|
|
30
|
+
}, _optional?: {}): (match: RegExpMatchArray, index: number) => Span | undefined;
|
|
31
|
+
//# sourceMappingURL=redaction-spans.d.ts.map
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { isMaskedValue } from './redaction-patterns.js';
|
|
2
|
+
/** Orders spans and merges overlapping or adjacent ones; masking whole merged runs means no rule's
|
|
3
|
+
* leftover can expose part of another rule's value.
|
|
4
|
+
* Category rule: the longest constituent span names the merged span; on a tie the earlier rule in
|
|
5
|
+
* {@link collectSpans} wins, so an exact rule labels a known secret it matches exactly
|
|
6
|
+
* (`t=<known-token>` stays `exact_secret`) and the exact-secret category marks what only it covers.
|
|
7
|
+
* @complexity O(k) time and space for k spans (string offsets fit in unsigned 32 bits). */
|
|
8
|
+
export function mergeSpans(spans, { keepAdjacent = false } = {}) {
|
|
9
|
+
const merged = [];
|
|
10
|
+
for (const rank of orderedSpanRanks({ spans })) {
|
|
11
|
+
const span = spans[rank];
|
|
12
|
+
const length = span.end - span.start;
|
|
13
|
+
const last = merged.at(-1);
|
|
14
|
+
if (!last || startsSeparateSpan({ start: span.start, end: last.end, keepAdjacent })) {
|
|
15
|
+
merged.push({ start: span.start, end: span.end, category: span.category, suffix: span.suffix, rank, categoryLength: length });
|
|
16
|
+
continue;
|
|
17
|
+
}
|
|
18
|
+
if (span.end >= last.end)
|
|
19
|
+
last.suffix = span.suffix;
|
|
20
|
+
last.end = Math.max(last.end, span.end);
|
|
21
|
+
if (length > last.categoryLength || (length === last.categoryLength && rank < last.rank)) {
|
|
22
|
+
Object.assign(last, { category: span.category, rank, categoryLength: length });
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
return merged;
|
|
26
|
+
}
|
|
27
|
+
/** Literal-only replacements preserve adjacent occurrences as distinct markers and counts. */
|
|
28
|
+
function startsSeparateSpan({ start, end, keepAdjacent }, _options = {}) {
|
|
29
|
+
return keepAdjacent ? start >= end : start > end;
|
|
30
|
+
}
|
|
31
|
+
/** Stable byte-wise radix order of span starts; ranks retain the original rule precedence.
|
|
32
|
+
* Dense labels produce millions of spans: sorting cloned objects both cost k log k and amplified
|
|
33
|
+
* GC. Four counting passes over integer ranks avoid those clones and bound work to O(k), with
|
|
34
|
+
* O(k) scratch space. JavaScript string offsets fit in 32 bits. No caller-owned data is mutated. */
|
|
35
|
+
function orderedSpanRanks({ spans }) {
|
|
36
|
+
let ranks = Uint32Array.from(spans, (_span, rank) => rank);
|
|
37
|
+
let scratch = new Uint32Array(ranks.length);
|
|
38
|
+
const offsets = new Uint32Array(256);
|
|
39
|
+
for (let shift = 0; shift < 32; shift += 8) {
|
|
40
|
+
offsets.fill(0);
|
|
41
|
+
for (const rank of ranks) {
|
|
42
|
+
const bucket = (spans[rank].start >>> shift) & 255;
|
|
43
|
+
offsets[bucket] = (offsets[bucket] ?? 0) + 1;
|
|
44
|
+
}
|
|
45
|
+
let total = 0;
|
|
46
|
+
for (let bucket = 0; bucket < offsets.length; bucket++) {
|
|
47
|
+
const count = offsets[bucket] ?? 0;
|
|
48
|
+
offsets[bucket] = total;
|
|
49
|
+
total += count;
|
|
50
|
+
}
|
|
51
|
+
for (const rank of ranks) {
|
|
52
|
+
const bucket = (spans[rank].start >>> shift) & 255;
|
|
53
|
+
const position = offsets[bucket] ?? 0;
|
|
54
|
+
scratch[position] = rank;
|
|
55
|
+
offsets[bucket] = position + 1;
|
|
56
|
+
}
|
|
57
|
+
[ranks, scratch] = [scratch, ranks];
|
|
58
|
+
}
|
|
59
|
+
return ranks;
|
|
60
|
+
}
|
|
61
|
+
/** Adds one span per match of `regex`; `spanOf` maps a match to its value range, or skips it. */
|
|
62
|
+
export function collectMatches({ text, add }, regex, spanOf) {
|
|
63
|
+
// Clone so a caller-owned or shared regex never carries lastIndex state across requests;
|
|
64
|
+
// non-global extra patterns use the same every-occurrence contract as the built-ins.
|
|
65
|
+
const flags = regex.flags.includes('g') ? regex.flags : `${regex.flags}g`;
|
|
66
|
+
for (const match of text.matchAll(new RegExp(regex.source, flags))) {
|
|
67
|
+
const span = spanOf(match, match.index ?? 0);
|
|
68
|
+
if (span)
|
|
69
|
+
add(span.start, span.end, span.category);
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
/** Span of the match's trailing capture `group`, unless that value is already a generated marker
|
|
73
|
+
* (already masked values are not new credentials and should not inflate the audit count). */
|
|
74
|
+
export function trailingValue({ category, group }, _optional = {}) {
|
|
75
|
+
return (match, index) => {
|
|
76
|
+
const value = match[group] ?? '';
|
|
77
|
+
if (isMaskedValue(value))
|
|
78
|
+
return undefined;
|
|
79
|
+
const end = index + match[0].length;
|
|
80
|
+
return { start: end - value.length, end, category };
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
//# sourceMappingURL=redaction-spans.js.map
|
|
@@ -72,7 +72,7 @@ export declare const AGENT_TOOL_PRINCIPAL_KIND: "agent";
|
|
|
72
72
|
* {@link humanConfirmedHandler}, which asks the human through the host's own confirmation transport
|
|
73
73
|
* and runs the action only on an explicit yes. Any other handler fails the build.
|
|
74
74
|
*/
|
|
75
|
-
export declare const ACTOR_CLASS_RULES_REQUIRING_CONFIRMATION_TRANSPORT:
|
|
75
|
+
export declare const ACTOR_CLASS_RULES_REQUIRING_CONFIRMATION_TRANSPORT: ReadonlySet<string>;
|
|
76
76
|
/**
|
|
77
77
|
* The human who confirmed, as {@link humanConfirmedHandler} hands it to `run`: always the run's own
|
|
78
78
|
* delegating principal (`ctx.principal.id`, see {@link AGENT_TOOL_PRINCIPAL_KIND}), always
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file The settings-ledger revision-conflict error, kept at the package root (it is the one settings
|
|
3
|
+
* error the root `optimistic-concurrency` bridge must recognise; `./settings/errors.js` re-exports it).
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* A scoped value changed since the caller's snapshot; read again before retrying.
|
|
7
|
+
* Both sequences refer to the addressed value row, never the ledger's global watermark.
|
|
8
|
+
* @example if (error instanceof SettingsRevisionConflictError) await refreshSnapshot();
|
|
9
|
+
*/
|
|
10
|
+
export declare class SettingsRevisionConflictError extends Error {
|
|
11
|
+
readonly expectedRevisionSeq: number;
|
|
12
|
+
readonly actualRevisionSeq: number;
|
|
13
|
+
constructor(required: {
|
|
14
|
+
expectedRevisionSeq: number;
|
|
15
|
+
actualRevisionSeq: number;
|
|
16
|
+
}, optional?: ErrorOptions);
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=revision-conflict-error.d.ts.map
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @file The settings-ledger revision-conflict error, kept at the package root (it is the one settings
|
|
3
|
+
* error the root `optimistic-concurrency` bridge must recognise; `./settings/errors.js` re-exports it).
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* A scoped value changed since the caller's snapshot; read again before retrying.
|
|
7
|
+
* Both sequences refer to the addressed value row, never the ledger's global watermark.
|
|
8
|
+
* @example if (error instanceof SettingsRevisionConflictError) await refreshSnapshot();
|
|
9
|
+
*/
|
|
10
|
+
export class SettingsRevisionConflictError extends Error {
|
|
11
|
+
expectedRevisionSeq;
|
|
12
|
+
actualRevisionSeq;
|
|
13
|
+
constructor(required, optional = {}) {
|
|
14
|
+
super(`Setting revision changed: expected ${required.expectedRevisionSeq}, found ${required.actualRevisionSeq}.`, optional);
|
|
15
|
+
this.name = "SettingsRevisionConflictError";
|
|
16
|
+
this.expectedRevisionSeq = required.expectedRevisionSeq;
|
|
17
|
+
this.actualRevisionSeq = required.actualRevisionSeq;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=revision-conflict-error.js.map
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/** Credential-shape vocabulary for secret-only redaction; no I/O or host dependencies. */
|
|
2
|
+
export interface SecretShapePattern {
|
|
3
|
+
readonly name: string;
|
|
4
|
+
readonly pattern: RegExp;
|
|
5
|
+
}
|
|
6
|
+
export declare const PEM_PATTERN_NAME = "PEM private key block";
|
|
7
|
+
export declare const SECRET_SHAPE_PATTERNS: readonly SecretShapePattern[];
|
|
8
|
+
/**
|
|
9
|
+
* Suppress PEM bodies across complete, ordered text lines before other redactors run.
|
|
10
|
+
* @param _required No ambient state; create one instance per framed output stream.
|
|
11
|
+
* @param _options Reserved optional policy inputs.
|
|
12
|
+
* @returns A line redactor and an EOF reset. Call reset after flushing the final line so a
|
|
13
|
+
* replacement child cannot inherit an unterminated block. Does not frame raw chunks or do I/O.
|
|
14
|
+
* @complexity O(n) per line; O(h) retained state for the open header's key type of length h.
|
|
15
|
+
* @example const keys = createPrivateKeyLineRedactor({}, {}); keys.redact({ text: line }, {});
|
|
16
|
+
*/
|
|
17
|
+
export declare function createPrivateKeyLineRedactor(_required: Record<string, never>, _options?: {}): {
|
|
18
|
+
redact(required: {
|
|
19
|
+
text: string;
|
|
20
|
+
}, optional?: Record<string, never>): string;
|
|
21
|
+
reset(required: Record<string, never>, optional?: Record<string, never>): void;
|
|
22
|
+
};
|
|
23
|
+
export declare const AGENT_FAILURE_SECRET_SHAPE_RE: RegExp;
|
|
24
|
+
/**
|
|
25
|
+
* Exact path SEGMENT names refused at any depth, matched case-insensitively against each segment
|
|
26
|
+
* of the caller-supplied path (never a substring — a directory named `not-secrets-actually` is not
|
|
27
|
+
* a match). `secrets` is the owner's explicit example: whatever a site or app tree names its
|
|
28
|
+
* credentials folder (`sites/**\/secrets/`, `app/**\/secrets/`, or anywhere else), it never
|
|
29
|
+
* becomes reachable through this domain. A denied segment is refused by the guarded reader
|
|
30
|
+
* AND skipped entirely by the `fs_list_files` walk — its contents are never even enumerated,
|
|
31
|
+
* not merely refused once named. Besides `secrets`, the set names the
|
|
32
|
+
* well-known credential-store directories a home-directory `custom` root can expose: `.aws`
|
|
33
|
+
* (`credentials`), `.docker` (`config.json` with registry auth), `.kube` (`config`), and
|
|
34
|
+
* `gcloud`/`gh` for `.config/gcloud/application_default_credentials.json` and
|
|
35
|
+
* `.config/gh/hosts.yml`. Denied by SEGMENT rather than by leaf filename on purpose: `config`,
|
|
36
|
+
* `config.json`, and `hosts.yml` are generic names that appear harmlessly elsewhere, so denying the
|
|
37
|
+
* directory is the narrower of the two mistakes.
|
|
38
|
+
*
|
|
39
|
+
* A host's install-wide site-key directory (2026-09-24) needs the same protection; the host appends it.
|
|
40
|
+
* Production stores it beside individual site folders on a durable volume; local/dev stores
|
|
41
|
+
* it below the home directory, reachable through an operator-set `custom` root. Its key backs
|
|
42
|
+
* site-key administration, webhook/newsletter signing secrets, and permission checks, so the
|
|
43
|
+
* agent must never read it from disk. Denying the whole directory segment, rather than only
|
|
44
|
+
* a generated key filename, also prevents `fs_list_files` from enumerating its contents — the
|
|
45
|
+
* same "never even advertise it" property `secrets` gets above.
|
|
46
|
+
*/
|
|
47
|
+
export declare const CREDENTIAL_FILE_DENY_SEGMENTS: readonly string[];
|
|
48
|
+
export declare const LOCAL_OWNER_PROXY_MARKER_PREFIXES: readonly string[];
|
|
49
|
+
export declare const LOCAL_OWNER_PROXY_MARKER_HEADERS: readonly string[];
|
|
50
|
+
//# sourceMappingURL=secret-shapes.d.ts.map
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
/** Credential-shape vocabulary for secret-only redaction; no I/O or host dependencies. */
|
|
2
|
+
// Named once and reused (by SECRET_SHAPE_PATTERNS here and by the guard's ALLOWLIST) rather than repeated
|
|
3
|
+
// as a literal in multiple places.
|
|
4
|
+
export const PEM_PATTERN_NAME = "PEM private key block";
|
|
5
|
+
const PRIVATE_KEY_HEADER = /-----BEGIN ([A-Z ]*)PRIVATE KEY-----/;
|
|
6
|
+
// Consume the body before any token/label rule can erase the delimiters. A missing footer
|
|
7
|
+
// masks through EOF; a different key type's footer cannot close this block.
|
|
8
|
+
const PRIVATE_KEY_BLOCK = /-----BEGIN ([A-Z ]*)PRIVATE KEY-----[\s\S]*?(?:-----END \1PRIVATE KEY-----|$)/;
|
|
9
|
+
// Share data between static scans and runtime redactors without importing a CLI entry point:
|
|
10
|
+
// top-level argv/path handling in a scanner can crash a daemon that imports it. Keeping the
|
|
11
|
+
// vocabulary dependency-free also avoids making core redaction depend on feature code.
|
|
12
|
+
// Match each vendor's actual alphabet. Fixed-length patterns need lookaround boundaries so a
|
|
13
|
+
// credential-shaped substring of a longer inert value is not mistaken for a complete secret.
|
|
14
|
+
export const SECRET_SHAPE_PATTERNS = [
|
|
15
|
+
{ name: "Google API key (AIza)", pattern: /(?<![A-Za-z0-9_-])AIza[0-9A-Za-z_-]{35}(?![A-Za-z0-9_-])/ },
|
|
16
|
+
{ name: "Anthropic API key (sk-ant-)", pattern: /(?<![A-Za-z0-9_-])sk-ant-[A-Za-z0-9_-]{90,}/ },
|
|
17
|
+
{ name: "generic sk- secret key (OpenAI-shaped)", pattern: /(?<![A-Za-z0-9_-])sk-[A-Za-z0-9]{40,}/ },
|
|
18
|
+
{ name: "GitHub personal access token (classic, ghp_)", pattern: /(?<!\w)ghp_\w{36}(?!\w)/ },
|
|
19
|
+
{ name: "GitHub OAuth token (gho_)", pattern: /(?<!\w)gho_\w{36}(?!\w)/ },
|
|
20
|
+
{ name: "GitHub fine-grained PAT", pattern: /(?<!\w)github_pat_\w{80,}/ },
|
|
21
|
+
{ name: "npm access token", pattern: /(?<!\w)npm_\w{36}(?!\w)/ },
|
|
22
|
+
{ name: "Slack token", pattern: /(?<![A-Za-z0-9-])xox[baprs]-[A-Za-z0-9-]{12,}/ },
|
|
23
|
+
{ name: "AWS access key ID", pattern: /(?<![0-9A-Z])AKIA[0-9A-Z]{16}(?![0-9A-Z])/ },
|
|
24
|
+
{ name: "Fastmail app password (fm2_)", pattern: /(?<![A-Za-z0-9+/=])fm2_[A-Za-z0-9+/=]{20,}/ },
|
|
25
|
+
{ name: PEM_PATTERN_NAME, pattern: PRIVATE_KEY_BLOCK },
|
|
26
|
+
];
|
|
27
|
+
/**
|
|
28
|
+
* Suppress PEM bodies across complete, ordered text lines before other redactors run.
|
|
29
|
+
* @param _required No ambient state; create one instance per framed output stream.
|
|
30
|
+
* @param _options Reserved optional policy inputs.
|
|
31
|
+
* @returns A line redactor and an EOF reset. Call reset after flushing the final line so a
|
|
32
|
+
* replacement child cannot inherit an unterminated block. Does not frame raw chunks or do I/O.
|
|
33
|
+
* @complexity O(n) per line; O(h) retained state for the open header's key type of length h.
|
|
34
|
+
* @example const keys = createPrivateKeyLineRedactor({}, {}); keys.redact({ text: line }, {});
|
|
35
|
+
*/
|
|
36
|
+
export function createPrivateKeyLineRedactor(_required, _options = {}) {
|
|
37
|
+
let footer;
|
|
38
|
+
return {
|
|
39
|
+
redact({ text }, _optional = {}) {
|
|
40
|
+
let remaining = text;
|
|
41
|
+
let out = '';
|
|
42
|
+
while (remaining) {
|
|
43
|
+
if (footer !== undefined) {
|
|
44
|
+
const end = remaining.indexOf(footer);
|
|
45
|
+
if (end === -1)
|
|
46
|
+
return out;
|
|
47
|
+
remaining = remaining.slice(end + footer.length);
|
|
48
|
+
footer = undefined;
|
|
49
|
+
}
|
|
50
|
+
const header = PRIVATE_KEY_HEADER.exec(remaining);
|
|
51
|
+
if (!header)
|
|
52
|
+
return out + remaining;
|
|
53
|
+
out += remaining.slice(0, header.index) + '[REDACTED:credential]';
|
|
54
|
+
footer = `-----END ${header[1]}PRIVATE KEY-----`;
|
|
55
|
+
remaining = remaining.slice(header.index + header[0].length);
|
|
56
|
+
}
|
|
57
|
+
return out;
|
|
58
|
+
},
|
|
59
|
+
reset(_input, _optional = {}) { footer = undefined; },
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
/** Broad token shapes for agent-failure text; consumers retain their plain [REDACTED] pipeline. */
|
|
63
|
+
const AGENT_FAILURE_TOKEN_SHAPES = [
|
|
64
|
+
/AIza[\w-]+/, // Google API key
|
|
65
|
+
/AQ\.[\w.\/-]+/, // AI Studio key
|
|
66
|
+
/sk-[\w.-]+/, // OpenAI-style secret key
|
|
67
|
+
/gh[pousr]_\w+/, // GitHub token
|
|
68
|
+
/github_pat_\w+/, // GitHub fine-grained token
|
|
69
|
+
/ya29\.[\w.-]+/, // Google OAuth access token
|
|
70
|
+
/eyJ[\w-]+\.[\w-]+(?:\.[\w-]+)?/, // JWT
|
|
71
|
+
];
|
|
72
|
+
export const AGENT_FAILURE_SECRET_SHAPE_RE = new RegExp(`\\b(?:${AGENT_FAILURE_TOKEN_SHAPES.map((shape) => shape.source).join('|')})`, 'g');
|
|
73
|
+
/**
|
|
74
|
+
* Exact path SEGMENT names refused at any depth, matched case-insensitively against each segment
|
|
75
|
+
* of the caller-supplied path (never a substring — a directory named `not-secrets-actually` is not
|
|
76
|
+
* a match). `secrets` is the owner's explicit example: whatever a site or app tree names its
|
|
77
|
+
* credentials folder (`sites/**\/secrets/`, `app/**\/secrets/`, or anywhere else), it never
|
|
78
|
+
* becomes reachable through this domain. A denied segment is refused by the guarded reader
|
|
79
|
+
* AND skipped entirely by the `fs_list_files` walk — its contents are never even enumerated,
|
|
80
|
+
* not merely refused once named. Besides `secrets`, the set names the
|
|
81
|
+
* well-known credential-store directories a home-directory `custom` root can expose: `.aws`
|
|
82
|
+
* (`credentials`), `.docker` (`config.json` with registry auth), `.kube` (`config`), and
|
|
83
|
+
* `gcloud`/`gh` for `.config/gcloud/application_default_credentials.json` and
|
|
84
|
+
* `.config/gh/hosts.yml`. Denied by SEGMENT rather than by leaf filename on purpose: `config`,
|
|
85
|
+
* `config.json`, and `hosts.yml` are generic names that appear harmlessly elsewhere, so denying the
|
|
86
|
+
* directory is the narrower of the two mistakes.
|
|
87
|
+
*
|
|
88
|
+
* A host's install-wide site-key directory (2026-09-24) needs the same protection; the host appends it.
|
|
89
|
+
* Production stores it beside individual site folders on a durable volume; local/dev stores
|
|
90
|
+
* it below the home directory, reachable through an operator-set `custom` root. Its key backs
|
|
91
|
+
* site-key administration, webhook/newsletter signing secrets, and permission checks, so the
|
|
92
|
+
* agent must never read it from disk. Denying the whole directory segment, rather than only
|
|
93
|
+
* a generated key filename, also prevents `fs_list_files` from enumerating its contents — the
|
|
94
|
+
* same "never even advertise it" property `secrets` gets above.
|
|
95
|
+
*/
|
|
96
|
+
// Generic credential-store segments only. A host adds its own product-specific key directory
|
|
97
|
+
// (e.g. its install-wide site-key folder) when it builds its deny-list; core stays product-neutral.
|
|
98
|
+
export const CREDENTIAL_FILE_DENY_SEGMENTS = ["secrets", ".aws", ".docker", ".kube", "gcloud", "gh"];
|
|
99
|
+
// A local tunnel has a loopback socket and may rewrite Host; refuse marker presence, even empty.
|
|
100
|
+
export const LOCAL_OWNER_PROXY_MARKER_PREFIXES = ["x-forwarded-", "x-envoy-", "x-ms-"];
|
|
101
|
+
export const LOCAL_OWNER_PROXY_MARKER_HEADERS = [
|
|
102
|
+
"forwarded", "x-real-ip", "via", "cf-connecting-ip", "true-client-ip", "x-original-host",
|
|
103
|
+
"x-client-ip", "x-cluster-client-ip", "fastly-client-ip", "tailscale-user-login", "x-original-forwarded-for",
|
|
104
|
+
];
|
|
105
|
+
//# sourceMappingURL=secret-shapes.js.map
|
|
@@ -132,14 +132,8 @@ const SET_VALUE_SCHEMA = {
|
|
|
132
132
|
required: ["namespace", "key", "value"],
|
|
133
133
|
properties: { ...CLEAR_VALUE_SCHEMA.properties, value: { description: "Any JSON matching the definition schema returned by settings_list_definitions." } },
|
|
134
134
|
};
|
|
135
|
-
/**
|
|
136
|
-
|
|
137
|
-
* wired. See file header.
|
|
138
|
-
*
|
|
139
|
-
* @complexity O(1) — a fixed, statically-defined list.
|
|
140
|
-
* @overallScore 100
|
|
141
|
-
*/
|
|
142
|
-
export function getSettingsAgentToolCatalog() {
|
|
135
|
+
/** The catalog's three metadata/value reads; none has a side effect. */
|
|
136
|
+
function readAgentTools() {
|
|
143
137
|
return [
|
|
144
138
|
{
|
|
145
139
|
name: "settings_list_definitions",
|
|
@@ -162,6 +156,11 @@ export function getSettingsAgentToolCatalog() {
|
|
|
162
156
|
authorization: { permission: "settings.read.raw" },
|
|
163
157
|
inputSchema: GET_RAW_SCHEMA,
|
|
164
158
|
},
|
|
159
|
+
];
|
|
160
|
+
}
|
|
161
|
+
/** The catalog's three bounded writes, each limited to the caller's own workspace or user layer. */
|
|
162
|
+
function boundedWriteAgentTools() {
|
|
163
|
+
return [
|
|
165
164
|
{
|
|
166
165
|
name: "settings_set_ui_preference",
|
|
167
166
|
description: "Sets one of the operator's own admin-UI preferences (interface language, theme, accent color, or notification sounds) and returns the stored value. Writes only to the calling operator's own user layer — it cannot target another operator, another scope, or any setting outside its fixed list. Use settings_get_effective to read current values first.",
|
|
@@ -187,6 +186,11 @@ export function getSettingsAgentToolCatalog() {
|
|
|
187
186
|
authorization: { permission: "settings.workspace.write" },
|
|
188
187
|
inputSchema: CLEAR_VALUE_SCHEMA,
|
|
189
188
|
},
|
|
189
|
+
];
|
|
190
|
+
}
|
|
191
|
+
/** Documented but never wired: the bulk reset and the schema-level definition change. */
|
|
192
|
+
function excludedAgentTools() {
|
|
193
|
+
return [
|
|
190
194
|
{
|
|
191
195
|
// EXCLUDED BY DESIGN, never wired: see this file's header. Bulk variant of a single-value clear —
|
|
192
196
|
// clears every value in an operator-named namespace at a scope in one call, irreversible.
|
|
@@ -206,4 +210,14 @@ export function getSettingsAgentToolCatalog() {
|
|
|
206
210
|
},
|
|
207
211
|
];
|
|
208
212
|
}
|
|
213
|
+
/**
|
|
214
|
+
* The Settings domain's fixed agent-tool catalog — three reads, three bounded writes, and two bulk/schema writes documented but never
|
|
215
|
+
* wired. See file header.
|
|
216
|
+
*
|
|
217
|
+
* @complexity O(1) — a fixed, statically-defined list.
|
|
218
|
+
* @overallScore 100
|
|
219
|
+
*/
|
|
220
|
+
export function getSettingsAgentToolCatalog() {
|
|
221
|
+
return [...readAgentTools(), ...boundedWriteAgentTools(), ...excludedAgentTools()];
|
|
222
|
+
}
|
|
209
223
|
//# sourceMappingURL=agent-tools.js.map
|
|
@@ -39,5 +39,8 @@ export declare function toWriteDeps(routeDeps: SettingsToolDeps): SettingsWriteS
|
|
|
39
39
|
* service write -> result. The service rechecks authorization and performs its normal transaction.
|
|
40
40
|
* @complexity O(value size + rule count) plus bounded repository calls and a human wait.
|
|
41
41
|
* @throws ToolInputError for invalid input, denied keys, absent/declined/stale confirmation. */
|
|
42
|
-
export declare function buildSettingsValueWriteHandler(deps
|
|
42
|
+
export declare function buildSettingsValueWriteHandler({ deps, toolId }: {
|
|
43
|
+
deps: SettingsToolDeps;
|
|
44
|
+
toolId: SettingsValueWriteToolId;
|
|
45
|
+
}, _optional?: Record<string, never>): ToolHandler;
|
|
43
46
|
//# sourceMappingURL=agent-value-write-tools.d.ts.map
|
|
@@ -4,7 +4,8 @@ import { AGENT_WRITE_CONFIRMATION_SETTINGS, AGENT_WRITE_DENIED_SETTINGS, findAge
|
|
|
4
4
|
import { DefinitionNotFoundError, DefinitionTombstonedError, ForbiddenError, ScopeNotAllowedError, SettingsRevisionConflictError, ValueValidationFailedError } from "./errors.js";
|
|
5
5
|
import { getEffective, resolveDefinitionRaw, validateValueAgainstSchema } from "./settings.js";
|
|
6
6
|
import { SCOPE_BIT } from "./types.js";
|
|
7
|
-
import { clear,
|
|
7
|
+
import { clear, set } from "./write-values.js";
|
|
8
|
+
import { deriveRequiredPermission } from "./write-service.js";
|
|
8
9
|
const WRITE_FIELDS = {
|
|
9
10
|
settings_set_value: ["namespace", "key", "value", "scope"],
|
|
10
11
|
settings_clear_value: ["namespace", "key", "scope"],
|
|
@@ -78,7 +79,7 @@ async function resolveTarget(deps, target, isSet) {
|
|
|
78
79
|
const scopeAllowed = (definition.scopes & SCOPE_BIT[target.scope]) !== 0;
|
|
79
80
|
if (!scopeAllowed)
|
|
80
81
|
throw new ScopeNotAllowedError(name);
|
|
81
|
-
if (isSet && !validateValueAgainstSchema(definition.schema, target.value))
|
|
82
|
+
if (isSet && !validateValueAgainstSchema({ schema: definition.schema, value: target.value }))
|
|
82
83
|
throw new ValueValidationFailedError(`value for '${name}' does not match the definition schema`);
|
|
83
84
|
return definition;
|
|
84
85
|
}
|
|
@@ -102,12 +103,12 @@ function writePolicy(deps, toolId, target, definition) {
|
|
|
102
103
|
const targets = definition ? [target, definition] : [target];
|
|
103
104
|
const { denied, confirmation } = agentWriteRules(deps);
|
|
104
105
|
for (const coordinate of targets) {
|
|
105
|
-
const rule = findAgentWriteRule(denied, coordinate);
|
|
106
|
+
const rule = findAgentWriteRule({ rules: denied, target: coordinate });
|
|
106
107
|
if (rule)
|
|
107
108
|
throw new ToolInputError({ message: `${toolId}: '${coordinate.namespace}.${coordinate.key}' can't be changed by the assistant: ${rule.reason}. The owner can change it in Settings.` });
|
|
108
109
|
}
|
|
109
110
|
for (const coordinate of targets) {
|
|
110
|
-
const rule = findAgentWriteRule(confirmation, coordinate);
|
|
111
|
+
const rule = findAgentWriteRule({ rules: confirmation, target: coordinate });
|
|
111
112
|
if (rule)
|
|
112
113
|
return { ...rule, namespace: coordinate.namespace, key: coordinate.key };
|
|
113
114
|
}
|
|
@@ -196,14 +197,14 @@ async function applyWrite(deps, request, prepared) {
|
|
|
196
197
|
return { key, scope: target.scope, previous, value: result.value, revisionSeq: result.revisionSeq };
|
|
197
198
|
}
|
|
198
199
|
await clear({ deps: writeDeps, input }, options);
|
|
199
|
-
const effective = await getEffective({ repo: deps.settingsRepo },
|
|
200
|
+
const effective = await getEffective({ deps: { repo: deps.settingsRepo }, namespace: definition.namespace, key: definition.key, scopeContext: { workspaceId: deps.workspaceId, principalId: ctx.principal.id } });
|
|
200
201
|
return { key, scope: target.scope, previous, effective: effective?.value ?? null };
|
|
201
202
|
}
|
|
202
203
|
/** Builds one value-write handler. Effects: authorize -> raw read -> optional human card ->
|
|
203
204
|
* service write -> result. The service rechecks authorization and performs its normal transaction.
|
|
204
205
|
* @complexity O(value size + rule count) plus bounded repository calls and a human wait.
|
|
205
206
|
* @throws ToolInputError for invalid input, denied keys, absent/declined/stale confirmation. */
|
|
206
|
-
export function buildSettingsValueWriteHandler(deps, toolId) {
|
|
207
|
+
export function buildSettingsValueWriteHandler({ deps, toolId }, _optional = {}) {
|
|
207
208
|
return async (ctx, options) => {
|
|
208
209
|
// Keep the delegating actor/run bound across readiness, consent and fresh service checks.
|
|
209
210
|
// parseTarget owns JSON validation/snapshotting so invalid values retain their exact refusal.
|
|
@@ -61,7 +61,9 @@ export declare const AGENT_WRITABLE_PREFERENCE_IDS: readonly string[];
|
|
|
61
61
|
* @complexity O(1).
|
|
62
62
|
* @overallScore 100
|
|
63
63
|
*/
|
|
64
|
-
export declare function resolveAgentWritablePreference(settingId
|
|
64
|
+
export declare function resolveAgentWritablePreference({ settingId }: {
|
|
65
|
+
settingId: string;
|
|
66
|
+
}, _optional?: Record<string, never>): AgentWritablePreference | undefined;
|
|
65
67
|
/** Re-exported so the drift test can assert the scope mask without reaching into `types.ts` itself. */
|
|
66
68
|
export declare const AGENT_PREFERENCE_REQUIRED_SCOPE_BIT: 4;
|
|
67
69
|
//# sourceMappingURL=agent-writable-preferences.d.ts.map
|