1.0.8 • Published 2 years ago

@azerothcore/ac-nodejs-srp6 v1.0.8

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

AzerothCore SRP6

This library is used to generate the SRP6 verifier for AzerothCore, based on https://github.com/Miorey/trinitycore-srp6 (original author)

Usage

To install \ npm install azerothcore-srp6 --save \

Generate verifier with default AzerothCore values:

const { computeVerifier, params } = require(`azerothcore-srp6`)
const myVerifier = computeVerifier(
    params.constants, 
    Buffer.from(salt), 
    username.toUpperCase(), 
    password.toUpperCase()
)

Generate verifier with custom values

const BigInteger = require(`big-integer`)   
const myParam = {
        N_length_bits: 256,
        N: BigInt(`0x894B645E89E1535BBDAD5B8B290650530801B18EBFBF5E8FAB3C82872A3E9BB7`),
        g: BigInt(`0x7`),
        hash: `sha1`
    }
const myVerifier = computeVerifier(
    myParam, 
    Buffer.from(salt), 
    username.toUpperCase(), 
    password.toUpperCase()
)
1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago