push neon reactor
This commit is contained in:
1 parent
172e72dbcd
commit
aeab5f7820
9597 files changed
+2407488
No files matched your search
Generated
Vendored
+2240
File diff suppressed because it is too large.
Load diff
Generated
Vendored
+1
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"msal-node-extensions.cjs","sources":["../../src/utils/Constants.ts","../../src/error/PersistenceError.ts","../../src/utils/TypeGuards.ts","../../src/lock/CrossPlatformLock.ts","../../src/persistence/PersistenceCachePlugin.ts","../../../lib/msal-common/dist/utils/Constants.mjs","../../../lib/msal-common/dist/error/AuthError.mjs","../../../lib/msal-common/dist/error/ClientAuthErrorCodes.mjs","../../../lib/msal-common/dist/error/ClientAuthError.mjs","../../../lib/msal-common/dist/logger/Logger.mjs","../../../lib/msal-common/dist/utils/TimeUtils.mjs","../../../lib/msal-common/dist/error/ClientConfigurationErrorCodes.mjs","../../../lib/msal-common/dist/error/ClientConfigurationError.mjs","../../../lib/msal-common/dist/constants/AADServerParamKeys.mjs","../../../lib/msal-common/dist/error/ServerError.mjs","../../../lib/msal-common/dist/error/InteractionRequiredAuthError.mjs","../../../lib/msal-common/dist/telemetry/server/ServerTelemetryManager.mjs","../../src/persistence/BasePersistence.ts","../../src/persistence/FilePersistence.ts","../../src/Dpapi.ts","../../src/persistence/DataProtectionScope.ts","../../src/persistence/FilePersistenceWithDataProtection.ts","../../src/persistence/KeychainPersistence.ts","../../src/persistence/LibSecretPersistence.ts","../../src/utils/Environment.ts","../../src/persistence/PersistenceCreator.ts","../../src/error/NativeAuthError.ts","../../src/packageMetadata.ts","../../src/broker/NativeBrokerPlugin.ts"],"sourcesContent":[null,null,null,null,null,"/*! @azure/msal-common v15.8.1 2025-07-08 */\n'use strict';\n/*\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * Licensed under the MIT License.\r\n */\r\nconst Constants = {\r\n LIBRARY_NAME: \"MSAL.JS\",\r\n SKU: \"msal.js.common\",\r\n // Prefix for all library cache entries\r\n CACHE_PREFIX: \"msal\",\r\n // default authority\r\n DEFAULT_AUTHORITY: \"https://login.microsoftonline.com/common/\",\r\n DEFAULT_AUTHORITY_HOST: \"login.microsoftonline.com\",\r\n DEFAULT_COMMON_TENANT: \"common\",\r\n // ADFS String\r\n ADFS: \"adfs\",\r\n DSTS: \"dstsv2\",\r\n // Default AAD Instance Discovery Endpoint\r\n AAD_INSTANCE_DISCOVERY_ENDPT: \"https://login.microsoftonline.com/common/discovery/instance?api-version=1.1&authorization_endpoint=\",\r\n // CIAM URL\r\n CIAM_AUTH_URL: \".ciamlogin.com\",\r\n AAD_TENANT_DOMAIN_SUFFIX: \".onmicrosoft.com\",\r\n // Resource delimiter - used for certain cache entries\r\n RESOURCE_DELIM: \"|\",\r\n // Placeholder for non-existent account ids/objects\r\n NO_ACCOUNT: \"NO_ACCOUNT\",\r\n // Claims\r\n CLAIMS: \"claims\",\r\n // Consumer UTID\r\n CONSUMER_UTID: \"9188040d-6c67-4c5b-b112-36a304b66dad\",\r\n // Default scopes\r\n OPENID_SCOPE: \"openid\",\r\n PROFILE_SCOPE: \"profile\",\r\n OFFLINE_ACCESS_SCOPE: \"offline_access\",\r\n EMAIL_SCOPE: \"email\",\r\n CODE_GRANT_TYPE: \"authorization_code\",\r\n RT_GRANT_TYPE: \"refresh_token\",\r\n S256_CODE_CHALLENGE_METHOD: \"S256\",\r\n URL_FORM_CONTENT_TYPE: \"application/x-www-form-urlencoded;charset=utf-8\",\r\n AUTHORIZATION_PENDING: \"authorization_pending\",\r\n NOT_DEFINED: \"not_defined\",\r\n EMPTY_STRING: \"\",\r\n NOT_APPLICABLE: \"N/A\",\r\n NOT_AVAILABLE: \"Not Available\",\r\n FORWARD_SLASH: \"/\",\r\n IMDS_ENDPOINT: \"http://169.254.169.254/metadata/instance/compute/location\",\r\n IMDS_VERSION: \"2020-06-01\",\r\n IMDS_TIMEOUT: 2000,\r\n AZURE_REGION_AUTO_DISCOVER_FLAG: \"TryAutoDetect\",\r\n REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX: \"login.microsoft.com\",\r\n KNOWN_PUBLIC_CLOUDS: [\r\n \"login.microsoftonline.com\",\r\n \"login.windows.net\",\r\n \"login.microsoft.com\",\r\n \"sts.windows.net\",\r\n ],\r\n SHR_NONCE_VALIDITY: 240,\r\n INVALID_INSTANCE: \"invalid_instance\",\r\n};\r\nconst HttpStatus = {\r\n SUCCESS: 200,\r\n SUCCESS_RANGE_START: 200,\r\n SUCCESS_RANGE_END: 299,\r\n REDIRECT: 302,\r\n CLIENT_ERROR: 400,\r\n CLIENT_ERROR_RANGE_START: 400,\r\n BAD_REQUEST: 400,\r\n UNAUTHORIZED: 401,\r\n NOT_FOUND: 404,\r\n REQUEST_TIMEOUT: 408,\r\n GONE: 410,\r\n TOO_MANY_REQUESTS: 429,\r\n CLIENT_ERROR_RANGE_END: 499,\r\n SERVER_ERROR: 500,\r\n SERVER_ERROR_RANGE_START: 500,\r\n SERVICE_UNAVAILABLE: 503,\r\n GATEWAY_TIMEOUT: 504,\r\n SERVER_ERROR_RANGE_END: 599,\r\n MULTI_SIDED_ERROR: 600,\r\n};\r\nconst OIDC_DEFAULT_SCOPES = [\r\n Constants.OPENID_SCOPE,\r\n Constants.PROFILE_SCOPE,\r\n Constants.OFFLINE_ACCESS_SCOPE,\r\n];\r\nconst OIDC_SCOPES = [...OIDC_DEFAULT_SCOPES, Constants.EMAIL_SCOPE];\r\n/**\r\n * Request header names\r\n */\r\nconst HeaderNames = {\r\n CONTENT_TYPE: \"Content-Type\",\r\n CONTENT_LENGTH: \"Content-Length\",\r\n RETRY_AFTER: \"Retry-After\",\r\n CCS_HEADER: \"X-AnchorMailbox\",\r\n WWWAuthenticate: \"WWW-Authenticate\",\r\n AuthenLine truncated
|
||||
+1
@@ -0,0 +1 @@
|
||||
{"type":"commonjs"}
|
||||
Generated
Vendored
+6
@@ -0,0 +1,6 @@
|
||||
export interface DpapiBindings {
|
||||
protectData(dataToEncrypt: Uint8Array, optionalEntropy: Uint8Array | null, scope: string): Uint8Array;
|
||||
unprotectData(encryptData: Uint8Array, optionalEntropy: Uint8Array | null, scope: string): Uint8Array;
|
||||
}
|
||||
declare let Dpapi: DpapiBindings;
|
||||
export { Dpapi };
|
||||
Generated
Vendored
+21
@@ -0,0 +1,21 @@
|
||||
/// <reference types="node" resolution-mode="require"/>
|
||||
/// <reference types="node" resolution-mode="require"/>
|
||||
import { AccountInfo, AuthenticationResult, INativeBrokerPlugin, LoggerOptions, NativeRequest, NativeSignOutRequest } from "@azure/msal-common/node";
|
||||
export declare class NativeBrokerPlugin implements INativeBrokerPlugin {
|
||||
private logger;
|
||||
isBrokerAvailable: boolean;
|
||||
constructor();
|
||||
setLogger(loggerOptions: LoggerOptions): void;
|
||||
getAccountById(accountId: string, correlationId: string): Promise<AccountInfo>;
|
||||
getAllAccounts(clientId: string, correlationId: string): Promise<AccountInfo[]>;
|
||||
acquireTokenSilent(request: NativeRequest): Promise<AuthenticationResult>;
|
||||
acquireTokenInteractive(request: NativeRequest, providedWindowHandle?: Buffer): Promise<AuthenticationResult>;
|
||||
signOut(request: NativeSignOutRequest): Promise<void>;
|
||||
private getAccount;
|
||||
private readAccountById;
|
||||
private generateRequestParameters;
|
||||
private getAuthenticationResult;
|
||||
private generateAccountInfo;
|
||||
private isMsalRuntimeError;
|
||||
private wrapError;
|
||||
}
|
||||
Generated
Vendored
+6
@@ -0,0 +1,6 @@
|
||||
import { AuthError } from "@azure/msal-common/node";
|
||||
export declare class NativeAuthError extends AuthError {
|
||||
statusCode: number;
|
||||
tag: number;
|
||||
constructor(errorStatus: string, errorContext: string, errorCode: number, errorTag: number);
|
||||
}
|
||||
Generated
Vendored
+57
@@ -0,0 +1,57 @@
|
||||
/**
|
||||
* Error thrown when trying to write MSAL cache to persistence.
|
||||
*/
|
||||
export declare class PersistenceError extends Error {
|
||||
errorCode: string;
|
||||
errorMessage: string;
|
||||
constructor(errorCode: string, errorMessage: string);
|
||||
/**
|
||||
* Error thrown when trying to access the file system.
|
||||
*/
|
||||
static createFileSystemError(errorCode: string, errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Error thrown when trying to write, load, or delete data from secret service on linux.
|
||||
* Libsecret is used to access secret service.
|
||||
*/
|
||||
static createLibSecretError(errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Error thrown when trying to write, load, or delete data from keychain on macOs.
|
||||
*/
|
||||
static createKeychainPersistenceError(errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Error thrown when trying to encrypt or decrypt data using DPAPI on Windows.
|
||||
*/
|
||||
static createFilePersistenceWithDPAPIError(errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Error thrown when using the cross platform lock.
|
||||
*/
|
||||
static createCrossPlatformLockError(errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Throw cache persistence error
|
||||
*
|
||||
* @param errorMessage string
|
||||
* @returns PersistenceError
|
||||
*/
|
||||
static createCachePersistenceError(errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Throw unsupported error
|
||||
*
|
||||
* @param errorMessage string
|
||||
* @returns PersistenceError
|
||||
*/
|
||||
static createNotSupportedError(errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Throw persistence not verified error
|
||||
*
|
||||
* @param errorMessage string
|
||||
* @returns PersistenceError
|
||||
*/
|
||||
static createPersistenceNotVerifiedError(errorMessage: string): PersistenceError;
|
||||
/**
|
||||
* Throw persistence creation validation error
|
||||
*
|
||||
* @param errorMessage string
|
||||
* @returns PersistenceError
|
||||
*/
|
||||
static createPersistenceNotValidatedError(errorMessage: string): PersistenceError;
|
||||
}
|
||||
Generated
Vendored
+12
@@ -0,0 +1,12 @@
|
||||
export { PersistenceCachePlugin } from "./persistence/PersistenceCachePlugin.js";
|
||||
export { FilePersistence } from "./persistence/FilePersistence.js";
|
||||
export { FilePersistenceWithDataProtection } from "./persistence/FilePersistenceWithDataProtection.js";
|
||||
export { DataProtectionScope } from "./persistence/DataProtectionScope.js";
|
||||
export { KeychainPersistence } from "./persistence/KeychainPersistence.js";
|
||||
export { LibSecretPersistence } from "./persistence/LibSecretPersistence.js";
|
||||
export { IPersistence } from "./persistence/IPersistence.js";
|
||||
export { CrossPlatformLockOptions } from "./lock/CrossPlatformLockOptions.js";
|
||||
export { PersistenceCreator } from "./persistence/PersistenceCreator.js";
|
||||
export { IPersistenceConfiguration } from "./persistence/IPersistenceConfiguration.js";
|
||||
export { Environment } from "./utils/Environment.js";
|
||||
export { NativeBrokerPlugin } from "./broker/NativeBrokerPlugin.js";
|
||||
Generated
Vendored
+24
@@ -0,0 +1,24 @@
|
||||
import { CrossPlatformLockOptions } from "./CrossPlatformLockOptions.js";
|
||||
import { Logger } from "@azure/msal-common/node";
|
||||
/**
|
||||
* Cross-process lock that works on all platforms.
|
||||
*/
|
||||
export declare class CrossPlatformLock {
|
||||
private readonly lockFilePath;
|
||||
private lockFileHandle;
|
||||
private readonly retryNumber;
|
||||
private readonly retryDelay;
|
||||
private logger;
|
||||
constructor(lockFilePath: string, logger: Logger, lockOptions?: CrossPlatformLockOptions);
|
||||
/**
|
||||
* Locks cache from read or writes by creating file with same path and name as
|
||||
* cache file but with .lockfile extension. If another process has already created
|
||||
* the lockfile, will back off and retry based on configuration settings set by CrossPlatformLockOptions
|
||||
*/
|
||||
lock(): Promise<void>;
|
||||
/**
|
||||
* unlocks cache file by deleting .lockfile.
|
||||
*/
|
||||
unlock(): Promise<void>;
|
||||
private sleep;
|
||||
}
|
||||
Generated
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
/**
|
||||
* Options for CrossPlatform lock.
|
||||
*
|
||||
* retryNumber: Numbers of times we should try to acquire a lock. Defaults to 500.
|
||||
* retryDelay: Time to wait before trying to retry a lock acquisition. Defaults to 100 ms.
|
||||
*/
|
||||
export type CrossPlatformLockOptions = {
|
||||
retryNumber: number;
|
||||
retryDelay: number;
|
||||
};
|
||||
Generated
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
export declare const name = "@azure/msal-node-extensions";
|
||||
export declare const version = "1.5.17";
|
||||
Generated
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
import { IPersistence } from "./IPersistence.js";
|
||||
export declare abstract class BasePersistence {
|
||||
abstract createForPersistenceValidation(): Promise<IPersistence>;
|
||||
verifyPersistence(): Promise<boolean>;
|
||||
}
|
||||
Generated
Vendored
+16
@@ -0,0 +1,16 @@
|
||||
/**
|
||||
* Specifies the scope of the data protection - either the current user or the local
|
||||
* machine.
|
||||
*
|
||||
* You do not need a key to protect or unprotect the data.
|
||||
* If you set the Scope to CurrentUser, only applications running on your credentials can
|
||||
* unprotect the data; however, that means that any application running on your credentials
|
||||
* can access the protected data. If you set the Scope to LocalMachine, any full-trust
|
||||
* application on the computer can unprotect, access, and modify the data.
|
||||
*
|
||||
*/
|
||||
export declare const DataProtectionScope: {
|
||||
readonly CurrentUser: "CurrentUser";
|
||||
readonly LocalMachine: "LocalMachine";
|
||||
};
|
||||
export type DataProtectionScope = (typeof DataProtectionScope)[keyof typeof DataProtectionScope];
|
||||
Generated
Vendored
+29
@@ -0,0 +1,29 @@
|
||||
import { IPersistence } from "./IPersistence.js";
|
||||
import { Logger, LoggerOptions } from "@azure/msal-common/node";
|
||||
import { BasePersistence } from "./BasePersistence.js";
|
||||
/**
|
||||
* Reads and writes data to file specified by file location. File contents are not
|
||||
* encrypted.
|
||||
*
|
||||
* If file or directory has not been created, it FilePersistence.create() will create
|
||||
* file and any directories in the path recursively.
|
||||
*/
|
||||
export declare class FilePersistence extends BasePersistence implements IPersistence {
|
||||
private filePath;
|
||||
private logger;
|
||||
private constructor();
|
||||
static create(fileLocation: string, loggerOptions?: LoggerOptions): Promise<FilePersistence>;
|
||||
save(contents: string): Promise<void>;
|
||||
saveBuffer(contents: Uint8Array): Promise<void>;
|
||||
load(): Promise<string | null>;
|
||||
loadBuffer(): Promise<Uint8Array>;
|
||||
delete(): Promise<boolean>;
|
||||
getFilePath(): string;
|
||||
reloadNecessary(lastSync: number): Promise<boolean>;
|
||||
getLogger(): Logger;
|
||||
createForPersistenceValidation(): Promise<FilePersistence>;
|
||||
private static createDefaultLoggerOptions;
|
||||
private timeLastModified;
|
||||
private createCacheFile;
|
||||
private createFileDirectory;
|
||||
}
|
||||
Generated
Vendored
+24
@@ -0,0 +1,24 @@
|
||||
import { IPersistence } from "./IPersistence.js";
|
||||
import { DataProtectionScope } from "./DataProtectionScope.js";
|
||||
import { Logger, LoggerOptions } from "@azure/msal-common/node";
|
||||
import { BasePersistence } from "./BasePersistence.js";
|
||||
/**
|
||||
* Uses CryptProtectData and CryptUnprotectData on Windows to encrypt and decrypt file contents.
|
||||
*
|
||||
* scope: Scope of the data protection. Either local user or the current machine
|
||||
* optionalEntropy: Password or other additional entropy used to encrypt the data
|
||||
*/
|
||||
export declare class FilePersistenceWithDataProtection extends BasePersistence implements IPersistence {
|
||||
private filePersistence;
|
||||
private scope;
|
||||
private optionalEntropy;
|
||||
private constructor();
|
||||
static create(fileLocation: string, scope: DataProtectionScope, optionalEntropy?: string, loggerOptions?: LoggerOptions): Promise<FilePersistenceWithDataProtection>;
|
||||
save(contents: string): Promise<void>;
|
||||
load(): Promise<string | null>;
|
||||
delete(): Promise<boolean>;
|
||||
reloadNecessary(lastSync: number): Promise<boolean>;
|
||||
getFilePath(): string;
|
||||
getLogger(): Logger;
|
||||
createForPersistenceValidation(): Promise<FilePersistenceWithDataProtection>;
|
||||
}
|
||||
CodeApp_NeonReactor/node_modules/@azure/msal-node-extensions/lib/types/persistence/IPersistence.d.ts
Generated
Vendored
+11
@@ -0,0 +1,11 @@
|
||||
import { Logger } from "@azure/msal-common/node";
|
||||
export interface IPersistence {
|
||||
save(contents: string): Promise<void>;
|
||||
load(): Promise<string | null>;
|
||||
delete(): Promise<boolean>;
|
||||
reloadNecessary(lastSync: number): Promise<boolean>;
|
||||
getFilePath(): string;
|
||||
getLogger(): Logger;
|
||||
verifyPersistence(): Promise<boolean>;
|
||||
createForPersistenceValidation(): Promise<IPersistence>;
|
||||
}
|
||||
Generated
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
import type { LoggerOptions } from "@azure/msal-common/node";
|
||||
import { DataProtectionScope } from "./DataProtectionScope.js";
|
||||
export interface IPersistenceConfiguration {
|
||||
cachePath?: string;
|
||||
dataProtectionScope?: DataProtectionScope;
|
||||
serviceName?: string;
|
||||
accountName?: string;
|
||||
usePlaintextFileOnLinux?: boolean;
|
||||
loggerOptions?: LoggerOptions;
|
||||
}
|
||||
Generated
Vendored
+23
@@ -0,0 +1,23 @@
|
||||
import { IPersistence } from "./IPersistence.js";
|
||||
import { Logger, LoggerOptions } from "@azure/msal-common/node";
|
||||
import { BasePersistence } from "./BasePersistence.js";
|
||||
/**
|
||||
* Uses reads and writes passwords to macOS keychain
|
||||
*
|
||||
* serviceName: Identifier used as key for whatever value is stored
|
||||
* accountName: Account under which password should be stored
|
||||
*/
|
||||
export declare class KeychainPersistence extends BasePersistence implements IPersistence {
|
||||
protected readonly serviceName: string;
|
||||
protected readonly accountName: string;
|
||||
private filePersistence;
|
||||
private constructor();
|
||||
static create(fileLocation: string, serviceName: string, accountName: string, loggerOptions?: LoggerOptions): Promise<KeychainPersistence>;
|
||||
save(contents: string): Promise<void>;
|
||||
load(): Promise<string | null>;
|
||||
delete(): Promise<boolean>;
|
||||
reloadNecessary(lastSync: number): Promise<boolean>;
|
||||
getFilePath(): string;
|
||||
getLogger(): Logger;
|
||||
createForPersistenceValidation(): Promise<KeychainPersistence>;
|
||||
}
|
||||
Generated
Vendored
+24
@@ -0,0 +1,24 @@
|
||||
import { IPersistence } from "./IPersistence.js";
|
||||
import { Logger, LoggerOptions } from "@azure/msal-common/node";
|
||||
import { BasePersistence } from "./BasePersistence.js";
|
||||
/**
|
||||
* Uses reads and writes passwords to Secret Service API/libsecret. Requires libsecret
|
||||
* to be installed.
|
||||
*
|
||||
* serviceName: Identifier used as key for whatever value is stored
|
||||
* accountName: Account under which password should be stored
|
||||
*/
|
||||
export declare class LibSecretPersistence extends BasePersistence implements IPersistence {
|
||||
protected readonly serviceName: string;
|
||||
protected readonly accountName: string;
|
||||
private filePersistence;
|
||||
private constructor();
|
||||
static create(fileLocation: string, serviceName: string, accountName: string, loggerOptions?: LoggerOptions): Promise<LibSecretPersistence>;
|
||||
save(contents: string): Promise<void>;
|
||||
load(): Promise<string | null>;
|
||||
delete(): Promise<boolean>;
|
||||
reloadNecessary(lastSync: number): Promise<boolean>;
|
||||
getFilePath(): string;
|
||||
getLogger(): Logger;
|
||||
createForPersistenceValidation(): Promise<LibSecretPersistence>;
|
||||
}
|
||||
Generated
Vendored
+38
@@ -0,0 +1,38 @@
|
||||
import { IPersistence } from "./IPersistence.js";
|
||||
import { CrossPlatformLockOptions } from "../lock/CrossPlatformLockOptions.js";
|
||||
import { TokenCacheContext, ICachePlugin } from "@azure/msal-common/node";
|
||||
/**
|
||||
* MSAL cache plugin which enables callers to write the MSAL cache to disk on Windows,
|
||||
* macOs, and Linux.
|
||||
*
|
||||
* - Persistence can be one of:
|
||||
* - FilePersistence: Writes and reads from an unencrypted file. Can be used on Windows,
|
||||
* macOs, or Linux.
|
||||
* - FilePersistenceWithDataProtection: Used on Windows, writes and reads from file encrypted
|
||||
* with windows dpapi-addon.
|
||||
* - KeychainPersistence: Used on macOs, writes and reads from keychain.
|
||||
* - LibSecretPersistence: Used on linux, writes and reads from secret service API. Requires
|
||||
* libsecret be installed.
|
||||
*/
|
||||
export declare class PersistenceCachePlugin implements ICachePlugin {
|
||||
persistence: IPersistence;
|
||||
lastSync: number;
|
||||
currentCache: string | null;
|
||||
lockFilePath: string;
|
||||
private crossPlatformLock;
|
||||
private logger;
|
||||
constructor(persistence: IPersistence, lockOptions?: CrossPlatformLockOptions);
|
||||
/**
|
||||
* Reads from storage and saves an in-memory copy. If persistence has not been updated
|
||||
* since last time data was read, in memory copy is used.
|
||||
*
|
||||
* If cacheContext.cacheHasChanged === true, then file lock is created and not deleted until
|
||||
* afterCacheAccess() is called, to prevent the cache file from changing in between
|
||||
* beforeCacheAccess() and afterCacheAccess().
|
||||
*/
|
||||
beforeCacheAccess(cacheContext: TokenCacheContext): Promise<void>;
|
||||
/**
|
||||
* Writes to storage if MSAL in memory copy of cache has been changed.
|
||||
*/
|
||||
afterCacheAccess(cacheContext: TokenCacheContext): Promise<void>;
|
||||
}
|
||||
Generated
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
import { IPersistence } from "./IPersistence.js";
|
||||
import { IPersistenceConfiguration } from "./IPersistenceConfiguration.js";
|
||||
export declare class PersistenceCreator {
|
||||
static createPersistence(config: IPersistenceConfiguration): Promise<IPersistence>;
|
||||
}
|
||||
Generated
Vendored
+54
@@ -0,0 +1,54 @@
|
||||
export declare const Constants: {
|
||||
/**
|
||||
* An existing file was the target of an operation that required that the target not exist
|
||||
*/
|
||||
EEXIST_ERROR: string;
|
||||
/**
|
||||
* No such file or directory: Commonly raised by fs operations to indicate that a component
|
||||
* of the specified pathname does not exist. No entity (file or directory) could be found
|
||||
* by the given path
|
||||
*/
|
||||
ENOENT_ERROR: string;
|
||||
/**
|
||||
* Operation not permitted. An attempt was made to perform an operation that requires
|
||||
* elevated privileges.
|
||||
*/
|
||||
EPERM_ERROR: string;
|
||||
/**
|
||||
* Default service name for using MSAL Keytar
|
||||
*/
|
||||
DEFAULT_SERVICE_NAME: string;
|
||||
/**
|
||||
* Test data used to verify underlying persistence mechanism
|
||||
*/
|
||||
PERSISTENCE_TEST_DATA: string;
|
||||
/**
|
||||
* This is the value of a the guid if the process is being ran by the root user
|
||||
*/
|
||||
LINUX_ROOT_USER_GUID: number;
|
||||
/**
|
||||
* List of environment variables
|
||||
*/
|
||||
ENVIRONMENT: {
|
||||
HOME: string;
|
||||
LOGNAME: string;
|
||||
USER: string;
|
||||
LNAME: string;
|
||||
USERNAME: string;
|
||||
PLATFORM: string;
|
||||
LOCAL_APPLICATION_DATA: string;
|
||||
};
|
||||
DEFAULT_CACHE_FILE_NAME: string;
|
||||
};
|
||||
export declare const Platform: {
|
||||
readonly WINDOWS: "win32";
|
||||
readonly LINUX: "linux";
|
||||
readonly MACOS: "darwin";
|
||||
};
|
||||
export type Platform = (typeof Platform)[keyof typeof Platform];
|
||||
export declare const ErrorCodes: {
|
||||
readonly INTERATION_REQUIRED_ERROR_CODE: "interaction_required";
|
||||
readonly SERVER_UNAVAILABLE: "server_unavailable";
|
||||
readonly UNKNOWN: "unknown_error";
|
||||
};
|
||||
export type ErrorCodes = (typeof ErrorCodes)[keyof typeof ErrorCodes];
|
||||
Generated
Vendored
+16
@@ -0,0 +1,16 @@
|
||||
export declare class Environment {
|
||||
static get homeEnvVar(): string;
|
||||
static get lognameEnvVar(): string;
|
||||
static get userEnvVar(): string;
|
||||
static get lnameEnvVar(): string;
|
||||
static get usernameEnvVar(): string;
|
||||
static getEnvironmentVariable(name: string): string;
|
||||
static getEnvironmentPlatform(): string;
|
||||
static isWindowsPlatform(): boolean;
|
||||
static isLinuxPlatform(): boolean;
|
||||
static isMacPlatform(): boolean;
|
||||
static isLinuxRootUser(): boolean;
|
||||
static getUserRootDirectory(): string | null;
|
||||
static getUserHomeDirOnWindows(): string;
|
||||
static getUserHomeDirOnUnix(): string | null;
|
||||
}
|
||||
Generated
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
/// <reference types="node" resolution-mode="require"/>
|
||||
/**
|
||||
* Returns whether or not the given object is a Node.js error
|
||||
*/
|
||||
export declare const isNodeError: (error: unknown) => error is NodeJS.ErrnoException;
|
||||
Reference in new issue
Block a user