Sponsored Content
Top Forums Shell Programming and Scripting Printf or any other method to put long string of spec characters - passing passwords Post 303007290 by MadeInGermany on Wednesday 15th of November 2017 03:30:04 AM
Old 11-15-2017
The "here document" is the correct method of storing a password in the script.
--
If you have a pwlist with one password per line then you can do
Code:
while IFS= read -r pw
do
  printf "%s\n" "$pw"
  echo 7z t -p"$pw"
done < pwlist

Remove the echo to run the 7z command.
 

8 More Discussions You Might Find Interesting

1. Programming

How i can read a long integer from standar input and a string with as many characters as specified..

how i can read a long integer from standar input and a string with as many characters as specified in the number? i thing that i must use the read command ofcourse.... (6 Replies)
Discussion started by: aintour
6 Replies

2. Shell Programming and Scripting

SSH - Passing Unix login passwords through shell scripts

Hi All , I need to call a script runscript_B.sh on server A, the runscript_B.sh script locating in server B. The runscript_B.sh in calls another script runscript_A on server A itself. it seend, i need to be connect from Server A to Server B using ssh. I have tryed like this in... (3 Replies)
Discussion started by: koti_rama
3 Replies

3. Shell Programming and Scripting

Need help with spec. characters.

Hi., I need transfer as parameter into shell script some spec. characters, for example " or ' or & or \ at the end of second parameter. (this parameter used as changed password). How I can transfer it into shell script. Thanks Staas,. (5 Replies)
Discussion started by: beckss
5 Replies

4. Shell Programming and Scripting

Reading a string and passing passing arguments to a while loop

I have an for loop that reads the following file cat param.cfg val1:env1:opt1 val2:env2:opt2 val3:env3:opt3 val4:env4:opt4 . . The for loop extracts the each line of the file so that at any one point, the value of i is val1:env1:opt1 etc... I would like to extract each... (19 Replies)
Discussion started by: goddevil
19 Replies

5. Programming

Passing printf formatting parameters as variables

Hi, I haven't programed in C in a few years. I have been doing a lot of shell scripting, I.E. not really programming anything heavy. :o That said, I have a script that gives hourly usage statistics for our email server. It runs w-a-y to slow as a script for my impatience, and needs to... (7 Replies)
Discussion started by: mph
7 Replies

6. Shell Programming and Scripting

Align with printf or other method

below line is one by one print audio_play PASS boot_check FAIL ethernet_change_mac NIC_82574L PASS gps_ublox_neo FAIL storage_bonnie USB2 PASS storage_copy_big_file USB2 PASS I would like below format ... (7 Replies)
Discussion started by: yanglei_fage
7 Replies

7. Shell Programming and Scripting

How to avoid "Too many arguments" error, when passing a long String literal as input to a command?

Hi, I am using awk here. Inside an awk script, I have a variable which contains a very long XML data in string format (500kb). I want to pass this data (as argument) to curl command using system function. But getting Too many arguments error due to length of string data(payloadBlock). I... (4 Replies)
Discussion started by: cool.aquarian
4 Replies

8. UNIX for Beginners Questions & Answers

How to put a 80 character limit on a long topic line in markdown?

I have a topic line in markdown that spans more than 80 characters that i need to add a line break. Markdown is simply treating the line break as a brand new line instead of continuing as a topic line. Eg: # This is a very long line Markdown interprets it as This is a very long line (4 Replies)
Discussion started by: dragonpoint
4 Replies
asadmin-rollback-transaction(1AS)				   User Commands				 asadmin-rollback-transaction(1AS)

NAME
asadmin-rollback-transaction, rollback-transaction - rollsback the named transaction SYNOPSIS
unfreeze-transaction-service --user admin_user [--password admin_password][--host localhost] [--port 4848][--secure|-s] [--passwordfile filename] [--terse=false] [--echo=false] [--interactive=true] transaction_id Rollsback the named transaction. This command is supported in remote mode only. OPTIONS
--user authorized domain application server administrative username. --password password to administer the domain application server. --host machine name where the domain application server is running. --port port number of the domain application server listening for administration requests. --secure if true, uses SSL/TLS to communicate with the domain application server. --passwordfile file containing the domain application server password. --terse indicates that any output data must be very concise, typically avoiding human-friendly sentences and favoring well- formatted data for consumption by a script. Default is false. --echo setting to true will echo the command line statement on the standard output. Default is false. --interactive if set to true (default), only the required password options are prompted. OPERANDS
transaction_id identifier for the transaction to be rolled back.. Example 1: Using rollback-transaction asadmin> rollback-transaction --user admin --password adminadmin transaction1 EXIT STATUS
0 command executed successfully 1 error in executing the command asadmin-freeze-transaction-service(1AS), asadmin-unfreeze-transaction-service(1AS) J2EE 1.4 SDK March 2004 asadmin-rollback-transaction(1AS)
All times are GMT -4. The time now is 12:53 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy