How to provide password?


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting How to provide password?
# 1  
Old 07-02-2013
How to provide password?

Hi ,

I am trying to unzip some file in a dir using shell script ,but it prompts for password to unzip those files ,how would i provide the passoword in the script it self
# 2  
Old 07-02-2013
Searching for password in man unzip:

Code:
       -P password
              use  password  to  decrypt  encrypted  zipfile entries (if any).
              THIS IS INSECURE!  Many  multi-user  operating  systems  provide
              ways  for  any user to see the current command line of any other
              user; even on stand-alone systems there is always the threat  of
              over-the-shoulder  peeking.   Storing  the plaintext password as
              part of a command line in an automated  script  is  even  worse.
              Whenever  possible,  use  the non-echoing, interactive prompt to
              enter passwords.  (And where security is  truly  important,  use
              strong  encryption  such  as  Pretty Good Privacy instead of the
              relatively weak encryption provided by standard  zipfile  utili-
              ties.)

These 2 Users Gave Thanks to Corona688 For This Post:
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Forum Support Area for Unregistered Users & Account Problems

Password sent via reset password email is 'weak' and won't allow me to change my password

I was unable to login and so used the "Forgotten Password' process. I was sent a NEWLY-PROVIDED password and a link through which my password could be changed. The NEWLY-PROVIDED password allowed me to login. Following the provided link I attempted to update my password to one of my own... (1 Reply)
Discussion started by: Rich Marton
1 Replies

2. Programming

Can anyone provide some sources about bank IT

I am working in IT company working for banks.I find hardly to get technology about bank IT on the internet.Consider banks all using Unix, I think I can get some help here. Recommend some sits or books about bank IT will be very helpful!! (0 Replies)
Discussion started by: hhdzhu
0 Replies

3. Emergency UNIX and Linux Support

How to provide password for rsync in shell script?

Hi, i want to call the rsync in a shell script so that i can run it in background by passing the password within script itself. Can any one please let me know how can i provide the password in the shell script itself so that rsync will read the password when promted by the script. Its very... (11 Replies)
Discussion started by: Little
11 Replies

4. Shell Programming and Scripting

Can any one provide shell script for this ...

• With this script, users will be able to o Enter into the recycle bin mode. During this mode, all files deleted will be sent to the recycle bin. The recycle bin will be common to all users. o View contents of the recycle bin (his/her file(s) only). o Retrieve a particular file from the recycle... (3 Replies)
Discussion started by: bhavana busetty
3 Replies

5. Shell Programming and Scripting

Provide 2 inputs when prompts

Hi All, I am a novice to UNIX, i need to know is there a way to provide 2 inputs when the shell prompts and i need to assign those 2 values to 2 separate variables. I dont want to give those values as a arguments (while running the script). Thanks in advance!! (1 Reply)
Discussion started by: prasanna2166
1 Replies

6. Shell Programming and Scripting

Provide Password using to the application using the shell script

Hello, I have a requirement to shut down and start up my application on different environments (Dev, QA and Prod). I have around 24 servers. I have to login to each server manually for shutinng down the application. I wrote a shell command on each server and I am invoking those shell... (2 Replies)
Discussion started by: GDSR Raju
2 Replies

7. Shell Programming and Scripting

Script to provide percentages?

so i'm have been stifled here inn my attempts at this. i need to calculate an unusual figure. what is the percentage difference between 400 and 3? usually, to get the percentage, you just divide the smaller number by the bigger number. then multiply the answer by 100. in this case... (10 Replies)
Discussion started by: SkySmart
10 Replies

8. Programming

How to provide password to the prompt through Java

Hi All, I am using Ubuntu machine with JDK 6. I am running following command on shell- sudo ./somecript . Now, it prompts for sudo password and I provide the sudo password on shell and "somescript" starts running with sudo permissions. What I want to do is, I need to execute... (1 Reply)
Discussion started by: jaibhim
1 Replies

9. Shell Programming and Scripting

provide a user password from a script

Hi all, passwd <username> < /var/adm/passwd.txt cat /var/adm/passwd.txt abcd1234 abcd1234 when I run this from the script, it comes with: New password: It is not able to pick from the location /var/adm/passwd.txt. thanks in advance. (6 Replies)
Discussion started by: solaix14
6 Replies

10. UNIX for Dummies Questions & Answers

Provide a count of files

Hi, I'm a unix newbie and need your help. I need to get a count of files on our server. Number of .html files, Number of .pdf's, and Number of .ppt. I tried: find . -type f | wc -l but it only give me a total count. Thanks. (5 Replies)
Discussion started by: keymind
5 Replies
Login or Register to Ask a Question