LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-05-2009, 06:11 AM   #1
ZAMO
Member
 
Registered: Mar 2007
Distribution: Redhat &CentOS
Posts: 598

Rep: Reputation: 30
reading credentials from a passwd file in perl


Hi,

I want to read the user username and password available in a password file. I want the password to be stored in a user home directory and my perl script should read , whenever needed from that file.

Am not a Perl programmer and I want to set this for admin related activities.

In what syntax I need to write the password file and How to call them using the perl script.

Thanks
 
Old 02-05-2009, 09:41 AM   #2
rizwanrafique
Member
 
Registered: Jul 2006
Distribution: Debian, Ubuntu, openSUSE, CentOS
Posts: 147

Rep: Reputation: 19
Are you talking about /etc/passwd or some other password file?
 
Old 02-05-2009, 06:36 PM   #3
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,349

Rep: Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750Reputation: 2750
What format is the orig file you need to read?

As you're new to Perl, I highly recommend these links:

http://perldoc.perl.org/
http://www.perlmonks.org/?node=Tutorials
 
Old 02-06-2009, 01:16 AM   #4
ZAMO
Member
 
Registered: Mar 2007
Distribution: Redhat &CentOS
Posts: 598

Original Poster
Rep: Reputation: 30
Its not a /etc/passwd file. It is a file created for the purpose to store the login name, password and SID(oracle) and to read from it , whenever needed.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Perl reading a file umbrella2 Programming 18 02-04-2009 05:18 PM
Script passwd command by reading passwords from a file redleg7 Linux - General 1 01-12-2009 09:57 PM
PERL pattern matching while reading a file content is dead slow gaynut Programming 13 08-13-2008 06:59 AM
perl : stop reading a file when condition ok frenchn00b Programming 7 07-05-2007 02:37 AM
Perl Script Reading a txt file and generate html to be published! kofi Linux - Software 1 09-22-2003 05:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:55 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration