I need to write a script getPwd.pl($user)
that parses a password file an returns the password for a particular user.
file(密码:txt)
DEFINE ALICE = alice#1 ;
DEFINE BENICE = benice#1 ;
DEFINE CATHY = cathy#1 ;
A second script authUser.pl
must call getPwd.pl($user)
and the returned value will be passed into the second script to authenticate a user.
由于<代码>getPwd.pl将由不同用户拥有,而我将使用代号执行<代码>getPwd.pl。
Please assist and provide some guidance on how to go about this.