UNPKG

@zowe/imperative

Version:
35 lines 1.53 kB
import * as http from "http"; import * as https from "https"; import * as net from "net"; import { Agent } from "agent-base"; /** * HTTPS Agent that supports certificates stored in the macOS Keychain or Windows Certificate Store, * including non-exportable private keys (e.g. Windows CNG, macOS Secure Enclave). * * On macOS, if the private key is exportable it is used directly by Node's TLS stack. * Otherwise (and always on Windows), TLS is handled by native OS APIs via a Rust helper. */ export declare class KeychainAgent extends Agent { private certAccount; /** * Creates a new KeychainAgent * @param certAccount - The account/label name for the identity in the keychain * @param options - Additional HTTPS agent options */ constructor(certAccount: string, options?: https.AgentOptions); /** * Returns the socket to use for each outgoing request. * @param _req - The outgoing request * @param options - The HTTPS agent options * @returns The socket to use for the request */ connect(_req: http.ClientRequest, options: https.AgentOptions): Promise<net.Socket>; private get keyring(); /** * Non-exportable key path (Windows / macOS Secure Enclave): TLS is handled by a Rust * helper that uses OS APIs (Schannel / Secure Transport) and proxies plaintext over a * local TCP socket, which is returned as a duck-typed TLS socket to Node's HTTP layer. */ private buildPipeSocket; } //# sourceMappingURL=KeychainAgent.d.ts.map