@microsoft/dev-tunnels-ssh
Version:
SSH library for Dev Tunnels
80 lines • 3.88 kB
TypeScript
/**
* SSH trace event level.
*/
export declare enum TraceLevel {
Error = "error",
Warning = "warning",
Info = "info",
Verbose = "verbose"
}
/**
* Signature for a function that handles SSH trace events.
*
* @param level The level of message being traced: error, warning, info, or verbose.
* @param eventId An integer that identifies the type of event. Normally this is one of
* the values from `SshTraceEventIds`, but extensions may define additional event IDs.
* @param msg A description of the event (non-localized).
* @param err Optional `Error` object associated with the event, often included with
* warning or error events. While the `Error.message` property is typically included as
* (part of) the `msg` parameter, the error object may contain additional useful context
* such as the stack trace.
*/
export type Trace = (level: TraceLevel, eventId: number, msg: string, err?: Error) => void;
export declare class SshTraceEventIds {
static readonly unknownError: number;
static readonly streamReadError: number;
static readonly streamWriteError: number;
static readonly streamCloseError: number;
static readonly sendMessageFailed: number;
static readonly receiveMessageFailed: number;
static readonly handleMessageFailed: number;
static readonly serverAuthenticationFailed: number;
static readonly clientAuthenticationFailed: number;
static readonly authenticationError: number;
static readonly channelWindowAdjustFailed: number;
static readonly channelWaitForWindowAdjust: number;
static readonly sessionReconnectInitFailed: number;
static readonly serverSessionReconnectFailed: number;
static readonly clientSessionReconnectFailed: number;
static readonly sessionRequestFailed: number;
static readonly channelRequestFailed: number;
static readonly serverListenFailed: number;
static readonly portForwardServerListenFailed: number;
static readonly portForwardRequestInvalid: number;
static readonly portForwardChannelInvalid: number;
static readonly portForwardChannelOpenFailed: number;
static readonly portForwardConnectionFailed: number;
static readonly metricsError: number;
static readonly keepAliveFailed: number;
static readonly keepAliveRequestReceived: number;
static readonly keepAliveResponseNotReceived: number;
static readonly protocolVersion: number;
static readonly sendingMessage: number;
static readonly receivingMessage: number;
static readonly sendingChannelData: number;
static readonly receivingChannelData: number;
static readonly sessionEncrypted: number;
static readonly sessionAuthenticating: number;
static readonly sessionAuthenticated: number;
static readonly sessionClosing: number;
static readonly sessionConnecting: number;
static readonly channelOpened: number;
static readonly channelOpenFailed: number;
static readonly channelEofReceived: number;
static readonly channelClosed: number;
static readonly serverListening: number;
static readonly serverClientConnected: number;
static readonly portForwardServerListening: number;
static readonly portForwardConnectionAccepted: number;
static readonly portForwardChannelOpened: number;
static readonly portForwardChannelClosed: number;
static readonly portForwardConnectionOpened: number;
static readonly portForwardConnectionClosed: number;
static readonly sessionDisconnected: number;
static readonly clientSessionReconnecting: number;
static readonly serverSessionReconnecting: number;
static readonly clientSessionStartReconnecting: number;
static readonly algorithmNegotiation: number;
static readonly debugMessage: number;
}
//# sourceMappingURL=trace.d.ts.map