I want to retrieve the username and password of the current user from a shell script ....
how to do this?
gauravmishra
-7
Light Poster
Recommended Answers
Jump to Post#!/bin/sh echo ${USER}
Password is a whole different (uglier) beast.
Jump to Post*Points to his previous post*
Ok, something to keep in mind, the password is ENCRYPTED, so even if I told you where to find it (/etc/passwd, /etc/shadow) it will do you no good unless you can figure out how to DECRYPT it... *nix is pretty secure... they don't just …
All 5 Replies
Comatose
290
Taboo Programmer
Team Colleague
gauravmishra
-7
Light Poster
Comatose
290
Taboo Programmer
Team Colleague
gauravmishra
-7
Light Poster
Salem
5,138
Posting Sage
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.