lib/auth/set-client-dh-params.js
function createAuthKeyID(context) {
    var authKeyHash = utility.createSHAHash(context.authKeyValue);
    var authKeyAuxHash = authKeyHash.slice(0, 8);
    var authKeyID = authKeyHash.slice(-8);
    if (logger.isDebugEnabled()) {
        logger.debug('authKeyID(%s) = %s', authKeyID.length, authKeyID.toString('hex'));
    }
    context.authKeyID = authKeyID;
    context.authKeyAuxHash = authKeyAuxHash;
    return context;
}
function createAuthKeyID(context) {
    var authKeyHash = utility.createSHAHash(context.authKeyValue);
    var authKeyAuxHash = authKeyHash.slice(0, 8);
    var authKeyID = authKeyHash.slice(-8);
    if (logger.isDebugEnabled()) {
        logger.debug('authKeyID(%s) = %s', authKeyID.length, authKeyID.toString('hex'));
    }
    context.authKeyID = authKeyID;
    context.authKeyAuxHash = authKeyAuxHash;
    return context;
}
function createAuthKeyID ( context ) { var authKeyHash = utility . createSHAHash ( context . authKeyValue ) ; var authKeyAuxHash = authKeyHash . slice ( 0 , 8 ) ; var authKeyID = authKeyHash . slice ( - 8 ) ; if ( logger . isDebugEnabled ( ) ) { logger . debug ( 'authKeyID(%s) = %s' , authKeyID . length , authKeyID . toString ( 'hex' ) ) ; } context . authKeyID = authKeyID ; context . authKeyAuxHash = authKeyAuxHash ; return context ; }
Calculate AuthKey hash and ID
Calculate AuthKey hash and ID