securing mysql 3.x
Results 1 to 5 of 5

Thread: securing mysql 3.x

  1. #1
    Senior Member
    Join Date
    Dec 2003
    Posts
    317

    securing mysql 3.x

    im running a small message board with mysql 3 and php 4. apparently anybody can connect to the database as root using the -h <hostname> flag unless i change my root password. i checked google and mysql.com for the syntax for password changing on mysql 4 but i havent found anything that works. first of all, it never requires me to enter a username or password when i get on the command line. second, when i try to change the password with this command(which i think is the right one):
    Code:
    set password for 'root' = 'mypass';"
    it says "OK, blah, blah", but the password is still "nothing". i need to change the password and make it enforce it. anybody know how to do this on mysql 3? also, i was wondering, if im behind a firewall that blocks inbound connections on port 3306(mysql) im pretty safe anyway. also, could someone with no sql experience use phpmyadmin to access my database remotely without me having phpmyadmin installed on my server, cuz i have a friend who claims to be messing with the database, but i dont know how he could be since he doesnt even know what a select statement is...

  2. #2
    Just a Virtualized Geek MrLinus's Avatar
    Join Date
    Sep 2001
    Location
    Redondo Beach, CA
    Posts
    7,324
    Have you tried this as well?

    Code:
    SET PASSWORD FOR root@"localhost"=PASSWORD("password");
    MySQL Manual Page for SET PASSWORD
    Goodbye, Mittens (1992-2008). My pillow will be cold without your purring beside my head
    Extra! Extra! Get your FREE copy of Insight Newsletter||MsMittens' HomePage

  3. #3
    Senior Member
    Join Date
    Dec 2003
    Posts
    317
    that worked for changing the password, but if i get on by just executing "mysql" and not "mysql -u root -p" it just lets me on with root accesss. how can i make it check for a password always?

  4. #4
    Just a Virtualized Geek MrLinus's Avatar
    Join Date
    Sep 2001
    Location
    Redondo Beach, CA
    Posts
    7,324
    MySQL Manual Page on GRANT and DELETE. Take a read through this and particularly near the botton.

    Have you thought about upgrading to 4?
    Goodbye, Mittens (1992-2008). My pillow will be cold without your purring beside my head
    Extra! Extra! Get your FREE copy of Insight Newsletter||MsMittens' HomePage

  5. #5
    Senior Member
    Join Date
    Dec 2003
    Posts
    317
    thanx, i think this will help

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •