Solved

adduser

Posted on 1998-09-15
3
157 Views
Last Modified: 2010-03-05
Does anyone know if there is a Perl script available that allows you to add a new user on a Linux system.  What I would ideally like to do is be able to add a new user via a web interface.
0
Comment
Question by:bsufs
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 84

Expert Comment

by:ozo
ID: 1204853
Yes.
(but I wouldn't ordinarily expect a web interface to be given the neccesary privileges to run it)
0
 

Author Comment

by:bsufs
ID: 1204854
How can I obtain this script?
0
 
LVL 1

Accepted Solution

by:
stormerider earned 200 total points
ID: 1204855
Adduser under linux is a script interface to useradd. Take a look at the script, and then rewrite it under either perl or CGI. You're either going to have to set a special entry into apache to run that script as root, or run all scripts as root, or pass information from the cgi to another script because apache does NOT like suid cgi's (server error). Unless there is a way to tell apache not to do that...

Make TIGHT security on it. If you use something like cgi-lib.pl, make sure you add a line to s/\`//g and s/\;//g. Otherwise you'll have very unfriendly things done...
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many time we need to work with multiple files all together. If its windows system then we can use some GUI based editor to accomplish our task. But what if you are on putty or have only CLI(Command Line Interface) as an option to  edit your files. I…
A year or so back I was asked to have a play with MongoDB; within half an hour I had downloaded (http://www.mongodb.org/downloads),  installed and started the daemon, and had a console window open. After an hour or two of playing at the command …
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Six Sigma Control Plans

687 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question