htpasswd with node.js

677 views
Skip to first unread message

rattus

unread,
Jan 5, 2012, 8:37:09 PM1/5/12
to Beagle Board
Hi - has anyone had success using the htpasswd module for either basic
or digest authentication for pages served by node.js? https://github.com/gevorg/htpasswd

If so, could you provide an example of how it's used?

I'll readily admit I'm a node newbie, but I cannot turn the example
provided on the git page into working authentication.

Thanks,

Mike

gevo...@gmail.com

unread,
Jan 31, 2012, 3:50:25 PM1/31/12
to beagl...@googlegroups.com
Hi Mike,

Sorry for late response, just install it using global flag - "npm install -g htpasswd" and after start using it as regular command line client by typing htpasswd in terminal. Usage is similar to Apache2 server utility, if you still need it and have problems, please let me know.

Gevorg.

tino

unread,
May 29, 2012, 3:38:46 PM5/29/12
to beagl...@googlegroups.com
I am also trying to password protect my node.js website running on port 8000. I have installed htpasswd and created a password file using htpasswd -c . But I am not sure how to proceed further. Can you please help me?

Koen Kooi

unread,
May 29, 2012, 4:57:52 PM5/29/12
to beagl...@googlegroups.com

Op 29 mei 2012, om 21:38 heeft tino het volgende geschreven:

> I am also trying to password protect my node.js website running on port 8000. I have installed htpasswd and created a password file using htpasswd -c . But I am not sure how to proceed further. Can you please help me?

I googled it for you: http://stackoverflow.com/questions/5951552/basic-http-authentication-in-node-js
Reply all
Reply to author
Forward
0 new messages