Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Mac OS X > create user account -- change password @ login

create user account -- change password @ login
Thread Tools
Mac Enthusiast
Join Date: Nov 2001
Location: Washington, DC 20009
Status: Offline
Reply With Quote
Aug 11, 2003, 09:10 AM
 
Is there a way to create an account through the command line that requires the user to set their own password during their initial login?

I didn't see anything like this mentioned in the useradd man pages. Thanks.
Just my $.02 :-)
Ti Powerbook 1Ghz w/ Superdrive ......and lovin' it! :)
     
Senior User
Join Date: Jan 2001
Location: Mahwah, NJ USA
Status: Offline
Reply With Quote
Aug 11, 2003, 09:41 AM
 
Originally posted by milf:
Is there a way to create an account through the command line that requires the user to set their own password during their initial login?

I didn't see anything like this mentioned in the useradd man pages. Thanks.
One way I have done it is to create a script called 'firstlogin' then have an entry in .tcshrc file that calls firstlogin. firstlogin looks like this:

Code:
#!/bin/sh echo You are logging in for the first time and are required to make a new password. echo passwd rm ~/firstlogin
-DU-...etc...
     
milf  (op)
Mac Enthusiast
Join Date: Nov 2001
Location: Washington, DC 20009
Status: Offline
Reply With Quote
Aug 11, 2003, 10:53 AM
 
This sounds like a possible solution. What if the user aborts the password change or fails to enter the correct initial password? The user will still have access to the system and may could, possibly, never change his/her password. Is this correct?

Also, what should the entry in the .tcshrc file look like? Thanks.
Just my $.02 :-)
Ti Powerbook 1Ghz w/ Superdrive ......and lovin' it! :)
     
Mac Elite
Join Date: Dec 2001
Location: Atlanta, GA, USA
Status: Offline
Reply With Quote
Aug 11, 2003, 12:12 PM
 
I'm pretty sure there is a way to do this in NetInfo manager. I was poking around and some of the accounts have an "expire" property.

I'd suggest looking to NetInfo to help you find your solution. Try creating a test account and setting the "expire" property to divverent values and see how they affect login (-1, 0, 1, 2, etc).
Mac Pro 2x 2.66 GHz Dual core, Apple TV 160GB, two Windows XP PCs
     
Clinically Insane
Join Date: Apr 2000
Status: Offline
Reply With Quote
Aug 12, 2003, 08:41 AM
 
Originally posted by Arkham_c:
I'm pretty sure there is a way to do this in NetInfo manager. I was poking around and some of the accounts have an "expire" property.

I'd suggest looking to NetInfo to help you find your solution. Try creating a test account and setting the "expire" property to divverent values and see how they affect login (-1, 0, 1, 2, etc).
Yes, you can indeed make logins expire; I don't know about passwords, though, but I imagine it's possible.

I'll have a play around with that tomorrow, and find out.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 08:15 AM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2