Questions tagged [passwd]

unix/mac questions about password changes or storage, the related `.passwd` file or `passwd` command

140 questions
0
votes
1 answer

Linux password exipiration with Awk,shadow, and password

I am trying to write a script that ouputs the username,real name, and account expriation date. This is the code I have so far. awk -F: '$3 > 1000 { print $1, $5 }|grep /etc/shadow (print $9)to_date('1970-01-01','YYYY-MM-DD') +…
Scifiguy
  • 1
  • 1
0
votes
0 answers

Print all users from one, selected group (GID) from /etc/passwd

I'm new here and I'm trying to learn some Bash. I need to write a script that will print all of users from etc/passwd in seperated lines from one, selected group defined as a $1 parameter. When group does not exist, the proper message is displayed.…
Cassy_1
  • 73
  • 1
  • 7
0
votes
2 answers

change password remote unix server using java

I am looking for a way to fire passwd onto a remote unix server via a java code. I am using Jsch, I can successfully execute commands like find, zip, get. But when I pass 'passwd' command nothing happens. The motive is to create an application which…
Vaibhav Arora
  • 91
  • 1
  • 7
0
votes
0 answers

Script to reset user password (HP-UX)

I am trying to write a shell script to reset a user password. It will accept 2 arguments, 1 old password and the new password. I have used expect and the script works. However, my tech folks do not allow me to install expect in the production…
Wes Ong
  • 15
  • 5
0
votes
1 answer

exp_spawnl executes passwd with reduced privileges

Folks, We are trying to develop a utility program (ChangePassword) which allows users to change their password automatically by executing: exp_spawnl("passwd", "username") The passwd command requires root privileges in order to change password of…
lyaffe
  • 1,407
  • 15
  • 24
0
votes
1 answer

Member list limit in /etc/group file

I'm creating user with group in my busybox Linux machine addgroup group1 adduser user1 -G group1 after creating 20 users I'm getting error like "adduser: unknown group group1", cat…
Rahul R Dhobi
  • 5,668
  • 1
  • 29
  • 38
0
votes
1 answer

libnss-extrausers and user tasks

I have Ubuntu 12.04. Installed libnss-extrausers and configured nsswitch.conf. Now, users registered in /var/lib/extrausers/{passwd,group,shadow} are recognized by the system and can login. However, common user management programs (passwd, userdel,…
morais
  • 161
  • 1
  • 1
  • 9
0
votes
1 answer

Reset UID/GID counter after vmail setup

On my personal server, I recently made the move from Ubuntu Server 10.04 to Debian Wheezy 7.2. As part of that transition, I went from physical users/mailboxes to a virtual mailbox setup using dovecot+postfix+postfixadmin. In doing so, I created a…
Chris
  • 1
  • 1
0
votes
1 answer

Send passwort to passwd automatically

I have a script, which is installing a guest machine on a xen server. It installs automatically. But in one step, I'll be asked for a password. The following happens: Enter new UNIX password: Retype new UNIX password: passwd: Authentication token…
Vince
  • 1,133
  • 3
  • 17
  • 34
0
votes
1 answer

How to get variable in terminal

Hi i am writing program which should change /etc/passwd file using chfn from file. Is it possible to run a file with bash file.txt with the command chfn there but for different user without editing file.txt. It should somehow let me to write user i…
0
votes
0 answers

run bash script on remote server without shell access

We have a server 'x'. We want a setup in which a user 'test' should scp a file 'f' to server 'x' then should login to the server(using ssh) and run a script 'test.sh' which does some operations on file 'f'. We dont want to give shell access to user…
0
votes
1 answer

SVN: Global and project-specific passwd files for single repository

I would like to configure my local SVN server to support both a global passwd file and a project specific passwd file. I have a global passwd file set up that is currently used to administer all accounts. The only problem is, sometimes we want to an…
Ian McIntyre Silber
  • 5,553
  • 13
  • 53
  • 76
0
votes
1 answer

How should I set password for a user I created using ssh?

I have 20 machines where I need to create a user and set his password. I can create the accounts and set the passwords using a for loop. The inside of the for loop is given as follows ssh -t user1@$node_name 'sudo useradd user2' ssh -t…
Budhapest
  • 601
  • 1
  • 5
  • 12
0
votes
1 answer

Change UNIX password with JAVA

sorry if my english is so bad. i wanna ask about executing "passwd" command from Java (i use Netbeans IDE & JSCH Library) This is my code String username = txtusername.getText(); String password = txtpassword.getText(); String ip =…
0
votes
3 answers

php - proc_open (or other function that works)

I need to do some command lines through a browser. What I need to do in a command-line would be: $login $passwd So, how can I do this using the proc_open function? Or…
RSilva
  • 6,753
  • 11
  • 43
  • 49