Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const ntlm = require('express-ntlm');
- module.exports = app => {
- app.use(
- ntlm({
- debug: function() {
- var args = Array.prototype.slice.apply(arguments);
- console.log.apply(null, args);
- },
- domain: 'MS',
- domaincontroller: 'ldap://something.com'
- })
- );
- app.post('/get-user-details/', (req, res) => {
- console.log(req.ntlm.UserName); //Returns correct user most of the time, but sometimes it returns different person who open site at the same time
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement