Class: PlainTextAuthProvider

auth~PlainTextAuthProvider(username, password)

Provides plain text Authenticator instances to be used when connecting to a host.

Constructor

new PlainTextAuthProvider(username, password)

Creates a new instance of the Authenticator provider

Extends:
Parameters:
Name Type Description
username String

User name in plain text

password String

Password in plain text

Source:
Example
var authProvider = new cassandra.auth.PlainTextAuthProvider('my_user', 'p@ssword1!');
//Set the auth provider in the clientOptions when creating the Client instance
const client = new Client({ contactPoints: contactPoints, authProvider: authProvider });

Extends

Methods

newAuthenticator(endpoint, name) → {Authenticator}

Returns a new Authenticator instance to be used for plain text authentication.

Parameters:
Name Type Description
endpoint String

The ip address and port number in the format ip:port

name String

Authenticator name

Overrides:
Source:
Returns:
Type
Authenticator