|
|
Adding Users (adduser.exe)
Adduser.exe is a utility for adding, modifying, or deleting users, but can only be used if the domain is based on either an IMail database or on an external database. (Adduser.exe cannot be used to add users to domains which use the Windows NT database.)
You can use adduser.exe to add users whose user IDs and passwords are stored in a text file. Passwords must be between 3 and 30 characters.
If you invoke adduser with no command line options (by typing only adduser at the MS-DOS prompt), you can then manually input command lines, pressing Enter after each line. If you do this, press CTRL-Z to exit the utility when you are done.
Basic Command Syntax
Adduser.exe [-h hostname] [-k userid] [-m userid] [-u userid] [-p password] [-n name] [-f filename] [-l] [ [Adding a User ID
The following examples add a user ID of test01.
Adduser -h myhost.com -u test01 -n "ms test" -p yourpass Adduser -u test01 -n "mr test" -p nopass Adduser -u test01 Adduser test01Deleting a User ID
The following examples delete a user ID.
Adduser -k -u test01 Adduser -h another.net -k test01Return Codes
Adduser returns 1 if it performed at least one of the requested operations; adduser returns 0 if it failed.
Using a Text File
Instead of entering commands at the MS-DOS prompt, you can use a text file to input multiple commands for one execution of adduser.exe. You can use this technique to add users to your IMail Server system from another mail system if the other mail program can create a delimited text file of user ids, passwords, and user names.
Let's suppose you want to add four user IDs (userid, smith, test1, and jones) to the wks013 server. Adduser.exe assumes that if there are no arguments in a text file, then the information on each line is userid, password, and full name - in that order.
For example, you could create a text file named addfour.txt that contains the following lines:
userid,password,full name smith,whypass,Mrs Smith test1,Mr Smith jones,okpass,Tom JonesAt the MS-DOS prompt, you enter:
Adduser -h station1.ipswitch.com -f addfour.txtYou then get the following messages:
current host is wks013.augusta.ipswitch.com OK: added userid to host station1.ipswitch.com OK: added smith to host station1.ipswitch.com OK: added test1 to host station1.ipswitch.com OK: added jones to host station1.ipswitch.comNote that the user named test1 will have "password" (the default) as his password.
Disabling Web Options
New users have all the Web options enabled unless you disable one of the Web options (-/+chgpass, -/+web, -/+active, -/+info) in the command line. Modifying a user does not change the user's Web options unless you include at least one of the Web arguments in the command line: if you include any web argument, then all Web options are enabled except those you specifically disable.
Sample File
#Entries below default to Primary domain automatically. #Adds user test100 with password nopass, and full name Mr. Test100 test100,nopass,"Mr. test100" #adds user test101 with password nopass, name of Ms. Test101, #has ability to #change own password, access from web, #account is not disabled, user info is accessible from outside. -u test101 -p nopass -n "Ms. test101" +chgpass +web +active +info #Add user killthisone -u killthisone #Remove user killthisone -k killthisone #Change domain(host) -h virtual001 #Change delimiter from default(,) to a (+). -c+ #Add user test100 with password of password and name of Mr. Test100 test100+password+"Mr. Test100" #Modify user test100 with new name of Mrs. Test100 -m -u test100 -n "Mrs. Test100" #Change domain(host) -h virtual002 #Change delimiter back to default -c, #Add user test101 with password nopass and name Mrs. Test101 test101,nopass,"Mrs. test101" #Add user test103 with default password, with default name test103, has #ability to change own password, access from web, account is not disabled, user #information is accessible from outside. -u test103 +chgpass +web +active +info #Add user test104 with default password, with default name test103, has #ability to change own password, access from web, account is not disabled, user #information is not accessible from outside. -u test104 -chgpass +web +active -info #Modify user test103 so user information is not accessible from outside. -m test103 -infoResults from running the above file:
current host is mail.some.where.com OK: added test100 to host mail.some.where.com OK: added test101 to host mail.some.where.com OK: added killthisone to host mail.some.where.com OK: User "killthisone" removed from " mail.some.where.com ". INF: current host is virtual001 OK: added test100 to host virtual001 OK: user test100 modified in virtual001 INF: current host is virtual002 OK: added test101 to host virtual002 OK: added test103 to host virtual002 OK: added test104 to host virtual002 OK: user test103 modified in virtual002
|
Ipswitch, Inc. http://www.ipswitch.com |
| ©Ipswitch 2002 | |||