How to add a user to /etc/passwd using CGI?

Discussion in 'Perl' started by Kempniu, Feb 2, 2004.

  1. Kempniu

    Kempniu Guest

    Hi there,

    I was wondering how do all the "free web space" services etc. work -
    when one fills in a form, he/she is automatically added to the
    system's userlist. How does this work? I mean, how is it possible for
    a CGI script to access /etc/passwd without executing `chmod 666
    /etc/passwd` first? ;)

    And if the users are NOT added to /etc/passwd, then how can they log
    in through FTP (e.g. to upload their websites)?

    Thanks in advance for any kind of explanation,
    Kempniu
     
    Kempniu, Feb 2, 2004
    #1
    1. Advertising

  2. The ISP I am familiar with runs all of their user information out of MySQL.
    Postfix, qpopper, ProFTPD, Apache, and other services can be patched to use
    a set of tables in MySQL. All you would need to do is write a front-end to
    populate those tables.

    Yes, I have oversimplified this, but a little digging should turn up the
    rest of what you need to know ;)

    "Kempniu" <lordpopcorn@[cut-this-out]poczta.onet.pl> wrote in message
    news:...
    > Hi there,
    >
    > I was wondering how do all the "free web space" services etc. work -
    > when one fills in a form, he/she is automatically added to the
    > system's userlist. How does this work? I mean, how is it possible for
    > a CGI script to access /etc/passwd without executing `chmod 666
    > /etc/passwd` first? ;)
    >
    > And if the users are NOT added to /etc/passwd, then how can they log
    > in through FTP (e.g. to upload their websites)?
    >
    > Thanks in advance for any kind of explanation,
    > Kempniu
     
    Jason A. Crome, Feb 3, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Robin Cull
    Replies:
    5
    Views:
    411
    Andrew Dalke
    Jul 31, 2003
  2. Marco Herrn
    Replies:
    7
    Views:
    631
    Ng Pheng Siong
    Apr 9, 2004
  3. Iván Cabria
    Replies:
    0
    Views:
    306
    Iván Cabria
    Nov 4, 2004
  4. Steven Hansen

    Etc.passwd on OS X

    Steven Hansen, Oct 13, 2009, in forum: Ruby
    Replies:
    3
    Views:
    147
    Steven Hansen
    Oct 13, 2009
  5. Kempniu
    Replies:
    3
    Views:
    259
    Josef Möllers
    Feb 2, 2004
Loading...

Share This Page