Su To Diffent Account And Automate The Password


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Su To Diffent Account And Automate The Password
# 1  
Old 02-07-2005
Su To Diffent Account And Automate The Password

I Need To Switch To A Different Account Before A Shell Is Executed. Unforturnately I Have To Call This Shell Via A Third Party App And The User Account Of The Processes That I Need To Kill Is Not The Same As The Default Account Gui Signs In As. I Need The Password To Be Hard Coded When Prompted After The Su Is Kicked Off.

Su Account
Password: (any Tips On How To Get This Password Populated Automatically)

-j
# 2  
Old 02-07-2005
Quote:
Originally Posted by kingoice
I Need To Switch To A Different Account Before A Shell Is Executed. Unforturnately I Have To Call This Shell Via A Third Party App And The User Account Of The Processes That I Need To Kill Is Not The Same As The Default Account Gui Signs In As. I Need The Password To Be Hard Coded When Prompted After The Su Is Kicked Off.

Su Account
Password: (any Tips On How To Get This Password Populated Automatically)

-j
or use rsh -l <myuser> -h localhost
of course, you will need to create some "security hole" by setting up .rhosts for that user to allow application user execute remote shell as <myuser>.
# 3  
Old 02-07-2005
Or, to maintain security, sudo might be the solution. You could also look into Expect although this will be less secure as passwords may have to be hard coded.

I'd personally say never hard code passwords into applications, as not only is this a huge security hole, but when the su target changes their password, the application then requires maintenance.

Cheers
ZB
# 4  
Old 02-08-2005
dont have root access

I do not have root access and the UNIX team will not install expect or sudo. Any other ideas?
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Problem to automate the change password

Hi. I know how to get new password from input file which have till Dec 2014 passwords with today's date, i want to change my password everyday for which i know how to set cron job that will run everyday in morning. once it is changed it should e-mail me if it successful or not. Can someone... (0 Replies)
Discussion started by: rajjev_saini123
0 Replies

2. UNIX for Advanced & Expert Users

Can we Automate the User creation and setting password through a script in solaris 10

Hi, I am using Solaris 10 OS and Bash shell.Is there any way can we automate User creation and setting passwords through a script or any freeware tool. Advance thanks for your response. (1 Reply)
Discussion started by: muraliinfy04
1 Replies

3. Solaris

PASSWORD LOOPof Oracle account

hi ...can anyone help me with this.. i have to create a oracle account, whose passwd should be in oracle password loop i know how to create account but i got stuck with oracle password loop so please help me ASAP... thanks in advance.. (0 Replies)
Discussion started by: 6pound
0 Replies

4. Shell Programming and Scripting

Automate Kerboer kinit password

Hi, I just wonder if anyone know how to auto encode the kerberos kinit password at prompt. kinit command is inside the one of the script called runscript.sh so ./runscript.sh ...... kinit username Password for username@example.com: How do I auto input the password without need to... (5 Replies)
Discussion started by: netlink
5 Replies

5. Solaris

Set Password Account to NP or NL

Hi Everyone, my name`s Sergio. I need your help please. I have a problem using Solaris 9. I create an account with the command line "useradd", with this I have no problem. My problem is I need set the created account to NP (No Password or Non Login). For example: cat /etc/shadow ... (2 Replies)
Discussion started by: roswell
2 Replies

6. HP-UX

how can find account without password

first I would like to find account that without password second I would like to find when account login fail ,account lock time third I would like to find when system idle ,force user logout time thanks (1 Reply)
Discussion started by: alert0919
1 Replies

7. UNIX for Dummies Questions & Answers

Change Account to not lock account if password expires

I have access to 15+ UNIX boxes at work, and I do not consistently log onto all of them over time. When I do try to access one I havent been on in awhile, my account is locked as the password has expired. I need to request to the UNIX SA's that the password expiration is 90 days and that if it... (1 Reply)
Discussion started by: stringzz
1 Replies

8. Solaris

how can I change user name and password , of account ?

passwd only changes the password but i need to change the user name tnx (5 Replies)
Discussion started by: umen
5 Replies

9. UNIX for Dummies Questions & Answers

Ftp account change password

How can I change the password from an ftp user account on a ssh server? Please give me simple instructions for a users who hasn't a lot of experience. :D Just the words in form of a list thanks a lot. (1 Reply)
Discussion started by: m.seidenberg
1 Replies
Login or Register to Ask a Question