@opengeni/contracts 5.5.0 → 5.5.2-canary.40656248492001
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-authored-durable-text.d.ts +9 -9
- package/dist/agent-config.d.ts +148 -37
- package/dist/api-key-presets.d.ts +19 -0
- package/dist/app-action-catalog-types.d.ts +32 -0
- package/dist/app-action-catalog.gen.d.ts +2 -0
- package/dist/app-actions.d.ts +91 -0
- package/dist/app-actions.js +10130 -0
- package/dist/app-actions.js.map +1 -0
- package/dist/app-shot.d.ts +55 -0
- package/dist/artifact-catalog.d.ts +33 -0
- package/dist/artifacts.d.ts +166 -0
- package/dist/atlassian-native-retirement.d.ts +16 -0
- package/dist/atlassian-native-retirement.js +30 -0
- package/dist/atlassian-native-retirement.js.map +1 -0
- package/dist/atlassian.js +48 -23
- package/dist/automation-templates.d.ts +434 -0
- package/dist/automation-templates.js +31 -0
- package/dist/automation-templates.js.map +1 -0
- package/dist/billing-subscriptions.d.ts +61 -0
- package/dist/bots.d.ts +583 -0
- package/dist/bundled-skills.d.ts +58 -2
- package/dist/canonical-human-identities.js +3 -1
- package/dist/child-lifecycle-notice-protocol.d.ts +45 -0
- package/dist/chunk-2QKIEAGY.js +396 -0
- package/dist/chunk-2QKIEAGY.js.map +1 -0
- package/dist/chunk-2WOWEWXV.js +426 -0
- package/dist/chunk-2WOWEWXV.js.map +1 -0
- package/dist/chunk-2ZIHHL72.js +153 -0
- package/dist/chunk-2ZIHHL72.js.map +1 -0
- package/dist/chunk-32U6NKQQ.js +389 -0
- package/dist/chunk-32U6NKQQ.js.map +1 -0
- package/dist/chunk-4YDDHSO2.js +799 -0
- package/dist/chunk-4YDDHSO2.js.map +1 -0
- package/dist/chunk-56SNIMDO.js +9 -0
- package/dist/chunk-56SNIMDO.js.map +1 -0
- package/dist/chunk-5RWB6QVL.js +101 -0
- package/dist/chunk-5RWB6QVL.js.map +1 -0
- package/dist/chunk-5UGUOT3L.js +243 -0
- package/dist/chunk-5UGUOT3L.js.map +1 -0
- package/dist/chunk-6LAT33BH.js +130 -0
- package/dist/chunk-6LAT33BH.js.map +1 -0
- package/dist/chunk-7272KVWZ.js +60 -0
- package/dist/chunk-7272KVWZ.js.map +1 -0
- package/dist/chunk-72QC2GTL.js +36 -0
- package/dist/chunk-72QC2GTL.js.map +1 -0
- package/dist/chunk-7EQGGZBY.js +105 -0
- package/dist/chunk-7EQGGZBY.js.map +1 -0
- package/dist/chunk-A3LXWVYU.js +382 -0
- package/dist/chunk-A3LXWVYU.js.map +1 -0
- package/dist/chunk-AQYDZUJV.js +34 -0
- package/dist/chunk-AQYDZUJV.js.map +1 -0
- package/dist/chunk-BHCEVVUP.js +93 -0
- package/dist/chunk-BHCEVVUP.js.map +1 -0
- package/dist/chunk-BMUTAZX5.js +486 -0
- package/dist/chunk-BMUTAZX5.js.map +1 -0
- package/dist/chunk-DGG6IBBK.js +150 -0
- package/dist/chunk-DGG6IBBK.js.map +1 -0
- package/dist/{chunk-YBW5JSA3.js → chunk-FBCTUMHI.js} +123 -102
- package/dist/chunk-FBCTUMHI.js.map +1 -0
- package/dist/chunk-G2KJTFIC.js +97 -0
- package/dist/chunk-G2KJTFIC.js.map +1 -0
- package/dist/chunk-G4RKARXZ.js +1167 -0
- package/dist/chunk-G4RKARXZ.js.map +1 -0
- package/dist/chunk-H6UJJIUM.js +350 -0
- package/dist/chunk-H6UJJIUM.js.map +1 -0
- package/dist/chunk-JOTHDW4H.js +18 -0
- package/dist/chunk-JOTHDW4H.js.map +1 -0
- package/dist/chunk-L4GUEP7K.js +56480 -0
- package/dist/chunk-L4GUEP7K.js.map +1 -0
- package/dist/{chunk-SIOU2K4U.js → chunk-LJH2EYGT.js} +23 -23
- package/dist/chunk-MTJKSIGA.js +161 -0
- package/dist/chunk-MTJKSIGA.js.map +1 -0
- package/dist/chunk-MYHMB6GZ.js +202 -0
- package/dist/chunk-MYHMB6GZ.js.map +1 -0
- package/dist/chunk-PI5VIKJY.js +660 -0
- package/dist/chunk-PI5VIKJY.js.map +1 -0
- package/dist/{chunk-RIY7GYQS.js → chunk-PTSROVDG.js} +2 -2
- package/dist/chunk-PUIUXIOL.js +189 -0
- package/dist/chunk-PUIUXIOL.js.map +1 -0
- package/dist/chunk-R6VXJIMB.js +19 -0
- package/dist/chunk-R6VXJIMB.js.map +1 -0
- package/dist/chunk-RLJUNVAM.js +15 -0
- package/dist/chunk-RLJUNVAM.js.map +1 -0
- package/dist/chunk-RR6APCBK.js +213 -0
- package/dist/chunk-RR6APCBK.js.map +1 -0
- package/dist/{chunk-TXTQIYCV.js → chunk-RUQ4I6DO.js} +59 -13
- package/dist/chunk-RUQ4I6DO.js.map +1 -0
- package/dist/{chunk-WYBDERIY.js → chunk-RWEEUDHD.js} +53 -42
- package/dist/chunk-RWEEUDHD.js.map +1 -0
- package/dist/chunk-S7MSQQL6.js +158 -0
- package/dist/chunk-S7MSQQL6.js.map +1 -0
- package/dist/{chunk-5Q54VCCH.js → chunk-SHO4YO4B.js} +20 -36
- package/dist/chunk-SHO4YO4B.js.map +1 -0
- package/dist/{chunk-HHZSZYYF.js → chunk-T3HSWMA5.js} +20 -4
- package/dist/chunk-T3HSWMA5.js.map +1 -0
- package/dist/{chunk-YRKRZ6OF.js → chunk-TOOJIBJC.js} +2 -2
- package/dist/chunk-UCUOTRS6.js +431 -0
- package/dist/chunk-UCUOTRS6.js.map +1 -0
- package/dist/chunk-UH4K7GP7.js +424 -0
- package/dist/chunk-UH4K7GP7.js.map +1 -0
- package/dist/chunk-UIZWGPHV.js +120 -0
- package/dist/chunk-UIZWGPHV.js.map +1 -0
- package/dist/chunk-VLUKBV6Y.js +1170 -0
- package/dist/chunk-VLUKBV6Y.js.map +1 -0
- package/dist/chunk-W2QQ5Y6K.js +55 -0
- package/dist/chunk-W2QQ5Y6K.js.map +1 -0
- package/dist/{chunk-Y3KNXVTD.js → chunk-W3NBPR4E.js} +131 -31
- package/dist/chunk-W3NBPR4E.js.map +1 -0
- package/dist/{chunk-NRMCVHAU.js → chunk-WMGO4HJU.js} +11 -9
- package/dist/chunk-WMGO4HJU.js.map +1 -0
- package/dist/{chunk-MYBZRDTY.js → chunk-WQI7VNN4.js} +19 -9
- package/dist/chunk-WQI7VNN4.js.map +1 -0
- package/dist/{chunk-PX3VCKAU.js → chunk-WVCFSOUZ.js} +1 -1
- package/dist/{chunk-PX3VCKAU.js.map → chunk-WVCFSOUZ.js.map} +1 -1
- package/dist/chunk-XB6GQLBH.js +76 -0
- package/dist/chunk-XB6GQLBH.js.map +1 -0
- package/dist/{chunk-D2HKF2EF.js → chunk-XP5M3IKT.js} +2 -2
- package/dist/{chunk-O77VSFYZ.js → chunk-ZMPU5BWE.js} +12 -2
- package/dist/chunk-ZMPU5BWE.js.map +1 -0
- package/dist/{chunk-3SIZGL3O.js → chunk-ZYVEJFNU.js} +22 -18
- package/dist/chunk-ZYVEJFNU.js.map +1 -0
- package/dist/claude-provider-account-authority.d.ts +18 -0
- package/dist/claude-subscription-oauth.d.ts +25 -0
- package/dist/claude-subscription-usage.d.ts +95 -1
- package/dist/client-error-report.d.ts +154 -8
- package/dist/client-error-report.js +157 -2
- package/dist/client-error-report.js.map +1 -1
- package/dist/code-search.d.ts +1 -1
- package/dist/code-search.js.map +1 -1
- package/dist/codex-provider-account-authority.js +23 -12
- package/dist/codex-provider-account-authority.js.map +1 -1
- package/dist/company-profile.d.ts +144 -0
- package/dist/connect.d.ts +38 -0
- package/dist/connect.js +244 -164
- package/dist/connect.js.map +1 -1
- package/dist/connection-account-label.d.ts +2 -0
- package/dist/connection-account-label.js +34 -0
- package/dist/connection-account-label.js.map +1 -0
- package/dist/connection-authority.js +49 -24
- package/dist/connector-attachments.js +3 -1
- package/dist/connector-destinations.js +3 -1
- package/dist/connector-tool-permissions.d.ts +68 -4
- package/dist/credential-profiles.d.ts +166 -0
- package/dist/cua-desktop-tools.d.ts +19 -0
- package/dist/define-schema.d.ts +8 -0
- package/dist/desktop-app.d.ts +28 -0
- package/dist/direct-model-provider.d.ts +38 -0
- package/dist/document-artifact-commands.js +2 -2
- package/dist/document-artifact-query.js +2 -2
- package/dist/editable-artifact-binary.d.ts +7 -0
- package/dist/editable-artifact-causal-frontier.js +2 -2
- package/dist/editable-artifact-codec-registry.js +7 -7
- package/dist/editable-artifact-committed-transaction.js +4 -2
- package/dist/editable-artifact-live.js +8 -8
- package/dist/editable-artifact-serialized-commit.js +9 -9
- package/dist/editable-artifact-versions.d.ts +7 -1
- package/dist/editable-artifact-versions.js +1 -1
- package/dist/editable-artifacts.js +49 -43
- package/dist/event-preview.d.ts +22 -0
- package/dist/event-triggers.d.ts +1253 -0
- package/dist/event-triggers.js +148 -0
- package/dist/event-triggers.js.map +1 -0
- package/dist/external-identities.d.ts +34 -0
- package/dist/external-identities.js +4 -2
- package/dist/feedback.d.ts +181 -0
- package/dist/file-access.d.ts +23 -0
- package/dist/first-party-tool-authorization.d.ts +852 -0
- package/dist/github-repository-contracts.js +64 -43
- package/dist/github-repository-contracts.js.map +1 -1
- package/dist/google-drive-native-retirement.d.ts +12 -0
- package/dist/google-drive-native-retirement.js +20 -0
- package/dist/google-drive-native-retirement.js.map +1 -0
- package/dist/google-drive.d.ts +1 -1
- package/dist/google-drive.js +323 -239
- package/dist/google-drive.js.map +1 -1
- package/dist/host-mcp-bindings.js +250 -198
- package/dist/host-mcp-bindings.js.map +1 -1
- package/dist/index.d.ts +29072 -20593
- package/dist/index.js +2432 -366
- package/dist/inference-residency.d.ts +22 -0
- package/dist/insights-usage.d.ts +948 -0
- package/dist/insights-usage.js +608 -0
- package/dist/insights-usage.js.map +1 -0
- package/dist/integration-capability-id.d.ts +8 -0
- package/dist/interaction-action-deadline.d.ts +48 -0
- package/dist/interaction-driver-diagnostic.d.ts +28 -0
- package/dist/interaction.d.ts +2126 -881
- package/dist/knowledge-entries.d.ts +38 -0
- package/dist/knowledge-preparation.d.ts +4 -0
- package/dist/learning-refusal.d.ts +43 -0
- package/dist/learning-refusal.js +49 -0
- package/dist/learning-refusal.js.map +1 -0
- package/dist/managed-auth-session-sets.d.ts +1 -0
- package/dist/managed-auth-session-sets.js +207 -146
- package/dist/managed-auth-session-sets.js.map +1 -1
- package/dist/managed-sign-in-methods.d.ts +96 -0
- package/dist/managed-sign-in-methods.js +157 -35
- package/dist/managed-sign-in-methods.js.map +1 -1
- package/dist/mcp-structured-content.d.ts +25 -0
- package/dist/message-time-zone.d.ts +38 -0
- package/dist/message-time-zone.js +19 -0
- package/dist/message-time-zone.js.map +1 -0
- package/dist/modal-native-proof-v2.d.ts +587 -0
- package/dist/modal-native-proof-v2.js +39 -0
- package/dist/modal-native-proof-v2.js.map +1 -0
- package/dist/model-account-choice.d.ts +237 -0
- package/dist/model-account-settings.d.ts +422 -0
- package/dist/model-availability.d.ts +15 -0
- package/dist/model-connection-access.d.ts +13 -0
- package/dist/model-context-inspector.d.ts +8 -0
- package/dist/model-display.d.ts +43 -0
- package/dist/model-display.js +17 -0
- package/dist/model-display.js.map +1 -0
- package/dist/model-picker-order.js.map +1 -1
- package/dist/model-residency.d.ts +304 -0
- package/dist/organization-access.d.ts +416 -0
- package/dist/organization-access.js +40 -0
- package/dist/organization-access.js.map +1 -0
- package/dist/organization-integration-policy.d.ts +18 -0
- package/dist/organization-membership-lifecycle.d.ts +66 -0
- package/dist/organization-model-usage.d.ts +146 -0
- package/dist/organization-model-usage.js +87 -0
- package/dist/organization-model-usage.js.map +1 -0
- package/dist/organization-recovery.js +3 -1
- package/dist/organization-usage.d.ts +12 -0
- package/dist/passkey-only-account.d.ts +14 -0
- package/dist/passkey-only-account.js +13 -0
- package/dist/passkey-only-account.js.map +1 -0
- package/dist/permissions.d.ts +19 -0
- package/dist/personal-github.js +220 -148
- package/dist/personal-github.js.map +1 -1
- package/dist/personal-integration-setup.d.ts +81 -0
- package/dist/personal-integration-setup.js +42 -0
- package/dist/personal-integration-setup.js.map +1 -0
- package/dist/prepared-mcp-setup.d.ts +54 -0
- package/dist/prepared-mcp-setup.js +13 -0
- package/dist/prepared-mcp-setup.js.map +1 -0
- package/dist/presentation-artifact-commands.js +2 -2
- package/dist/presentation-artifact-query.js +2 -2
- package/dist/primitives.d.ts +18 -0
- package/dist/product-analytics.d.ts +27 -10
- package/dist/product-lifecycle-facts.d.ts +26 -3
- package/dist/prompt-cache-diagnostics.d.ts +92 -0
- package/dist/recordings.d.ts +1371 -0
- package/dist/remember.d.ts +98 -2
- package/dist/retained-output.d.ts +4 -2
- package/dist/sandbox-file-artifacts.d.ts +19 -2
- package/dist/sandbox-provider-command.d.ts +5 -44
- package/dist/sandbox-recovery.d.ts +139 -8
- package/dist/secret-generator.d.ts +44 -0
- package/dist/secret-mask-strings.d.ts +32 -0
- package/dist/secret-references.d.ts +90 -0
- package/dist/secret-resolution.d.ts +143 -0
- package/dist/secret-shape-masking.d.ts +52 -0
- package/dist/secret-shape-masking.js +19 -0
- package/dist/secret-shape-masking.js.map +1 -0
- package/dist/secret-totp.d.ts +41 -0
- package/dist/secret-use-approval-question.d.ts +11 -0
- package/dist/secret-use-approval-question.js +11 -0
- package/dist/secret-use-approval-question.js.map +1 -0
- package/dist/secret-use-approvals.d.ts +106 -0
- package/dist/secret-value-masking.d.ts +299 -0
- package/dist/secret-value-masking.js +62 -0
- package/dist/secret-value-masking.js.map +1 -0
- package/dist/secret-value.d.ts +19 -0
- package/dist/session-history-import.d.ts +444 -8
- package/dist/session-history.d.ts +111 -0
- package/dist/session-history.js +35 -0
- package/dist/session-history.js.map +1 -0
- package/dist/session-list-entries.d.ts +8 -0
- package/dist/session-list-entries.js +61 -0
- package/dist/session-list-entries.js.map +1 -0
- package/dist/session-mcp-projections.d.ts +13 -1
- package/dist/session-mcp-tool-permissions.d.ts +62 -0
- package/dist/session-target.d.ts +18 -0
- package/dist/session-titles.d.ts +8 -0
- package/dist/session-titles.js +5 -1
- package/dist/session-usage-limit-refusal.d.ts +34 -0
- package/dist/session-usage-limit-refusal.js +15 -0
- package/dist/session-usage-limit-refusal.js.map +1 -0
- package/dist/session-usage-limits.d.ts +127 -0
- package/dist/session-usage-limits.js +43 -0
- package/dist/session-usage-limits.js.map +1 -0
- package/dist/site-data.d.ts +286 -0
- package/dist/site-operations.d.ts +39 -0
- package/dist/site-publishing.d.ts +813 -0
- package/dist/site-session-http.d.ts +103 -4
- package/dist/site-session-http.js +27 -1
- package/dist/site-sql.d.ts +425 -0
- package/dist/skills.d.ts +38 -0
- package/dist/slack-bot-scopes.d.ts +9 -7
- package/dist/slack-bot-scopes.js +6 -3
- package/dist/slack-rest-mcp.d.ts +36 -0
- package/dist/slack-rest-mcp.js +25 -0
- package/dist/slack-rest-mcp.js.map +1 -0
- package/dist/spreadsheet-artifact-commands.d.ts +14 -1
- package/dist/spreadsheet-artifact-commands.js +9 -2
- package/dist/spreadsheet-artifact-query.d.ts +13 -6
- package/dist/spreadsheet-artifact-query.js +4 -3
- package/dist/subscription-account-actions.d.ts +83 -0
- package/dist/subscription-account-pools.d.ts +326 -0
- package/dist/subscription-personal-authority-v2.d.ts +28 -0
- package/dist/subscription-personal-authority-v2.js +13 -0
- package/dist/subscription-personal-authority-v2.js.map +1 -0
- package/dist/subscription-plans.d.ts +38 -0
- package/dist/subscription-usage-pool.d.ts +89 -0
- package/dist/tool-action-review.d.ts +141 -0
- package/dist/tool-catalog.d.ts +479 -0
- package/dist/tool-policy.d.ts +5 -0
- package/dist/tool-review-presentation.d.ts +29 -0
- package/dist/tool-review-presentation.js +21 -0
- package/dist/tool-review-presentation.js.map +1 -0
- package/dist/turn-serving-policy.d.ts +223 -0
- package/dist/usage-allowances.d.ts +30 -0
- package/dist/usage-allowances.js +5 -1
- package/dist/values.d.ts +11 -0
- package/dist/values.js +19 -0
- package/dist/values.js.map +1 -0
- package/dist/vault-provider-wire.d.ts +907 -0
- package/dist/vault-provider-wire.js +74 -0
- package/dist/vault-provider-wire.js.map +1 -0
- package/dist/vaults.d.ts +2185 -0
- package/dist/video-generation.d.ts +75 -0
- package/dist/video-generation.js +8 -1
- package/dist/workspace-control-event.d.ts +18 -0
- package/dist/workspace-control-event.js +18 -0
- package/dist/workspace-control-event.js.map +1 -0
- package/dist/workspace-governance-context.d.ts +18 -0
- package/dist/workspace-integration-wire.d.ts +1 -1
- package/dist/workspace-integration-wire.js +1 -1
- package/dist/workspace-integrations.d.ts +212 -12
- package/dist/xai-provider-account-authority.js +3 -1
- package/package.json +121 -4
- package/src/agent-authored-durable-text.ts +14 -11
- package/src/agent-config.ts +382 -203
- package/src/agent-instruction-changes.ts +94 -74
- package/src/agent-learning.ts +94 -66
- package/src/agent-topology.ts +58 -52
- package/src/api-key-presets.ts +28 -0
- package/src/app-action-catalog-types.ts +32 -0
- package/src/app-action-catalog.gen.ts +9905 -0
- package/src/app-actions.ts +365 -0
- package/src/app-shot.ts +176 -0
- package/src/artifact-catalog.ts +81 -46
- package/src/artifacts.ts +360 -227
- package/src/atlassian-native-retirement.ts +33 -0
- package/src/atlassian.ts +136 -108
- package/src/automation-templates.ts +201 -0
- package/src/billing-subscriptions.ts +48 -0
- package/src/bots.ts +238 -0
- package/src/bundled-skills.ts +79 -22
- package/src/canonical-human-identities.ts +65 -62
- package/src/child-lifecycle-notice-protocol.gen.json +1310 -0
- package/src/child-lifecycle-notice-protocol.ts +224 -0
- package/src/claude-provider-account-authority.ts +12 -0
- package/src/claude-subscription-oauth.ts +61 -19
- package/src/claude-subscription-usage.ts +64 -35
- package/src/client-error-report.ts +344 -9
- package/src/code-search.ts +1 -1
- package/src/codex-provider-account-authority.ts +22 -16
- package/src/company-brain-governed-writes.ts +265 -244
- package/src/company-brain.ts +165 -154
- package/src/company-profile.ts +362 -297
- package/src/connect.ts +222 -173
- package/src/connection-account-label.ts +45 -0
- package/src/connection-authority.ts +172 -152
- package/src/connector-attachments.ts +139 -123
- package/src/connector-destinations.ts +48 -43
- package/src/connector-tool-permissions.ts +104 -46
- package/src/credential-profiles.ts +161 -0
- package/src/cua-desktop-tools.gen.json +6722 -0
- package/src/cua-desktop-tools.linux.gen.json +6798 -0
- package/src/cua-desktop-tools.ts +42 -0
- package/src/cua-desktop-tools.windows.gen.json +6739 -0
- package/src/define-schema.ts +10 -0
- package/src/desktop-app.ts +50 -0
- package/src/direct-model-provider.ts +112 -0
- package/src/editable-artifact-binary.ts +29 -8
- package/src/editable-artifact-committed-transaction.ts +19 -18
- package/src/editable-artifact-serialized-commit.ts +8 -2
- package/src/editable-artifact-versions.ts +7 -1
- package/src/event-preview.ts +53 -3
- package/src/event-triggers.ts +891 -0
- package/src/external-identities.ts +239 -195
- package/src/feedback.ts +125 -30
- package/src/file-access.ts +26 -0
- package/src/first-party-tool-authorization.ts +383 -0
- package/src/github-repository-contracts.ts +78 -64
- package/src/google-drive-native-retirement.ts +20 -0
- package/src/google-drive.ts +286 -234
- package/src/governed-learning-activation.ts +159 -137
- package/src/governed-learning-evaluator.ts +141 -133
- package/src/host-mcp-bindings.ts +244 -221
- package/src/image-generation.ts +105 -95
- package/src/index.ts +13928 -9899
- package/src/inference-residency.ts +36 -0
- package/src/insights-usage.ts +774 -0
- package/src/integration-capability-id.ts +16 -0
- package/src/interaction-action-deadline.ts +143 -0
- package/src/interaction-driver-diagnostic.ts +89 -0
- package/src/interaction.ts +3527 -2427
- package/src/knowledge-entries.ts +386 -299
- package/src/knowledge-preparation.ts +49 -41
- package/src/knowledge.ts +242 -213
- package/src/learning-refusal.ts +90 -0
- package/src/managed-auth-session-sets.ts +180 -133
- package/src/managed-sign-in-methods.ts +156 -34
- package/src/mcp-oauth.ts +58 -46
- package/src/mcp-receipts.ts +199 -194
- package/src/mcp-structured-content.ts +81 -0
- package/src/memory-slack-delivery.ts +172 -142
- package/src/message-time-zone.ts +109 -0
- package/src/modal-native-proof-v2.ts +430 -0
- package/src/model-account-choice.ts +178 -0
- package/src/model-account-settings.ts +210 -0
- package/src/model-availability.ts +22 -0
- package/src/model-connection-access.ts +62 -14
- package/src/model-context-inspector.ts +130 -109
- package/src/model-display.ts +221 -0
- package/src/model-picker-order.ts +1 -1
- package/src/model-residency.ts +535 -0
- package/src/organization-access.ts +216 -0
- package/src/organization-integration-policy.ts +47 -28
- package/src/organization-membership-lifecycle.ts +558 -384
- package/src/organization-model-usage.ts +82 -0
- package/src/organization-recovery.ts +148 -135
- package/src/organization-usage.ts +84 -52
- package/src/passkey-only-account.ts +29 -0
- package/src/permissions.ts +94 -52
- package/src/personal-github.ts +211 -171
- package/src/personal-integration-setup.ts +150 -0
- package/src/preference-registry.ts +319 -263
- package/src/prepared-mcp-setup.ts +190 -0
- package/src/primitives.ts +22 -0
- package/src/product-analytics.ts +40 -15
- package/src/product-lifecycle-facts.ts +50 -20
- package/src/prompt-cache-diagnostics.ts +212 -0
- package/src/recordings.ts +1153 -0
- package/src/remember.ts +184 -172
- package/src/retained-output.ts +181 -168
- package/src/sandbox-file-artifacts.ts +78 -57
- package/src/sandbox-provider-command.ts +55 -72
- package/src/sandbox-recovery.ts +163 -77
- package/src/scoped-knowledge.ts +62 -43
- package/src/secret-generator.ts +156 -0
- package/src/secret-mask-strings.ts +175 -0
- package/src/secret-references.ts +414 -0
- package/src/secret-resolution.ts +322 -0
- package/src/secret-shape-masking.ts +573 -0
- package/src/secret-totp.ts +188 -0
- package/src/secret-use-approval-question.ts +22 -0
- package/src/secret-use-approvals.ts +219 -0
- package/src/secret-value-masking.ts +1283 -0
- package/src/secret-value.ts +22 -0
- package/src/session-goal-reports.ts +55 -49
- package/src/session-history-import.ts +84 -68
- package/src/session-history.ts +197 -0
- package/src/session-list-entries.ts +106 -0
- package/src/session-mcp-projections.ts +21 -3
- package/src/session-mcp-tool-permissions.ts +109 -0
- package/src/session-message-search.ts +46 -38
- package/src/session-target.ts +58 -0
- package/src/session-titles.ts +40 -4
- package/src/session-topology-primitives.ts +20 -12
- package/src/session-usage-limit-refusal.ts +101 -0
- package/src/session-usage-limits.ts +169 -0
- package/src/signup-attribution.ts +20 -15
- package/src/site-data.ts +337 -0
- package/src/site-operations.ts +154 -0
- package/src/site-publishing.ts +903 -0
- package/src/site-session-http.ts +344 -16
- package/src/site-sql.ts +1120 -0
- package/src/skill-use.ts +18 -17
- package/src/skills.ts +105 -50
- package/src/slack-bot-scopes.ts +18 -35
- package/src/slack-rest-mcp.ts +222 -0
- package/src/slack-task-policy.ts +97 -73
- package/src/spreadsheet-artifact-commands.ts +74 -13
- package/src/spreadsheet-artifact-query.ts +188 -50
- package/src/subscription-account-actions.ts +103 -0
- package/src/subscription-account-pools.ts +74 -0
- package/src/subscription-personal-authority-v2.ts +69 -0
- package/src/subscription-plans.ts +51 -0
- package/src/subscription-usage-pool.ts +44 -0
- package/src/task-notes.ts +70 -68
- package/src/tool-action-review.ts +271 -0
- package/src/tool-catalog.ts +694 -379
- package/src/tool-policy.ts +82 -0
- package/src/tool-result-spill.ts +13 -9
- package/src/tool-review-presentation.ts +643 -0
- package/src/turn-serving-policy.ts +167 -0
- package/src/usage-allowances.ts +212 -136
- package/src/values.ts +25 -0
- package/src/vault-provider-wire.ts +580 -0
- package/src/vaults.ts +1296 -0
- package/src/video-generation.ts +430 -361
- package/src/work-claims.ts +183 -166
- package/src/workspace-control-event.ts +134 -0
- package/src/workspace-governance-context.ts +63 -0
- package/src/workspace-instruction-policies.ts +346 -279
- package/src/workspace-integration-wire.ts +10 -0
- package/src/workspace-integrations.ts +488 -398
- package/src/workspace-learning-administration.ts +58 -44
- package/src/workspace-learning-policy.ts +126 -99
- package/src/workspace-state.ts +239 -220
- package/src/xai-provider-account-authority.ts +23 -17
- package/dist/chunk-3SIZGL3O.js.map +0 -1
- package/dist/chunk-566IFOVP.js +0 -26133
- package/dist/chunk-566IFOVP.js.map +0 -1
- package/dist/chunk-5IXYF6XN.js +0 -728
- package/dist/chunk-5IXYF6XN.js.map +0 -1
- package/dist/chunk-5Q54VCCH.js.map +0 -1
- package/dist/chunk-BCS7WHCK.js +0 -139
- package/dist/chunk-BCS7WHCK.js.map +0 -1
- package/dist/chunk-EK7NDGFR.js +0 -128
- package/dist/chunk-EK7NDGFR.js.map +0 -1
- package/dist/chunk-GRG7PHWQ.js +0 -25
- package/dist/chunk-GRG7PHWQ.js.map +0 -1
- package/dist/chunk-HHZSZYYF.js.map +0 -1
- package/dist/chunk-ICDZGUX2.js +0 -186
- package/dist/chunk-ICDZGUX2.js.map +0 -1
- package/dist/chunk-JUFK3T4Q.js +0 -80
- package/dist/chunk-JUFK3T4Q.js.map +0 -1
- package/dist/chunk-MYBZRDTY.js.map +0 -1
- package/dist/chunk-NRMCVHAU.js.map +0 -1
- package/dist/chunk-O77VSFYZ.js.map +0 -1
- package/dist/chunk-P3HLDT77.js +0 -59
- package/dist/chunk-P3HLDT77.js.map +0 -1
- package/dist/chunk-TXTQIYCV.js.map +0 -1
- package/dist/chunk-WYBDERIY.js.map +0 -1
- package/dist/chunk-Y3KNXVTD.js.map +0 -1
- package/dist/chunk-YBW5JSA3.js.map +0 -1
- package/dist/chunk-YRXAWWCU.js +0 -45
- package/dist/chunk-YRXAWWCU.js.map +0 -1
- package/dist/chunk-YWMOIZ6A.js +0 -185
- package/dist/chunk-YWMOIZ6A.js.map +0 -1
- package/dist/site-request-headers.test.d.ts +0 -1
- package/dist/transcription-recordings.d.ts +0 -300
- package/src/transcription-recordings.ts +0 -169
- /package/dist/{chunk-SIOU2K4U.js.map → chunk-LJH2EYGT.js.map} +0 -0
- /package/dist/{chunk-RIY7GYQS.js.map → chunk-PTSROVDG.js.map} +0 -0
- /package/dist/{chunk-YRKRZ6OF.js.map → chunk-TOOJIBJC.js.map} +0 -0
- /package/dist/{chunk-D2HKF2EF.js.map → chunk-XP5M3IKT.js.map} +0 -0
|
@@ -0,0 +1,1170 @@
|
|
|
1
|
+
import {
|
|
2
|
+
collectSecretShapes,
|
|
3
|
+
mapSecretMaskableStrings,
|
|
4
|
+
maskSecretShapes,
|
|
5
|
+
maskSecretShapesInText,
|
|
6
|
+
secretShapeMaskLabel
|
|
7
|
+
} from "./chunk-BMUTAZX5.js";
|
|
8
|
+
import {
|
|
9
|
+
VAULT_LIMITS,
|
|
10
|
+
isValidSecretName
|
|
11
|
+
} from "./chunk-G4RKARXZ.js";
|
|
12
|
+
|
|
13
|
+
// src/secret-references.ts
|
|
14
|
+
var SECRET_REFERENCE_MARKER = "{{secret";
|
|
15
|
+
var SecretReferenceSyntaxError = class extends Error {
|
|
16
|
+
reason;
|
|
17
|
+
constructor(reason, message) {
|
|
18
|
+
super(message ?? `invalid secret reference: ${reason}`);
|
|
19
|
+
this.name = "SecretReferenceSyntaxError";
|
|
20
|
+
this.reason = reason;
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
var PREFIXES = [
|
|
24
|
+
// Longest first: "{{secretfile:" must win over "{{secret".
|
|
25
|
+
{ prefix: "{{secretfile:", kind: "secretfile" },
|
|
26
|
+
{ prefix: "{{secret:", kind: "secret" }
|
|
27
|
+
];
|
|
28
|
+
var UUID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
29
|
+
var PREVIOUS_SUFFIX = "#previous";
|
|
30
|
+
var ID_PREFIX = "id:";
|
|
31
|
+
function containsSecretReference(text) {
|
|
32
|
+
return text.includes(SECRET_REFERENCE_MARKER);
|
|
33
|
+
}
|
|
34
|
+
function prefixAt(text, index) {
|
|
35
|
+
for (const candidate of PREFIXES) {
|
|
36
|
+
if (text.startsWith(candidate.prefix, index)) return candidate;
|
|
37
|
+
}
|
|
38
|
+
return null;
|
|
39
|
+
}
|
|
40
|
+
function isControl(code) {
|
|
41
|
+
return code <= 31 || code >= 127 && code <= 159;
|
|
42
|
+
}
|
|
43
|
+
function parseBody(body) {
|
|
44
|
+
if (body.length === 0)
|
|
45
|
+
throw new SecretReferenceSyntaxError("empty_body", "secret reference is empty");
|
|
46
|
+
let rest = body;
|
|
47
|
+
let previous = false;
|
|
48
|
+
if (rest.endsWith(PREVIOUS_SUFFIX)) {
|
|
49
|
+
previous = true;
|
|
50
|
+
rest = rest.slice(0, -PREVIOUS_SUFFIX.length);
|
|
51
|
+
}
|
|
52
|
+
if (rest.includes("#")) {
|
|
53
|
+
throw new SecretReferenceSyntaxError(
|
|
54
|
+
"unsupported_version_suffix",
|
|
55
|
+
"only #previous is supported, and it must be last"
|
|
56
|
+
);
|
|
57
|
+
}
|
|
58
|
+
const parts = rest.split("/");
|
|
59
|
+
let otp = false;
|
|
60
|
+
if (parts.length >= 2 && parts[parts.length - 1].toLowerCase() === "otp") {
|
|
61
|
+
otp = true;
|
|
62
|
+
parts.pop();
|
|
63
|
+
}
|
|
64
|
+
if (parts[0].toLowerCase().startsWith(ID_PREFIX)) {
|
|
65
|
+
const itemId = parts[0].slice(ID_PREFIX.length);
|
|
66
|
+
if (!UUID_PATTERN.test(itemId)) {
|
|
67
|
+
throw new SecretReferenceSyntaxError("invalid_id", "id: must be followed by an item UUID");
|
|
68
|
+
}
|
|
69
|
+
if (parts.length > 2) {
|
|
70
|
+
throw new SecretReferenceSyntaxError("too_many_segments", "id form takes at most one field");
|
|
71
|
+
}
|
|
72
|
+
const field = parts[1] ?? null;
|
|
73
|
+
if (field !== null) assertSegment(field);
|
|
74
|
+
return { target: { form: "id", itemId: itemId.toLowerCase(), field }, otp, previous };
|
|
75
|
+
}
|
|
76
|
+
if (parts.length > 3) {
|
|
77
|
+
throw new SecretReferenceSyntaxError(
|
|
78
|
+
"too_many_segments",
|
|
79
|
+
"a reference has at most Vault/Item/field"
|
|
80
|
+
);
|
|
81
|
+
}
|
|
82
|
+
for (const segment of parts) assertSegment(segment);
|
|
83
|
+
return {
|
|
84
|
+
target: {
|
|
85
|
+
form: "path",
|
|
86
|
+
segments: parts
|
|
87
|
+
},
|
|
88
|
+
otp,
|
|
89
|
+
previous
|
|
90
|
+
};
|
|
91
|
+
}
|
|
92
|
+
function assertSegment(segment) {
|
|
93
|
+
if (segment.length === 0) {
|
|
94
|
+
throw new SecretReferenceSyntaxError("empty_segment", "a reference has an empty name");
|
|
95
|
+
}
|
|
96
|
+
if (!isValidSecretName(segment)) {
|
|
97
|
+
throw new SecretReferenceSyntaxError(
|
|
98
|
+
"invalid_segment",
|
|
99
|
+
`"${segment.slice(0, 40)}" is not a valid vault, item or field name`
|
|
100
|
+
);
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
function scanCandidate(text, index, prefix) {
|
|
104
|
+
const bodyStart = index + prefix.prefix.length;
|
|
105
|
+
const limit = Math.min(text.length, index + VAULT_LIMITS.referenceMaxChars);
|
|
106
|
+
let cursor = bodyStart;
|
|
107
|
+
while (cursor < text.length) {
|
|
108
|
+
const code = text.charCodeAt(cursor);
|
|
109
|
+
const character = text[cursor];
|
|
110
|
+
if (character === "}" && text[cursor + 1] === "}") {
|
|
111
|
+
const end = cursor + 2;
|
|
112
|
+
if (end - index > VAULT_LIMITS.referenceMaxChars) {
|
|
113
|
+
return { ok: false, end, reason: "too_long" };
|
|
114
|
+
}
|
|
115
|
+
const raw = text.slice(index, end);
|
|
116
|
+
try {
|
|
117
|
+
const parsed = parseBody(text.slice(bodyStart, cursor));
|
|
118
|
+
return {
|
|
119
|
+
ok: true,
|
|
120
|
+
end,
|
|
121
|
+
reference: { kind: prefix.kind, raw, start: index, end, ...parsed }
|
|
122
|
+
};
|
|
123
|
+
} catch (error) {
|
|
124
|
+
return {
|
|
125
|
+
ok: false,
|
|
126
|
+
end,
|
|
127
|
+
reason: error instanceof SecretReferenceSyntaxError ? error.reason : "invalid"
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
if (character === "{" || character === "}" || isControl(code) || cursor >= limit) {
|
|
132
|
+
const end = Math.max(cursor, bodyStart);
|
|
133
|
+
return { ok: false, end, reason: cursor >= limit ? "too_long" : "unterminated" };
|
|
134
|
+
}
|
|
135
|
+
cursor += 1;
|
|
136
|
+
}
|
|
137
|
+
return { ok: false, end: text.length, reason: "unterminated" };
|
|
138
|
+
}
|
|
139
|
+
function tokenizeSecretText(text) {
|
|
140
|
+
if (!containsSecretReference(text)) return text.length > 0 ? [{ type: "text", value: text }] : [];
|
|
141
|
+
const tokens = [];
|
|
142
|
+
let buffer = "";
|
|
143
|
+
let cursor = 0;
|
|
144
|
+
const flush = () => {
|
|
145
|
+
if (buffer.length > 0) tokens.push({ type: "text", value: buffer });
|
|
146
|
+
buffer = "";
|
|
147
|
+
};
|
|
148
|
+
while (cursor < text.length) {
|
|
149
|
+
const next = text.indexOf(SECRET_REFERENCE_MARKER, cursor);
|
|
150
|
+
if (next < 0) {
|
|
151
|
+
buffer += text.slice(cursor);
|
|
152
|
+
break;
|
|
153
|
+
}
|
|
154
|
+
const prefix = prefixAt(text, next);
|
|
155
|
+
if (prefix === null) {
|
|
156
|
+
buffer += text.slice(cursor, next + SECRET_REFERENCE_MARKER.length);
|
|
157
|
+
cursor = next + SECRET_REFERENCE_MARKER.length;
|
|
158
|
+
continue;
|
|
159
|
+
}
|
|
160
|
+
const escaped = next - 1 >= cursor && text[next - 1] === "\\";
|
|
161
|
+
const scanned = scanCandidate(text, next, prefix);
|
|
162
|
+
if (escaped) {
|
|
163
|
+
buffer += text.slice(cursor, next - 1) + text.slice(next, scanned.end);
|
|
164
|
+
cursor = scanned.end;
|
|
165
|
+
continue;
|
|
166
|
+
}
|
|
167
|
+
buffer += text.slice(cursor, next);
|
|
168
|
+
flush();
|
|
169
|
+
if (scanned.ok) {
|
|
170
|
+
tokens.push({ type: "reference", reference: scanned.reference });
|
|
171
|
+
} else {
|
|
172
|
+
tokens.push({
|
|
173
|
+
type: "invalid",
|
|
174
|
+
raw: text.slice(next, scanned.end),
|
|
175
|
+
start: next,
|
|
176
|
+
end: scanned.end,
|
|
177
|
+
reason: scanned.reason
|
|
178
|
+
});
|
|
179
|
+
}
|
|
180
|
+
cursor = scanned.end;
|
|
181
|
+
}
|
|
182
|
+
flush();
|
|
183
|
+
return tokens;
|
|
184
|
+
}
|
|
185
|
+
function findSecretReferences(text) {
|
|
186
|
+
if (!containsSecretReference(text)) return [];
|
|
187
|
+
return tokenizeSecretText(text).flatMap(
|
|
188
|
+
(token) => token.type === "reference" ? [token.reference] : []
|
|
189
|
+
);
|
|
190
|
+
}
|
|
191
|
+
function findInvalidSecretReferences(text) {
|
|
192
|
+
if (!containsSecretReference(text)) return [];
|
|
193
|
+
return tokenizeSecretText(text).filter(
|
|
194
|
+
(token) => token.type === "invalid"
|
|
195
|
+
);
|
|
196
|
+
}
|
|
197
|
+
function parseSecretReference(raw) {
|
|
198
|
+
const prefix = prefixAt(raw, 0);
|
|
199
|
+
if (prefix === null) {
|
|
200
|
+
throw new SecretReferenceSyntaxError(
|
|
201
|
+
"missing_prefix",
|
|
202
|
+
"a secret reference starts with {{secret: or {{secretfile:"
|
|
203
|
+
);
|
|
204
|
+
}
|
|
205
|
+
const scanned = scanCandidate(raw, 0, prefix);
|
|
206
|
+
if (!scanned.ok) throw new SecretReferenceSyntaxError(scanned.reason);
|
|
207
|
+
if (scanned.end !== raw.length) {
|
|
208
|
+
throw new SecretReferenceSyntaxError("trailing_text", "unexpected text after the reference");
|
|
209
|
+
}
|
|
210
|
+
return scanned.reference;
|
|
211
|
+
}
|
|
212
|
+
function formatSecretReference(input) {
|
|
213
|
+
const kind = input.kind ?? "secret";
|
|
214
|
+
const parts = [];
|
|
215
|
+
if ("itemId" in input) {
|
|
216
|
+
if (!UUID_PATTERN.test(input.itemId)) throw new SecretReferenceSyntaxError("invalid_id");
|
|
217
|
+
parts.push(`${ID_PREFIX}${input.itemId.toLowerCase()}`);
|
|
218
|
+
} else {
|
|
219
|
+
if (input.vault !== void 0) parts.push(input.vault);
|
|
220
|
+
parts.push(input.item);
|
|
221
|
+
}
|
|
222
|
+
if (input.field !== void 0) parts.push(input.field);
|
|
223
|
+
for (const part of "itemId" in input ? parts.slice(1) : parts) assertSegment(part);
|
|
224
|
+
const body = `${parts.join("/")}${input.otp ? "/otp" : ""}${input.previous ? PREVIOUS_SUFFIX : ""}`;
|
|
225
|
+
const raw = `{{${kind}:${body}}}`;
|
|
226
|
+
if (raw.length > VAULT_LIMITS.referenceMaxChars) throw new SecretReferenceSyntaxError("too_long");
|
|
227
|
+
return raw;
|
|
228
|
+
}
|
|
229
|
+
function secretNameKey(name) {
|
|
230
|
+
return name.normalize("NFC").trim().toLowerCase();
|
|
231
|
+
}
|
|
232
|
+
function referenceKey(ref) {
|
|
233
|
+
const target = ref.target.form === "id" ? `id:${ref.target.itemId.toLowerCase()}/${ref.target.field === null ? "" : secretNameKey(ref.target.field)}` : `path:${ref.target.segments.map(secretNameKey).join("/")}`;
|
|
234
|
+
return `${ref.kind}|${target}|${ref.otp ? "otp" : ""}|${ref.previous ? "previous" : ""}`;
|
|
235
|
+
}
|
|
236
|
+
function unescapeSecretText(text) {
|
|
237
|
+
if (!containsSecretReference(text)) return text;
|
|
238
|
+
return tokenizeSecretText(text).map(
|
|
239
|
+
(token) => token.type === "text" ? token.value : token.type === "reference" ? token.reference.raw : token.raw
|
|
240
|
+
).join("");
|
|
241
|
+
}
|
|
242
|
+
function walkStrings(value, visit, seen) {
|
|
243
|
+
if (typeof value === "string") {
|
|
244
|
+
visit(value);
|
|
245
|
+
return;
|
|
246
|
+
}
|
|
247
|
+
if (value === null || typeof value !== "object") return;
|
|
248
|
+
if (seen.has(value)) return;
|
|
249
|
+
seen.add(value);
|
|
250
|
+
if (Array.isArray(value)) {
|
|
251
|
+
for (const entry of value) walkStrings(entry, visit, seen);
|
|
252
|
+
return;
|
|
253
|
+
}
|
|
254
|
+
for (const entry of Object.values(value))
|
|
255
|
+
walkStrings(entry, visit, seen);
|
|
256
|
+
}
|
|
257
|
+
function collectReferencesDeep(value) {
|
|
258
|
+
const out = [];
|
|
259
|
+
walkStrings(value, (text) => out.push(...findSecretReferences(text)), /* @__PURE__ */ new Set());
|
|
260
|
+
return out;
|
|
261
|
+
}
|
|
262
|
+
function collectInvalidReferencesDeep(value) {
|
|
263
|
+
const out = [];
|
|
264
|
+
walkStrings(value, (text) => out.push(...findInvalidSecretReferences(text)), /* @__PURE__ */ new Set());
|
|
265
|
+
return out;
|
|
266
|
+
}
|
|
267
|
+
function replaceReferencesDeep(value, replace) {
|
|
268
|
+
const replaceText = (text) => {
|
|
269
|
+
if (!containsSecretReference(text)) return text;
|
|
270
|
+
return tokenizeSecretText(text).map(
|
|
271
|
+
(token) => token.type === "text" ? token.value : token.type === "reference" ? replace(token.reference) : token.raw
|
|
272
|
+
).join("");
|
|
273
|
+
};
|
|
274
|
+
const copy = (input) => {
|
|
275
|
+
if (typeof input === "string") return replaceText(input);
|
|
276
|
+
if (input === null || typeof input !== "object") return input;
|
|
277
|
+
if (Array.isArray(input)) return input.map(copy);
|
|
278
|
+
if (input instanceof Uint8Array || input instanceof Date) return input;
|
|
279
|
+
const out = {};
|
|
280
|
+
for (const [key, entry] of Object.entries(input)) {
|
|
281
|
+
out[key] = copy(entry);
|
|
282
|
+
}
|
|
283
|
+
return out;
|
|
284
|
+
};
|
|
285
|
+
return copy(value);
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
// src/secret-value-masking.ts
|
|
289
|
+
var SECRET_VALUE_MASK_MIN_CHARS = 8;
|
|
290
|
+
var SECRET_VALUE_CLIPPED_MIN_CHARS = 16;
|
|
291
|
+
var SECRET_VALUE_CLIPPED_MIN_SHARE = 0.5;
|
|
292
|
+
var SECRET_VALUE_MEMORY_MAX_ENTRIES = 512;
|
|
293
|
+
var CREDENTIAL_LABEL_OPEN = "[opengeni credential: ";
|
|
294
|
+
var SHAPE_MARKER_OPEN = "[masked ";
|
|
295
|
+
function secretCredentialMaskLabel(kind) {
|
|
296
|
+
const safe = kind.replace(/[^A-Za-z0-9 ._-]/gu, "").slice(0, 60) || "credential";
|
|
297
|
+
return `${CREDENTIAL_LABEL_OPEN}${safe}]`;
|
|
298
|
+
}
|
|
299
|
+
var SECRET_VALUE_GENERIC_MASK_LABEL = "[secret]";
|
|
300
|
+
var REFERENCE_OPEN = "{{secret:";
|
|
301
|
+
var FILE_REFERENCE_OPEN = "{{secretfile:";
|
|
302
|
+
var JSON_UNSAFE = /["\\\u0000-\u001f\u007f-\u009f\u2028\u2029]/u;
|
|
303
|
+
function secretReferenceMaskLabel(input) {
|
|
304
|
+
let raw = input.raw;
|
|
305
|
+
if (raw.startsWith(FILE_REFERENCE_OPEN)) {
|
|
306
|
+
raw = REFERENCE_OPEN + raw.slice(FILE_REFERENCE_OPEN.length);
|
|
307
|
+
}
|
|
308
|
+
if (raw.startsWith(REFERENCE_OPEN) && !JSON_UNSAFE.test(raw)) return raw;
|
|
309
|
+
if (input.itemId) {
|
|
310
|
+
try {
|
|
311
|
+
let previous = false;
|
|
312
|
+
try {
|
|
313
|
+
previous = parseSecretReference(raw).previous;
|
|
314
|
+
} catch {
|
|
315
|
+
previous = false;
|
|
316
|
+
}
|
|
317
|
+
const id = formatSecretReference({
|
|
318
|
+
itemId: input.itemId,
|
|
319
|
+
...input.fieldName ? { field: input.fieldName } : {},
|
|
320
|
+
...previous ? { previous: true } : {}
|
|
321
|
+
});
|
|
322
|
+
if (!JSON_UNSAFE.test(id)) return id;
|
|
323
|
+
} catch {
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
return SECRET_VALUE_GENERIC_MASK_LABEL;
|
|
327
|
+
}
|
|
328
|
+
function isSecretReferenceMaskLabel(label) {
|
|
329
|
+
return label.startsWith(REFERENCE_OPEN);
|
|
330
|
+
}
|
|
331
|
+
var BASE64_ALPHABET = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
332
|
+
function utf8Bytes(value) {
|
|
333
|
+
try {
|
|
334
|
+
return new TextEncoder().encode(value);
|
|
335
|
+
} catch {
|
|
336
|
+
return null;
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
function base64(bytes) {
|
|
340
|
+
let out = "";
|
|
341
|
+
for (let index = 0; index < bytes.length; index += 3) {
|
|
342
|
+
const a = bytes[index];
|
|
343
|
+
const b = index + 1 < bytes.length ? bytes[index + 1] : 0;
|
|
344
|
+
const c = index + 2 < bytes.length ? bytes[index + 2] : 0;
|
|
345
|
+
const triple = a << 16 | b << 8 | c;
|
|
346
|
+
out += BASE64_ALPHABET[triple >> 18 & 63];
|
|
347
|
+
out += BASE64_ALPHABET[triple >> 12 & 63];
|
|
348
|
+
out += index + 1 < bytes.length ? BASE64_ALPHABET[triple >> 6 & 63] : "=";
|
|
349
|
+
out += index + 2 < bytes.length ? BASE64_ALPHABET[triple & 63] : "=";
|
|
350
|
+
}
|
|
351
|
+
return out;
|
|
352
|
+
}
|
|
353
|
+
function base64Forms(value) {
|
|
354
|
+
const bytes = utf8Bytes(value);
|
|
355
|
+
if (bytes === null || bytes.length === 0) return [];
|
|
356
|
+
const forms = [];
|
|
357
|
+
const whole = base64(bytes);
|
|
358
|
+
forms.push(whole, whole.replace(/=+$/u, ""));
|
|
359
|
+
for (let offset = 0; offset < 3; offset += 1) {
|
|
360
|
+
const padded = new Uint8Array(offset + bytes.length);
|
|
361
|
+
padded.set(bytes, offset);
|
|
362
|
+
const encoded = base64(padded);
|
|
363
|
+
const start = Math.ceil(offset * 8 / 6);
|
|
364
|
+
const end = Math.floor((offset + bytes.length) * 8 / 6);
|
|
365
|
+
if (end > start) forms.push(encoded.slice(start, end));
|
|
366
|
+
}
|
|
367
|
+
const withUrlSafe = [];
|
|
368
|
+
for (const form of forms) {
|
|
369
|
+
withUrlSafe.push(form, form.replaceAll("+", "-").replaceAll("/", "_"));
|
|
370
|
+
}
|
|
371
|
+
return withUrlSafe;
|
|
372
|
+
}
|
|
373
|
+
var PEM_BOUNDARY = /^-----(BEGIN|END) [A-Z0-9 ]+-----$/u;
|
|
374
|
+
var KEY_MATERIAL_LINE = /^(?:[0-9A-Fa-f]+|(?=[^\n]*[A-Z])(?=[^\n]*[a-z])(?=[^\n]*[0-9])[A-Za-z0-9+/_-]+={0,2})$/u;
|
|
375
|
+
function secretValueForms(value, options = {}) {
|
|
376
|
+
const minChars = options.minChars ?? SECRET_VALUE_MASK_MIN_CHARS;
|
|
377
|
+
if (typeof value !== "string" || value.length < minChars) return [];
|
|
378
|
+
const forms = /* @__PURE__ */ new Set();
|
|
379
|
+
const add = (form) => {
|
|
380
|
+
if (form && form.length >= minChars) forms.add(form);
|
|
381
|
+
};
|
|
382
|
+
add(value);
|
|
383
|
+
add(value.trim());
|
|
384
|
+
const lines = value.split(/\r?\n|\r/u);
|
|
385
|
+
if (lines.length > 1) {
|
|
386
|
+
for (const line of lines) {
|
|
387
|
+
const trimmed = line.trim();
|
|
388
|
+
if (PEM_BOUNDARY.test(trimmed)) continue;
|
|
389
|
+
if (options.lines === "all" || trimmed.length >= 16 && KEY_MATERIAL_LINE.test(trimmed)) {
|
|
390
|
+
add(trimmed);
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
const escaped = JSON.stringify(value).slice(1, -1);
|
|
395
|
+
add(escaped);
|
|
396
|
+
add(JSON.stringify(escaped).slice(1, -1));
|
|
397
|
+
try {
|
|
398
|
+
const uri = encodeURIComponent(value);
|
|
399
|
+
add(uri);
|
|
400
|
+
add(uri.replaceAll("%20", "+"));
|
|
401
|
+
add(uri.replace(/%[0-9A-F]{2}/gu, (match) => match.toLowerCase()));
|
|
402
|
+
} catch {
|
|
403
|
+
}
|
|
404
|
+
try {
|
|
405
|
+
add(new URLSearchParams({ v: value }).toString().slice(2));
|
|
406
|
+
} catch {
|
|
407
|
+
}
|
|
408
|
+
if (options.base64 !== false) for (const form of base64Forms(value)) add(form);
|
|
409
|
+
return [...forms].sort((left, right) => right.length - left.length);
|
|
410
|
+
}
|
|
411
|
+
var PROTECTED_PATTERNS = [
|
|
412
|
+
"\\[opengeni credential: [A-Za-z0-9 ._-]{1,60}\\]",
|
|
413
|
+
"\\[masked [a-z0-9 _-]{1,40}\\]",
|
|
414
|
+
"\\[secret\\]"
|
|
415
|
+
];
|
|
416
|
+
function escapeRegExp(text) {
|
|
417
|
+
return text.replace(/[.*+?^${}()|[\]\\]/gu, "\\$&");
|
|
418
|
+
}
|
|
419
|
+
var TRUNCATION_MARK = /\.\.\.|\u2026/gu;
|
|
420
|
+
var CLIPPED_INDEX_MAX_FORM_CHARS = 8192;
|
|
421
|
+
var CLIPPED_INDEX_MAX_ENTRIES = 2e5;
|
|
422
|
+
var CLIPPED_MAX_CUTS = 256;
|
|
423
|
+
var CLIPPED_MAX_CANDIDATES = 32;
|
|
424
|
+
var SECRET_VALUE_CLIPPED_TEXT_END_MIN_CHARS = 1024;
|
|
425
|
+
function compileSecretValueMasks(entries, options = {}) {
|
|
426
|
+
const minChars = Math.max(2, options.minChars ?? SECRET_VALUE_MASK_MIN_CHARS);
|
|
427
|
+
const clippedMinChars = Math.max(
|
|
428
|
+
minChars,
|
|
429
|
+
options.clippedMinChars ?? SECRET_VALUE_CLIPPED_MIN_CHARS
|
|
430
|
+
);
|
|
431
|
+
const clippedMinShare = Math.min(
|
|
432
|
+
1,
|
|
433
|
+
Math.max(0, options.clippedMinShare ?? SECRET_VALUE_CLIPPED_MIN_SHARE)
|
|
434
|
+
);
|
|
435
|
+
const labels = /* @__PURE__ */ new Map();
|
|
436
|
+
const labelTexts = /* @__PURE__ */ new Set();
|
|
437
|
+
const clippable = /* @__PURE__ */ new Set();
|
|
438
|
+
for (const entry of entries) {
|
|
439
|
+
if (typeof entry?.value !== "string" || typeof entry.label !== "string") continue;
|
|
440
|
+
const forms2 = secretValueForms(entry.value, { ...options, minChars });
|
|
441
|
+
if (forms2.length === 0) continue;
|
|
442
|
+
labelTexts.add(entry.label);
|
|
443
|
+
for (const form of forms2) if (!labels.has(form)) labels.set(form, entry.label);
|
|
444
|
+
clippable.add(entry.value);
|
|
445
|
+
clippable.add(entry.value.trim());
|
|
446
|
+
clippable.add(JSON.stringify(entry.value).slice(1, -1));
|
|
447
|
+
}
|
|
448
|
+
const forms = [...labels.keys()].sort((left, right) => right.length - left.length);
|
|
449
|
+
const byPrefix = /* @__PURE__ */ new Map();
|
|
450
|
+
const byClippedEnd = /* @__PURE__ */ new Map();
|
|
451
|
+
const firstPairs = /* @__PURE__ */ new Set();
|
|
452
|
+
for (const form of forms) {
|
|
453
|
+
const prefix = form.slice(0, minChars);
|
|
454
|
+
const bucket = byPrefix.get(prefix);
|
|
455
|
+
if (bucket) bucket.push(form);
|
|
456
|
+
else byPrefix.set(prefix, [form]);
|
|
457
|
+
firstPairs.add(form.charCodeAt(0) * 65536 + form.charCodeAt(1));
|
|
458
|
+
}
|
|
459
|
+
let indexed = 0;
|
|
460
|
+
for (let index = forms.length - 1; index >= 0; index -= 1) {
|
|
461
|
+
const form = forms[index];
|
|
462
|
+
if (options.clippedForms !== "all" && !clippable.has(form)) continue;
|
|
463
|
+
if (form.length <= clippedMinChars || form.length > CLIPPED_INDEX_MAX_FORM_CHARS) continue;
|
|
464
|
+
const shortest = Math.max(clippedMinChars, Math.ceil(form.length * clippedMinShare));
|
|
465
|
+
if (indexed + (form.length - shortest) > CLIPPED_INDEX_MAX_ENTRIES) break;
|
|
466
|
+
for (let length = shortest; length < form.length; length += 1) {
|
|
467
|
+
const key = form.slice(length - clippedMinChars, length);
|
|
468
|
+
const starts = byClippedEnd.get(key);
|
|
469
|
+
if (starts) starts.push({ form, length });
|
|
470
|
+
else byClippedEnd.set(key, [{ form, length }]);
|
|
471
|
+
}
|
|
472
|
+
indexed += form.length - shortest;
|
|
473
|
+
}
|
|
474
|
+
for (const starts of byClippedEnd.values()) {
|
|
475
|
+
starts.sort((left, right) => right.length - left.length);
|
|
476
|
+
}
|
|
477
|
+
const pattern = forms.length === 0 ? null : new RegExp(
|
|
478
|
+
[
|
|
479
|
+
...[...labelTexts].sort((left, right) => right.length - left.length).map(escapeRegExp),
|
|
480
|
+
...PROTECTED_PATTERNS
|
|
481
|
+
].map((source) => `(?:${source})`).join("|"),
|
|
482
|
+
"gu"
|
|
483
|
+
);
|
|
484
|
+
return {
|
|
485
|
+
empty: forms.length === 0,
|
|
486
|
+
minChars,
|
|
487
|
+
skipKey: options.skipKey,
|
|
488
|
+
pattern,
|
|
489
|
+
labels,
|
|
490
|
+
forms,
|
|
491
|
+
byPrefix,
|
|
492
|
+
firstPairs,
|
|
493
|
+
clippedMinChars,
|
|
494
|
+
clippedMinShare,
|
|
495
|
+
clippedTextEndMinChars: Math.max(
|
|
496
|
+
0,
|
|
497
|
+
options.clippedTextEndMinChars ?? SECRET_VALUE_CLIPPED_TEXT_END_MIN_CHARS
|
|
498
|
+
),
|
|
499
|
+
byClippedEnd,
|
|
500
|
+
longestForm: forms[0]?.length ?? 0
|
|
501
|
+
};
|
|
502
|
+
}
|
|
503
|
+
function clippedSecretTail(text, cut, masks) {
|
|
504
|
+
const probe = masks.clippedMinChars;
|
|
505
|
+
if (cut < probe || masks.byClippedEnd.size === 0) return null;
|
|
506
|
+
const candidates = masks.byClippedEnd.get(text.slice(cut - probe, cut));
|
|
507
|
+
if (!candidates) return null;
|
|
508
|
+
let checked = 0;
|
|
509
|
+
for (const { form, length } of candidates) {
|
|
510
|
+
if (length > cut) continue;
|
|
511
|
+
if (checked++ >= CLIPPED_MAX_CANDIDATES) break;
|
|
512
|
+
if (!text.startsWith(form.slice(0, length), cut - length)) continue;
|
|
513
|
+
const label = masks.labels.get(form);
|
|
514
|
+
if (label !== void 0) return { length, label };
|
|
515
|
+
}
|
|
516
|
+
return null;
|
|
517
|
+
}
|
|
518
|
+
function overlapsKept(start, end, kept) {
|
|
519
|
+
for (const [from, to] of kept) if (start < to && from < end) return true;
|
|
520
|
+
return false;
|
|
521
|
+
}
|
|
522
|
+
function keptRanges(text, pattern) {
|
|
523
|
+
const kept = [];
|
|
524
|
+
pattern.lastIndex = 0;
|
|
525
|
+
for (const match of text.matchAll(pattern)) {
|
|
526
|
+
if (match[0].length > 0) kept.push([match.index, match.index + match[0].length]);
|
|
527
|
+
}
|
|
528
|
+
return kept;
|
|
529
|
+
}
|
|
530
|
+
function maskSecretValuesInText(text, masks) {
|
|
531
|
+
if (masks.empty || masks.pattern === null || text.length < masks.minChars) return text;
|
|
532
|
+
const size = masks.minChars;
|
|
533
|
+
const kept = keptRanges(text, masks.pattern);
|
|
534
|
+
let out = "";
|
|
535
|
+
let copied = 0;
|
|
536
|
+
let next = 0;
|
|
537
|
+
for (let at = 0; at <= text.length - size; ) {
|
|
538
|
+
while (next < kept.length && kept[next][1] <= at) next += 1;
|
|
539
|
+
if (next < kept.length && kept[next][0] <= at) {
|
|
540
|
+
at = kept[next][1];
|
|
541
|
+
next += 1;
|
|
542
|
+
continue;
|
|
543
|
+
}
|
|
544
|
+
if (!masks.firstPairs.has(text.charCodeAt(at) * 65536 + text.charCodeAt(at + 1))) {
|
|
545
|
+
at += 1;
|
|
546
|
+
continue;
|
|
547
|
+
}
|
|
548
|
+
const candidates = masks.byPrefix.get(text.slice(at, at + size));
|
|
549
|
+
const limit = next < kept.length ? kept[next][0] : text.length;
|
|
550
|
+
const form = candidates?.find(
|
|
551
|
+
(candidate) => at + candidate.length <= limit && text.startsWith(candidate, at)
|
|
552
|
+
);
|
|
553
|
+
if (form === void 0) {
|
|
554
|
+
at += 1;
|
|
555
|
+
continue;
|
|
556
|
+
}
|
|
557
|
+
out += text.slice(copied, at) + masks.labels.get(form);
|
|
558
|
+
at += form.length;
|
|
559
|
+
copied = at;
|
|
560
|
+
}
|
|
561
|
+
out += text.slice(copied);
|
|
562
|
+
if (masks.byClippedEnd.size === 0) return out;
|
|
563
|
+
const cuts = out.length >= masks.clippedTextEndMinChars ? [out.length] : [];
|
|
564
|
+
const marks = [...out.matchAll(TRUNCATION_MARK)];
|
|
565
|
+
for (let index = marks.length - 1; index >= 0; index -= 1) {
|
|
566
|
+
if (cuts.length >= CLIPPED_MAX_CUTS) break;
|
|
567
|
+
const mark = marks[index];
|
|
568
|
+
const previous = marks[index - 1];
|
|
569
|
+
if (previous && previous.index + previous[0].length === mark.index) continue;
|
|
570
|
+
cuts.push(mark.index);
|
|
571
|
+
}
|
|
572
|
+
if (cuts.length === 0) return out;
|
|
573
|
+
const keptBefore = keptRanges(out, masks.pattern);
|
|
574
|
+
let changedFrom = out.length + 1;
|
|
575
|
+
for (const cut of cuts) {
|
|
576
|
+
if (cut > changedFrom) continue;
|
|
577
|
+
const tail = clippedSecretTail(out, cut, masks);
|
|
578
|
+
if (!tail) continue;
|
|
579
|
+
const start = cut - tail.length;
|
|
580
|
+
if (overlapsKept(start, cut, keptBefore)) continue;
|
|
581
|
+
out = out.slice(0, start) + tail.label + out.slice(cut);
|
|
582
|
+
changedFrom = start;
|
|
583
|
+
}
|
|
584
|
+
return out;
|
|
585
|
+
}
|
|
586
|
+
function maskSecretValues(value, entries, options = {}) {
|
|
587
|
+
const masks = Array.isArray(entries) ? compileSecretValueMasks(entries, options) : entries;
|
|
588
|
+
if (masks.empty) return value;
|
|
589
|
+
return mapSecretMaskableStrings(
|
|
590
|
+
value,
|
|
591
|
+
(text) => maskSecretValuesInText(text, masks),
|
|
592
|
+
masks.skipKey
|
|
593
|
+
);
|
|
594
|
+
}
|
|
595
|
+
var FIRST_PARTY_SECRET_VALUES_META_KEY = "opengeniSecretValues";
|
|
596
|
+
function firstPartySecretValuesFromMeta(meta) {
|
|
597
|
+
if (meta === null || typeof meta !== "object") return [];
|
|
598
|
+
const entries = meta[FIRST_PARTY_SECRET_VALUES_META_KEY];
|
|
599
|
+
if (!Array.isArray(entries)) return [];
|
|
600
|
+
return entries.filter(
|
|
601
|
+
(entry) => entry !== null && typeof entry === "object" && typeof entry.value === "string" && typeof entry.label === "string"
|
|
602
|
+
);
|
|
603
|
+
}
|
|
604
|
+
function isDistinctiveSecret(value, username) {
|
|
605
|
+
if (username !== void 0 && value === username) return false;
|
|
606
|
+
const kinds = Number(/[a-z]/.test(value)) + Number(/[A-Z]/.test(value)) + Number(/[0-9]/.test(value)) + Number(/[^A-Za-z0-9]/.test(value));
|
|
607
|
+
return value.length >= 16 && kinds >= 3 || value.length >= 24 && kinds >= 2;
|
|
608
|
+
}
|
|
609
|
+
function revealedForms(value) {
|
|
610
|
+
if (value.length === 0) return [];
|
|
611
|
+
const escaped = JSON.stringify(value).slice(1, -1);
|
|
612
|
+
return escaped === value ? [value] : [value, escaped];
|
|
613
|
+
}
|
|
614
|
+
var SECRET_SHAPE_CAPTURES_PER_RESULT = 16;
|
|
615
|
+
var SecretValueMemory = class {
|
|
616
|
+
values = /* @__PURE__ */ new Map();
|
|
617
|
+
operations = /* @__PURE__ */ new Map();
|
|
618
|
+
compiled = null;
|
|
619
|
+
/** Masks without values that only have a `[masked <kind>]` marker, by version. */
|
|
620
|
+
compiledReferenced = null;
|
|
621
|
+
changes = 0;
|
|
622
|
+
options;
|
|
623
|
+
maxEntries;
|
|
624
|
+
onDiagnostic;
|
|
625
|
+
refresher;
|
|
626
|
+
/** Values an explicit, audited reveal (`secret_get`) handed to the agent. */
|
|
627
|
+
revealed = /* @__PURE__ */ new Set();
|
|
628
|
+
disposed = false;
|
|
629
|
+
/** Secret-shaped values seen in tool output, with what replaces them (any length). */
|
|
630
|
+
shapes = /* @__PURE__ */ new Map();
|
|
631
|
+
shapeCapturer;
|
|
632
|
+
constructor(options = {}) {
|
|
633
|
+
const { maxEntries, onDiagnostic, ...maskOptions } = options;
|
|
634
|
+
this.options = maskOptions;
|
|
635
|
+
this.maxEntries = maxEntries ?? SECRET_VALUE_MEMORY_MAX_ENTRIES;
|
|
636
|
+
this.onDiagnostic = onDiagnostic;
|
|
637
|
+
}
|
|
638
|
+
/** Replace the diagnostic sink (for example once observability is ready). */
|
|
639
|
+
setDiagnosticSink(sink) {
|
|
640
|
+
this.onDiagnostic = sink;
|
|
641
|
+
}
|
|
642
|
+
/**
|
|
643
|
+
* Attach a loader that may remember more values (for example uses recorded
|
|
644
|
+
* by another process). It owns its own throttling.
|
|
645
|
+
*/
|
|
646
|
+
setRefresher(refresher) {
|
|
647
|
+
this.refresher = refresher;
|
|
648
|
+
}
|
|
649
|
+
/** Run the refresher, waiting at most `maxWaitMs`; never throws. */
|
|
650
|
+
async refresh(maxWaitMs = 2e3) {
|
|
651
|
+
const refresher = this.refresher;
|
|
652
|
+
if (!refresher) return;
|
|
653
|
+
let timer;
|
|
654
|
+
try {
|
|
655
|
+
await Promise.race([
|
|
656
|
+
refresher(),
|
|
657
|
+
new Promise((resolve) => {
|
|
658
|
+
timer = setTimeout(resolve, maxWaitMs);
|
|
659
|
+
})
|
|
660
|
+
]);
|
|
661
|
+
} catch (error) {
|
|
662
|
+
this.report("refresh", error);
|
|
663
|
+
} finally {
|
|
664
|
+
if (timer !== void 0) clearTimeout(timer);
|
|
665
|
+
}
|
|
666
|
+
}
|
|
667
|
+
get minChars() {
|
|
668
|
+
return this.options.minChars ?? SECRET_VALUE_MASK_MIN_CHARS;
|
|
669
|
+
}
|
|
670
|
+
get size() {
|
|
671
|
+
return this.values.size;
|
|
672
|
+
}
|
|
673
|
+
/** Increases whenever the searched values change (for memoized masking). */
|
|
674
|
+
get version() {
|
|
675
|
+
return this.changes;
|
|
676
|
+
}
|
|
677
|
+
/**
|
|
678
|
+
* Remember a value. Returns whether it is searched for (false when shorter
|
|
679
|
+
* than the minimum). A value keeps its first reference label; a reference
|
|
680
|
+
* label replaces a credential marker, because it is the more useful name.
|
|
681
|
+
*/
|
|
682
|
+
remember(value, label) {
|
|
683
|
+
try {
|
|
684
|
+
if (typeof value !== "string" || typeof label !== "string") return false;
|
|
685
|
+
if (this.disposed || value.length < this.minChars || this.isRevealed(value)) return false;
|
|
686
|
+
const existing = this.values.get(value);
|
|
687
|
+
const keep = existing !== void 0 && (existing === label || isSecretReferenceMaskLabel(existing) || !isSecretReferenceMaskLabel(label));
|
|
688
|
+
this.values.delete(value);
|
|
689
|
+
this.values.set(value, keep ? existing : label);
|
|
690
|
+
this.evict();
|
|
691
|
+
if (!keep) {
|
|
692
|
+
this.compiled = null;
|
|
693
|
+
this.changes += 1;
|
|
694
|
+
}
|
|
695
|
+
return true;
|
|
696
|
+
} catch (error) {
|
|
697
|
+
this.report("remember", error);
|
|
698
|
+
return false;
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
/**
|
|
702
|
+
* Over the limit, the oldest values go first, but Opengeni's own
|
|
703
|
+
* credentials (`[opengeni credential: …]`) stay while others can go.
|
|
704
|
+
*/
|
|
705
|
+
evict() {
|
|
706
|
+
if (this.values.size <= this.maxEntries) return;
|
|
707
|
+
for (const [value, label] of this.values) {
|
|
708
|
+
if (this.values.size <= this.maxEntries) break;
|
|
709
|
+
if (label.startsWith(CREDENTIAL_LABEL_OPEN)) continue;
|
|
710
|
+
this.values.delete(value);
|
|
711
|
+
}
|
|
712
|
+
while (this.values.size > this.maxEntries) {
|
|
713
|
+
const oldest = this.values.keys().next().value;
|
|
714
|
+
if (oldest === void 0) break;
|
|
715
|
+
this.values.delete(oldest);
|
|
716
|
+
}
|
|
717
|
+
this.compiled = null;
|
|
718
|
+
this.changes += 1;
|
|
719
|
+
}
|
|
720
|
+
/**
|
|
721
|
+
* An explicit, audited plaintext read (`secret_get`) handed this value to
|
|
722
|
+
* the agent on purpose: it is not masked for the rest of this memory's
|
|
723
|
+
* life. Never throws.
|
|
724
|
+
*/
|
|
725
|
+
reveal(value) {
|
|
726
|
+
try {
|
|
727
|
+
if (typeof value !== "string" || value.length === 0) return;
|
|
728
|
+
this.revealed.add(value);
|
|
729
|
+
let changed = false;
|
|
730
|
+
for (const [known, label] of this.values) {
|
|
731
|
+
if (label.startsWith(CREDENTIAL_LABEL_OPEN) || !value.includes(known)) continue;
|
|
732
|
+
this.values.delete(known);
|
|
733
|
+
changed = true;
|
|
734
|
+
}
|
|
735
|
+
for (const known of this.shapes.keys()) {
|
|
736
|
+
if (value.includes(known)) this.shapes.delete(known);
|
|
737
|
+
}
|
|
738
|
+
if (changed) {
|
|
739
|
+
this.compiled = null;
|
|
740
|
+
this.changes += 1;
|
|
741
|
+
}
|
|
742
|
+
} catch (error) {
|
|
743
|
+
this.report("reveal", error);
|
|
744
|
+
}
|
|
745
|
+
}
|
|
746
|
+
/**
|
|
747
|
+
* Whether `value` is, or lies within, a value `secret_get` revealed. Only a
|
|
748
|
+
* value of at least the minimum length counts as lying within one, so a
|
|
749
|
+
* short value is not released by a chance match.
|
|
750
|
+
*/
|
|
751
|
+
isRevealed(value) {
|
|
752
|
+
if (this.revealed.size === 0) return false;
|
|
753
|
+
if (this.revealed.has(value)) return true;
|
|
754
|
+
if (value.length < this.minChars) return false;
|
|
755
|
+
for (const revealed of this.revealed) if (revealed.includes(value)) return true;
|
|
756
|
+
return false;
|
|
757
|
+
}
|
|
758
|
+
/**
|
|
759
|
+
* Forget every value at the end of the owner's life (an attempt), so work
|
|
760
|
+
* that outlives it neither keeps the plaintext nor masks with it.
|
|
761
|
+
*/
|
|
762
|
+
dispose() {
|
|
763
|
+
this.disposed = true;
|
|
764
|
+
this.values.clear();
|
|
765
|
+
this.operations.clear();
|
|
766
|
+
this.revealed.clear();
|
|
767
|
+
this.shapes.clear();
|
|
768
|
+
this.shapeCapturer = void 0;
|
|
769
|
+
this.refresher = void 0;
|
|
770
|
+
this.compiled = null;
|
|
771
|
+
this.compiledReferenced = null;
|
|
772
|
+
this.changes += 1;
|
|
773
|
+
}
|
|
774
|
+
/**
|
|
775
|
+
* Remember a value and note that one tool call (its operation ID) used it,
|
|
776
|
+
* so the receiver of that call can mask its own stored text with exactly
|
|
777
|
+
* the values it was given.
|
|
778
|
+
*/
|
|
779
|
+
rememberForOperation(operationId, value, label) {
|
|
780
|
+
const searched = this.remember(value, label);
|
|
781
|
+
if (!searched || !operationId) return searched;
|
|
782
|
+
try {
|
|
783
|
+
const entries = this.operations.get(operationId) ?? [];
|
|
784
|
+
if (!entries.some((entry) => entry.value === value)) entries.push({ value, label });
|
|
785
|
+
this.operations.delete(operationId);
|
|
786
|
+
this.operations.set(operationId, entries);
|
|
787
|
+
while (this.operations.size > 256) {
|
|
788
|
+
const oldest = this.operations.keys().next().value;
|
|
789
|
+
if (oldest === void 0) break;
|
|
790
|
+
this.operations.delete(oldest);
|
|
791
|
+
}
|
|
792
|
+
} catch (error) {
|
|
793
|
+
this.report("remember", error);
|
|
794
|
+
}
|
|
795
|
+
return searched;
|
|
796
|
+
}
|
|
797
|
+
/** The values one tool call used (see `rememberForOperation`). */
|
|
798
|
+
operationEntries(operationId) {
|
|
799
|
+
return [...this.operations.get(operationId) ?? []];
|
|
800
|
+
}
|
|
801
|
+
/** Whether a value is remembered (for tests and dedupe; never exposes values). */
|
|
802
|
+
has(value) {
|
|
803
|
+
return this.values.has(value);
|
|
804
|
+
}
|
|
805
|
+
entries() {
|
|
806
|
+
return [...this.values].map(([value, label]) => ({ value, label }));
|
|
807
|
+
}
|
|
808
|
+
masks() {
|
|
809
|
+
this.compiled ??= compileSecretValueMasks(this.entries(), this.options);
|
|
810
|
+
return this.compiled;
|
|
811
|
+
}
|
|
812
|
+
/** Deep copy with every remembered value replaced; never throws. */
|
|
813
|
+
mask(value, stage = "mask") {
|
|
814
|
+
if (this.values.size === 0) return value;
|
|
815
|
+
try {
|
|
816
|
+
return maskSecretValues(value, this.masks());
|
|
817
|
+
} catch (error) {
|
|
818
|
+
this.report(stage, error);
|
|
819
|
+
return value;
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
/** `mask` without the values whose label is only a `[masked <kind>]` marker. */
|
|
823
|
+
maskReferenced(value, stage) {
|
|
824
|
+
if (this.values.size === 0) return value;
|
|
825
|
+
let markers = false;
|
|
826
|
+
for (const label of this.values.values()) {
|
|
827
|
+
if (label.startsWith(SHAPE_MARKER_OPEN)) {
|
|
828
|
+
markers = true;
|
|
829
|
+
break;
|
|
830
|
+
}
|
|
831
|
+
}
|
|
832
|
+
if (!markers) return this.mask(value, stage);
|
|
833
|
+
try {
|
|
834
|
+
if (this.compiledReferenced?.version !== this.changes) {
|
|
835
|
+
this.compiledReferenced = {
|
|
836
|
+
version: this.changes,
|
|
837
|
+
masks: compileSecretValueMasks(
|
|
838
|
+
this.entries().filter((entry) => !entry.label.startsWith(SHAPE_MARKER_OPEN)),
|
|
839
|
+
this.options
|
|
840
|
+
)
|
|
841
|
+
};
|
|
842
|
+
}
|
|
843
|
+
return maskSecretValues(value, this.compiledReferenced.masks);
|
|
844
|
+
} catch (error) {
|
|
845
|
+
this.report(stage, error);
|
|
846
|
+
return value;
|
|
847
|
+
}
|
|
848
|
+
}
|
|
849
|
+
/** Mask one text; never throws. */
|
|
850
|
+
maskText(text, stage = "mask") {
|
|
851
|
+
if (this.values.size === 0 || typeof text !== "string") return text;
|
|
852
|
+
try {
|
|
853
|
+
return maskSecretValuesInText(text, this.masks());
|
|
854
|
+
} catch (error) {
|
|
855
|
+
this.report(stage, error);
|
|
856
|
+
return text;
|
|
857
|
+
}
|
|
858
|
+
}
|
|
859
|
+
/** Mask with the remembered values plus, for this call only, extra ones. */
|
|
860
|
+
maskWith(value, extra, stage = "mask") {
|
|
861
|
+
if (extra.length === 0) return this.mask(value, stage);
|
|
862
|
+
try {
|
|
863
|
+
return maskSecretValues(value, [...this.entries(), ...extra], this.options);
|
|
864
|
+
} catch (error) {
|
|
865
|
+
this.report(stage, error);
|
|
866
|
+
return value;
|
|
867
|
+
}
|
|
868
|
+
}
|
|
869
|
+
/**
|
|
870
|
+
* Attach the capturer that saves secret-shaped values found in tool output
|
|
871
|
+
* (normally into the task vault). Without one they are masked with a marker.
|
|
872
|
+
*/
|
|
873
|
+
setShapeCapturer(capturer) {
|
|
874
|
+
this.shapeCapturer = capturer;
|
|
875
|
+
}
|
|
876
|
+
/**
|
|
877
|
+
* Remember a secret-shaped value from tool output: it is replaced wherever
|
|
878
|
+
* a shape detector finds it, and (when long enough) searched for as a known
|
|
879
|
+
* value everywhere else. A reference replaces an earlier marker.
|
|
880
|
+
*/
|
|
881
|
+
rememberShape(value, label, username) {
|
|
882
|
+
try {
|
|
883
|
+
if (typeof value !== "string" || typeof label !== "string" || value.length === 0) return;
|
|
884
|
+
if (this.disposed || this.isRevealed(value)) return;
|
|
885
|
+
const existing = this.shapes.get(value);
|
|
886
|
+
if (existing === void 0 || !isSecretReferenceMaskLabel(existing) && isSecretReferenceMaskLabel(label)) {
|
|
887
|
+
this.shapes.set(value, label);
|
|
888
|
+
while (this.shapes.size > this.maxEntries) {
|
|
889
|
+
const oldest = this.shapes.keys().next().value;
|
|
890
|
+
if (oldest === void 0) break;
|
|
891
|
+
this.shapes.delete(oldest);
|
|
892
|
+
}
|
|
893
|
+
}
|
|
894
|
+
if (isDistinctiveSecret(value, username)) {
|
|
895
|
+
this.remember(value, this.shapes.get(value) ?? label);
|
|
896
|
+
}
|
|
897
|
+
} catch (error) {
|
|
898
|
+
this.report("remember_shape", error);
|
|
899
|
+
}
|
|
900
|
+
}
|
|
901
|
+
/**
|
|
902
|
+
* Find secret-shaped values in tool output that are not known yet and
|
|
903
|
+
* capture them, waiting at most `maxWaitMs`. Values the capturer does not
|
|
904
|
+
* return a reference for (or all of them, without a capturer or on any
|
|
905
|
+
* failure) are remembered with a `[masked <kind>]` marker. Never throws.
|
|
906
|
+
*/
|
|
907
|
+
async captureShapes(value, stage = "tool_result", maxWaitMs = 5e3) {
|
|
908
|
+
let pending;
|
|
909
|
+
try {
|
|
910
|
+
const known = this.maskReferenced(value, stage);
|
|
911
|
+
pending = collectSecretShapes(known, 256, {
|
|
912
|
+
...this.options.skipKey ? { skipKey: this.options.skipKey } : {},
|
|
913
|
+
keep: (match, text) => !this.insideRevealed(match, text) && !this.isRevealed(match.value)
|
|
914
|
+
}).filter((match) => !isSecretReferenceMaskLabel(this.shapes.get(match.value) ?? ""));
|
|
915
|
+
} catch (error) {
|
|
916
|
+
this.report(stage, error);
|
|
917
|
+
return;
|
|
918
|
+
}
|
|
919
|
+
if (pending.length === 0) return;
|
|
920
|
+
const capturable = pending.slice(0, SECRET_SHAPE_CAPTURES_PER_RESULT);
|
|
921
|
+
const usernames = new Map(pending.map((match) => [match.value, match.username]));
|
|
922
|
+
let captured = /* @__PURE__ */ new Map();
|
|
923
|
+
const capturer = this.shapeCapturer;
|
|
924
|
+
if (capturer) {
|
|
925
|
+
let timer;
|
|
926
|
+
try {
|
|
927
|
+
const late = capturer(capturable);
|
|
928
|
+
late.then(
|
|
929
|
+
(references) => {
|
|
930
|
+
for (const [secret, reference] of references) {
|
|
931
|
+
if (!isSecretReferenceMaskLabel(reference)) continue;
|
|
932
|
+
this.rememberShape(secret, reference, usernames.get(secret));
|
|
933
|
+
}
|
|
934
|
+
},
|
|
935
|
+
() => {
|
|
936
|
+
}
|
|
937
|
+
);
|
|
938
|
+
captured = await Promise.race([
|
|
939
|
+
late,
|
|
940
|
+
new Promise((resolve) => {
|
|
941
|
+
timer = setTimeout(() => resolve(null), maxWaitMs);
|
|
942
|
+
})
|
|
943
|
+
]) ?? /* @__PURE__ */ new Map();
|
|
944
|
+
} catch (error) {
|
|
945
|
+
this.report("shape_capture", error);
|
|
946
|
+
} finally {
|
|
947
|
+
if (timer !== void 0) clearTimeout(timer);
|
|
948
|
+
}
|
|
949
|
+
}
|
|
950
|
+
for (const match of pending) {
|
|
951
|
+
const reference = captured.get(match.value);
|
|
952
|
+
this.rememberShape(
|
|
953
|
+
match.value,
|
|
954
|
+
reference && isSecretReferenceMaskLabel(reference) ? reference : secretShapeMaskLabel(match.kind),
|
|
955
|
+
match.username
|
|
956
|
+
);
|
|
957
|
+
}
|
|
958
|
+
}
|
|
959
|
+
/**
|
|
960
|
+
* Whether a detected part lies within a value `secret_get` revealed (as
|
|
961
|
+
* written or JSON-escaped), for example the password of a revealed URL.
|
|
962
|
+
*/
|
|
963
|
+
insideRevealed(match, text) {
|
|
964
|
+
if (this.revealed.size === 0) return false;
|
|
965
|
+
for (const value of this.revealed) {
|
|
966
|
+
for (const form of revealedForms(value)) {
|
|
967
|
+
const at = text.indexOf(form, Math.max(0, match.start - form.length + 1));
|
|
968
|
+
if (at >= 0 && at < match.end) return true;
|
|
969
|
+
}
|
|
970
|
+
}
|
|
971
|
+
return false;
|
|
972
|
+
}
|
|
973
|
+
/** What replaces a detected shape: its capture, a known label, a marker, or nothing when revealed. */
|
|
974
|
+
shapeLabel = (match, text) => this.insideRevealed(match, text) || this.isRevealed(match.value) ? null : this.shapes.get(match.value) ?? this.values.get(match.value) ?? secretShapeMaskLabel(match.kind);
|
|
975
|
+
/**
|
|
976
|
+
* Mask tool output: known values first, then every secret-shaped part
|
|
977
|
+
* (with its captured reference, or a marker). Never throws.
|
|
978
|
+
*/
|
|
979
|
+
maskToolOutput(value, stage = "tool_result") {
|
|
980
|
+
const known = this.mask(value, stage);
|
|
981
|
+
try {
|
|
982
|
+
return maskSecretShapes(known, this.shapeLabel, this.options.skipKey);
|
|
983
|
+
} catch (error) {
|
|
984
|
+
this.report(stage, error);
|
|
985
|
+
return known;
|
|
986
|
+
}
|
|
987
|
+
}
|
|
988
|
+
/** `maskToolOutput` for one text. */
|
|
989
|
+
maskToolOutputText(text, stage = "tool_result") {
|
|
990
|
+
const known = this.maskText(text, stage);
|
|
991
|
+
if (typeof known !== "string") return known;
|
|
992
|
+
try {
|
|
993
|
+
return maskSecretShapesInText(known, this.shapeLabel);
|
|
994
|
+
} catch (error) {
|
|
995
|
+
this.report(stage, error);
|
|
996
|
+
return known;
|
|
997
|
+
}
|
|
998
|
+
}
|
|
999
|
+
report(stage, error) {
|
|
1000
|
+
try {
|
|
1001
|
+
this.onDiagnostic?.({ stage, error: error instanceof Error ? error.name : typeof error });
|
|
1002
|
+
} catch {
|
|
1003
|
+
}
|
|
1004
|
+
}
|
|
1005
|
+
};
|
|
1006
|
+
function maskSecretValuesInError(error, memory, mode = "known", depth = 0) {
|
|
1007
|
+
if (!memory || !(error instanceof Error) || depth > 4) return error;
|
|
1008
|
+
if (mode === "known" && memory.size === 0) return error;
|
|
1009
|
+
const field = (name) => {
|
|
1010
|
+
try {
|
|
1011
|
+
const text = error[name];
|
|
1012
|
+
if (typeof text !== "string") return;
|
|
1013
|
+
const masked = mode === "tool_output" ? memory.maskToolOutputText(text, "tool_error") : memory.maskText(text, "tool_error");
|
|
1014
|
+
if (masked !== text) error[name] = masked;
|
|
1015
|
+
} catch {
|
|
1016
|
+
}
|
|
1017
|
+
};
|
|
1018
|
+
field("message");
|
|
1019
|
+
field("stack");
|
|
1020
|
+
try {
|
|
1021
|
+
if (error.cause !== void 0) maskSecretValuesInError(error.cause, memory, mode, depth + 1);
|
|
1022
|
+
} catch {
|
|
1023
|
+
}
|
|
1024
|
+
try {
|
|
1025
|
+
const inner = error.errors;
|
|
1026
|
+
if (Array.isArray(inner)) {
|
|
1027
|
+
for (const item of inner.slice(0, 32)) {
|
|
1028
|
+
maskSecretValuesInError(item, memory, mode, depth + 1);
|
|
1029
|
+
}
|
|
1030
|
+
}
|
|
1031
|
+
} catch {
|
|
1032
|
+
}
|
|
1033
|
+
return error;
|
|
1034
|
+
}
|
|
1035
|
+
function isSecretRevealToolName(name) {
|
|
1036
|
+
return name === "secret_get" || name === "opengeni__secret_get";
|
|
1037
|
+
}
|
|
1038
|
+
function decodedBase64Text(value) {
|
|
1039
|
+
try {
|
|
1040
|
+
const binary = atob(value.replace(/\s+/gu, ""));
|
|
1041
|
+
const bytes = new Uint8Array(binary.length);
|
|
1042
|
+
for (let index = 0; index < binary.length; index += 1) bytes[index] = binary.charCodeAt(index);
|
|
1043
|
+
return new TextDecoder("utf-8", { fatal: true }).decode(bytes);
|
|
1044
|
+
} catch {
|
|
1045
|
+
return null;
|
|
1046
|
+
}
|
|
1047
|
+
}
|
|
1048
|
+
function secretGetRevealedValues(result, depth = 0) {
|
|
1049
|
+
if (depth > 6) return [];
|
|
1050
|
+
if (typeof result === "string") {
|
|
1051
|
+
const trimmed = result.trim();
|
|
1052
|
+
if (!trimmed.startsWith("{") && !trimmed.startsWith("[")) return [];
|
|
1053
|
+
try {
|
|
1054
|
+
return secretGetRevealedValues(JSON.parse(trimmed), depth + 1);
|
|
1055
|
+
} catch {
|
|
1056
|
+
return [];
|
|
1057
|
+
}
|
|
1058
|
+
}
|
|
1059
|
+
if (result === null || typeof result !== "object") return [];
|
|
1060
|
+
if (Array.isArray(result)) {
|
|
1061
|
+
return result.flatMap((item) => secretGetRevealedValues(item, depth + 1));
|
|
1062
|
+
}
|
|
1063
|
+
const record = result;
|
|
1064
|
+
if (typeof record.value === "string" && record.encoding === "utf8") return [record.value];
|
|
1065
|
+
if (typeof record.value === "string" && record.encoding === "base64") {
|
|
1066
|
+
const decoded = decodedBase64Text(record.value);
|
|
1067
|
+
return decoded === null ? [record.value] : [record.value, decoded];
|
|
1068
|
+
}
|
|
1069
|
+
return Object.values(record).flatMap((value) => secretGetRevealedValues(value, depth + 1));
|
|
1070
|
+
}
|
|
1071
|
+
function revealSecretGetResult(memory, toolName, result) {
|
|
1072
|
+
if (!memory) return;
|
|
1073
|
+
try {
|
|
1074
|
+
if (!isSecretRevealToolName(toolName)) return;
|
|
1075
|
+
for (const value of secretGetRevealedValues(result)) memory.reveal(value);
|
|
1076
|
+
} catch {
|
|
1077
|
+
}
|
|
1078
|
+
}
|
|
1079
|
+
function textMaterial(value) {
|
|
1080
|
+
const material = value.material;
|
|
1081
|
+
if (material.type === "text") return material.value;
|
|
1082
|
+
if (material.type === "bytes") {
|
|
1083
|
+
try {
|
|
1084
|
+
return new TextDecoder("utf-8", { fatal: true }).decode(material.value);
|
|
1085
|
+
} catch {
|
|
1086
|
+
return null;
|
|
1087
|
+
}
|
|
1088
|
+
}
|
|
1089
|
+
return null;
|
|
1090
|
+
}
|
|
1091
|
+
function rememberResolvedSecretValues(memory, resolved, operationId) {
|
|
1092
|
+
if (!memory) return;
|
|
1093
|
+
for (const value of resolved.values()) {
|
|
1094
|
+
try {
|
|
1095
|
+
if (value.fieldKind === "text") continue;
|
|
1096
|
+
const text = textMaterial(value);
|
|
1097
|
+
if (text === null) continue;
|
|
1098
|
+
const label = secretReferenceMaskLabel({
|
|
1099
|
+
raw: value.reference.raw,
|
|
1100
|
+
itemId: value.itemId,
|
|
1101
|
+
fieldName: value.fieldName
|
|
1102
|
+
});
|
|
1103
|
+
if (operationId) memory.rememberForOperation(operationId, text, label);
|
|
1104
|
+
else memory.remember(text, label);
|
|
1105
|
+
} catch {
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
}
|
|
1109
|
+
function rememberingSecretResolver(resolver, target) {
|
|
1110
|
+
return {
|
|
1111
|
+
get principal() {
|
|
1112
|
+
return resolver.principal;
|
|
1113
|
+
},
|
|
1114
|
+
get enabled() {
|
|
1115
|
+
return resolver.enabled;
|
|
1116
|
+
},
|
|
1117
|
+
async resolve(refs, use) {
|
|
1118
|
+
const resolved = await resolver.resolve(refs, use);
|
|
1119
|
+
let memory;
|
|
1120
|
+
try {
|
|
1121
|
+
memory = typeof target === "function" ? target() : target;
|
|
1122
|
+
} catch {
|
|
1123
|
+
memory = null;
|
|
1124
|
+
}
|
|
1125
|
+
rememberResolvedSecretValues(memory, resolved, use.operationId);
|
|
1126
|
+
return resolved;
|
|
1127
|
+
}
|
|
1128
|
+
};
|
|
1129
|
+
}
|
|
1130
|
+
|
|
1131
|
+
export {
|
|
1132
|
+
SECRET_REFERENCE_MARKER,
|
|
1133
|
+
SecretReferenceSyntaxError,
|
|
1134
|
+
containsSecretReference,
|
|
1135
|
+
tokenizeSecretText,
|
|
1136
|
+
findSecretReferences,
|
|
1137
|
+
findInvalidSecretReferences,
|
|
1138
|
+
parseSecretReference,
|
|
1139
|
+
formatSecretReference,
|
|
1140
|
+
secretNameKey,
|
|
1141
|
+
referenceKey,
|
|
1142
|
+
unescapeSecretText,
|
|
1143
|
+
collectReferencesDeep,
|
|
1144
|
+
collectInvalidReferencesDeep,
|
|
1145
|
+
replaceReferencesDeep,
|
|
1146
|
+
SECRET_VALUE_MASK_MIN_CHARS,
|
|
1147
|
+
SECRET_VALUE_CLIPPED_MIN_CHARS,
|
|
1148
|
+
SECRET_VALUE_CLIPPED_MIN_SHARE,
|
|
1149
|
+
SECRET_VALUE_MEMORY_MAX_ENTRIES,
|
|
1150
|
+
secretCredentialMaskLabel,
|
|
1151
|
+
SECRET_VALUE_GENERIC_MASK_LABEL,
|
|
1152
|
+
secretReferenceMaskLabel,
|
|
1153
|
+
isSecretReferenceMaskLabel,
|
|
1154
|
+
secretValueForms,
|
|
1155
|
+
SECRET_VALUE_CLIPPED_TEXT_END_MIN_CHARS,
|
|
1156
|
+
compileSecretValueMasks,
|
|
1157
|
+
maskSecretValuesInText,
|
|
1158
|
+
maskSecretValues,
|
|
1159
|
+
FIRST_PARTY_SECRET_VALUES_META_KEY,
|
|
1160
|
+
firstPartySecretValuesFromMeta,
|
|
1161
|
+
SECRET_SHAPE_CAPTURES_PER_RESULT,
|
|
1162
|
+
SecretValueMemory,
|
|
1163
|
+
maskSecretValuesInError,
|
|
1164
|
+
isSecretRevealToolName,
|
|
1165
|
+
secretGetRevealedValues,
|
|
1166
|
+
revealSecretGetResult,
|
|
1167
|
+
rememberResolvedSecretValues,
|
|
1168
|
+
rememberingSecretResolver
|
|
1169
|
+
};
|
|
1170
|
+
//# sourceMappingURL=chunk-VLUKBV6Y.js.map
|