Options
All
  • Public
  • Public/Protected
  • All
Menu

Utility Methods for Zowe

export

Hierarchy

  • SshSession

Index

Constructors

constructor

Properties

Optional hostKeyVerifier

hostKeyVerifier: (info: { changed: boolean; fingerprint: string; key: string; pinnedFingerprint?: string }) => Promise<boolean>

Optional runtime hook, invoked during connection when the server presents a host key that is not already trusted (no ISshSession.hostKey pinned, or the presented key differs from it). It is set by the command handler layer to prompt the user interactively (trust on first use) and is intentionally not part of the serializable ISshSession configuration. When unset (e.g. pure SDK usage with no interactive layer), an untrusted key is rejected.

param

the presented key (base64 blob), its fingerprint, whether it differs from a pinned key, and the pinned key's fingerprint when it does.

returns

a promise resolving to true to trust the key and continue, or false to reject the connection.

Type declaration

    • (info: { changed: boolean; fingerprint: string; key: string; pinnedFingerprint?: string }): Promise<boolean>
    • Parameters

      • info: { changed: boolean; fingerprint: string; key: string; pinnedFingerprint?: string }
        • changed: boolean
        • fingerprint: string
        • key: string
        • Optional pinnedFingerprint?: string

      Returns Promise<boolean>

Private mISshSession

mISshSession: ISshSession

Static Readonly DEFAULT_SSH_PORT

DEFAULT_SSH_PORT: 22 = 22

Default ssh port 22

static
memberof

AbstractSession

Static SSH_CONNECTION_OPTIONS

SSH_CONNECTION_OPTIONS: ICommandOptionDefinition[] = [SshSession.SSH_OPTION_HOST,SshSession.SSH_OPTION_PORT,SshSession.SSH_OPTION_USER,SshSession.SSH_OPTION_PASSWORD,SshSession.SSH_OPTION_PRIVATEKEY,SshSession.SSH_OPTION_KEYPASSPHRASE,SshSession.SSH_OPTION_HANDSHAKETIMEOUT,SshSession.SSH_OPTION_HOSTKEY,SshSession.SSH_OPTION_INSECURE]

Options related to connecting to z/OS SSH These options can be filled in if the user creates a profile

Static SSH_CONNECTION_OPTION_GROUP

SSH_CONNECTION_OPTION_GROUP: string = "z/OS Ssh Connection Options"

Accessors

ISshSession

Static Private log

Methods

Private buildSession

Static createSshSessCfgFromArgs

Object literals

Static SSH_OPTION_HANDSHAKETIMEOUT

SSH_OPTION_HANDSHAKETIMEOUT: object

Option used in profile creation to set handshake timeout. If unset, defaults to no timeout.

aliases

aliases: string[] = ["timeout", "to"]

description

description: string = "How long in milliseconds to wait for the SSH handshake to complete."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "handshakeTimeout"

type

type: string = "number"

Static SSH_OPTION_HOST

SSH_OPTION_HOST: object

Option used in profile creation and commands for hostname for z/OS SSH

aliases

aliases: string[] = ["H"]

description

description: string = "The z/OS SSH server host name."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "host"

required

required: boolean = false

type

type: string = "string"

Static SSH_OPTION_HOSTKEY

SSH_OPTION_HOSTKEY: object

Option used in profile creation and commands to pin the trusted host key of the z/OS SSH server.

aliases

aliases: string[] = ["hk"]

description

description: string = "The trusted host key of the z/OS SSH server, as the base64-encoded key blob presented " +"by the server. When set, the server's key is verified against it before any credentials are sent."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "host-key"

type

type: string = "string"

Static SSH_OPTION_INSECURE

SSH_OPTION_INSECURE: object

Option used in profile creation and commands to skip host key verification.

aliases

aliases: string[] = ["i"]

defaultValue

defaultValue: boolean = false

description

description: string = "Skip verification of the z/OS SSH server's host key, so the server's identity is " +"not confirmed before credentials are sent."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "insecure"

type

type: string = "boolean"

Static SSH_OPTION_KEYPASSPHRASE

SSH_OPTION_KEYPASSPHRASE: object

Option used in profile creation and commands for passphrase for private key

aliases

aliases: string[] = ["passphrase", "kp"]

description

description: string = "Private key passphrase, which unlocks the private key."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "keyPassphrase"

type

type: string = "string"

Static SSH_OPTION_PASSWORD

SSH_OPTION_PASSWORD: object

Option used in profile creation and commands for password/passphrase for z/OS SSH

aliases

aliases: string[] = ["pass", "pw"]

description

description: string = "Mainframe password, which can be the same as your TSO password."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "password"

type

type: string = "string"

Static SSH_OPTION_PORT

SSH_OPTION_PORT: object

Option used in profile creation and commands for port for z/OS SSH

aliases

aliases: string[] = ["P"]

defaultValue

defaultValue: number = 22

description

description: string = "The z/OS SSH server port."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "port"

type

type: string = "number"

Static SSH_OPTION_PRIVATEKEY

SSH_OPTION_PRIVATEKEY: object

Option used in profile creation and commands for private key path

aliases

aliases: string[] = ["key", "pk"]

description

description: string = "Path to a file containing your private key, that must match a public key stored in the server for authentication"

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "privateKey"

type

type: string = "string"

Static SSH_OPTION_USER

SSH_OPTION_USER: object

Option used in profile creation and commands for username / ID for z/OS SSH

aliases

aliases: string[] = ["u"]

description

description: string = "Mainframe user name, which can be the same as your TSO login."

group

group: string = SshSession.SSH_CONNECTION_OPTION_GROUP

name

name: string = "user"

required

required: boolean = false

type

type: string = "string"

Generated using TypeDoc