[SOLVED] What encryption does the /etc/shadow file use for passwords?
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
What encryption does the /etc/shadow file use for passwords?
I am just wondering what encryption method the shadow file uses, so that I may be able to manually change it. I ask this because I am trying to make a web page that will allow people to change their linux password via a browser.
Or if anyone has any better ideas I am open to suggestions.
I am just wondering what encryption method the shadow file uses, so that I may be able to manually change it. I ask this because I am trying to make a web page that will allow people to change their linux password via a browser.
Or if anyone has any better ideas I am open to suggestions.
Thanks again.
There are several that can be used, and what your options are, depends on your system and how you set it up. openSUSE uses Blowfish by default, others use MDx, etc.
And I would *NEVER* allow password changes via web page....so many security holes, it's not even funny. That said, it's your call...I'd use the default "passwd" program, and just pass it a string from the web form, and not code your own.
If you want to supply more information on what your intending to achieve might be able to give a better answer to this question. Are the customer's not able to use SSH for any particular reason?
I would advise that if you have a page that does anything around passwords that you ensure it's using an SSL certificate (ie an https:// page instead of a normal http://).
Customers can use SSH if they choose, but this is for a uni project, and I am meant to add extra value, one such value being web stuff, file upload, password changing and blog software etc.
How would I pass a string to passwd from a web page?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.