• Home
  • API Documentation
Show / Hide Table of Contents
  • Yort.Otp
    • CounterBasedPasswordGenerator
      • Counter
      • CounterBasedPasswordGenerator
    • IHashAlgorithm
      • ComputeHash
      • Name
    • IOnetimePasswordGenerator
      • GeneratedPassword
      • HashAlgorithm
      • PasswordLength
      • SetSecret
    • MD5HashAlgorithm
      • ComputeHash
      • Name
    • OnetimePasswordAccount
      • Issuer
      • Label
      • Metadata
      • PasswordGenerator
      • Secret
    • OnetimePasswordGeneratorBase
      • Dispose
      • GeneratedPassword
      • HashAlgorithm
      • IsDisposed
      • MovingFactor
      • OnetimePasswordGeneratorBase
      • PasswordLength
      • SetSecret
    • OnetimePasswordGeneratorFactory
      • CreateFactory
      • CreateNewPasswordGenerator
      • FromOtpUrl
      • GetOtpUrl
    • OnetimePasswordSecret
      • FromAscii
      • FromBase32
      • FromHex
      • ToBase32
    • Resource
    • Resource.Attribute
    • Resource.String
      • ApplicationName
      • Hello
    • Sha1HashAlgorithm
      • ComputeHash
      • Name
    • Sha256HashAlgorithm
      • ComputeHash
      • Name
    • Sha512HashAlgorithm
      • ComputeHash
      • Name
    • TimeBasedPasswordGenerator
      • MovingFactor
      • TimeBasedPasswordGenerator
      • TimeInterval
      • Timestamp
      • ValidUntilUtc

Class OnetimePasswordGeneratorBase

Base cass used for onetime password generators, provides re-use as well as a "versionable" common interface.

Inheritance
System.Object
OnetimePasswordGeneratorBase
CounterBasedPasswordGenerator
TimeBasedPasswordGenerator
Implements
IOnetimePasswordGenerator
IDisposable
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Yort.Otp
Assembly: cs.temp.dll.dll
Syntax
public abstract class OnetimePasswordGeneratorBase : IOnetimePasswordGenerator, IDisposable

Constructors

Name Description
OnetimePasswordGeneratorBase()

Default constructor

OnetimePasswordGeneratorBase()

Default constructor

OnetimePasswordGeneratorBase(Boolean)

Partial constructor.

OnetimePasswordGeneratorBase(Boolean)

Partial constructor.

OnetimePasswordGeneratorBase(Boolean, Byte[])

Full constructor, initialises this instance with an already known secret.

OnetimePasswordGeneratorBase(Boolean, Byte[])

Full constructor, initialises this instance with an already known secret.

Properties

Name Description
GeneratedPassword

Returns the password generated for the current MovingFactor using the provided secret and HashAlgorithm.

GeneratedPassword

Returns the password generated for the current MovingFactor using the provided secret and HashAlgorithm.

HashAlgorithm

Sets or rturns an IHashAlgorithm implementation used to generate onetime passwords.

HashAlgorithm

Sets or rturns an IHashAlgorithm implementation used to generate onetime passwords.

IsDisposed

Returns a boolean indicating whether or not this instance has been disposed.

IsDisposed

Returns a boolean indicating whether or not this instance has been disposed.

MovingFactor

Sets or returns a 64 bit integer which is the value that changes over time (either literally, or on some even such as a successful login) which is converted into a onetime password.

MovingFactor

Sets or returns a 64 bit integer which is the value that changes over time (either literally, or on some even such as a successful login) which is converted into a onetime password.

PasswordLength

Sets or returns length of the password to generate.

PasswordLength

Sets or returns length of the password to generate.

Methods

Name Description
Dispose()

Disposes this class and any internal resources.

Dispose()

Disposes this class and any internal resources.

Dispose(Boolean)

Used by derived classes to clean up resources held by the base class.

Dispose(Boolean)

Used by derived classes to clean up resources held by the base class.

SetSecret(Byte[])

Sets the secret used to generate passwords.

SetSecret(Byte[])

Sets the secret used to generate passwords.

Back to top Copyright (c) 2017 Troy Willmot