UNPKG

ntlm-parser

Version:

Check and understand the content of a NTLM message

22 lines 728 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.decode = exports.getFlags = exports.toHex = void 0; // const debug = dbg('ntlm-parser'); function toHex(buffer) { return Buffer.from(buffer).toString('hex'); } exports.toHex = toHex; function getFlags(flags, value) { const str = flags .filter(flag => value & flag.value) .map(flag => flag.label) .join(' '); return str.replace(/NTLMSSP_NEGOTIATE_/g, ''); } exports.getFlags = getFlags; function decode(base64) { const b = Buffer.from(base64, 'base64'); return b.buffer.slice(b.byteOffset, b.byteOffset + b.byteLength); } exports.decode = decode; //# sourceMappingURL=misc.js.map