Table of Contents

Class PasswordEvidence

Namespace
MongoDB.Driver
Assembly
MongoDB.Driver.dll

Evidence of a MongoIdentity via a shared secret.

public sealed class PasswordEvidence : MongoIdentityEvidence
Inheritance
PasswordEvidence
Inherited Members

Constructors

PasswordEvidence(SecureString)

Initializes a new instance of the PasswordEvidence class. Less secure when used in conjunction with SCRAM-SHA-256, due to the need to store the password in a managed string in order to SaslPrep it. See Driver Authentication: SCRAM-SHA-256 for additional details.

public PasswordEvidence(SecureString password)

Parameters

password SecureString

The password.

PasswordEvidence(string)

Initializes a new instance of the PasswordEvidence class.

public PasswordEvidence(string password)

Parameters

password string

The password.

Properties

SecurePassword

Gets the password.

public SecureString SecurePassword { get; }

Property Value

SecureString

Methods

Equals(object)

Determines whether the specified object is equal to this instance.

public override bool Equals(object rhs)

Parameters

rhs object

The object to compare with this instance.

Returns

bool

true if the specified object is equal to this instance; otherwise, false.

GetHashCode()

Returns a hash code for this instance.

public override int GetHashCode()

Returns

int

A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.