Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Define variables with UNIX script Post 302570163 by ctsgnb on Wednesday 2nd of November 2011 01:54:08 PM
Old 11-02-2011
What are you trying to achieve ?
Are you trying to store a password because you want your script use this password to pass some other commands ?
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

how to define permission of unix group

While logged on as root, I created a user 'usera' I also created a group called 'groupa' I need to modify the permission of the user i created to not have root privileges. I also need to change groupa to be in 'others' please help! thanks, nieves (3 Replies)
Discussion started by: mncapara
3 Replies

2. Shell Programming and Scripting

Adding variables in a unix script

Hi I am trying to add variables(float values) in a unix script but am getting an error value=`expr $a + $b + $c` The error I am getting is "expr: non-numeric argument" I guess it has got to something with the decimal points. Plz help (13 Replies)
Discussion started by: akashtcs
13 Replies

3. Shell Programming and Scripting

Pass variables to a Unix script from a file

Hi, I am running a Java program from a unix script. I need to pass a variable to the Java code from a file. Here are teh details: cat Parm <<this is my Parameter file>> queuename=queue1 and my shell script is : #!/bin/ksh . ./Parm /opt/java1.5/bin/java -classpath ./java.jar... (1 Reply)
Discussion started by: sangharsh
1 Replies

4. Shell Programming and Scripting

Simple unix variables in script

I'm creating a script that asks a user for a variable ex read filename; read numberinput; I also have a bunch of files named file.0 file.1 ... file.55 I'm trying to delete all files (if they exist) about file.$numberinput. Can someone help me out on how to include the variable as part... (6 Replies)
Discussion started by: jenix4545
6 Replies

5. Shell Programming and Scripting

Loop to define variables in KSH

Hi, I am trying to use a database to store configurations in an environment definition scripts to make the configurations easily modifiable. (long story short - it is an easier process to make changes in the db than trying to deploy a file). The values will be stored in the database in the... (1 Reply)
Discussion started by: gbala
1 Replies

6. Shell Programming and Scripting

Using Datastage environment variables in Unix script

Hi All, I am using ETL tool Datastage and is installed on Linux environment. Few environment variables are set in datastage. Now my requirement is to use those environment variables in a unix script. Is there any option I can do it? Sugeestions from people working on datastage and linux... (1 Reply)
Discussion started by: bghosh
1 Replies

7. Shell Programming and Scripting

Using a script to define variables and run multiple other scripts in succession.

I'm pretty new to scripting in Korn shell so please forgive me... What I'm trying to do is to create a script that calls multiple other ksh scripts and defines variables for text files. I need it to define my user defined variables (file paths, date & time stamps, etc that are currently in... (1 Reply)
Discussion started by: bluejwxn8
1 Replies

8. Shell Programming and Scripting

How to define two digits variable in shell script?

Dear Shell script Experts, I am working on shell script which is defined here, qsub_seq.csh . The purpose of this script is to read few input files (with defined starting index and last index) and make processing faster over server. For some task, I had 1064 of input files, so I wrote another... (8 Replies)
Discussion started by: emily
8 Replies

9. Shell Programming and Scripting

Define Variables

Hi, I just define the variable in script and use those script in another script but the variable not recognize. test1.sh #!/bin/bash DB="test_db" USR="test_user" PWD="test_pwd" HST="24.254.87.12" test2.sh #!/bin/bash ./test1.sh mysql -u $USR -p $PWD -h $HST... (2 Replies)
Discussion started by: fspalero
2 Replies

10. Shell Programming and Scripting

Need assistance to define path on a script which cron will execute

I have written a script to execute some sql statement via executable file. It is working fine via command line, however when I schedule it in cron. The executable file is looking for library file in its root directory. Wonder where does cron run the script from, and can we get the script... (4 Replies)
Discussion started by: jaapar
4 Replies
SECRET-TOOL(1)							   User Commands						    SECRET-TOOL(1)

NAME
secret-tool - Store and retrieve passwords SYNOPSIS
secret-tool store --label='Label' {attribute} {value} ... secret-tool lookup {attribute} {value} ... secret-tool clear {attribute} {value} ... secret-tool search [--all]{attribute} {value} ... DESCRIPTION
secret-tool is a command line tool that can be used to store and retrieve passwords. Each password is stored in an item. Items are uniquely identified by a set of attribute keys and values. When storing a password you must specify unique pairs of attributes names and values, and when looking up a password you provide the same attribute name and value pairs. STORE
To store a password run secret-tool with the store argument. You must also specify a label for the passward with the --label argument. This label will be displayed in the password manager. Make sure to pass a unique set of attributes names and values when storing a password. If the attributes match an already existing item, it will be updated instead of creating a new item. If invoked from a terminal or tty, then the password to store will be prompted for and only one line will be accepted. A password to store can also be piped in via stdin. The password will be the contents of stdin until EOF. If you provide a newline via stdin it will be stored as part of the password. LOOKUP
To lookup a password run secret-tool with the lookup argument. Specify the same same attribute names and value pairs that you passed when storing the password. If multiple items match the attribute provided, then the first password that is already unlocked will be returned. If necessary an item will be unlocked. When printing the password to a terminal or tty, an extra newline will be added after the password. CLEAR
To remove a password run secret-tool with the clear argument. Specify the same attirbute name and value pairs that you passed when storing the password. All unlocked items that match the attributes will be removed. SEARCH
This command searches for and prints details on matching items in secret service. Specify the same attribute and value pairs that you passed in when storing the password. You can use the following options: --all Return all matching results, rather than just the one of the matches. Without this option, the first unlocked match returned from the service will be printed. --unlock Unlock items that are locked and then print out their details. Without this option, locked items are skipped. EXIT STATUS
On success 0 is returned, a non-zero failure code otherwise. EXAMPLES
Example 1. Storing, retrieving, and clearing a password $ secret-tool store --label='My password' key1 value1 key2 value2 Password: My password $ secret-tool lookup key1 value1 key2 value2 My password $ secret-tool clear key1 value1 key2 value2 XDG
SECRET-TOOL(1)
All times are GMT -4. The time now is 03:02 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy