Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type aliases

SecureVersion

SecureVersion: "TLSv1.3" | "TLSv1.2" | "TLSv1.1" | "TLSv1"

Variables

Const CLIENT_RENEG_LIMIT

CLIENT_RENEG_LIMIT: number

Const CLIENT_RENEG_WINDOW

CLIENT_RENEG_WINDOW: number

Let DEFAULT_ECDH_CURVE

DEFAULT_ECDH_CURVE: string

The default curve name to use for ECDH key agreement in a tls server. The default value is 'auto'. See tls.createSecureContext() for further information.

Let DEFAULT_MAX_VERSION

DEFAULT_MAX_VERSION: SecureVersion

The default value of the maxVersion option of tls.createSecureContext(). It can be assigned any of the supported TLS protocol versions, 'TLSv1.3', 'TLSv1.2', 'TLSv1.1', or 'TLSv1'. Default: 'TLSv1.3', unless changed using CLI options. Using --tls-max-v1.2 sets the default to 'TLSv1.2'. Using --tls-max-v1.3 sets the default to 'TLSv1.3'. If multiple of the options are provided, the highest maximum is used.

Let DEFAULT_MIN_VERSION

DEFAULT_MIN_VERSION: SecureVersion

The default value of the minVersion option of tls.createSecureContext(). It can be assigned any of the supported TLS protocol versions, 'TLSv1.3', 'TLSv1.2', 'TLSv1.1', or 'TLSv1'. Default: 'TLSv1.2', unless changed using CLI options. Using --tls-min-v1.0 sets the default to 'TLSv1'. Using --tls-min-v1.1 sets the default to 'TLSv1.1'. Using --tls-min-v1.3 sets the default to 'TLSv1.3'. If multiple of the options are provided, the lowest minimum is used.

Const rootCertificates

rootCertificates: ReadonlyArray<string>

An immutable array of strings representing the root certificates (in PEM format) used for verifying peer certificates. This is the default value of the ca option to tls.createSecureContext().

Functions

checkServerIdentity

  • Parameters

    Returns Error | undefined

connect

  • Parameters

    • options: ConnectionOptions
    • Optional secureConnectListener: function
        • (): void
        • Returns void

    Returns TLSSocket

  • Parameters

    • port: number
    • Optional host: string
    • Optional options: ConnectionOptions
    • Optional secureConnectListener: function
        • (): void
        • Returns void

    Returns TLSSocket

  • Parameters

    • port: number
    • Optional options: ConnectionOptions
    • Optional secureConnectListener: function
        • (): void
        • Returns void

    Returns TLSSocket

createSecureContext

createSecurePair

  • createSecurePair(credentials?: SecureContext, isServer?: boolean, requestCert?: boolean, rejectUnauthorized?: boolean): SecurePair
  • deprecated

    since v0.11.3 Use tls.TLSSocket instead.

    Parameters

    • Optional credentials: SecureContext
    • Optional isServer: boolean
    • Optional requestCert: boolean
    • Optional rejectUnauthorized: boolean

    Returns SecurePair

createServer

  • createServer(secureConnectionListener?: function): Server
  • createServer(options: TlsOptions, secureConnectionListener?: function): Server
  • Parameters

    • Optional secureConnectionListener: function

    Returns Server

  • Parameters

    Returns Server

getCiphers

  • getCiphers(): string[]
  • Returns string[]

Generated using TypeDoc