@openziti/ziti-console-lib 1.2.1 → 1.3.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/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as lottie_web from 'lottie-web';
2
2
  import * as i0 from '@angular/core';
3
- import { PipeTransform, EventEmitter, InjectionToken, ViewContainerRef, ElementRef, OnInit, DoCheck, OnDestroy, AfterViewInit, ChangeDetectorRef, OnChanges, SimpleChanges, TemplateRef } from '@angular/core';
3
+ import { PipeTransform, EventEmitter, InjectionToken, ViewContainerRef, ElementRef, OnInit, DoCheck, OnDestroy, AfterViewInit, ChangeDetectorRef, OnChanges, SimpleChanges, TemplateRef, Injector } from '@angular/core';
4
4
  import * as _angular_platform_browser from '@angular/platform-browser';
5
5
  import { DomSanitizer } from '@angular/platform-browser';
6
6
  import * as rxjs from 'rxjs';
@@ -66,6 +66,7 @@ interface ExtensionService {
66
66
  listActions?: any[];
67
67
  consoleActionTriggered?: EventEmitter<any>;
68
68
  disabledComponents?: any[];
69
+ showApiCalls?: boolean;
69
70
  emitEvent?<TData, TResult>(event: ExtensionEvent<TData, TResult>): Promise<TResult | undefined>;
70
71
  extendOnInit(): void;
71
72
  extendAfterViewInits(extentionPoints: any): void;
@@ -505,6 +506,8 @@ declare abstract class SettingsServiceClass {
505
506
  port: number;
506
507
  portTLS: number;
507
508
  apiVersions: any[];
509
+ capabilities: string[];
510
+ edgeOidcPath: string | null;
508
511
  protocol: string;
509
512
  host: string;
510
513
  httpClient: HttpClient;
@@ -517,6 +520,9 @@ declare abstract class SettingsServiceClass {
517
520
  abstract initApiVersions(url: any): any;
518
521
  abstract loadSettings(): any;
519
522
  abstract hasSession(): any;
523
+ oidcAvailable(): boolean;
524
+ setOidcCapabilities(versionData: any): void;
525
+ clearOidcCapabilities(): void;
520
526
  abstract isHAEnabled(): boolean;
521
527
  abstract getHAControllers(): any[];
522
528
  abstract getActiveSessions(): Map<string, string>;
@@ -558,11 +564,18 @@ declare abstract class ZitiDataService {
558
564
  total: number;
559
565
  };
560
566
  constructor(logger: LoggerService, growler: GrowlerService, settingsService: SettingsServiceClass, httpClient: HttpClient, router: Router);
567
+ private readonly injector;
568
+ /** Resolved lazily to break the circular dependency: ManagementPermissionsService → ZITI_DATA_SERVICE → ManagementPermissionsService. */
569
+ private get managementPermissions();
570
+ /** Empty list response returned when the user lacks read permission for the requested resource. */
571
+ private static readonly EMPTY_READ_RESULT;
561
572
  abstract post(type: any, model: any, chained?: any, contentType?: any): Promise<any>;
562
573
  abstract put(type: any, model: any, id: any, chained?: any): Promise<any>;
563
574
  abstract patch(type: any, model: any, id: any, chained?: any): Promise<any>;
564
- abstract get(type: string, paging: any, filters: FilterObj[], url?: any, useClient?: any): Promise<any>;
565
- abstract getSubdata(entityType: string, id: any, dataType: string, paging?: any, contentType?: any, filters?: any): Promise<any>;
575
+ abstract doGet(type: string, paging: any, filters: FilterObj[], url?: any, useClient?: any): Promise<any>;
576
+ abstract doGetSubdata(entityType: string, id: any, dataType: string, paging?: any, contentType?: any, filters?: any): Promise<any>;
577
+ get(type: string, paging: any, filters: FilterObj[], url?: any, useClient?: any): Promise<any>;
578
+ getSubdata(entityType: string, id: any, dataType: string, paging?: any, contentType?: any, filters?: any): Promise<any>;
566
579
  abstract saveSubdata(entityType: string, id: any, dataType: string, params: any): Promise<any>;
567
580
  abstract deleteSubdata(entityType: string, id: any, dataType: string, params: any): Promise<any>;
568
581
  abstract delete(type: string, id: string): Promise<any>;
@@ -740,6 +753,8 @@ declare class SettingsService extends SettingsServiceClass {
740
753
  }
741
754
 
742
755
  declare const SAVE_DENIED_BY_PERMISSION_TOOLTIP = "You do not have permission to save changes.";
756
+ /** Maps ZAC entityType strings to controller permission entity keys. */
757
+ declare const API_RESOURCE_TO_ENTITY_PERMISSION: Record<string, string>;
743
758
  declare class ManagementPermissionsService {
744
759
  private readonly settings;
745
760
  private readonly zitiData;
@@ -762,15 +777,16 @@ declare class ManagementPermissionsService {
762
777
  isUnrestricted(): boolean;
763
778
  private isAdmin;
764
779
  isAdminReadonly(): boolean;
765
- /** Read is not entity-scoped yet; parameter reserved for future use. */
766
- canRead(_apiResource: string): boolean;
767
- /** Create is global-role only until entity grants exist; apiResource unused for now. */
768
- canCreate(_apiResource: string): boolean;
769
- /** Update is global-role only until entity grants exist; apiResource unused for now. */
770
- canUpdate(_apiResource: string): boolean;
771
- /** Delete is global-role only until entity grants exist; apiResource unused for now. */
772
- canDelete(_apiResource: string): boolean;
773
- /** Strict read-only shell when the session has global admin_readonly (no writes). */
780
+ /** True once fetchCurrentIdentity() (or clear()) has run at least once — version > 0. */
781
+ get permissionsLoaded(): boolean;
782
+ private resolveEntityKey;
783
+ private hasEntityGrant;
784
+ private hasActionGrant;
785
+ canRead(apiResource: string): boolean;
786
+ canCreate(apiResource: string): boolean;
787
+ canUpdate(apiResource: string): boolean;
788
+ canDelete(apiResource: string): boolean;
789
+ /** Strict read-only form UI: no write permission for this resource (covers admin_readonly and missing entity grant). */
774
790
  useStrictReadonlyFormUi(apiResource: string, isEdit: boolean): boolean;
775
791
  isSaveDisabled(apiResource: string, isEdit: boolean): boolean;
776
792
  isMenuActionAllowed(apiResource: string, action: string): boolean;
@@ -838,10 +854,12 @@ declare abstract class ProjectableForm extends ExtendableComponent implements Do
838
854
  protected readonly managementPermissions: ManagementPermissionsService;
839
855
  formInit: boolean;
840
856
  formContainer: ElementRef;
857
+ get showApiCalls(): boolean;
841
858
  protected constructor(growlerService: GrowlerService, extService: ExtensionService, zitiService: ZitiDataService, router?: Router, route?: ActivatedRoute, location?: Location, settingsService?: SettingsService, dialogForm?: MatDialog);
842
859
  get isEdit(): boolean;
843
860
  get formPermissionSaveDisabled(): boolean;
844
861
  get formPermissionSaveTooltip(): string;
862
+ canReadRelated(apiResource: string): boolean;
845
863
  get useStrictReadonlyForm(): boolean;
846
864
  /** Blocks save from shortcuts/callbacks when the controller denies create/update for this resource. */
847
865
  protected canSaveByPermissions(): boolean;
@@ -1249,6 +1267,7 @@ declare abstract class ListPageComponent {
1249
1267
  protected readonly managementPermissions: ManagementPermissionsService;
1250
1268
  get headerBlockCreate(): boolean;
1251
1269
  get headerBlockDelete(): boolean;
1270
+ get headerBlockRead(): boolean;
1252
1271
  constructor(filterService: DataTableFilterService, svc: ListPageServiceClass, consoleEvents: ConsoleEventsService, dialogForm: MatDialog, extensionService?: ExtensionService);
1253
1272
  ngOnInit(): void;
1254
1273
  ngOnDestroy(): void;
@@ -1820,6 +1839,8 @@ declare class DataTableComponent implements OnChanges, OnInit {
1820
1839
  showNoItemsAdd: boolean;
1821
1840
  /** When true, empty-state copy does not prompt to add (e.g. admin_readonly / no create permission). */
1822
1841
  noItemsReadonly: boolean;
1842
+ /** When true, shows "no permission to view" message instead of the table. */
1843
+ accessDenied: boolean;
1823
1844
  currentPage: number;
1824
1845
  noItemsImage: string;
1825
1846
  rowHeight: number;
@@ -1954,7 +1975,7 @@ declare class DataTableComponent implements OnChanges, OnInit {
1954
1975
  _handleTableScroll(scroller: any): void;
1955
1976
  remToPx(remValue: any): number;
1956
1977
  static ɵfac: i0.ɵɵFactoryDeclaration<DataTableComponent, never>;
1957
- static ɵcmp: i0.ɵɵComponentDeclaration<DataTableComponent, "lib-data-table", never, { "rowData": { "alias": "rowData"; "required": false; }; "expandRowData": { "alias": "expandRowData"; "required": false; }; "collapseRowData": { "alias": "collapseRowData"; "required": false; }; "rowValidation": { "alias": "rowValidation"; "required": false; }; "isTimeSearchAvailable": { "alias": "isTimeSearchAvailable"; "required": false; }; "isLoading": { "alias": "isLoading"; "required": false; }; "tableId": { "alias": "tableId"; "required": false; }; "options": { "alias": "options"; "required": false; }; "validateService": { "alias": "validateService"; "required": false; }; "rowsToggled": { "alias": "rowsToggled"; "required": false; }; "tableRefreshCount": { "alias": "tableRefreshCount"; "required": false; }; "view": { "alias": "view"; "required": false; }; "serverSideDataSource": { "alias": "serverSideDataSource"; "required": false; }; "allowDownload": { "alias": "allowDownload"; "required": false; }; "startCount": { "alias": "startCount"; "required": false; }; "endCount": { "alias": "endCount"; "required": false; }; "totalCount": { "alias": "totalCount"; "required": false; }; "emptyMsg": { "alias": "emptyMsg"; "required": false; }; "filterApplied": { "alias": "filterApplied"; "required": false; }; "menuItems": { "alias": "menuItems"; "required": false; }; "headerActions": { "alias": "headerActions"; "required": false; }; "noItemsClass": { "alias": "noItemsClass"; "required": false; }; "entityTypeName": { "alias": "entityTypeName"; "required": false; }; "showNoItemsAdd": { "alias": "showNoItemsAdd"; "required": false; }; "noItemsReadonly": { "alias": "noItemsReadonly"; "required": false; }; "currentPage": { "alias": "currentPage"; "required": false; }; "noItemsImage": { "alias": "noItemsImage"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "filterName": { "alias": "filterName"; "required": false; }; "filterColumn": { "alias": "filterColumn"; "required": false; }; "columnDefinitions": { "alias": "columnDefinitions"; "required": false; }; "refreshCount": { "alias": "refreshCount"; "required": false; }; }, { "actionRequested": "actionRequested"; "gridReady": "gridReady"; "dragStart": "dragStart"; "dragLeave": "dragLeave"; "pageChanged": "pageChanged"; }, never, never, false, never>;
1978
+ static ɵcmp: i0.ɵɵComponentDeclaration<DataTableComponent, "lib-data-table", never, { "rowData": { "alias": "rowData"; "required": false; }; "expandRowData": { "alias": "expandRowData"; "required": false; }; "collapseRowData": { "alias": "collapseRowData"; "required": false; }; "rowValidation": { "alias": "rowValidation"; "required": false; }; "isTimeSearchAvailable": { "alias": "isTimeSearchAvailable"; "required": false; }; "isLoading": { "alias": "isLoading"; "required": false; }; "tableId": { "alias": "tableId"; "required": false; }; "options": { "alias": "options"; "required": false; }; "validateService": { "alias": "validateService"; "required": false; }; "rowsToggled": { "alias": "rowsToggled"; "required": false; }; "tableRefreshCount": { "alias": "tableRefreshCount"; "required": false; }; "view": { "alias": "view"; "required": false; }; "serverSideDataSource": { "alias": "serverSideDataSource"; "required": false; }; "allowDownload": { "alias": "allowDownload"; "required": false; }; "startCount": { "alias": "startCount"; "required": false; }; "endCount": { "alias": "endCount"; "required": false; }; "totalCount": { "alias": "totalCount"; "required": false; }; "emptyMsg": { "alias": "emptyMsg"; "required": false; }; "filterApplied": { "alias": "filterApplied"; "required": false; }; "menuItems": { "alias": "menuItems"; "required": false; }; "headerActions": { "alias": "headerActions"; "required": false; }; "noItemsClass": { "alias": "noItemsClass"; "required": false; }; "entityTypeName": { "alias": "entityTypeName"; "required": false; }; "showNoItemsAdd": { "alias": "showNoItemsAdd"; "required": false; }; "noItemsReadonly": { "alias": "noItemsReadonly"; "required": false; }; "accessDenied": { "alias": "accessDenied"; "required": false; }; "currentPage": { "alias": "currentPage"; "required": false; }; "noItemsImage": { "alias": "noItemsImage"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "filterName": { "alias": "filterName"; "required": false; }; "filterColumn": { "alias": "filterColumn"; "required": false; }; "columnDefinitions": { "alias": "columnDefinitions"; "required": false; }; "refreshCount": { "alias": "refreshCount"; "required": false; }; }, { "actionRequested": "actionRequested"; "gridReady": "gridReady"; "dragStart": "dragStart"; "dragLeave": "dragLeave"; "pageChanged": "pageChanged"; }, never, never, false, never>;
1958
1979
  }
1959
1980
 
1960
1981
  declare class TableCellSelectComponent implements ICellRendererAngularComp {
@@ -2312,6 +2333,7 @@ declare class NoItemsComponent implements OnChanges {
2312
2333
  hiddenResults: boolean;
2313
2334
  isLoading: boolean;
2314
2335
  readonly: boolean;
2336
+ accessDenied: boolean;
2315
2337
  background: any;
2316
2338
  clickEmit: EventEmitter<any>;
2317
2339
  refresh: EventEmitter<any>;
@@ -2319,7 +2341,7 @@ declare class NoItemsComponent implements OnChanges {
2319
2341
  ngOnChanges(): void;
2320
2342
  iconClick(): void;
2321
2343
  static ɵfac: i0.ɵɵFactoryDeclaration<NoItemsComponent, never>;
2322
- static ɵcmp: i0.ɵɵComponentDeclaration<NoItemsComponent, "lib-no-items", never, { "image": { "alias": "image"; "required": false; }; "typeName": { "alias": "typeName"; "required": false; }; "isEmpty": { "alias": "isEmpty"; "required": false; }; "hasAdd": { "alias": "hasAdd"; "required": false; }; "hiddenResults": { "alias": "hiddenResults"; "required": false; }; "isLoading": { "alias": "isLoading"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; }, { "clickEmit": "clickEmit"; "refresh": "refresh"; }, never, never, false, never>;
2344
+ static ɵcmp: i0.ɵɵComponentDeclaration<NoItemsComponent, "lib-no-items", never, { "image": { "alias": "image"; "required": false; }; "typeName": { "alias": "typeName"; "required": false; }; "isEmpty": { "alias": "isEmpty"; "required": false; }; "hasAdd": { "alias": "hasAdd"; "required": false; }; "hiddenResults": { "alias": "hiddenResults"; "required": false; }; "isLoading": { "alias": "isLoading"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "accessDenied": { "alias": "accessDenied"; "required": false; }; }, { "clickEmit": "clickEmit"; "refresh": "refresh"; }, never, never, false, never>;
2323
2345
  }
2324
2346
 
2325
2347
  declare class SideModalComponent implements OnInit {
@@ -2855,10 +2877,16 @@ declare class IdentityServicePathComponent implements OnInit {
2855
2877
  isDarkMode: boolean;
2856
2878
  refreshRotate: boolean;
2857
2879
  closeRotate: boolean;
2880
+ private lastRenderContext;
2881
+ private zoomBehavior;
2882
+ private hasInitialFit;
2883
+ private readonly viewBoxWidth;
2884
+ private readonly viewBoxHeight;
2858
2885
  filterText: string;
2859
2886
  noSearchResults: boolean;
2860
2887
  autocompleteOptions: any[];
2861
2888
  fullScreen: boolean;
2889
+ legendCollapsed: boolean;
2862
2890
  serviceOptions: any;
2863
2891
  endpointData: any;
2864
2892
  networkGraph: any;
@@ -2887,12 +2915,17 @@ declare class IdentityServicePathComponent implements OnInit {
2887
2915
  clearSearchFilter(): void;
2888
2916
  autocompleteSearch(event: any): void;
2889
2917
  serviceChanged(): void;
2918
+ refreshFabricData(): Promise<void>;
2890
2919
  addItemToArray(bindIdnetities: any, ob: any): any;
2891
2920
  getLinkForResource(ob: any, resource: any): any;
2892
2921
  startVisProcess(bindIdnetities: any, selectedServiceOb: any, serviceConfigs: any, hostEdgeRouters?: any[], serviceTerminators?: any[], serviceCircuits?: any[]): void;
2893
2922
  toggleModalSize(): void;
2894
2923
  hide(): void;
2895
2924
  initTopoView(): void;
2925
+ fitToContent(): void;
2926
+ zoomIn(): void;
2927
+ zoomOut(): void;
2928
+ resetView(): void;
2896
2929
  static ɵfac: i0.ɵɵFactoryDeclaration<IdentityServicePathComponent, never>;
2897
2930
  static ɵcmp: i0.ɵɵComponentDeclaration<IdentityServicePathComponent, "app-identity-visualizer", never, {}, {}, never, never, false, never>;
2898
2931
  }
@@ -3547,6 +3580,7 @@ declare class ServiceFormComponent extends ProjectableForm implements OnInit, On
3547
3580
  configFilterChanged(filterText: string): void;
3548
3581
  configTypeChanged($event: any): void;
3549
3582
  get showConfigData(): boolean;
3583
+ get canCreateConfig(): boolean;
3550
3584
  attachConfig(): void;
3551
3585
  captureConfigEnterEvent(event: any): void;
3552
3586
  protected deleteServiceWithOrphans(): Promise<any>;
@@ -3764,6 +3798,8 @@ declare class SimpleServiceComponent extends ProjectableForm {
3764
3798
  entityIdInit: boolean;
3765
3799
  set entityId(id: String);
3766
3800
  get entityId(): String;
3801
+ get formPermissionSaveDisabled(): boolean;
3802
+ get formPermissionSaveTooltip(): string;
3767
3803
  ngOnInit(): void;
3768
3804
  formDataSet: boolean;
3769
3805
  initFormData(): Promise<[void, void]>;
@@ -3789,6 +3825,7 @@ declare class SimpleServiceComponent extends ProjectableForm {
3789
3825
  interceptPortChanged($event: any): void;
3790
3826
  hostProtocolsChanged($event: any): void;
3791
3827
  save(refresh?: any): Promise<void>;
3828
+ markEntityError(summaryData: any, type: string, subtype?: string): void;
3792
3829
  showSummary(): any;
3793
3830
  checkNameConflicts(): Promise<boolean>;
3794
3831
  showConflictWarning(conflictData: any): void;
@@ -4571,6 +4608,10 @@ declare abstract class LoginServiceClass {
4571
4608
  serviceUrl: string;
4572
4609
  loginInProgress: boolean;
4573
4610
  callbackRoute: string;
4611
+ pendingMfa: boolean;
4612
+ mfaAuthQueries: any[];
4613
+ completeMfaAuth(code: string): Promise<any>;
4614
+ cancelMfaAuth(): void;
4574
4615
  abstract init(): any;
4575
4616
  abstract login(prefix: string, url: string, username: string, password: string, doNav?: any, type?: any, token?: any, isTest?: any): any;
4576
4617
  abstract observeLogin(serviceUrl: string, username: string, password: string, doNav?: any, type?: any, token?: any, isTest?: any): any;
@@ -7689,8 +7730,8 @@ declare class NodeDataService extends ZitiDataService {
7689
7730
  post(type: any, model: any, chained?: boolean): Promise<any>;
7690
7731
  put(type: any, model: any, id: any, chained?: boolean): Promise<any>;
7691
7732
  patch(type: any, model: any, id: any, chained?: boolean): Promise<any>;
7692
- get(type: string, paging: any, filters?: FilterObj[], url?: any): Promise<any>;
7693
- getSubdata(entityType: string, id: any, dataType: string): Promise<any>;
7733
+ doGet(type: string, paging: any, filters?: FilterObj[], url?: any): Promise<any>;
7734
+ doGetSubdata(entityType: string, id: any, dataType: string): Promise<any>;
7694
7735
  saveSubdata(entityType: string, id: any, dataType: string, data: any): Promise<any>;
7695
7736
  resetEnrollment(id: string, date: any): Promise<any>;
7696
7737
  deleteEnrollment(enrollmentId: string): Promise<any>;
@@ -7721,8 +7762,8 @@ declare class ZitiControllerDataService extends ZitiDataService {
7721
7762
  post(type: any, model: any, chained?: boolean, contentType?: any): Promise<any>;
7722
7763
  put(type: any, model: any, id: any, chained?: boolean): Promise<any>;
7723
7764
  patch(type: any, model: any, id: any, chained?: boolean): Promise<any>;
7724
- get(type: string, paging: any, filters?: FilterObj[], url?: any, useClient?: any): Promise<any>;
7725
- getSubdata(entityType: string, id: any, dataType: string, paging?: any, contentType?: any, filters?: any[]): Promise<any>;
7765
+ doGet(type: string, paging: any, filters?: FilterObj[], url?: any, useClient?: any): Promise<any>;
7766
+ doGetSubdata(entityType: string, id: any, dataType: string, paging?: any, contentType?: any, filters?: any[]): Promise<any>;
7726
7767
  saveSubdata(entityType: string, id: any, dataType: string, params: any): Promise<any>;
7727
7768
  deleteSubdata(entityType: string, id: any, dataType: string, params: any): Promise<any>;
7728
7769
  resetEnrollment(id: string, date: any): Promise<any>;
@@ -7774,6 +7815,115 @@ declare class DeactivateGuardService implements CanDeactivate<CanComponentDeacti
7774
7815
  static ɵprov: i0.ɵɵInjectableDeclaration<DeactivateGuardService>;
7775
7816
  }
7776
7817
 
7818
+ declare class InsecureContextError extends Error {
7819
+ constructor();
7820
+ }
7821
+ declare function randomUrlSafeString(byteLen?: number): string;
7822
+ declare function pkceChallengeS256(verifier: string): Promise<string>;
7823
+ declare function decodeJwtPayload(token: string): any | null;
7824
+ declare function jwtExpMs(token: string): number | undefined;
7825
+ declare function jwtIatMs(token: string): number | undefined;
7826
+
7827
+ declare const OIDC_CLIENT_ID = "openziti";
7828
+ declare const OIDC_CLIENT_ID_LEGACY = "native";
7829
+ interface OidcTokenSet {
7830
+ accessToken: string;
7831
+ refreshToken?: string;
7832
+ idToken?: string;
7833
+ expiresAt: number;
7834
+ refreshExpiresAt?: number;
7835
+ clientId: string;
7836
+ }
7837
+ interface OidcAuthContext {
7838
+ controllerUrl: string;
7839
+ oidcBase: string;
7840
+ authRequestId: string;
7841
+ state: string;
7842
+ nonce: string;
7843
+ codeVerifier: string;
7844
+ redirectUri: string;
7845
+ clientId: string;
7846
+ }
7847
+ type OidcLoginStep = {
7848
+ status: 'code';
7849
+ code: string;
7850
+ } | {
7851
+ status: 'totpRequired';
7852
+ authQueries: any[];
7853
+ } | {
7854
+ status: 'error';
7855
+ error: any;
7856
+ };
7857
+ declare class OidcEnvironmentalError extends Error {
7858
+ causedBy?: any;
7859
+ constructor(message: string, causedBy?: any);
7860
+ }
7861
+ declare class OidcSessionUnrecoverableError extends Error {
7862
+ reason?: string;
7863
+ constructor(message: string, reason?: string);
7864
+ }
7865
+ /**
7866
+ * Drives the ziti controller's native OIDC provider (auth code + PKCE) programmatically,
7867
+ * the same way the ziti SDKs do, so the console keeps its own login UI.
7868
+ *
7869
+ * Uses fetch rather than HttpClient: the auth request id and authorization code must be
7870
+ * parsed from Response.url after redirect-following (the controller's CORS config does not
7871
+ * expose the auth-request-id/totp-required headers cross-origin), and these requests must
7872
+ * bypass the app's HTTP interceptors.
7873
+ */
7874
+ declare class ZitiOidcService {
7875
+ private inflightRefresh;
7876
+ buildRedirectUri(): string;
7877
+ startAuthRequest(controllerUrl: string, options?: {
7878
+ redirectUri?: string;
7879
+ oidcPath?: string;
7880
+ }): Promise<OidcAuthContext>;
7881
+ private authorize;
7882
+ loginWithPassword(ctx: OidcAuthContext, username: string, password: string): Promise<OidcLoginStep>;
7883
+ loginWithExtJwt(ctx: OidcAuthContext, extToken: string): Promise<OidcLoginStep>;
7884
+ loginWithCert(ctx: OidcAuthContext): Promise<OidcLoginStep>;
7885
+ submitTotp(ctx: OidcAuthContext, code: string): Promise<OidcLoginStep>;
7886
+ private submitLogin;
7887
+ exchangeCode(ctx: OidcAuthContext, code: string): Promise<OidcTokenSet>;
7888
+ refreshTokens(controllerUrl: string, refreshToken: string, clientId?: string, oidcPath?: string): Promise<OidcTokenSet>;
7889
+ private doRefresh;
7890
+ revokeToken(controllerUrl: string, token: string, hint: 'refresh_token' | 'access_token', clientId?: string, oidcPath?: string): Promise<void>;
7891
+ private toTokenSet;
7892
+ private normalizeUrl;
7893
+ static ɵfac: i0.ɵɵFactoryDeclaration<ZitiOidcService, never>;
7894
+ static ɵprov: i0.ɵɵInjectableDeclaration<ZitiOidcService>;
7895
+ }
7896
+
7897
+ /**
7898
+ * Keeps OIDC sessions alive by refreshing the access token before it expires, and
7899
+ * self-monitors for sessions that can no longer be renewed (refresh token expired or
7900
+ * revoked), logging the user out and returning them to the login page.
7901
+ */
7902
+ declare class SessionRefreshService {
7903
+ private settingsService;
7904
+ private oidcService;
7905
+ private growlerService;
7906
+ private injector;
7907
+ private refreshTimer;
7908
+ private monitorInterval;
7909
+ private retryDelayMs;
7910
+ private running;
7911
+ private readonly onWake;
7912
+ private readonly onStorage;
7913
+ constructor(settingsService: SettingsServiceClass, oidcService: ZitiOidcService, growlerService: GrowlerService, injector: Injector);
7914
+ start(): void;
7915
+ stop(): void;
7916
+ refreshNow(): Promise<boolean>;
7917
+ private persistTokens;
7918
+ private scheduleNextRefresh;
7919
+ private scheduleRetry;
7920
+ private checkSessionState;
7921
+ private hasOidcSession;
7922
+ private handleUnrecoverable;
7923
+ static ɵfac: i0.ɵɵFactoryDeclaration<SessionRefreshService, never>;
7924
+ static ɵprov: i0.ɵɵInjectableDeclaration<SessionRefreshService>;
7925
+ }
7926
+
7777
7927
  declare const ZITI_URLS: InjectionToken<string>;
7778
7928
  declare const ZITI_NAVIGATOR: InjectionToken<string>;
7779
7929
  declare const DEFAULT_APP_CONFIG: InjectionToken<string>;
@@ -7782,6 +7932,6 @@ declare const ZAC_VERSION: {
7782
7932
  version: string;
7783
7933
  };
7784
7934
 
7785
- export { APISessionFormComponent, APISessionsPageComponent, ApiSessionsPageService, AttributesComponent, AuthPoliciesPageComponent, AuthPoliciesPageService, AuthPolicyFormComponent, AuthPolicyFormService, AuthService, BooleanToggleInputComponent, CallbackComponent, CardListComponent, CertificateAuthoritiesPageComponent, CertificateAuthoritiesPageService, CertificateAuthorityFormComponent, CertificateAuthorityFormService, CheckboxListInputComponent, ChipsInputComponent, ConfigEditorComponent, ConfigTypeFormComponent, ConfigTypesPageComponent, ConfigurationFormComponent, ConfigurationService, ConfigurationsPageComponent, CsvDownloadService, DEACTIVATE_GUARD, DEFAULT_APP_CONFIG, DataTableFilterService, DeactivateGuardService, EDGE_ROUTER_EXTENSION_SERVICE, EDGE_ROUTER_POLICY_EXTENSION_SERVICE, EdgeRouter, EdgeRouterFormComponent, EdgeRouterFormService, EdgeRouterPoliciesPageComponent, EdgeRouterPoliciesPageService, EdgeRouterPolicyFormComponent, EdgeRouterPolicyFormService, EdgeRoutersPageComponent, EdgeRoutersPageService, Entity, ExtendableComponent, ExtensionsNoopService, FilterSelectComponent, FilterSelectOptionTemplateDirective, FilterSelectTriggerTemplateDirective, FormFieldContainerComponent, FormFieldToggleComponent, FormHeaderComponent, GeolocateComponent, GrowlerComponent, GrowlerModel, GrowlerModule, GrowlerService, HAControllerService, HaStatusIndicatorComponent, HeaderBarComponent, IDENTITY_EXTENSION_SERVICE, IdentitiesPageComponent, IdentitiesPageService, Identity$1 as Identity, IdentityFormComponent, IdentityFormService, IdentityServicePathComponent, JsonViewComponent, JwtSignerFormComponent, JwtSignerFormService, JwtSignersPageComponent, JwtSignersPageService, KEY_CODES, ListPageComponent, ListPageServiceClass, LoadingIndicatorComponent, LoggerService, LoginDialogComponent, LoginServiceClass, ManagementPermissionsService, NetworkVisualizerComponent, NodeDataService, NoopLoginService, NoopTabInterceptorService, NumberInputComponent, ObjectComponent, OpenZitiConsoleLibModule, PasswordInputComponent, PostureCheckFormComponent, PostureChecksPageComponent, PostureChecksPageService, PreviewListComponent, ProfileComponent, ProgressMeterComponent, ProgressMeterStep, ProgressWizardComponent, ProgressWizardStep, ProjectableForm, ProtocolAddressPortInputComponent, QuickAddComponent, ResetEnrollmentService, SAVE_DENIED_BY_PERMISSION_TOOLTIP, SERVICE_EDGE_ROUTER_POLICY_EXTENSION_SERVICE, SERVICE_EXTENSION_SERVICE, SERVICE_POLICY_EXTENSION_SERVICE, SETTINGS_SERVICE, SHAREDZ_EXTENSION, SelectorInputComponent, ServiceEdgeRouterPoliciesPageComponent, ServiceEdgeRouterPoliciesPageService, ServiceEdgeRouterPolicyFormComponent, ServiceEdgeRouterPolicyFormService, ServiceFormComponent, ServiceFormService, ServicePoliciesPageComponent, ServicePoliciesPageService, ServicePolicyFormComponent, ServicePolicyFormService, ServicesPageComponent, ServicesPageService, Session, SessionFormComponent, SessionsPageComponent, SessionsPageService, SettingsComponent, SettingsService, SettingsServiceClass, SideModalComponent, SideNavbarComponent, SideNavigatorComponent, SimpleServiceComponent, StringInputComponent, TabNameService, TagSelectorComponent, TerminatorFormComponent, TerminatorFormService, TerminatorsPageComponent, TerminatorsPageService, TextListInputComponent, TransitRouterFormComponent, TransitRouterFormService, TransitRoutersPageComponent, TransitRoutersPageService, ValidationService, VerifyCertificateComponent, VisualizerServiceClass, ZAC_LOGIN_SERVICE, ZAC_VERSION, ZITI_DATA_SERVICE, ZITI_DOMAIN_CONTROLLER, ZITI_NAVIGATOR, ZITI_TAB_OVERRIDES, ZITI_URLS, ZacRoutingModule, ZitiControllerDataService, ZitiDataService, playerFactory };
7786
- export type { CanComponentDeactivate, ExtensionEvent, ExtensionEventType, ExtensionService, FilterObj, HAClusterStatus, HAController, TabInterceptorService, ZitiDomainControllerService, ZitiSessionData };
7935
+ export { APISessionFormComponent, APISessionsPageComponent, API_RESOURCE_TO_ENTITY_PERMISSION, ApiSessionsPageService, AttributesComponent, AuthPoliciesPageComponent, AuthPoliciesPageService, AuthPolicyFormComponent, AuthPolicyFormService, AuthService, BooleanToggleInputComponent, CallbackComponent, CardListComponent, CertificateAuthoritiesPageComponent, CertificateAuthoritiesPageService, CertificateAuthorityFormComponent, CertificateAuthorityFormService, CheckboxListInputComponent, ChipsInputComponent, ConfigEditorComponent, ConfigTypeFormComponent, ConfigTypesPageComponent, ConfigurationFormComponent, ConfigurationService, ConfigurationsPageComponent, CsvDownloadService, DEACTIVATE_GUARD, DEFAULT_APP_CONFIG, DataTableFilterService, DeactivateGuardService, EDGE_ROUTER_EXTENSION_SERVICE, EDGE_ROUTER_POLICY_EXTENSION_SERVICE, EdgeRouter, EdgeRouterFormComponent, EdgeRouterFormService, EdgeRouterPoliciesPageComponent, EdgeRouterPoliciesPageService, EdgeRouterPolicyFormComponent, EdgeRouterPolicyFormService, EdgeRoutersPageComponent, EdgeRoutersPageService, Entity, ExtendableComponent, ExtensionsNoopService, FilterSelectComponent, FilterSelectOptionTemplateDirective, FilterSelectTriggerTemplateDirective, FormFieldContainerComponent, FormFieldToggleComponent, FormHeaderComponent, GeolocateComponent, GrowlerComponent, GrowlerModel, GrowlerModule, GrowlerService, HAControllerService, HaStatusIndicatorComponent, HeaderBarComponent, IDENTITY_EXTENSION_SERVICE, IdentitiesPageComponent, IdentitiesPageService, Identity$1 as Identity, IdentityFormComponent, IdentityFormService, IdentityServicePathComponent, InsecureContextError, JsonViewComponent, JwtSignerFormComponent, JwtSignerFormService, JwtSignersPageComponent, JwtSignersPageService, KEY_CODES, ListPageComponent, ListPageServiceClass, LoadingIndicatorComponent, LoggerService, LoginDialogComponent, LoginServiceClass, ManagementPermissionsService, NetworkVisualizerComponent, NodeDataService, NoopLoginService, NoopTabInterceptorService, NumberInputComponent, OIDC_CLIENT_ID, OIDC_CLIENT_ID_LEGACY, ObjectComponent, OidcEnvironmentalError, OidcSessionUnrecoverableError, OpenZitiConsoleLibModule, PasswordInputComponent, PostureCheckFormComponent, PostureChecksPageComponent, PostureChecksPageService, PreviewListComponent, ProfileComponent, ProgressMeterComponent, ProgressMeterStep, ProgressWizardComponent, ProgressWizardStep, ProjectableForm, ProtocolAddressPortInputComponent, QuickAddComponent, ResetEnrollmentService, SAVE_DENIED_BY_PERMISSION_TOOLTIP, SERVICE_EDGE_ROUTER_POLICY_EXTENSION_SERVICE, SERVICE_EXTENSION_SERVICE, SERVICE_POLICY_EXTENSION_SERVICE, SETTINGS_SERVICE, SHAREDZ_EXTENSION, SelectorInputComponent, ServiceEdgeRouterPoliciesPageComponent, ServiceEdgeRouterPoliciesPageService, ServiceEdgeRouterPolicyFormComponent, ServiceEdgeRouterPolicyFormService, ServiceFormComponent, ServiceFormService, ServicePoliciesPageComponent, ServicePoliciesPageService, ServicePolicyFormComponent, ServicePolicyFormService, ServicesPageComponent, ServicesPageService, Session, SessionFormComponent, SessionRefreshService, SessionsPageComponent, SessionsPageService, SettingsComponent, SettingsService, SettingsServiceClass, SideModalComponent, SideNavbarComponent, SideNavigatorComponent, SimpleServiceComponent, StringInputComponent, TabNameService, TagSelectorComponent, TerminatorFormComponent, TerminatorFormService, TerminatorsPageComponent, TerminatorsPageService, TextListInputComponent, TransitRouterFormComponent, TransitRouterFormService, TransitRoutersPageComponent, TransitRoutersPageService, ValidationService, VerifyCertificateComponent, VisualizerServiceClass, ZAC_LOGIN_SERVICE, ZAC_VERSION, ZITI_DATA_SERVICE, ZITI_DOMAIN_CONTROLLER, ZITI_NAVIGATOR, ZITI_TAB_OVERRIDES, ZITI_URLS, ZacRoutingModule, ZitiControllerDataService, ZitiDataService, ZitiOidcService, decodeJwtPayload, jwtExpMs, jwtIatMs, pkceChallengeS256, playerFactory, randomUrlSafeString };
7936
+ export type { CanComponentDeactivate, ExtensionEvent, ExtensionEventType, ExtensionService, FilterObj, HAClusterStatus, HAController, OidcAuthContext, OidcLoginStep, OidcTokenSet, TabInterceptorService, ZitiDomainControllerService, ZitiSessionData };
7787
7937
  //# sourceMappingURL=index.d.ts.map