Module: authn

Methods

(static) authenticate(host, user, passwordOrUri, optionsopt) → {Promise}

Implements token auth

Parameters:
Name Type Attributes Description
host String

Host to connect to.

user String

User (with admin rights).

passwordOrUri String

Password for user or URI (file, http, https, ARN, etc.) to location containing password.

options Object <optional>

Optional parameters.

Properties
Name Type Attributes Description
product String <optional>

Prouct we are running on. See module:sharedConstants. Default is to determine the product.

port Number <optional>

Port to connect to. Default 443.

passwordIsUri Boolean <optional>

Indicates that password is a URI for the password.

passwordIsToken Boolean <optional>

Indicates that the password is an auth token.

passwordEncrypted Boolean <optional>

Indicates that the password is encrypted.

clOptions Object <optional>

Command line options if called from a script.

logger Object <optional>

Logger to use. Or, pass loggerOptions to get your own logger.

loggerOptions Object <optional>

Options for the logger. See module:logger.getLogger for details.

Returns:

A promise which is resolved with an iControl object to use for future requests or rejected if an error occurs.

Type
Promise