@rockcarver/frodo-lib 4.10.0-1 → 4.11.0-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/dist/index.js +2 -2
- package/dist/index.mjs +2 -2
- package/package.json +6 -3
- package/types/api/AgentApi.d.ts +128 -0
- package/types/api/AgentApi.d.ts.map +1 -0
- package/types/api/AmConfigApi.d.ts +87 -0
- package/types/api/AmConfigApi.d.ts.map +1 -0
- package/types/api/ApiTypes.d.ts +59 -0
- package/types/api/ApiTypes.d.ts.map +1 -0
- package/types/api/AuthenticateApi.d.ts +38 -0
- package/types/api/AuthenticateApi.d.ts.map +1 -0
- package/types/api/AuthenticationSettingsApi.d.ts +31 -0
- package/types/api/AuthenticationSettingsApi.d.ts.map +1 -0
- package/types/api/BaseApi.d.ts +190 -0
- package/types/api/BaseApi.d.ts.map +1 -0
- package/types/api/CirclesOfTrustApi.d.ts +52 -0
- package/types/api/CirclesOfTrustApi.d.ts.map +1 -0
- package/types/api/IdmConfigApi.d.ts +69 -0
- package/types/api/IdmConfigApi.d.ts.map +1 -0
- package/types/api/IdmScriptApi.d.ts +17 -0
- package/types/api/IdmScriptApi.d.ts.map +1 -0
- package/types/api/IdmSystemApi.d.ts +111 -0
- package/types/api/IdmSystemApi.d.ts.map +1 -0
- package/types/api/InternalObjectApi.d.ts +103 -0
- package/types/api/InternalObjectApi.d.ts.map +1 -0
- package/types/api/ManagedObjectApi.d.ts +252 -0
- package/types/api/ManagedObjectApi.d.ts.map +1 -0
- package/types/api/ManagedSystemObjectApi.d.ts +150 -0
- package/types/api/ManagedSystemObjectApi.d.ts.map +1 -0
- package/types/api/NodeApi.d.ts +243 -0
- package/types/api/NodeApi.d.ts.map +1 -0
- package/types/api/OAuth2ClientApi.d.ts +78 -0
- package/types/api/OAuth2ClientApi.d.ts.map +1 -0
- package/types/api/OAuth2OIDCApi.d.ts +121 -0
- package/types/api/OAuth2OIDCApi.d.ts.map +1 -0
- package/types/api/OAuth2ProviderApi.d.ts +176 -0
- package/types/api/OAuth2ProviderApi.d.ts.map +1 -0
- package/types/api/OAuth2TrustedJwtIssuerApi.d.ts +54 -0
- package/types/api/OAuth2TrustedJwtIssuerApi.d.ts.map +1 -0
- package/types/api/PoliciesApi.d.ts +60 -0
- package/types/api/PoliciesApi.d.ts.map +1 -0
- package/types/api/PolicySetApi.d.ts +52 -0
- package/types/api/PolicySetApi.d.ts.map +1 -0
- package/types/api/RawConfigApi.d.ts +75 -0
- package/types/api/RawConfigApi.d.ts.map +1 -0
- package/types/api/RealmApi.d.ts +54 -0
- package/types/api/RealmApi.d.ts.map +1 -0
- package/types/api/ReconApi.d.ts +171 -0
- package/types/api/ReconApi.d.ts.map +1 -0
- package/types/api/ResourceTypesApi.d.ts +63 -0
- package/types/api/ResourceTypesApi.d.ts.map +1 -0
- package/types/api/Saml2Api.d.ts +112 -0
- package/types/api/Saml2Api.d.ts.map +1 -0
- package/types/api/ScriptApi.d.ts +94 -0
- package/types/api/ScriptApi.d.ts.map +1 -0
- package/types/api/ScriptTypeApi.d.ts +103 -0
- package/types/api/ScriptTypeApi.d.ts.map +1 -0
- package/types/api/SecretStoreApi.d.ts +185 -0
- package/types/api/SecretStoreApi.d.ts.map +1 -0
- package/types/api/ServerInfoApi.d.ts +26 -0
- package/types/api/ServerInfoApi.d.ts.map +1 -0
- package/types/api/ServiceApi.d.ts +102 -0
- package/types/api/ServiceApi.d.ts.map +1 -0
- package/types/api/SessionApi.d.ts +23 -0
- package/types/api/SessionApi.d.ts.map +1 -0
- package/types/api/SocialIdentityProvidersApi.d.ts +89 -0
- package/types/api/SocialIdentityProvidersApi.d.ts.map +1 -0
- package/types/api/TreeApi.d.ts +62 -0
- package/types/api/TreeApi.d.ts.map +1 -0
- package/types/api/UserApi.d.ts +159 -0
- package/types/api/UserApi.d.ts.map +1 -0
- package/types/api/classic/ServerApi.d.ts +78 -0
- package/types/api/classic/ServerApi.d.ts.map +1 -0
- package/types/api/classic/SiteApi.d.ts +39 -0
- package/types/api/classic/SiteApi.d.ts.map +1 -0
- package/types/api/cloud/AdminFederationProvidersApi.d.ts +71 -0
- package/types/api/cloud/AdminFederationProvidersApi.d.ts.map +1 -0
- package/types/api/cloud/EnvAIAgentApi.d.ts +9 -0
- package/types/api/cloud/EnvAIAgentApi.d.ts.map +1 -0
- package/types/api/cloud/EnvCSRsApi.d.ts +165 -0
- package/types/api/cloud/EnvCSRsApi.d.ts.map +1 -0
- package/types/api/cloud/EnvCertificatesApi.d.ts +74 -0
- package/types/api/cloud/EnvCertificatesApi.d.ts.map +1 -0
- package/types/api/cloud/EnvContentSecurityPolicyApi.d.ts +87 -0
- package/types/api/cloud/EnvContentSecurityPolicyApi.d.ts.map +1 -0
- package/types/api/cloud/EnvCookieDomainsApi.d.ts +26 -0
- package/types/api/cloud/EnvCookieDomainsApi.d.ts.map +1 -0
- package/types/api/cloud/EnvCustomDomainsApi.d.ts +37 -0
- package/types/api/cloud/EnvCustomDomainsApi.d.ts.map +1 -0
- package/types/api/cloud/EnvDirectConfigurationSessionApi.d.ts +43 -0
- package/types/api/cloud/EnvDirectConfigurationSessionApi.d.ts.map +1 -0
- package/types/api/cloud/EnvFederationEnforcementApi.d.ts +26 -0
- package/types/api/cloud/EnvFederationEnforcementApi.d.ts.map +1 -0
- package/types/api/cloud/EnvInfoApi.d.ts +22 -0
- package/types/api/cloud/EnvInfoApi.d.ts.map +1 -0
- package/types/api/cloud/EnvPromotionApi.d.ts +218 -0
- package/types/api/cloud/EnvPromotionApi.d.ts.map +1 -0
- package/types/api/cloud/EnvReleaseApi.d.ts +16 -0
- package/types/api/cloud/EnvReleaseApi.d.ts.map +1 -0
- package/types/api/cloud/EnvSSOCookieConfigApi.d.ts +35 -0
- package/types/api/cloud/EnvSSOCookieConfigApi.d.ts.map +1 -0
- package/types/api/cloud/EnvServiceAccountScopesApi.d.ts +17 -0
- package/types/api/cloud/EnvServiceAccountScopesApi.d.ts.map +1 -0
- package/types/api/cloud/EsvCountApi.d.ts +13 -0
- package/types/api/cloud/EsvCountApi.d.ts.map +1 -0
- package/types/api/cloud/FeatureApi.d.ts +16 -0
- package/types/api/cloud/FeatureApi.d.ts.map +1 -0
- package/types/api/cloud/IdmFeatureApi.d.ts +65 -0
- package/types/api/cloud/IdmFeatureApi.d.ts.map +1 -0
- package/types/api/cloud/LogApi.d.ts +108 -0
- package/types/api/cloud/LogApi.d.ts.map +1 -0
- package/types/api/cloud/SecretsApi.d.ts +163 -0
- package/types/api/cloud/SecretsApi.d.ts.map +1 -0
- package/types/api/cloud/StartupApi.d.ts +20 -0
- package/types/api/cloud/StartupApi.d.ts.map +1 -0
- package/types/api/cloud/TelemetryApi.d.ts +60 -0
- package/types/api/cloud/TelemetryApi.d.ts.map +1 -0
- package/types/api/cloud/VariablesApi.d.ts +86 -0
- package/types/api/cloud/VariablesApi.d.ts.map +1 -0
- package/types/api/cloud/WSFedApi.d.ts +495 -0
- package/types/api/cloud/WSFedApi.d.ts.map +1 -0
- package/types/api/cloud/iga/IgaCertificationTemplateApi.d.ts +227 -0
- package/types/api/cloud/iga/IgaCertificationTemplateApi.d.ts.map +1 -0
- package/types/api/cloud/iga/IgaEventApi.d.ts +111 -0
- package/types/api/cloud/iga/IgaEventApi.d.ts.map +1 -0
- package/types/api/cloud/iga/IgaGlossaryApi.d.ts +103 -0
- package/types/api/cloud/iga/IgaGlossaryApi.d.ts.map +1 -0
- package/types/api/cloud/iga/IgaRequestFormApi.d.ts +184 -0
- package/types/api/cloud/iga/IgaRequestFormApi.d.ts.map +1 -0
- package/types/api/cloud/iga/IgaRequestTypeApi.d.ts +124 -0
- package/types/api/cloud/iga/IgaRequestTypeApi.d.ts.map +1 -0
- package/types/api/cloud/iga/IgaWorkflowApi.d.ts +208 -0
- package/types/api/cloud/iga/IgaWorkflowApi.d.ts.map +1 -0
- package/types/ext/axios-curlirize/curlirize.d.ts +14 -0
- package/types/ext/axios-curlirize/curlirize.d.ts.map +1 -0
- package/types/ext/axios-curlirize/lib/CurlHelper.d.ts +12 -0
- package/types/ext/axios-curlirize/lib/CurlHelper.d.ts.map +1 -0
- package/types/index.d.ts +11 -0
- package/types/index.d.ts.map +1 -0
- package/types/lib/FrodoLib.d.ts +407 -0
- package/types/lib/FrodoLib.d.ts.map +1 -0
- package/types/lib/Help.d.ts +18 -0
- package/types/lib/Help.d.ts.map +1 -0
- package/types/mcp/CapabilityMetadata.d.ts +48 -0
- package/types/mcp/CapabilityMetadata.d.ts.map +1 -0
- package/types/mcp/CapabilityPolicy.d.ts +22 -0
- package/types/mcp/CapabilityPolicy.d.ts.map +1 -0
- package/types/mcp/CapabilityRegistry.d.ts +62 -0
- package/types/mcp/CapabilityRegistry.d.ts.map +1 -0
- package/types/mcp/CapabilityRouting.d.ts +9 -0
- package/types/mcp/CapabilityRouting.d.ts.map +1 -0
- package/types/mcp/CapabilityTypes.d.ts +371 -0
- package/types/mcp/CapabilityTypes.d.ts.map +1 -0
- package/types/mcp/DiscoveryHydration.d.ts +21 -0
- package/types/mcp/DiscoveryHydration.d.ts.map +1 -0
- package/types/mcp/DocsContext.d.ts +123 -0
- package/types/mcp/DocsContext.d.ts.map +1 -0
- package/types/mcp/McpService.d.ts +94 -0
- package/types/mcp/McpService.d.ts.map +1 -0
- package/types/mcp/ProfileRegistry.d.ts +63 -0
- package/types/mcp/ProfileRegistry.d.ts.map +1 -0
- package/types/mcp/SemanticIdentifiers.d.ts +17 -0
- package/types/mcp/SemanticIdentifiers.d.ts.map +1 -0
- package/types/mcp/SemanticObjectFamilies.d.ts +24 -0
- package/types/mcp/SemanticObjectFamilies.d.ts.map +1 -0
- package/types/mcp/ToolManifest.d.ts +231 -0
- package/types/mcp/ToolManifest.d.ts.map +1 -0
- package/types/mcp/ToolRuntime.d.ts +477 -0
- package/types/mcp/ToolRuntime.d.ts.map +1 -0
- package/types/mcp/index.d.ts +20 -0
- package/types/mcp/index.d.ts.map +1 -0
- package/types/ops/AdminOps.d.ts +85 -0
- package/types/ops/AdminOps.d.ts.map +1 -0
- package/types/ops/AgentOps.d.ts +938 -0
- package/types/ops/AgentOps.d.ts.map +1 -0
- package/types/ops/AmConfigOps.d.ts +96 -0
- package/types/ops/AmConfigOps.d.ts.map +1 -0
- package/types/ops/ApiFactoryOps.d.ts +77 -0
- package/types/ops/ApiFactoryOps.d.ts.map +1 -0
- package/types/ops/ApplicationOps.d.ts +334 -0
- package/types/ops/ApplicationOps.d.ts.map +1 -0
- package/types/ops/AuthenticateOps.d.ts +196 -0
- package/types/ops/AuthenticateOps.d.ts.map +1 -0
- package/types/ops/AuthenticationSettingsOps.d.ts +78 -0
- package/types/ops/AuthenticationSettingsOps.d.ts.map +1 -0
- package/types/ops/BrowserAuthenticateOps.d.ts +188 -0
- package/types/ops/BrowserAuthenticateOps.d.ts.map +1 -0
- package/types/ops/CallbackOps.d.ts +27 -0
- package/types/ops/CallbackOps.d.ts.map +1 -0
- package/types/ops/CallerTrustTierOps.d.ts +103 -0
- package/types/ops/CallerTrustTierOps.d.ts.map +1 -0
- package/types/ops/CirclesOfTrustOps.d.ts +203 -0
- package/types/ops/CirclesOfTrustOps.d.ts.map +1 -0
- package/types/ops/ConfigOps.d.ts +214 -0
- package/types/ops/ConfigOps.d.ts.map +1 -0
- package/types/ops/ConnectionProfileOps.d.ts +346 -0
- package/types/ops/ConnectionProfileOps.d.ts.map +1 -0
- package/types/ops/ConnectorOps.d.ts +269 -0
- package/types/ops/ConnectorOps.d.ts.map +1 -0
- package/types/ops/EmailTemplateOps.d.ts +160 -0
- package/types/ops/EmailTemplateOps.d.ts.map +1 -0
- package/types/ops/FrodoError.d.ts +40 -0
- package/types/ops/FrodoError.d.ts.map +1 -0
- package/types/ops/IdmConfigOps.d.ts +286 -0
- package/types/ops/IdmConfigOps.d.ts.map +1 -0
- package/types/ops/IdmCryptoOps.d.ts +68 -0
- package/types/ops/IdmCryptoOps.d.ts.map +1 -0
- package/types/ops/IdmScriptOps.d.ts +29 -0
- package/types/ops/IdmScriptOps.d.ts.map +1 -0
- package/types/ops/IdmSystemOps.d.ts +198 -0
- package/types/ops/IdmSystemOps.d.ts.map +1 -0
- package/types/ops/IdpOps.d.ts +234 -0
- package/types/ops/IdpOps.d.ts.map +1 -0
- package/types/ops/InfoOps.d.ts +28 -0
- package/types/ops/InfoOps.d.ts.map +1 -0
- package/types/ops/InternalRoleOps.d.ts +232 -0
- package/types/ops/InternalRoleOps.d.ts.map +1 -0
- package/types/ops/JoseOps.d.ts +87 -0
- package/types/ops/JoseOps.d.ts.map +1 -0
- package/types/ops/JourneyOps.d.ts +573 -0
- package/types/ops/JourneyOps.d.ts.map +1 -0
- package/types/ops/ManagedObjectOps.d.ts +393 -0
- package/types/ops/ManagedObjectOps.d.ts.map +1 -0
- package/types/ops/ManagedObjectSchemaOps.d.ts +757 -0
- package/types/ops/ManagedObjectSchemaOps.d.ts.map +1 -0
- package/types/ops/ManagedSystemObjectOps.d.ts +270 -0
- package/types/ops/ManagedSystemObjectOps.d.ts.map +1 -0
- package/types/ops/ManagedSystemObjectSchemaOps.d.ts +42 -0
- package/types/ops/ManagedSystemObjectSchemaOps.d.ts.map +1 -0
- package/types/ops/MappingOps.d.ts +332 -0
- package/types/ops/MappingOps.d.ts.map +1 -0
- package/types/ops/NodeOps.d.ts +627 -0
- package/types/ops/NodeOps.d.ts.map +1 -0
- package/types/ops/OAuth2ClientOps.d.ts +235 -0
- package/types/ops/OAuth2ClientOps.d.ts.map +1 -0
- package/types/ops/OAuth2OidcOps.d.ts +64 -0
- package/types/ops/OAuth2OidcOps.d.ts.map +1 -0
- package/types/ops/OAuth2ProviderOps.d.ts +57 -0
- package/types/ops/OAuth2ProviderOps.d.ts.map +1 -0
- package/types/ops/OAuth2TrustedJwtIssuerOps.d.ts +223 -0
- package/types/ops/OAuth2TrustedJwtIssuerOps.d.ts.map +1 -0
- package/types/ops/OpsTypes.d.ts +12 -0
- package/types/ops/OpsTypes.d.ts.map +1 -0
- package/types/ops/OrganizationOps.d.ts +34 -0
- package/types/ops/OrganizationOps.d.ts.map +1 -0
- package/types/ops/PolicyOps.d.ts +294 -0
- package/types/ops/PolicyOps.d.ts.map +1 -0
- package/types/ops/PolicySetOps.d.ts +195 -0
- package/types/ops/PolicySetOps.d.ts.map +1 -0
- package/types/ops/PrivilegeEscalationOps.d.ts +51 -0
- package/types/ops/PrivilegeEscalationOps.d.ts.map +1 -0
- package/types/ops/RawConfigOps.d.ts +67 -0
- package/types/ops/RawConfigOps.d.ts.map +1 -0
- package/types/ops/RealmOps.d.ts +196 -0
- package/types/ops/RealmOps.d.ts.map +1 -0
- package/types/ops/ReconOps.d.ts +57 -0
- package/types/ops/ReconOps.d.ts.map +1 -0
- package/types/ops/RequiredScopesOps.d.ts +69 -0
- package/types/ops/RequiredScopesOps.d.ts.map +1 -0
- package/types/ops/ResourceTypeOps.d.ts +219 -0
- package/types/ops/ResourceTypeOps.d.ts.map +1 -0
- package/types/ops/Saml2Ops.d.ts +261 -0
- package/types/ops/Saml2Ops.d.ts.map +1 -0
- package/types/ops/ScriptOps.d.ts +426 -0
- package/types/ops/ScriptOps.d.ts.map +1 -0
- package/types/ops/ScriptTypeOps.d.ts +124 -0
- package/types/ops/ScriptTypeOps.d.ts.map +1 -0
- package/types/ops/SecretStoreOps.d.ts +357 -0
- package/types/ops/SecretStoreOps.d.ts.map +1 -0
- package/types/ops/ServiceOps.d.ts +194 -0
- package/types/ops/ServiceOps.d.ts.map +1 -0
- package/types/ops/SessionOps.d.ts +22 -0
- package/types/ops/SessionOps.d.ts.map +1 -0
- package/types/ops/ThemeOps.d.ts +245 -0
- package/types/ops/ThemeOps.d.ts.map +1 -0
- package/types/ops/TokenCacheOps.d.ts +243 -0
- package/types/ops/TokenCacheOps.d.ts.map +1 -0
- package/types/ops/UserOps.d.ts +199 -0
- package/types/ops/UserOps.d.ts.map +1 -0
- package/types/ops/VersionUtils.d.ts +29 -0
- package/types/ops/VersionUtils.d.ts.map +1 -0
- package/types/ops/classic/ServerOps.d.ts +195 -0
- package/types/ops/classic/ServerOps.d.ts.map +1 -0
- package/types/ops/classic/SiteOps.d.ts +117 -0
- package/types/ops/classic/SiteOps.d.ts.map +1 -0
- package/types/ops/cloud/AdminFederationOps.d.ts +165 -0
- package/types/ops/cloud/AdminFederationOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvAIAgentOps.d.ts +18 -0
- package/types/ops/cloud/EnvAIAgentOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvCSRsOps.d.ts +86 -0
- package/types/ops/cloud/EnvCSRsOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvCertificatesOps.d.ts +140 -0
- package/types/ops/cloud/EnvCertificatesOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvContentSecurityPolicyOps.d.ts +101 -0
- package/types/ops/cloud/EnvContentSecurityPolicyOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvCookieDomainsOps.d.ts +36 -0
- package/types/ops/cloud/EnvCookieDomainsOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvCustomDomainsOps.d.ts +53 -0
- package/types/ops/cloud/EnvCustomDomainsOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvDirectConfigurationSessionOps.d.ts +55 -0
- package/types/ops/cloud/EnvDirectConfigurationSessionOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvFederationEnforcementOps.d.ts +58 -0
- package/types/ops/cloud/EnvFederationEnforcementOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvPromotionOps.d.ts +175 -0
- package/types/ops/cloud/EnvPromotionOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvReleaseOps.d.ts +19 -0
- package/types/ops/cloud/EnvReleaseOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvSSOCookieConfigOps.d.ts +50 -0
- package/types/ops/cloud/EnvSSOCookieConfigOps.d.ts.map +1 -0
- package/types/ops/cloud/EnvServiceAccountScopesOps.d.ts +21 -0
- package/types/ops/cloud/EnvServiceAccountScopesOps.d.ts.map +1 -0
- package/types/ops/cloud/EsvCountOps.d.ts +15 -0
- package/types/ops/cloud/EsvCountOps.d.ts.map +1 -0
- package/types/ops/cloud/FeatureOps.d.ts +34 -0
- package/types/ops/cloud/FeatureOps.d.ts.map +1 -0
- package/types/ops/cloud/IdmFeatureOps.d.ts +78 -0
- package/types/ops/cloud/IdmFeatureOps.d.ts.map +1 -0
- package/types/ops/cloud/LogOps.d.ts +271 -0
- package/types/ops/cloud/LogOps.d.ts.map +1 -0
- package/types/ops/cloud/SecretsOps.d.ts +306 -0
- package/types/ops/cloud/SecretsOps.d.ts.map +1 -0
- package/types/ops/cloud/ServiceAccountOps.d.ts +86 -0
- package/types/ops/cloud/ServiceAccountOps.d.ts.map +1 -0
- package/types/ops/cloud/StartupOps.d.ts +62 -0
- package/types/ops/cloud/StartupOps.d.ts.map +1 -0
- package/types/ops/cloud/TelemetryOps.d.ts +109 -0
- package/types/ops/cloud/TelemetryOps.d.ts.map +1 -0
- package/types/ops/cloud/VariablesOps.d.ts +224 -0
- package/types/ops/cloud/VariablesOps.d.ts.map +1 -0
- package/types/ops/cloud/WSFedOps.d.ts +412 -0
- package/types/ops/cloud/WSFedOps.d.ts.map +1 -0
- package/types/ops/cloud/iga/IgaCertificationTemplateOps.d.ts +261 -0
- package/types/ops/cloud/iga/IgaCertificationTemplateOps.d.ts.map +1 -0
- package/types/ops/cloud/iga/IgaEventOps.d.ts +242 -0
- package/types/ops/cloud/iga/IgaEventOps.d.ts.map +1 -0
- package/types/ops/cloud/iga/IgaGlossaryOps.d.ts +241 -0
- package/types/ops/cloud/iga/IgaGlossaryOps.d.ts.map +1 -0
- package/types/ops/cloud/iga/IgaRequestFormOps.d.ts +259 -0
- package/types/ops/cloud/iga/IgaRequestFormOps.d.ts.map +1 -0
- package/types/ops/cloud/iga/IgaRequestTypeOps.d.ts +240 -0
- package/types/ops/cloud/iga/IgaRequestTypeOps.d.ts.map +1 -0
- package/types/ops/cloud/iga/IgaWorkflowOps.d.ts +334 -0
- package/types/ops/cloud/iga/IgaWorkflowOps.d.ts.map +1 -0
- package/types/ops/internal/RelationshipHelpers.d.ts +111 -0
- package/types/ops/internal/RelationshipHelpers.d.ts.map +1 -0
- package/types/shared/Constants.d.ts +100 -0
- package/types/shared/Constants.d.ts.map +1 -0
- package/types/shared/OperationType.d.ts +14 -0
- package/types/shared/OperationType.d.ts.map +1 -0
- package/types/shared/State.d.ts +355 -0
- package/types/shared/State.d.ts.map +1 -0
- package/types/shared/Version.d.ts +16 -0
- package/types/shared/Version.d.ts.map +1 -0
- package/types/test/mocks/ForgeRockApiMockEngine.d.ts +38 -0
- package/types/test/mocks/ForgeRockApiMockEngine.d.ts.map +1 -0
- package/types/test/setup/EmailTemplateSetup.d.ts +8 -0
- package/types/test/setup/EmailTemplateSetup.d.ts.map +1 -0
- package/types/test/setup/IgaCertificationTemplateSetup.d.ts +12 -0
- package/types/test/setup/IgaCertificationTemplateSetup.d.ts.map +1 -0
- package/types/test/setup/IgaEventSetup.d.ts +22 -0
- package/types/test/setup/IgaEventSetup.d.ts.map +1 -0
- package/types/test/setup/IgaGlossarySetup.d.ts +11 -0
- package/types/test/setup/IgaGlossarySetup.d.ts.map +1 -0
- package/types/test/setup/IgaRequestFormSetup.d.ts +42 -0
- package/types/test/setup/IgaRequestFormSetup.d.ts.map +1 -0
- package/types/test/setup/IgaRequestTypeSetup.d.ts +10 -0
- package/types/test/setup/IgaRequestTypeSetup.d.ts.map +1 -0
- package/types/test/setup/IgaWorkflowSetup.d.ts +32 -0
- package/types/test/setup/IgaWorkflowSetup.d.ts.map +1 -0
- package/types/test/setup/JourneySetup.d.ts +18 -0
- package/types/test/setup/JourneySetup.d.ts.map +1 -0
- package/types/test/setup/NodeSetup.d.ts +14 -0
- package/types/test/setup/NodeSetup.d.ts.map +1 -0
- package/types/test/setup/RawConfigSetup.d.ts +2 -0
- package/types/test/setup/RawConfigSetup.d.ts.map +1 -0
- package/types/test/setup/SecretSetup.d.ts +69 -0
- package/types/test/setup/SecretSetup.d.ts.map +1 -0
- package/types/test/setup/StartupSetup.d.ts +2 -0
- package/types/test/setup/StartupSetup.d.ts.map +1 -0
- package/types/test/setup/TelemetrySetup.d.ts +8 -0
- package/types/test/setup/TelemetrySetup.d.ts.map +1 -0
- package/types/test/setup/VariablesSetup.d.ts +27 -0
- package/types/test/setup/VariablesSetup.d.ts.map +1 -0
- package/types/test/utils/TestUtils.d.ts +15 -0
- package/types/test/utils/TestUtils.d.ts.map +1 -0
- package/types/utils/AsyncUtils.d.ts +14 -0
- package/types/utils/AsyncUtils.d.ts.map +1 -0
- package/types/utils/AutoSetupPolly.d.ts +25 -0
- package/types/utils/AutoSetupPolly.d.ts.map +1 -0
- package/types/utils/Base64Utils.d.ts +41 -0
- package/types/utils/Base64Utils.d.ts.map +1 -0
- package/types/utils/ColorTheme.d.ts +40 -0
- package/types/utils/ColorTheme.d.ts.map +1 -0
- package/types/utils/Console.d.ts +110 -0
- package/types/utils/Console.d.ts.map +1 -0
- package/types/utils/CryptoUtils.d.ts +35 -0
- package/types/utils/CryptoUtils.d.ts.map +1 -0
- package/types/utils/DataProtection.d.ts +24 -0
- package/types/utils/DataProtection.d.ts.map +1 -0
- package/types/utils/ExportImportUtils.d.ts +415 -0
- package/types/utils/ExportImportUtils.d.ts.map +1 -0
- package/types/utils/ForgeRockUtils.d.ts +122 -0
- package/types/utils/ForgeRockUtils.d.ts.map +1 -0
- package/types/utils/FrodoNodeHttpAdapter.d.ts +5 -0
- package/types/utils/FrodoNodeHttpAdapter.d.ts.map +1 -0
- package/types/utils/FrodoUtils.d.ts +15 -0
- package/types/utils/FrodoUtils.d.ts.map +1 -0
- package/types/utils/HelpUtils.d.ts +19 -0
- package/types/utils/HelpUtils.d.ts.map +1 -0
- package/types/utils/JsonUtils.d.ts +105 -0
- package/types/utils/JsonUtils.d.ts.map +1 -0
- package/types/utils/JwtUtils.d.ts +19 -0
- package/types/utils/JwtUtils.d.ts.map +1 -0
- package/types/utils/PkceUtils.d.ts +17 -0
- package/types/utils/PkceUtils.d.ts.map +1 -0
- package/types/utils/PollyUtils.d.ts +65 -0
- package/types/utils/PollyUtils.d.ts.map +1 -0
- package/types/utils/ScriptValidationUtils.d.ts +38 -0
- package/types/utils/ScriptValidationUtils.d.ts.map +1 -0
- package/types/utils/SemverUtils.d.ts +61 -0
- package/types/utils/SemverUtils.d.ts.map +1 -0
- package/types/utils/SetupPollyForFrodoLib.d.ts +7 -0
- package/types/utils/SetupPollyForFrodoLib.d.ts.map +1 -0
- package/types/utils/TerminalBackgroundDetection.d.ts +48 -0
- package/types/utils/TerminalBackgroundDetection.d.ts.map +1 -0
- package/types/utils/TerminalContrast.d.ts +44 -0
- package/types/utils/TerminalContrast.d.ts.map +1 -0
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
import { AuthenticateSuccessResponse } from '../api/AuthenticateApi';
|
|
2
|
+
import { State } from '../shared/State';
|
|
3
|
+
import { BrowserLoginPromptHandler } from './BrowserAuthenticateOps';
|
|
4
|
+
import { CallbackHandler } from './CallbackOps';
|
|
5
|
+
import { JwkRsa } from './JoseOps';
|
|
6
|
+
import { type AccessTokenMetaType } from './OAuth2OidcOps';
|
|
7
|
+
export type Authenticate = {
|
|
8
|
+
/**
|
|
9
|
+
* Get tokens and store them in State
|
|
10
|
+
* @param {boolean} forceLoginAsUser true to force login as user even if a service account or Amster account is available (default: false)
|
|
11
|
+
* @param {boolean} autoRefresh true to automatically refresh tokens before they expire (default: true)
|
|
12
|
+
* @param {string[]} types Array of supported deployment types. The function will throw an error if an unsupported type is detected (default: ['classic', 'cloud', 'forgeops'])
|
|
13
|
+
* @param {CallbackHandler} callbackHandler function allowing the library to collect responses from the user through callbacks
|
|
14
|
+
* @param {boolean} useDeviceFlow only consulted when a loaded connection profile prefers browser login (`preferredCredential: 'browser'`, or the legacy `authMode: 'interactive'` for a profile predating that field) — falls back to the profile's own `preferredDeviceFlow` when not explicitly passed; see `getTokensInteractive()` (default: false)
|
|
15
|
+
* @param {BrowserLoginPromptHandler} promptHandler required only when a loaded connection profile prefers browser login; every other case ignores it
|
|
16
|
+
* @returns {Promise<Tokens>} object containing the tokens
|
|
17
|
+
*/
|
|
18
|
+
getTokens(forceLoginAsUser?: boolean, autoRefresh?: boolean, types?: string[], callbackHandler?: CallbackHandler, useDeviceFlow?: boolean, promptHandler?: BrowserLoginPromptHandler, credentialOverride?: 'user' | 'svcacct' | 'amster' | 'browser'): Promise<Tokens>;
|
|
19
|
+
/**
|
|
20
|
+
* Get tokens via a real interactive browser login (loopback-redirect or
|
|
21
|
+
* device-authorization grant) instead of a CLI-driven password/service-
|
|
22
|
+
* account/Amster login. Alongside `getTokens()`, not a replacement for it.
|
|
23
|
+
* @param {BrowserLoginOptions} options browser-login options
|
|
24
|
+
* @returns {Promise<Tokens>} object containing the tokens
|
|
25
|
+
*/
|
|
26
|
+
getTokensInteractive(options: BrowserLoginOptions): Promise<Tokens>;
|
|
27
|
+
/**
|
|
28
|
+
* Applies an already-obtained, externally-issued OAuth2 access token to
|
|
29
|
+
* `state`, ready for immediate use. Unlike `getTokens()`/
|
|
30
|
+
* `getTokensInteractive()`, this never talks to an authorization endpoint
|
|
31
|
+
* itself — the token was already minted (and, by the caller's own
|
|
32
|
+
* contract, already verified) elsewhere; this only wires it onto `state`
|
|
33
|
+
* using the exact same deployment-type-specific handling a real browser
|
|
34
|
+
* login uses. Intended for hosts that resolve their own caller identity
|
|
35
|
+
* per request (e.g. an MCP server acting as an OAuth2 resource server)
|
|
36
|
+
* rather than performing a login themselves.
|
|
37
|
+
* @param {AccessTokenMetaType} token the already-obtained access token
|
|
38
|
+
* @returns {Promise<Tokens>} object containing the tokens
|
|
39
|
+
*/
|
|
40
|
+
applyAccessToken(token: AccessTokenMetaType): Promise<Tokens>;
|
|
41
|
+
};
|
|
42
|
+
declare const _default: (state: State) => Authenticate;
|
|
43
|
+
export default _default;
|
|
44
|
+
export type UserSessionMetaType = AuthenticateSuccessResponse & {
|
|
45
|
+
expires: number;
|
|
46
|
+
from_cache?: boolean;
|
|
47
|
+
universalId?: string;
|
|
48
|
+
latestAccessTime?: string;
|
|
49
|
+
amCtxId?: string;
|
|
50
|
+
};
|
|
51
|
+
/**
|
|
52
|
+
* Helper function to extract the semantic version string from a version info object
|
|
53
|
+
* @param {Object} versionInfo version info object
|
|
54
|
+
* @returns {String} semantic version
|
|
55
|
+
*/
|
|
56
|
+
export declare function getSemanticVersion(versionInfo: any): string;
|
|
57
|
+
export declare function createPayload(serviceAccountId: string, host: string): {
|
|
58
|
+
iss: string;
|
|
59
|
+
sub: string;
|
|
60
|
+
aud: string;
|
|
61
|
+
exp: number;
|
|
62
|
+
jti: string;
|
|
63
|
+
};
|
|
64
|
+
/**
|
|
65
|
+
* Get fresh access token for service account
|
|
66
|
+
* @param {State} state library state
|
|
67
|
+
* @returns {Promise<AccessTokenResponseType>} response object containg token, scope, type, and expiration in seconds
|
|
68
|
+
*/
|
|
69
|
+
export declare function getFreshSaBearerToken({ saId, saJwk, state, }: {
|
|
70
|
+
saId?: string;
|
|
71
|
+
saJwk?: JwkRsa;
|
|
72
|
+
state: State;
|
|
73
|
+
}): Promise<AccessTokenMetaType>;
|
|
74
|
+
/**
|
|
75
|
+
* Get fresh PingFed access token for service account
|
|
76
|
+
* @param {State} state library state
|
|
77
|
+
* @returns {Promise<AccessTokenResponseType>} response object containg token, scope, type, and expiration in seconds
|
|
78
|
+
*/
|
|
79
|
+
export declare function getFreshPfSaBearerToken({ saId, saJwk, state, }: {
|
|
80
|
+
saId?: string;
|
|
81
|
+
saJwk?: JwkRsa;
|
|
82
|
+
state: State;
|
|
83
|
+
}): Promise<AccessTokenMetaType>;
|
|
84
|
+
/**
|
|
85
|
+
* Get cached or fresh access token for service account
|
|
86
|
+
* @param {State} state library state
|
|
87
|
+
* @returns {Promise<AccessTokenResponseType>} response object containg token, scope, type, and expiration in seconds
|
|
88
|
+
*/
|
|
89
|
+
export declare function getSaBearerToken({ state, }: {
|
|
90
|
+
state: State;
|
|
91
|
+
}): Promise<AccessTokenMetaType>;
|
|
92
|
+
/**
|
|
93
|
+
* Get cached or fresh PingFed access token for service account
|
|
94
|
+
* @param {State} state library state
|
|
95
|
+
* @returns {Promise<AccessTokenResponseType>} response object containg token, scope, type, and expiration in seconds
|
|
96
|
+
*/
|
|
97
|
+
export declare function getPfSaBearerToken({ state, }: {
|
|
98
|
+
state: State;
|
|
99
|
+
}): Promise<AccessTokenMetaType>;
|
|
100
|
+
export type Tokens = {
|
|
101
|
+
bearerToken?: AccessTokenMetaType;
|
|
102
|
+
userSessionToken?: UserSessionMetaType;
|
|
103
|
+
pfBearerToken?: AccessTokenMetaType;
|
|
104
|
+
subject?: string;
|
|
105
|
+
host?: string;
|
|
106
|
+
realm?: string;
|
|
107
|
+
};
|
|
108
|
+
/**
|
|
109
|
+
* Get tokens
|
|
110
|
+
* @param {boolean} forceLoginAsUser true to force login as user even if a service account or Amster account is available (default: false)
|
|
111
|
+
* @param {boolean} autoRefresh true to automatically refresh tokens before they expire (default: true)
|
|
112
|
+
* @param {string[]} types Array of supported deployment types. The function will throw an error if an unsupported type is detected (default: ['classic', 'cloud', 'forgeops'])
|
|
113
|
+
* @param {CallbackHandler} callbackHandler function allowing the library to collect responses from the user through callbacks
|
|
114
|
+
* @param {State} state library state
|
|
115
|
+
* @returns {Promise<Tokens>} object containing the tokens
|
|
116
|
+
*/
|
|
117
|
+
export declare function getTokens({ forceLoginAsUser, credentialOverride, autoRefresh, types, callbackHandler, useDeviceFlow, promptHandler, state, }: {
|
|
118
|
+
forceLoginAsUser?: boolean;
|
|
119
|
+
/**
|
|
120
|
+
* Force this one invocation to use a specific configured credential type,
|
|
121
|
+
* overriding ambient browser-session cache reuse and any saved
|
|
122
|
+
* defaultCredential/forceLoginAsUser preference (the generalized,
|
|
123
|
+
* stateless successor to forceLoginAsUser — see `--credential` on the
|
|
124
|
+
* CLI). 'browser' means "use my cached browser-login session"; if none
|
|
125
|
+
* is valid, this throws rather than falling back to a different
|
|
126
|
+
* credential or popping a fresh interactive login. Every other value
|
|
127
|
+
* means "don't even consider a cached browser session"; if the requested
|
|
128
|
+
* type isn't actually configured, this falls through to the same
|
|
129
|
+
* "Incomplete or no credentials" error any other unconfigured credential
|
|
130
|
+
* hits today.
|
|
131
|
+
*/
|
|
132
|
+
credentialOverride?: 'user' | 'svcacct' | 'amster' | 'browser';
|
|
133
|
+
autoRefresh?: boolean;
|
|
134
|
+
types?: string[];
|
|
135
|
+
callbackHandler?: CallbackHandler;
|
|
136
|
+
/** Only consulted when a loaded connection profile prefers browser login — see below; falls back to the profile's own `preferredDeviceFlow` when not explicitly passed. */
|
|
137
|
+
useDeviceFlow?: boolean;
|
|
138
|
+
/** Required only when a loaded connection profile prefers browser login; every other case ignores it. */
|
|
139
|
+
promptHandler?: BrowserLoginPromptHandler;
|
|
140
|
+
state: State;
|
|
141
|
+
}): Promise<Tokens>;
|
|
142
|
+
export type BrowserLoginOptions = {
|
|
143
|
+
/**
|
|
144
|
+
* Deployment type to authenticate against. Required — unlike `getTokens()`,
|
|
145
|
+
* there is no AM session yet at the start of a browser login for
|
|
146
|
+
* `determineDeploymentType()` to probe with, so it can't be auto-detected.
|
|
147
|
+
*/
|
|
148
|
+
deploymentType?: string;
|
|
149
|
+
/** Use the OAuth2 Device Authorization Grant instead of a loopback redirect. */
|
|
150
|
+
useDeviceFlow?: boolean;
|
|
151
|
+
/** Override the built-in OAuth2 client id for the target deployment type. */
|
|
152
|
+
loginClientId?: string;
|
|
153
|
+
/** Override the default scope requested for the target deployment type. */
|
|
154
|
+
loginScope?: string;
|
|
155
|
+
/**
|
|
156
|
+
* Full, absolute redirect URI to use for browser login, for a client
|
|
157
|
+
* registered with an exact-match redirect URI. Shared with the
|
|
158
|
+
* non-interactive synthetic login flow's own `--login-redirect-uri` (see
|
|
159
|
+
* `state.getAdminClientRedirectUri()`) — when omitted here, that value is
|
|
160
|
+
* used as the fallback, exactly like `loginClientId` already falls back
|
|
161
|
+
* to `state.getAdminClientId()`. When both are absent, falls through to
|
|
162
|
+
* an auto-generated loopback redirect on an OS-assigned ephemeral port
|
|
163
|
+
* (or, for cloud's built-in client specifically, its one confirmed-fixed
|
|
164
|
+
* redirect URI — see `CLOUD_BROWSER_LOGIN_REDIRECT_URI`).
|
|
165
|
+
*/
|
|
166
|
+
loginRedirectUri?: string;
|
|
167
|
+
/** Presents the login step (a URL, or a device code) to the human completing it. */
|
|
168
|
+
promptHandler: BrowserLoginPromptHandler;
|
|
169
|
+
/** How long to wait for the human to complete the login step. */
|
|
170
|
+
timeoutMs?: number;
|
|
171
|
+
};
|
|
172
|
+
/**
|
|
173
|
+
* Checks whether AM's REST API accepts a bearer token directly for this
|
|
174
|
+
* session, performing one cheap authenticated read call. This is ForgeOps
|
|
175
|
+
* browser-login's Tier B fallback (see the plan doc's Phase C): AM's REST
|
|
176
|
+
* API is not a resource server by default, so whether a plain bearer token
|
|
177
|
+
* works at all is genuinely undecided until probed — the *recommended* path
|
|
178
|
+
* (a session-capture script on the OAuth2 client) never needs this at all,
|
|
179
|
+
* since it gets a real session cookie instead. Cached on `state` for the
|
|
180
|
+
* life of the session so the probe only ever runs once.
|
|
181
|
+
* @param {State} state library state
|
|
182
|
+
* @returns {Promise<boolean>} whether AM accepted the bearer token
|
|
183
|
+
*/
|
|
184
|
+
export declare function probeAmBearerTokenAcceptance({ state, }: {
|
|
185
|
+
state: State;
|
|
186
|
+
}): Promise<boolean>;
|
|
187
|
+
/**
|
|
188
|
+
* Get tokens via a real interactive browser login.
|
|
189
|
+
* @param {BrowserLoginOptions} options browser-login options
|
|
190
|
+
* @param {State} state library state
|
|
191
|
+
* @returns {Promise<Tokens>} object containing the tokens
|
|
192
|
+
*/
|
|
193
|
+
export declare function getTokensInteractive({ deploymentType, useDeviceFlow, loginClientId, loginScope, loginRedirectUri, promptHandler, timeoutMs, state, }: BrowserLoginOptions & {
|
|
194
|
+
state: State;
|
|
195
|
+
}): Promise<Tokens>;
|
|
196
|
+
//# sourceMappingURL=AuthenticateOps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|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B,EAChB,aAAa,EACb,SAAS,EACT,KAAK,GACN,EAAE,mBAAmB,GAAG;IAAE,KAAK,EAAE,KAAK,CAAA;CAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CA2V1D"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { type AuthenticationSettingsSkeleton } from '../api/AuthenticationSettingsApi';
|
|
2
|
+
import { State } from '../shared/State';
|
|
3
|
+
import { type ExportMetaData } from './OpsTypes';
|
|
4
|
+
export type AuthenticationSettings = {
|
|
5
|
+
/**
|
|
6
|
+
* Read authentication settings
|
|
7
|
+
* @param {boolean} globalConfig true if global authentication settings is the target of the operation, false otherwise. Default: false.
|
|
8
|
+
* @returns {Promise<AuthenticationSettingsSkeleton>} a promise that resolves an authentication settings object
|
|
9
|
+
*/
|
|
10
|
+
readAuthenticationSettings(globalConfig: boolean): Promise<AuthenticationSettingsSkeleton>;
|
|
11
|
+
/**
|
|
12
|
+
* Update authentication settings
|
|
13
|
+
* @param {AuthenticationSettingsSkeleton} settings authentication settings data
|
|
14
|
+
* @param {boolean} globalConfig true if global authentication settings are the target of the operation, false otherwise. Default: false.
|
|
15
|
+
* @returns {Promise<AuthenticationSettingsSkeleton>} a promise that resolves an authentication settings object
|
|
16
|
+
*/
|
|
17
|
+
updateAuthenticationSettings(settings: AuthenticationSettingsSkeleton, globalConfig: boolean): Promise<AuthenticationSettingsSkeleton>;
|
|
18
|
+
/**
|
|
19
|
+
* Export authentication settings
|
|
20
|
+
* @param {boolean} globalConfig true if global authentication settings is the target of the operation, false otherwise. Default: false.
|
|
21
|
+
* @returns {Promise<AuthenticationSettingsExportInterface>} a promise that resolves to an AuthenticationSettingsExportInterface object
|
|
22
|
+
*/
|
|
23
|
+
exportAuthenticationSettings(globalConfig: boolean): Promise<AuthenticationSettingsExportInterface>;
|
|
24
|
+
/**
|
|
25
|
+
* Import authentication settings
|
|
26
|
+
* @param {AuthenticationSettingsExportInterface} importData import data
|
|
27
|
+
* @param {boolean} globalConfig true if global authentication settings are the target of the operation, false otherwise. Default: false.
|
|
28
|
+
*/
|
|
29
|
+
importAuthenticationSettings(importData: AuthenticationSettingsExportInterface, globalConfig: boolean): Promise<AuthenticationSettingsSkeleton>;
|
|
30
|
+
};
|
|
31
|
+
declare const _default: (state: State) => AuthenticationSettings;
|
|
32
|
+
export default _default;
|
|
33
|
+
export interface AuthenticationSettingsExportInterface {
|
|
34
|
+
meta?: ExportMetaData;
|
|
35
|
+
authentication: AuthenticationSettingsSkeleton;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Create an empty authentication settings export template
|
|
39
|
+
* @returns {AuthenticationSettingsExportInterface} an empty authentication settings export template
|
|
40
|
+
*/
|
|
41
|
+
export declare function createAuthenticationSettingsExportTemplate({ state, }: {
|
|
42
|
+
state: State;
|
|
43
|
+
}): AuthenticationSettingsExportInterface;
|
|
44
|
+
/**
|
|
45
|
+
* Read authentication settings
|
|
46
|
+
* @param {boolean} globalConfig true if global agent is the target of the operation, false otherwise. Default: false.
|
|
47
|
+
* @returns {Promise} a promise that resolves to an object containing an array of authentication settingss
|
|
48
|
+
*/
|
|
49
|
+
export declare function readAuthenticationSettings({ state, globalConfig, }: {
|
|
50
|
+
state: State;
|
|
51
|
+
globalConfig: boolean;
|
|
52
|
+
}): Promise<AuthenticationSettingsSkeleton>;
|
|
53
|
+
export declare function updateAuthenticationSettings({ settings, globalConfig, state, }: {
|
|
54
|
+
settings: AuthenticationSettingsSkeleton;
|
|
55
|
+
globalConfig: boolean;
|
|
56
|
+
state: State;
|
|
57
|
+
}): Promise<AuthenticationSettingsSkeleton>;
|
|
58
|
+
/**
|
|
59
|
+
* Export authentication settings
|
|
60
|
+
* @param {boolean} globalConfig true if global agent is the target of the operation, false otherwise. Default: false.
|
|
61
|
+
* @returns {Promise<AuthenticationSettingsExportInterface>} a promise that resolves to a AuthenticationSettingsExportInterface object
|
|
62
|
+
*/
|
|
63
|
+
export declare function exportAuthenticationSettings({ state, globalConfig, }: {
|
|
64
|
+
state: State;
|
|
65
|
+
globalConfig: boolean;
|
|
66
|
+
}): Promise<AuthenticationSettingsExportInterface>;
|
|
67
|
+
/**
|
|
68
|
+
* Import authentication settings
|
|
69
|
+
* @param {AuthenticationSettingsExportInterface} importData import data
|
|
70
|
+
* @param {boolean} globalConfig true if global authentication settings are the target of the operation, false otherwise. Default: false.
|
|
71
|
+
* @returns {Promise<AuthenticationSettingsSkeleton>} a promise resolving to a authentication settings object
|
|
72
|
+
*/
|
|
73
|
+
export declare function importAuthenticationSettings({ importData, globalConfig, state, }: {
|
|
74
|
+
importData: AuthenticationSettingsExportInterface;
|
|
75
|
+
globalConfig: boolean;
|
|
76
|
+
state: State;
|
|
77
|
+
}): Promise<AuthenticationSettingsSkeleton>;
|
|
78
|
+
//# sourceMappingURL=AuthenticationSettingsOps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AuthenticationSettingsOps.d.ts","sourceRoot":"","sources":["../../src/ops/AuthenticationSettingsOps.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,8BAA8B,EACpC,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAKxC,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,YAAY,CAAC;AAEjD,MAAM,MAAM,sBAAsB,GAAG;IACnC;;;;OAIG;IACH,0BAA0B,CACxB,YAAY,EAAE,OAAO,GACpB,OAAO,CAAC,8BAA8B,CAAC,CAAC;IAC3C;;;;;OAKG;IACH,4BAA4B,CAC1B,QAAQ,EAAE,8BAA8B,EACxC,YAAY,EAAE,OAAO,GACpB,OAAO,CAAC,8BAA8B,CAAC,CAAC;IAC3C;;;;OAIG;IACH,4BAA4B,CAC1B,YAAY,EAAE,OAAO,GACpB,OAAO,CAAC,qCAAqC,CAAC,CAAC;IAClD;;;;OAIG;IACH,4BAA4B,CAC1B,UAAU,EAAE,qCAAqC,EACjD,YAAY,EAAE,OAAO,GACpB,OAAO,CAAC,8BAA8B,CAAC,CAAC;CAC5C,CAAC;yBAEc,OAAO,KAAK,KAAG,sBAAsB;AAArD,wBA2BE;AAEF,MAAM,WAAW,qCAAqC;IACpD,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,cAAc,EAAE,8BAA8B,CAAC;CAChD;AAED;;;GAGG;AACH,wBAAgB,0CAA0C,CAAC,EACzD,KAAK,GACN,EAAE;IACD,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,qCAAqC,CAKxC;AAED;;;;GAIG;AACH,wBAAsB,0BAA0B,CAAC,EAC/C,KAAK,EACL,YAAoB,GACrB,EAAE;IACD,KAAK,EAAE,KAAK,CAAC;IACb,YAAY,EAAE,OAAO,CAAC;CACvB,GAAG,OAAO,CAAC,8BAA8B,CAAC,CAkB1C;AAED,wBAAsB,4BAA4B,CAAC,EACjD,QAAQ,EACR,YAAoB,EACpB,KAAK,GACN,EAAE;IACD,QAAQ,EAAE,8BAA8B,CAAC;IACzC,YAAY,EAAE,OAAO,CAAC;IACtB,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,OAAO,CAAC,8BAA8B,CAAC,CAsB1C;AAED;;;;GAIG;AACH,wBAAsB,4BAA4B,CAAC,EACjD,KAAK,EACL,YAAoB,GACrB,EAAE;IACD,KAAK,EAAE,KAAK,CAAC;IACb,YAAY,EAAE,OAAO,CAAC;CACvB,GAAG,OAAO,CAAC,qCAAqC,CAAC,CAuBjD;AAED;;;;;GAKG;AACH,wBAAsB,4BAA4B,CAAC,EACjD,UAAU,EACV,YAAY,EACZ,KAAK,GACN,EAAE;IACD,UAAU,EAAE,qCAAqC,CAAC;IAClD,YAAY,EAAE,OAAO,CAAC;IACtB,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,OAAO,CAAC,8BAA8B,CAAC,CAe1C"}
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
import { State } from '../shared/State';
|
|
2
|
+
import { type AccessTokenMetaType } from './OAuth2OidcOps';
|
|
3
|
+
/**
|
|
4
|
+
* Matches `aic-mcp-server`'s interactive-flow timeout: long enough for a
|
|
5
|
+
* human to complete MFA/passkey/federation steps, short enough not to leave
|
|
6
|
+
* an abandoned listener or polling loop running indefinitely.
|
|
7
|
+
*/
|
|
8
|
+
export declare const DEFAULT_INTERACTIVE_LOGIN_TIMEOUT_MS: number;
|
|
9
|
+
/**
|
|
10
|
+
* Info handed to the caller-supplied {@link BrowserLoginPromptHandler} so it
|
|
11
|
+
* can present the login step however is appropriate for its environment.
|
|
12
|
+
*/
|
|
13
|
+
export type BrowserLoginPrompt = {
|
|
14
|
+
/** Set for the loopback-redirect (authorization code + PKCE) flow. */
|
|
15
|
+
authorizeUrl?: string;
|
|
16
|
+
/** Set for the device-authorization flow. */
|
|
17
|
+
userCode?: string;
|
|
18
|
+
/** Set for the device-authorization flow. */
|
|
19
|
+
verificationUri?: string;
|
|
20
|
+
/** When to stop waiting for the user to complete this step. */
|
|
21
|
+
expiresAt: Date;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* Presents an interactive login step to a human. frodo-lib never opens a
|
|
25
|
+
* browser or prints to a terminal itself — the caller (frodo-cli, an MCP
|
|
26
|
+
* server host, a test) decides how to surface `prompt` and is responsible
|
|
27
|
+
* for getting the user to `prompt.authorizeUrl` or `prompt.verificationUri`.
|
|
28
|
+
*/
|
|
29
|
+
export type BrowserLoginPromptHandler = (prompt: BrowserLoginPrompt) => void | Promise<void>;
|
|
30
|
+
export type LoopbackCallbackResult = {
|
|
31
|
+
code?: string;
|
|
32
|
+
state?: string;
|
|
33
|
+
error?: string;
|
|
34
|
+
errorDescription?: string;
|
|
35
|
+
};
|
|
36
|
+
export type LoopbackResultPage = {
|
|
37
|
+
success?: string;
|
|
38
|
+
failure?: string;
|
|
39
|
+
};
|
|
40
|
+
export type LoopbackRedirectListener = {
|
|
41
|
+
/** The exact redirect_uri to use in the authorize request. */
|
|
42
|
+
redirectUri: string;
|
|
43
|
+
/** The loopback port the listener bound to. */
|
|
44
|
+
port: number;
|
|
45
|
+
/** Await the single inbound redirect, or reject on timeout. */
|
|
46
|
+
waitForCallback(timeoutMs?: number): Promise<LoopbackCallbackResult>;
|
|
47
|
+
/** Stop listening. Safe to call more than once. */
|
|
48
|
+
close(): void;
|
|
49
|
+
};
|
|
50
|
+
/**
|
|
51
|
+
* Generate a fresh CSRF `state` nonce for an OAuth2 authorization request.
|
|
52
|
+
*/
|
|
53
|
+
export declare function generateStateNonce(): string;
|
|
54
|
+
/**
|
|
55
|
+
* Start a short-lived, loopback-only (`127.0.0.1`) HTTP listener that
|
|
56
|
+
* catches exactly one OAuth2 authorization_code redirect and validates the
|
|
57
|
+
* returned `state` parameter against `expectedState` with a constant-time
|
|
58
|
+
* comparison before resolving.
|
|
59
|
+
*
|
|
60
|
+
* @remarks
|
|
61
|
+
* Mirrors the loopback-redirect pattern `aic-mcp-server` and `gcloud auth
|
|
62
|
+
* login` both use: a real browser is directed here by the authorization
|
|
63
|
+
* server, not by this process, so the listener only ever needs to accept
|
|
64
|
+
* one inbound request before shutting itself down. Binds an OS-assigned
|
|
65
|
+
* ephemeral port by default; pass `preferredPort` for an OAuth2 client
|
|
66
|
+
* whose redirect URI is registered against one fixed port.
|
|
67
|
+
*/
|
|
68
|
+
export declare function startLoopbackRedirectListener({ preferredPort, redirectHost, callbackPath, expectedState, resultPage, state, }: {
|
|
69
|
+
preferredPort?: number;
|
|
70
|
+
/**
|
|
71
|
+
* Hostname to advertise in `redirectUri` (the listener always binds the
|
|
72
|
+
* loopback interface regardless of this value). Some OAuth2 clients'
|
|
73
|
+
* registered redirect URIs require the literal string `localhost` rather
|
|
74
|
+
* than `127.0.0.1` — pass `'localhost'` to match one of those exactly.
|
|
75
|
+
*/
|
|
76
|
+
redirectHost?: string;
|
|
77
|
+
callbackPath?: string;
|
|
78
|
+
expectedState: string;
|
|
79
|
+
resultPage?: LoopbackResultPage;
|
|
80
|
+
state?: State;
|
|
81
|
+
}): Promise<LoopbackRedirectListener>;
|
|
82
|
+
/**
|
|
83
|
+
* Drive a full interactive OAuth2 authorization_code + PKCE login: open a
|
|
84
|
+
* loopback listener, build the `/oauth2/authorize` URL a real browser should
|
|
85
|
+
* be sent to, hand it to `promptHandler`, wait for the redirect, and
|
|
86
|
+
* exchange the returned code for a token.
|
|
87
|
+
*
|
|
88
|
+
* @remarks
|
|
89
|
+
* Deployment-agnostic — the caller supplies `clientId`/`scope`/redirect
|
|
90
|
+
* shape, which differ per deployment type and per candidate OAuth2 client
|
|
91
|
+
* (see `AuthenticateOps.ts`'s deployment-specific `getTokensInteractive`
|
|
92
|
+
* branches). Unlike `AuthenticateOps.ts`'s existing synthetic PKCE flow
|
|
93
|
+
* (`getAuthCode`/`getFreshUserBearerToken`), this never POSTs to
|
|
94
|
+
* `/oauth2/authorize` itself — the authorize step is driven by the human
|
|
95
|
+
* in a real browser, and this process only ever sees the resulting
|
|
96
|
+
* redirect.
|
|
97
|
+
*/
|
|
98
|
+
export declare function runInteractiveAuthorizationCodeFlow({ clientId, scope, redirectHost, callbackPath, preferredPort, redirectUri: redirectUriOverride, promptHandler, timeoutMs, state, }: {
|
|
99
|
+
clientId: string;
|
|
100
|
+
scope: string;
|
|
101
|
+
redirectHost?: string;
|
|
102
|
+
callbackPath?: string;
|
|
103
|
+
preferredPort?: number;
|
|
104
|
+
/**
|
|
105
|
+
* A complete, literal redirect URI to use verbatim instead of
|
|
106
|
+
* constructing one from `redirectHost`/`callbackPath`/`preferredPort` —
|
|
107
|
+
* for an OAuth2 client registered with an exact-match redirect URI (no
|
|
108
|
+
* wildcard/pattern support), where even a functionally-equivalent
|
|
109
|
+
* reconstruction could fail validation (a URL parser normalizes a bare
|
|
110
|
+
* `http://localhost:3000` into `http://localhost:3000/`, for instance,
|
|
111
|
+
* which is a different string than what a client might be registered
|
|
112
|
+
* with). When given, its port is used for the local listener (still
|
|
113
|
+
* bound, as always, to `127.0.0.1` regardless of the advertised
|
|
114
|
+
* hostname) and its path for the listener's inbound request matching;
|
|
115
|
+
* `redirectHost`/`callbackPath`/`preferredPort` are ignored. The literal
|
|
116
|
+
* string itself — never a reconstruction — is what's sent as
|
|
117
|
+
* `redirect_uri` to both the authorize call and the token exchange.
|
|
118
|
+
*/
|
|
119
|
+
redirectUri?: string;
|
|
120
|
+
promptHandler: BrowserLoginPromptHandler;
|
|
121
|
+
timeoutMs?: number;
|
|
122
|
+
state: State;
|
|
123
|
+
}): Promise<AccessTokenMetaType>;
|
|
124
|
+
/**
|
|
125
|
+
* Exchange a subject token for a new, narrower-scoped token via RFC 8693
|
|
126
|
+
* Token Exchange (`grant_type=urn:ietf:params:oauth:grant-type:token-exchange`).
|
|
127
|
+
*
|
|
128
|
+
* @remarks
|
|
129
|
+
* Confirmed against a real AIC tenant as the mechanism that unlocks AM
|
|
130
|
+
* REST API access for an interactively-obtained token: the primary
|
|
131
|
+
* token from `runInteractiveAuthorizationCodeFlow` is rejected by AM
|
|
132
|
+
* directly, but a token exchanged through the client named in the
|
|
133
|
+
* primary token's own `may_act` claim is accepted. When `exchangeClientId`
|
|
134
|
+
* is not supplied, it's read from `subjectToken`'s decoded `may_act.client_id`
|
|
135
|
+
* claim — do not hardcode a single exchange client, since different
|
|
136
|
+
* deployments (or a future Ping-side change) may name a different one.
|
|
137
|
+
* The resulting token is typically extremely short-lived (tens of seconds)
|
|
138
|
+
* and must never be cached — mint a fresh one immediately before each
|
|
139
|
+
* AM-domain call that needs it.
|
|
140
|
+
*/
|
|
141
|
+
export declare function exchangeTokenForScope({ subjectToken, scope, exchangeClientId, state, }: {
|
|
142
|
+
subjectToken: string;
|
|
143
|
+
scope: string;
|
|
144
|
+
exchangeClientId?: string;
|
|
145
|
+
state: State;
|
|
146
|
+
}): Promise<AccessTokenMetaType>;
|
|
147
|
+
/**
|
|
148
|
+
* Refreshes a browser-login primary token via a plain `grant_type=refresh_token`
|
|
149
|
+
* exchange — the on-demand counterpart to a fresh interactive login, used
|
|
150
|
+
* only when the primary token's response actually included a refresh token
|
|
151
|
+
* (confirmed empirically: cloud's `AICMCPClient`/`AICMCPExchangeClient` never
|
|
152
|
+
* return one today, so this path exists for the sub-flows/deployment types
|
|
153
|
+
* that do return one, not as a universal assumption). Public-client exchange
|
|
154
|
+
* (no client secret), matching how the primary interactive login itself
|
|
155
|
+
* authenticates. Never call this for the short-lived RFC 8693-exchanged
|
|
156
|
+
* AM-domain token — that one is mint-and-discard by design and never has a
|
|
157
|
+
* refresh token to begin with.
|
|
158
|
+
*/
|
|
159
|
+
export declare function refreshBrowserBearerToken({ state, }: {
|
|
160
|
+
state: State;
|
|
161
|
+
}): Promise<AccessTokenMetaType>;
|
|
162
|
+
/**
|
|
163
|
+
* Reads the `may_act.client_id` claim off a decoded access token, if
|
|
164
|
+
* present. Exported so callers can decide *whether* a token needs an RFC
|
|
165
|
+
* 8693 exchange before attempting one — see `applyCloudInteractiveToken`'s
|
|
166
|
+
* BYOT (bring-your-own-token) fallback in `AuthenticateOps.ts`.
|
|
167
|
+
*/
|
|
168
|
+
export declare function readMayActClientId(jwt: string): string | undefined;
|
|
169
|
+
/**
|
|
170
|
+
* Drive an OAuth2 Device Authorization Grant (RFC 8628), PKCE-protected the
|
|
171
|
+
* same way `aic-mcp-server` layers PKCE on top of its own device flow: the
|
|
172
|
+
* verifier/challenge are generated once, the challenge is sent on the
|
|
173
|
+
* device-code request, and the verifier is redeemed on the token poll.
|
|
174
|
+
*
|
|
175
|
+
* @remarks
|
|
176
|
+
* Deployment-agnostic — the caller supplies `clientId`/`scope`, which
|
|
177
|
+
* differ per deployment type (see `AuthenticateOps.ts`'s deployment-specific
|
|
178
|
+
* `getTokensInteractive` branches). `state.getHost()` supplies the AM base
|
|
179
|
+
* URL for both the device-code and token endpoints.
|
|
180
|
+
*/
|
|
181
|
+
export declare function startDeviceAuthorizationFlow({ clientId, scope, promptHandler, timeoutMs, state, }: {
|
|
182
|
+
clientId: string;
|
|
183
|
+
scope: string;
|
|
184
|
+
promptHandler: BrowserLoginPromptHandler;
|
|
185
|
+
timeoutMs?: number;
|
|
186
|
+
state: State;
|
|
187
|
+
}): Promise<AccessTokenMetaType>;
|
|
188
|
+
//# sourceMappingURL=BrowserAuthenticateOps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrowserAuthenticateOps.d.ts","sourceRoot":"","sources":["../../src/ops/BrowserAuthenticateOps.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAKxC,OAAO,EAGL,KAAK,mBAAmB,EACzB,MAAM,iBAAiB,CAAC;AAEzB;;;;GAIG;AACH,eAAO,MAAM,oCAAoC,QAAgB,CAAC;AAIlE;;;GAGG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAC/B,sEAAsE;IACtE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,6CAA6C;IAC7C,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,6CAA6C;IAC7C,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,+DAA+D;IAC/D,SAAS,EAAE,IAAI,CAAC;CACjB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,yBAAyB,GAAG,CACtC,MAAM,EAAE,kBAAkB,KACvB,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AAE1B,MAAM,MAAM,sBAAsB,GAAG;IACnC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,wBAAwB,GAAG;IACrC,8DAA8D;IAC9D,WAAW,EAAE,MAAM,CAAC;IACpB,+CAA+C;IAC/C,IAAI,EAAE,MAAM,C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AAC,EAC1C,YAAY,EACZ,KAAK,EACL,gBAAgB,EAChB,KAAK,GACN,EAAE;IACD,YAAY,EAAE,MAAM,CAAC;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAe/B;AAED;;;;;;;;;;;GAWG;AACH,wBAAsB,yBAAyB,CAAC,EAC9C,KAAK,GACN,EAAE;IACD,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAgB/B;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAQlE;AAkHD;;;;;;;;;;;GAWG;AACH,wBAAsB,4BAA4B,CAAC,EACjD,QAAQ,EACR,KAAK,EACL,aAAa,EACb,SAAgD,EAChD,KAAK,GACN,EAAE;IACD,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,EAAE,yBAAyB,CAAC;IACzC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAkD/B"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { AuthenticateStep } from '../api/AuthenticateApi';
|
|
2
|
+
export type CallbackType = 'NameCallback' | 'PasswordCallback' | 'TextInputCallback' | 'HiddenValueCallback' | 'SelectIdPCallback';
|
|
3
|
+
export type CallbackKeyValuePair = {
|
|
4
|
+
name: string;
|
|
5
|
+
value: any;
|
|
6
|
+
};
|
|
7
|
+
export type Callback = {
|
|
8
|
+
type: CallbackType;
|
|
9
|
+
output: CallbackKeyValuePair[];
|
|
10
|
+
input: CallbackKeyValuePair[];
|
|
11
|
+
};
|
|
12
|
+
export type CallbackHandler = (callback: Callback) => Callback;
|
|
13
|
+
/**
|
|
14
|
+
* Fill callbacks from a map
|
|
15
|
+
* @param {AuthenticateStep} step authenticate step json response from a call to /authenticate
|
|
16
|
+
* @param {{ [k: string]: string | number | boolean | string[] }} map name/value map
|
|
17
|
+
* @returns filled authenticate step body so it can be used as input to another call to /authenticate
|
|
18
|
+
*/
|
|
19
|
+
export declare function fillCallbacks({ step, map, }: {
|
|
20
|
+
step: AuthenticateStep;
|
|
21
|
+
map: {
|
|
22
|
+
[k: string]: string | number | boolean | string[];
|
|
23
|
+
};
|
|
24
|
+
}): AuthenticateStep;
|
|
25
|
+
export declare function getCallbackValue(name: string, pairs: CallbackKeyValuePair[]): any | undefined;
|
|
26
|
+
export declare function setCallbackValue(name: string, value: any, pairs: CallbackKeyValuePair[]): boolean;
|
|
27
|
+
//# sourceMappingURL=CallbackOps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CallbackOps.d.ts","sourceRoot":"","sources":["../../src/ops/CallbackOps.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAG1D,MAAM,MAAM,YAAY,GACpB,cAAc,GACd,kBAAkB,GAClB,mBAAmB,GACnB,qBAAqB,GACrB,mBAAmB,CAAC;AACxB,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,GAAG,CAAC;CACZ,CAAC;AACF,MAAM,MAAM,QAAQ,GAAG;IACrB,IAAI,EAAE,YAAY,CAAC;IACnB,MAAM,EAAE,oBAAoB,EAAE,CAAC;IAC/B,KAAK,EAAE,oBAAoB,EAAE,CAAC;CAC/B,CAAC;AACF,MAAM,MAAM,eAAe,GAAG,CAAC,QAAQ,EAAE,QAAQ,KAAK,QAAQ,CAAC;AAE/D;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,EAC5B,IAAI,EACJ,GAAG,GACJ,EAAE;IACD,IAAI,EAAE,gBAAgB,CAAC;IACvB,GAAG,EAAE;QAAE,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,EAAE,CAAA;KAAE,CAAC;CAC5D,GAAG,gBAAgB,CAQnB;AAED,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,oBAAoB,EAAE,GAC5B,GAAG,GAAG,SAAS,CAGjB;AAED,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,GAAG,EACV,KAAK,EAAE,oBAAoB,EAAE,GAC5B,OAAO,CAKT"}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Determines the caller-privilege tier for the currently-authenticated
|
|
3
|
+
* session, so the MCP runtime's `assertTrustTierAllowed` (see
|
|
4
|
+
* `mcp/ToolRuntime.ts`) can decide whether a capability marked
|
|
5
|
+
* `trustTier: 'full-trust'` (the default — see `mcp/CapabilityTypes.ts`'s
|
|
6
|
+
* `McpCapabilityTrustTier`) is safe to expose to this caller.
|
|
7
|
+
*
|
|
8
|
+
* @remarks
|
|
9
|
+
* `admin-account`/`service-account`/`state-config` sessions are already
|
|
10
|
+
* full-trust identities by construction — there is no privilege to probe,
|
|
11
|
+
* so this short-circuits for every auth mode except a real interactive
|
|
12
|
+
* (browser) login, which is the only mode that can plausibly represent a
|
|
13
|
+
* non-admin, delegated end user.
|
|
14
|
+
*
|
|
15
|
+
* For a browser-login session, `state.setCallerTrustTierResolver(fn)` (if
|
|
16
|
+
* set) always wins — a customer's own privilege model, verified against
|
|
17
|
+
* their own tenant, is preferred over guessing. Failing that, the built-in
|
|
18
|
+
* heuristic below (`resolveBuiltInCallerTrustTier`) checks the logged-in
|
|
19
|
+
* identity's own AM-native privilege markers via `frodo.user.readUser()` —
|
|
20
|
+
* confirmed live, this session, to be self-readable (unlike the equivalent
|
|
21
|
+
* IDM `teammember` managed-object record, which 403s even for a self-read)
|
|
22
|
+
* for both ForgeOps/classic (`roles` containing `'ui-global-admin'`) and
|
|
23
|
+
* cloud (`isMemberOf` containing a known admin-tier group). Any lookup
|
|
24
|
+
* failure, or no username at all (e.g. a fully custom instance resolver
|
|
25
|
+
* that never populated `state.getUsername()`), fails toward the more
|
|
26
|
+
* restrictive `'delegated'` tier rather than guessing.
|
|
27
|
+
*/
|
|
28
|
+
import { State } from '../shared/State';
|
|
29
|
+
/**
|
|
30
|
+
* The subset of `frodo.user.readUser()`'s result relevant to privilege
|
|
31
|
+
* classification and display — shared by `resolveBuiltInCallerTrustTier()`
|
|
32
|
+
* below and by the login-time role/group capture in `AuthenticateOps.ts`
|
|
33
|
+
* (`session describe`'s "besides the scopes" display), so both consult the
|
|
34
|
+
* exact same field names/shapes.
|
|
35
|
+
*/
|
|
36
|
+
export type CallerPrivilegeGroups = {
|
|
37
|
+
roles?: string[];
|
|
38
|
+
isMemberOf?: string[];
|
|
39
|
+
};
|
|
40
|
+
/**
|
|
41
|
+
* Looks up the given identity's own AM-native privilege markers
|
|
42
|
+
* (`frodo.user.readUser()`, root-realm scoped regardless of the caller's
|
|
43
|
+
* currently-active realm — see `resolveBuiltInCallerTrustTier()`'s own
|
|
44
|
+
* remarks). Never throws: returns `undefined` for a missing username or any
|
|
45
|
+
* lookup failure, so a caller can treat "no privilege info available" and
|
|
46
|
+
* "genuinely no privilege" identically without special-casing errors.
|
|
47
|
+
*/
|
|
48
|
+
export declare function lookupCallerPrivilegeGroups({ username, state, }: {
|
|
49
|
+
username: string | undefined;
|
|
50
|
+
state: State;
|
|
51
|
+
}): Promise<CallerPrivilegeGroups | undefined>;
|
|
52
|
+
/**
|
|
53
|
+
* A customer- (or future built-in-) supplied privilege resolver, plugged in
|
|
54
|
+
* via `state.setCallerTrustTierResolver()`. Only ever consulted for a real
|
|
55
|
+
* interactive (browser) login session — every other auth mode already
|
|
56
|
+
* short-circuits to `'full-trust'` before this would be called.
|
|
57
|
+
*/
|
|
58
|
+
export type CallerTrustTierResolver = (args: {
|
|
59
|
+
state: State;
|
|
60
|
+
}) => Promise<'full-trust' | 'delegated'>;
|
|
61
|
+
/**
|
|
62
|
+
* Cloud (AIC) `isMemberOf` group names confirmed live, this session, to
|
|
63
|
+
* carry full tenant privilege (item 21's privilege-hierarchy tiers 1–2):
|
|
64
|
+
* `super-admins` ("manages everything... with zero restrictions") and
|
|
65
|
+
* `tenant-admins` ("everything super admin can do except manage other
|
|
66
|
+
* admin users and manage admin federation"). Named individually (not just
|
|
67
|
+
* a combined list) since `ops/PrivilegeEscalationOps.ts` needs to rank
|
|
68
|
+
* them relative to each other, not just know both are full-trust.
|
|
69
|
+
* Together, deliberately an allow-list, not a deny-list — any group not
|
|
70
|
+
* named here (including the two tracked immediately below) fails toward
|
|
71
|
+
* `'delegated'` by default, so a future, as-yet-unseen AIC admin-group
|
|
72
|
+
* name can't accidentally grant full trust.
|
|
73
|
+
*/
|
|
74
|
+
export declare const CLOUD_SUPER_ADMIN_GROUP = "super-admins";
|
|
75
|
+
export declare const CLOUD_TENANT_ADMIN_GROUP = "tenant-admins";
|
|
76
|
+
/**
|
|
77
|
+
* Cloud groups confirmed live this session to exist and be genuinely
|
|
78
|
+
* narrower than the full-trust tier above (item 21's tiers 6–7) — tracked
|
|
79
|
+
* explicitly, by name (not just left as an implicit "everything else"), so
|
|
80
|
+
* a maintainer reading this file can see they were deliberately considered
|
|
81
|
+
* and excluded, not simply never checked. Not consulted by
|
|
82
|
+
* `hasCloudFullTrustGroup()` — inclusion here has no effect on the actual
|
|
83
|
+
* `'delegated'` outcome, which already applies to any group not named in
|
|
84
|
+
* `CLOUD_FULL_TRUST_GROUPS` above; also reused by
|
|
85
|
+
* `ops/PrivilegeEscalationOps.ts` to classify these two tiers for the
|
|
86
|
+
* escalation ladder. `tenant-auditor`: read-only. `brand-admin`: the
|
|
87
|
+
* narrowest tier, hosted pages/themes only. Both are singular, unlike the
|
|
88
|
+
* two full-trust groups above — AIC's own group-naming isn't uniformly
|
|
89
|
+
* pluralized, confirmed by directly inspecting a live identity holding
|
|
90
|
+
* both simultaneously (`isMemberOf` is additive, not a single value).
|
|
91
|
+
*/
|
|
92
|
+
export declare const CLOUD_TENANT_AUDITOR_GROUP = "tenant-auditor";
|
|
93
|
+
export declare const CLOUD_THEME_ADMIN_GROUP = "brand-admin";
|
|
94
|
+
/**
|
|
95
|
+
* Resolves and caches (for the life of the session, on `state`) the
|
|
96
|
+
* caller-privilege tier for the currently-authenticated session.
|
|
97
|
+
* @param {State} state library state
|
|
98
|
+
* @returns {Promise<'full-trust' | 'delegated'>} the resolved tier
|
|
99
|
+
*/
|
|
100
|
+
export declare function determineCallerTrustTier({ state, }: {
|
|
101
|
+
state: State;
|
|
102
|
+
}): Promise<'full-trust' | 'delegated'>;
|
|
103
|
+
//# sourceMappingURL=CallerTrustTierOps.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CallerTrustTierOps.d.ts","sourceRoot":"","sources":["../../src/ops/CallerTrustTierOps.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAGxC;;;;;;GAMG;AACH,MAAM,MAAM,qBAAqB,GAAG;IAClC,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;CACvB,CAAC;AAEF;;;;;;;GAOG;AACH,wBAAsB,2BAA2B,CAAC,EAChD,QAAQ,EACR,KAAK,GACN,EAAE;IACD,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;IAC7B,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,OAAO,CAAC,qBAAqB,GAAG,SAAS,CAAC,CAc7C;AAED;;;;;GAKG;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,IAAI,EAAE;IAC3C,KAAK,EAAE,KAAK,CAAC;CACd,KAAK,OAAO,CAAC,YAAY,GAAG,WAAW,CAAC,CAAC;AAe1C;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,uBAAuB,iBAAiB,CAAC;AACtD,eAAO,MAAM,wBAAwB,kBAAkB,CAAC;AAMxD;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,0BAA0B,mBAAmB,CAAC;AAC3D,eAAO,MAAM,uBAAuB,gBAAgB,CAAC;AAmDrD;;;;;GAKG;AACH,wBAAsB,wBAAwB,CAAC,EAC7C,KAAK,GACN,EAAE;IACD,KAAK,EAAE,KAAK,CAAC;CACd,GAAG,OAAO,CAAC,YAAY,GAAG,WAAW,CAAC,CAqBtC"}
|