thanks for replying, i just want to compare the current input password matching the password saved in system, making sure the user is valid. that is all. thanks for any help. and i change my script as follow based on your suggesting,
[CODE=perl]#!/usr/bin/perl
use Getopt::Std;
getopt('a:u:');
# First command switch, adding a user.
if ($opt_a)
{
print "Adding user ",...
User Profile
Collapse
-
-
thanks for reply, my script as following
[CODE=perl]open (SENDMAIL, "| /usr/lib/sendmail -t -n -oi");
print SENDMAIL "From: user\@domain.co m\n";
print SENDMAIL "To: root@domain.com \n";
print SENDMAIL "Subject: testing 123\n\n";
print SENDMAIL "Body: hello every\n";
close (SENDMAIL);[/CODE]
but i do not why when i run the script,...Leave a comment:
-
yes, i just begin to learn perl, so any help for me to write the script. thanks very much.Leave a comment:
-
thanks for your replying, so based on my problem, how can i change my script making it working. thanks very much.Leave a comment:
-
conform the password
hi everyone
could anyone help to conform the password, my script is following
[CODE=perl]#!/usr/bin/perl
use Getopt::Std;
getopt('a:u:');
# First command switch, adding a user.
if ($opt_a)
{
print "Adding user ", $opt_a, "\n";
password_creati on();
if ($pass1 eq $pass2) { print "\nSuccess. Adding user... -
thanks for your replying, i checked the link which you gave me. i think i just confused my question, my question is : for example, once you did wrong password in unix, the email would be sent to you. i think the email destination is unix's file, like using 'mail' to check the email in unix.Leave a comment:
-
send email
hi guys,
could any one help me how to write perl script to send email in unix system.
thank you for any helping. -
thanks your reply!
actually, I need add new user into unix by using -a switch, and after that when you update user by using -u switch, how can i check the current password when i update the user password.
[CODE=perl]#!/usr/bin/perl
use Getopt::Std;
getopt('a:u:');
# First command switch, adding a user.
if ($opt_a)
{
print "Adding user ", $opt_a, "\n";...Leave a comment:
-
Perl: invoke value
hi everyone
could everyone tell me how can i invoke value from getopt('u') to getopt('a')?
for example
[CODE=perl]
getopt('u);
if (opt_u)
{
print"enter something:\n";
$input=<STDIN>;
}
getopt('a');
if(opt_a)
{
#here, how can i use the value $input from getopt('u')
}[/CODE]
thank you for any help...
No activity results to display
Show More
Leave a comment: