@ionite/ecv 0.0.24-beta.20260928.18 → 0.0.24-beta.20260930.19

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.d.ts CHANGED
@@ -1,6 +1,3 @@
1
- import { AppUnderTest, StartAppOptions, WaitForReadyOptions } from "@ionite/devtools";
2
- import { startAppUnderTest, waitForReady } from "@ionite/devtools";
3
- import { ConfigLocator, EnterpriseExtension, Ionite } from "@ionite/server";
4
1
  /** Serializable connection details provided by the ECV server control API. */
5
2
  interface SerializedEcvServerHandle {
6
3
  baseUrl: string;
@@ -11,6 +8,7 @@ interface SerializedEcvServerHandle {
11
8
  ION_VAULT_URL: string;
12
9
  ION_VAULT_TOKEN: string;
13
10
  ION_VAULT_PATH: string;
11
+ ION_ECV_CONTROL_TOKEN: string;
14
12
  REDIS_URL?: string;
15
13
  };
16
14
  configLocator: {
@@ -44,6 +42,7 @@ interface OaaPushRecord {
44
42
  }
45
43
  interface EcvServerHandle extends SerializedEcvServerHandle {
46
44
  reset(): Promise<void>;
45
+ decideAccessRequest(id: string, status: "approved" | "denied"): Promise<void>;
47
46
  setTestUser(user: TestUser): Promise<void>;
48
47
  mintTmHandle(input: {
49
48
  audience: string;
@@ -61,6 +60,7 @@ interface EcvServerHandle extends SerializedEcvServerHandle {
61
60
  /** Restore control methods after a handle crosses Vitest's serializable `provide` boundary. */
62
61
  declare function ecvHandleFrom(serialized: SerializedEcvServerHandle): EcvServerHandle;
63
62
  declare function connectEcvServer(baseUrl: string, token?: string): Promise<EcvServerHandle>;
63
+ import { ConfigLocator, EnterpriseExtension, Ionite } from "@ionite/server";
64
64
  /**
65
65
  * ionite Validator Types
66
66
  *
@@ -435,6 +435,26 @@ interface ValidationReport {
435
435
  */
436
436
  duration: number;
437
437
  }
438
+ interface EcvAccessRequestVariantOptions {
439
+ /** App-owned ECV endpoint that submits and reads access requests for this principal kind. */
440
+ accessRequestsPath: string;
441
+ /** App-owned ECV endpoint that probes the requested permission with this principal's session. */
442
+ permissionProbePath: string;
443
+ /** Principal represented by the matching ECV mock IdP identity. */
444
+ subject: string;
445
+ /** Requestable catalog target whose approval should add an entitlement claim. */
446
+ target: string;
447
+ /** CIAM provider key when the App has multiple customer access-request destinations. */
448
+ provider?: string;
449
+ }
450
+ interface EcvAccessRequestsOptions {
451
+ /** Validate workforce/SSO IdP-governed assignment. */
452
+ users?: EcvAccessRequestVariantOptions;
453
+ /** Validate customer/CIAM IdP-governed assignment. */
454
+ customers?: EcvAccessRequestVariantOptions;
455
+ }
456
+ import { AppUnderTest, StartAppOptions, WaitForReadyOptions } from "@ionite/devtools";
457
+ import { startAppUnderTest, waitForReady } from "@ionite/devtools";
438
458
  declare function createAuthzClosureTests(): {
439
459
  tests: TestDef[];
440
460
  };
@@ -447,7 +467,7 @@ declare function createOaaProjectionTests(config: AuthzValidationConfig): TestDe
447
467
  /**
448
468
  * Workload OAuth-scope tests (require the ECV mock server for JWKS + token minting). They validate
449
469
  * the two authorization sources for a workload: explicit `hasScope*` (token claims) and the
450
- * config-gated `scopesAsEntitlements` auto-honor inside `has*`.
470
+ * config-gated `claimsAsEntitlements` derivation inside `has*`.
451
471
  */
452
472
  declare function createWorkloadScopeTests(config: AuthzValidationConfig): TestDef[];
453
473
  /**
@@ -509,6 +529,15 @@ declare function buildEcvTenantCatalog(config: ECVCatalogConfig, options?: EcvTe
509
529
  /** Options specific to one explicitly registered capability unit. */
510
530
  interface EcvUnitCatalogOptions {
511
531
  expectedCallbackErrorPattern?: RegExp;
532
+ ssoClaimsAuthz?: {
533
+ permissionProbePath: string;
534
+ group: string;
535
+ };
536
+ ciamClaimsAuthz?: {
537
+ permissionProbePath: string;
538
+ group: string;
539
+ };
540
+ accessRequests?: EcvAccessRequestsOptions;
512
541
  }
513
542
  /** Build the static entries for one capability selected by the suite builder. */
514
543
  declare function buildEcvUnitCatalog(config: ECVCatalogConfig, unit: CapabilityKey2, options?: EcvUnitCatalogOptions): EcvCatalogEntry[];
@@ -572,7 +601,7 @@ declare class EcvContainer {
572
601
  }
573
602
  /**
574
603
  * Canonical `ion:*` scope strings the ECV harness embeds in workload tokens so deny-by-default SDK
575
- * endpoints (AUDIT_HISTORY.md §1.32) authorize via `scopesAsEntitlements`. They mirror the SDK-owned Permission
604
+ * endpoints (AUDIT_HISTORY.md §1.32) authorize via `claimsAsEntitlements`. They mirror the SDK-owned Permission
576
605
  * ids so they can never drift from the gate.
577
606
  */
578
607
  /** All three SCIM scopes (read + user/group writes) — the IAM suite reads and writes with one token. */
@@ -587,7 +616,7 @@ declare const ION_TENANT_SCOPE: string;
587
616
  * identity.
588
617
  *
589
618
  * The SDK gates its protected endpoints deny-by-default (AUDIT_HISTORY.md §1.32). When the app under test enables
590
- * `RemoteConfig.authz.scopesAsEntitlements` (the ECV mock vault does), the requested `scope` is honored
619
+ * `workload.incoming.claimsAsEntitlements` with `claims: ['scope']` (the ECV mock vault does), the requested `scope` is honored
591
620
  * as the matching entitlement — so pass the `ion:*` permission id(s) the endpoint requires (e.g.
592
621
  * `ion:tenant:manage`, `ion:capabilitiez:read`, or the IAM scopes). Omit `scope` to mint an
593
622
  * authenticated-but-unauthorized token (useful for asserting 403 denial).
@@ -882,7 +911,7 @@ declare function validateVaultWebSocketTransport(): Promise<ValidationSuiteResul
882
911
  *
883
912
  * Keep this synchronized with packages/ecv/package.json via publish.ts.
884
913
  */
885
- declare const ECV_VERSION = "0.0.24-beta.20260928.18";
914
+ declare const ECV_VERSION = "0.0.24-beta.20260930.19";
886
915
  /**
887
916
  * Runs all Workload validation tests
888
917
  */
@@ -933,6 +962,12 @@ interface EcvSsoLoginOptions {
933
962
  /** Register a named assertion that failed callbacks expose this generic error marker. */
934
963
  expectedCallbackErrorPattern?: RegExp;
935
964
  }
965
+ interface EcvClaimsAuthzOptions {
966
+ /** App-owned endpoint that returns 200 when the principal holds the tested permission and 403 otherwise. */
967
+ permissionProbePath: string;
968
+ /** Catalog group id the configured issuer's `groups` claim expands. */
969
+ group: string;
970
+ }
936
971
  type EcvTenantsOptions = EcvTenantCatalogOptions;
937
972
  /** Navigable ECV unit registrar returned by {@link ecvSuite}. */
938
973
  interface EcvSuite {
@@ -941,12 +976,14 @@ interface EcvSuite {
941
976
  jit: () => void;
942
977
  logout: () => void;
943
978
  back_channel_logout: () => void;
979
+ claims_authz: (options: EcvClaimsAuthzOptions) => void;
944
980
  };
945
981
  ciam: {
946
982
  customer: () => void;
947
983
  magic_link: () => void;
948
984
  oidc_login: () => void;
949
985
  logout: () => void;
986
+ claims_authz: (options: EcvClaimsAuthzOptions) => void;
950
987
  };
951
988
  iam: {
952
989
  users: () => void;
@@ -957,9 +994,11 @@ interface EcvSuite {
957
994
  workload: {
958
995
  incoming: () => void;
959
996
  outgoing: () => void;
997
+ claims_authz: () => void;
960
998
  };
961
999
  authz: {
962
1000
  oaa: () => void;
1001
+ access_requests: (options: EcvAccessRequestsOptions) => void;
963
1002
  };
964
1003
  /** Register root tenant-management and cross-tenant isolation assertions. */
965
1004
  tenants: (options?: EcvTenantsOptions) => void;
@@ -976,4 +1015,4 @@ interface EcvSuite {
976
1015
  declare function ecvSuite(config: EcvSuiteOptions): EcvSuite;
977
1016
  /** Print the legacy structured report used by the deferred standalone runner. */
978
1017
  declare function printReport(report: ValidationReport): void;
979
- export { AppUnderTest, AuthzValidationConfig, CIAMValidationConfig, ECVCatalogConfig, ECV_VERSION, EcvCatalogEntry, EcvCatalogUnit, EcvContainer, EcvContainerOptions, EcvPostgresOptions, EcvServerHandle, EcvSsoLoginOptions, EcvSuite, EcvSuiteHooks, EcvSuiteOptions, EcvSuiteSetup, EcvTenantCatalogOptions, EcvTenantsOptions, EcvTestContext, EcvTestEnvironmentOptions, EcvUnitCatalogOptions, IAMValidationConfig, ION_CAPABILITIEZ_SCOPE, ION_IAM_SCOPES, ION_TENANT_SCOPE, OaaPushRecord, ProvisionTenantOptions, ProvisionedTenant, QUARANTINED_SDK_VERSIONS, SSOValidationConfig, SUPPORTED_SDK_RANGE, SerializedEcvServerHandle, StartAppOptions, StartedEcvContainer, StartedEcvTestEnvironment, TenantManagementTestConfig, TenantValidationConfig, TenantValidationProfile, TestDef, TestUser, ValidationConfig, ValidationReport, ValidationResult, ValidationSuiteResult, WaitForReadyOptions, WorkloadValidationConfig, assert, assertEqual, assertValid, buildEcvMetaCatalog, buildEcvSdkCatalog, buildEcvTenantCatalog, buildEcvUnitCatalog, completeLoginFlow, connectEcvServer, createAuthzClosureTests, createCIAMTests, createConfigBoundaryTests, createConfigLifecycleTests, createConfigRetryTests, createDisplayCookieTests, createFetcher, createHarnessSelfTests, createIAMTests, createIamDeltaPatchTests, createIamPrincipalPullTests, createKmsTests, createLfvCallbackTests, createOaaProjectionTests, createOtelTests, createPerformanceTuningTests, createProtocolSurfaceTests, createRedisStoreTests, createSSOTests, createSecretsHardeningTests, createSessionEntriesTests, createSsoControlContractTests, createSsoIdTokenVerificationTests, createSsoSessionWindowTests, createSsoTokenClientAuthTests, createTenantAccessTests, createTenantLifecycleTests, createTenantManagementTests, createTenantTests, createValidatorParityTests, createVaultCoordinationTests, createVaultWebSocketTransportTests, createWorkloadScopeTests, createWorkloadTests, ecvHandleFrom, ecvSuite, fetchCapabilitiezManifest, getTenantAuthToken, printReport, provisionTenant, resolveBaseUrl, runLoginToCallback, runTest, satisfiesSdkRange, skipTest, startAppUnderTest, startEcvTestEnvironment, validateAuthz, validateCIAM, validateDisplayCookies, validateIAM, validateIamDelta, validateIamPrincipals, validateKms, validateLfvDelivery, validateOtel, validatePerformanceTuning, validateProtocolSurface, validateRedisStores, validateSSO, validateSecretsHardening, validateSessionEntries, validateSsoControlContract, validateSsoIdTokenVerification, validateSsoSessionWindow, validateSsoTokenClientAuth, validateTenant, validateTenantAccess, validateTenantLifecycle, validateValidatorParity, validateVaultCoordination, validateVaultWebSocketTransport, validateWorkload, waitForReady };
1018
+ export { AppUnderTest, AuthzValidationConfig, CIAMValidationConfig, ECVCatalogConfig, ECV_VERSION, EcvAccessRequestVariantOptions, EcvAccessRequestsOptions, EcvCatalogEntry, EcvCatalogUnit, EcvClaimsAuthzOptions, EcvContainer, EcvContainerOptions, EcvPostgresOptions, EcvServerHandle, EcvSsoLoginOptions, EcvSuite, EcvSuiteHooks, EcvSuiteOptions, EcvSuiteSetup, EcvTenantCatalogOptions, EcvTenantsOptions, EcvTestContext, EcvTestEnvironmentOptions, EcvUnitCatalogOptions, IAMValidationConfig, ION_CAPABILITIEZ_SCOPE, ION_IAM_SCOPES, ION_TENANT_SCOPE, OaaPushRecord, ProvisionTenantOptions, ProvisionedTenant, QUARANTINED_SDK_VERSIONS, SSOValidationConfig, SUPPORTED_SDK_RANGE, SerializedEcvServerHandle, StartAppOptions, StartedEcvContainer, StartedEcvTestEnvironment, TenantManagementTestConfig, TenantValidationConfig, TenantValidationProfile, TestDef, TestUser, ValidationConfig, ValidationReport, ValidationResult, ValidationSuiteResult, WaitForReadyOptions, WorkloadValidationConfig, assert, assertEqual, assertValid, buildEcvMetaCatalog, buildEcvSdkCatalog, buildEcvTenantCatalog, buildEcvUnitCatalog, completeLoginFlow, connectEcvServer, createAuthzClosureTests, createCIAMTests, createConfigBoundaryTests, createConfigLifecycleTests, createConfigRetryTests, createDisplayCookieTests, createFetcher, createHarnessSelfTests, createIAMTests, createIamDeltaPatchTests, createIamPrincipalPullTests, createKmsTests, createLfvCallbackTests, createOaaProjectionTests, createOtelTests, createPerformanceTuningTests, createProtocolSurfaceTests, createRedisStoreTests, createSSOTests, createSecretsHardeningTests, createSessionEntriesTests, createSsoControlContractTests, createSsoIdTokenVerificationTests, createSsoSessionWindowTests, createSsoTokenClientAuthTests, createTenantAccessTests, createTenantLifecycleTests, createTenantManagementTests, createTenantTests, createValidatorParityTests, createVaultCoordinationTests, createVaultWebSocketTransportTests, createWorkloadScopeTests, createWorkloadTests, ecvHandleFrom, ecvSuite, fetchCapabilitiezManifest, getTenantAuthToken, printReport, provisionTenant, resolveBaseUrl, runLoginToCallback, runTest, satisfiesSdkRange, skipTest, startAppUnderTest, startEcvTestEnvironment, validateAuthz, validateCIAM, validateDisplayCookies, validateIAM, validateIamDelta, validateIamPrincipals, validateKms, validateLfvDelivery, validateOtel, validatePerformanceTuning, validateProtocolSurface, validateRedisStores, validateSSO, validateSecretsHardening, validateSessionEntries, validateSsoControlContract, validateSsoIdTokenVerification, validateSsoSessionWindow, validateSsoTokenClientAuth, validateTenant, validateTenantAccess, validateTenantLifecycle, validateValidatorParity, validateVaultCoordination, validateVaultWebSocketTransport, validateWorkload, waitForReady };
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- import{ie,ce,n,a,s,c,e,t,o,u,p,Z,de,le,m,h,ue,U,q,M,N,L,l,r,D,pe,g,f,me,y,he,w,ge,i,V,Q,ee,v,fe,b,ye,k,we,S,ve,be,T,z,ke,C,Se,R,Te,x,Ce,E,Re,A,xe,d,Ee,te,B,I,Ae,P,Ie,_,Pe,_e,j,J,G,W,K,F,se,H,Y,O,je,ae,Oe,ne,Ue,re,$e,oe,qe,X,Me}from"./shared/ecv-x9smnj0y.js";export{i as ECV_VERSION,O as EcvContainer,L as ION_CAPABILITIEZ_SCOPE,N as ION_IAM_SCOPES,l as ION_TENANT_SCOPE,Q as QUARANTINED_SDK_VERSIONS,V as SUPPORTED_SDK_RANGE,Y as StartedEcvContainer,e as assert,t as assertEqual,o as assertValid,G as buildEcvMetaCatalog,W as buildEcvSdkCatalog,K as buildEcvTenantCatalog,F as buildEcvUnitCatalog,z as completeLoginFlow,H as connectEcvServer,u as createAuthzClosureTests,m as createCIAMTests,q as createConfigBoundaryTests,U as createConfigLifecycleTests,M as createConfigRetryTests,R as createDisplayCookieTests,a as createFetcher,D as createHarnessSelfTests,g as createIAMTests,f as createIamDeltaPatchTests,y as createIamPrincipalPullTests,w as createKmsTests,h as createLfvCallbackTests,p as createOaaProjectionTests,v as createOtelTests,ae as createPerformanceTuningTests,b as createProtocolSurfaceTests,ne as createRedisStoreTests,T as createSSOTests,k as createSecretsHardeningTests,S as createSessionEntriesTests,C as createSsoControlContractTests,x as createSsoIdTokenVerificationTests,E as createSsoSessionWindowTests,A as createSsoTokenClientAuthTests,I as createTenantAccessTests,re as createTenantLifecycleTests,B as createTenantManagementTests,te as createTenantTests,oe as createValidatorParityTests,P as createVaultCoordinationTests,_ as createVaultWebSocketTransportTests,Z as createWorkloadScopeTests,j as createWorkloadTests,se as ecvHandleFrom,X as ecvSuite,J as fetchCapabilitiezManifest,r as getTenantAuthToken,Me as printReport,d as provisionTenant,n as resolveBaseUrl,ke as runLoginToCallback,s as runTest,ee as satisfiesSdkRange,c as skipTest,ie as startAppUnderTest,je as startEcvTestEnvironment,de as validateAuthz,le as validateCIAM,Te as validateDisplayCookies,pe as validateIAM,me as validateIamDelta,he as validateIamPrincipals,ge as validateKms,ue as validateLfvDelivery,fe as validateOtel,Oe as validatePerformanceTuning,ye as validateProtocolSurface,Ue as validateRedisStores,be as validateSSO,we as validateSecretsHardening,ve as validateSessionEntries,Se as validateSsoControlContract,Ce as validateSsoIdTokenVerification,Re as validateSsoSessionWindow,xe as validateSsoTokenClientAuth,Ee as validateTenant,Ae as validateTenantAccess,$e as validateTenantLifecycle,qe as validateValidatorParity,Ie as validateVaultCoordination,Pe as validateVaultWebSocketTransport,_e as validateWorkload,ce as waitForReady};
1
+ import{ie,ce,n,a,s,c,e,t,o,u,p,Z,de,le,m,O,q,l,r,h,ue,M,N,L,D,pe,g,f,me,y,he,w,ge,i,z,Q,ee,v,fe,b,ye,k,we,S,ve,be,T,V,ke,C,Se,R,Te,x,Ce,E,Re,A,xe,d,Ee,te,B,I,Ae,P,Ie,_,Pe,_e,j,J,G,W,K,F,se,H,Y,U,je,ae,Ue,ne,Oe,re,qe,oe,$e,X,Me}from"./shared/ecv-e1pn2rgg.js";export{i as ECV_VERSION,U as EcvContainer,q as ION_CAPABILITIEZ_SCOPE,O as ION_IAM_SCOPES,l as ION_TENANT_SCOPE,Q as QUARANTINED_SDK_VERSIONS,z as SUPPORTED_SDK_RANGE,Y as StartedEcvContainer,e as assert,t as assertEqual,o as assertValid,G as buildEcvMetaCatalog,W as buildEcvSdkCatalog,K as buildEcvTenantCatalog,F as buildEcvUnitCatalog,V as completeLoginFlow,H as connectEcvServer,u as createAuthzClosureTests,m as createCIAMTests,N as createConfigBoundaryTests,M as createConfigLifecycleTests,L as createConfigRetryTests,R as createDisplayCookieTests,a as createFetcher,D as createHarnessSelfTests,g as createIAMTests,f as createIamDeltaPatchTests,y as createIamPrincipalPullTests,w as createKmsTests,h as createLfvCallbackTests,p as createOaaProjectionTests,v as createOtelTests,ae as createPerformanceTuningTests,b as createProtocolSurfaceTests,ne as createRedisStoreTests,T as createSSOTests,k as createSecretsHardeningTests,S as createSessionEntriesTests,C as createSsoControlContractTests,x as createSsoIdTokenVerificationTests,E as createSsoSessionWindowTests,A as createSsoTokenClientAuthTests,I as createTenantAccessTests,re as createTenantLifecycleTests,B as createTenantManagementTests,te as createTenantTests,oe as createValidatorParityTests,P as createVaultCoordinationTests,_ as createVaultWebSocketTransportTests,Z as createWorkloadScopeTests,j as createWorkloadTests,se as ecvHandleFrom,X as ecvSuite,J as fetchCapabilitiezManifest,r as getTenantAuthToken,Me as printReport,d as provisionTenant,n as resolveBaseUrl,ke as runLoginToCallback,s as runTest,ee as satisfiesSdkRange,c as skipTest,ie as startAppUnderTest,je as startEcvTestEnvironment,de as validateAuthz,le as validateCIAM,Te as validateDisplayCookies,pe as validateIAM,me as validateIamDelta,he as validateIamPrincipals,ge as validateKms,ue as validateLfvDelivery,fe as validateOtel,Ue as validatePerformanceTuning,ye as validateProtocolSurface,Oe as validateRedisStores,be as validateSSO,we as validateSecretsHardening,ve as validateSessionEntries,Se as validateSsoControlContract,Ce as validateSsoIdTokenVerification,Re as validateSsoSessionWindow,xe as validateSsoTokenClientAuth,Ee as validateTenant,Ae as validateTenantAccess,qe as validateTenantLifecycle,$e as validateValidatorParity,Ie as validateVaultCoordination,Pe as validateVaultWebSocketTransport,_e as validateWorkload,ce as waitForReady};