#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2001
    Posts
    14
    Rep Power
    0

    Question Special permissions for user


    I have a server and I need to add a new user who will have telnet access to ONLY 1 or 2 MYSQL databases and not the others.

    He also will have FTP access as well.

    I don't want to give him my username and password for obvious security reasons.

    I was told that a new user can be set up with special permissions, but I don't know exactly how to do it.


    I am running the following:

    FreeBSD (latest version)
    MySQL (latest version)
    Apache (latest version)

    Please let me know how to make a special setup for this user.

    Regards,
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jan 2001
    Posts
    5
    Rep Power
    0
    Just RTFM via man 8 adduser. Then he should be able to telnet/ftp immediately. For MySQL, you need to add another user (him).

    You keep saying special permissions in your duplicated posts (in other forums), how special exactly?
  4. #3
  5. funky munky
    Devshed Beginner (1000 - 1499 posts)

    Join Date
    Jul 2001
    Location
    UK
    Posts
    1,446
    Rep Power
    15
    For the MySQL side - from the manual:

    You can add new users by issuing GRANT statements:

    shell> mysql --user=root mysql
    mysql> GRANT ALL PRIVILEGES ON *.* TO monty@localhost
    IDENTIFIED BY 'some_pass' WITH GRANT OPTION;
    mysql> GRANT ALL PRIVILEGES ON *.* TO monty@"%"
    IDENTIFIED BY 'some_pass' WITH GRANT OPTION;
    mysql> GRANT RELOAD,PROCESS ON *.* TO admin@localhost;
    mysql> GRANT USAGE ON *.* TO dummy@localhost;
    See here: http://www.mysql.com/doc/A/d/Adding_users.html
    cf: http://www.mysql.com/udmsearch/searc...q=add+new+user

    To only allow a user, monty, access to the db called 'montydb' just do:
    Code:
    mysql> GRANT ALL PRIVILEGES ON montydb.* TO monty@localhost /
               IDENTIFIED BY 'some_pass' WITH GRANT OPTION;

IMN logo majestic logo threadwatch logo seochat tools logo