Hi,
I use AIX (ksh) and Linux (bash) servers. I'm trying to do scripts to will run in both ksh and bash, and most of the time it works. But this time I don't get it in bash (I'm more familar in ksh).
The goal of my script if to read a "config file" (like "ini" file), and make various report.... (2 Replies)
I'm trying to understand if it's possible to create a set of variables that are numbered based on another variable (using eval) in a loop, and then call on it before the loop ends.
As an example I've written a script called question (The fist command is to show what is the contents of the... (2 Replies)
Hello, here is my problem:
I have 20 machines that need to SSH into 1 machine throughout the day. The issue is every time I go through the process of putting my keys from one of the computers that needs to SSH to the server that needs to accept all the incoming SSH's it overrides the last one.
... (6 Replies)
Hi all
Sorry for the basic question, but i am writing a shell script to get around a slightly flaky binary that ships with one of our servers. This particular utility randomly generates the correct information and could work first time or may work on the 12th or 100th attempt etc !.... (4 Replies)
Hello all, I am i am trying to read username password. Bassicaly, i have file called sidlist and it has my database name, username and password....
looks something like this....
db1, user1, pass1
db2, user2, pass2
db3, user3, pass4
but i dont know how to make it work, until i get... (4 Replies)
hello all, i am trying to find a better to do what i am doing right now...
i have a file called sidlist...which has my database_name and password to the respective database
so something like below.. file is called sidlist and entry is below...
test, abc123
kes12, abcd12
pss, abcd1234... (5 Replies)
Hello,
I am studying few things on unux and scripting. I need a script to create bulk users in unux. I need some assistance from you for creating 100 or more User IDs using a bash script:
Here's my requirements:
1. I need to create 100 or even more user ids of different naming... (1 Reply)
I want to give my long scripts to customer. The customer must not be able to read the scripts even if he has the password. The following command locks and unlocks the script but the set +x is simply ignored.
The code:
read -p 'Script: ' S && C=$S.crypt H='eval "$((dd if=$0 bs=1 skip=//|gpg... (7 Replies)
I am super new to scripting and I am trying to create a bash script that is interactive that will change other user passwords as well as a few other thing (ie. change SMB pw, see pw expiration,lock/unlock user).
I have started it by making it check to see if the username entered is in the... (2 Replies)
Discussion started by: thumbelina
2 Replies
LEARN ABOUT DEBIAN
expect_mkpasswd
MKPASSWD(1) General Commands Manual MKPASSWD(1)NAME
mkpasswd - generate new password, optionally apply it to a user
SYNOPSIS
mkpasswd [ args ] [ user ]
INTRODUCTION
mkpasswd generates passwords and can apply them automatically to users. mkpasswd is based on the code from Chapter 23 of the O'Reilly book
"Exploring Expect".
USAGE
With no arguments, mkpasswd returns a new password.
mkpasswd
With a user name, mkpasswd assigns a new password to the user.
mkpasswd don
The passwords are randomly generated according to the flags below.
FLAGS
The -l flag defines the length of the password. The default is 9. The following example creates a 20 character password.
mkpasswd -l 20
The -d flag defines the minimum number of digits that must be in the password. The default is 2. The following example creates a password
with at least 3 digits.
mkpasswd -d 3
The -c flag defines the minimum number of lowercase alphabetic characters that must be in the password. The default is 2.
The -C flag defines the minimum number of uppercase alphabetic characters that must be in the password. The default is 2.
The -s flag defines the minimum number of special characters that must be in the password. The default is 1.
The -p flag names a program to set the password. By default, /etc/yppasswd is used if present, otherwise /bin/passwd is used.
The -2 flag causes characters to be chosen so that they alternate between right and left hands (qwerty-style), making it harder for anyone
watching passwords being entered. This can also make it easier for a password-guessing program.
The -v flag causes the password-setting interaction to be visible. By default, it is suppressed.
EXAMPLE
The following example creates a 15-character password that contains at least 3 digits and 5 uppercase characters.
mkpasswd -l 15 -d 3 -C 5
SEE ALSO
"Exploring Expect: A Tcl-Based Toolkit for Automating Interactive Programs" by Don Libes, O'Reilly and Associates, January 1995.
AUTHOR
Don Libes, National Institute of Standards and Technology
mkpasswd is in the public domain. NIST and I would appreciate credit if this program or parts of it are used.
22 August 1994 MKPASSWD(1)