BSD Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsOperating SystemsBSD Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
1200+ fellow developers rate and compare features of the top IDEs, like Visual Studio, Eclipse, RAD, Delphi and others, across 13 categories. Enjoy this FREE Download of the IDE User Satisfaction Study by Evans Data Corporation. Download Now!
  #1  
Old October 27th, 2001, 12:49 AM
spinkick spinkick is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2001
Location: Riverside CA
Posts: 58 spinkick User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Send a message via AIM to spinkick
adding users another way?

Is there any other way to add a user to the system other than the "adduser" script?
FreeBSD 4.3...

Reply With Quote
  #2  
Old October 27th, 2001, 05:36 AM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
>> Is there any other way to add a user

Yes. You can even alter /etc/group, /etc/passwd and /etc/mater.passwd manually.

Tell us what exactly are you trying to do?

Reply With Quote
  #3  
Old October 27th, 2001, 01:43 PM
spinkick spinkick is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2001
Location: Riverside CA
Posts: 58 spinkick User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Send a message via AIM to spinkick
sorry

I want to make a php script to add new users to the system. So I can just create a new user by adding new lines to those files?
Also, how do I encrypt the password?

Last edited by spinkick : October 27th, 2001 at 01:51 PM.

Reply With Quote
  #4  
Old October 28th, 2001, 05:19 AM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
>> I want to make a php script to add new users to the system

mod_php can never do this. Perl, being the all purpose scripting language, can do all sort of system tasks and do it more securely than standalone PHP.

>> So I can just create a new user by adding new lines to those files?

mod_php? No way.

>> how do I encrypt the password?

Depend on what language you wish to use.

Check out my following posts in Perl forum:

1) http://forums.devshed.com/showthrea...23249&forumid=6

2) http://forums.devshed.com/showthrea...23561&forumid=6

Reply With Quote
  #5  
Old October 28th, 2001, 06:35 PM
spinkick spinkick is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2001
Location: Riverside CA
Posts: 58 spinkick User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Send a message via AIM to spinkick
hmmm

I noticed that in the second location you posted, the script contains a line like this:

$result = system("/usr/sbin/useradd -m poophead -s /bin/bash");

the "adduser" script cannot do a "-m username" can it? I am able to do that with every other option but the username.
I have decided to use perl cgi to create the script. It does seem that perl is quite a bit more powerful than php for tasks such as this.

Reply With Quote
  #6  
Old October 28th, 2001, 08:06 PM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
>> I noticed that in the second location you posted

I didn't post it, I was just copying the exact useradd's option from poster freakybutt.

>> the "adduser" script cannot do a "-m username" can it?

I don't run Linux and don't have a need to as it wastes my time. Why don't you find out the available option of it from the manpage?

Reply With Quote
  #7  
Old October 29th, 2001, 01:06 AM
spinkick spinkick is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2001
Location: Riverside CA
Posts: 58 spinkick User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
Send a message via AIM to spinkick
I'm not running linux

adduser, in FreeBSD, not linux. I did check the man pages, that's why I was making sure to see maybe I was missing something.
man adduser does not list any options for specifying the username in the command.

Reply With Quote
  #8  
Old October 29th, 2001, 04:16 AM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
>> that's why I was making sure to see maybe I was missing something

All Linux distributions and different BSD might use different command with different syntax for adding user.

>> adduser, in FreeBSD, not linux

Use pw instead in FreeBSD.

Reply With Quote
  #9  
Old June 29th, 2003, 04:59 AM
thikana thikana is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Posts: 1 thikana User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via Yahoo to thikana
adduser from web

i need to adduser on my slackware box from web. someone please help me.

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsBSD Help > adding users another way?


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway