#1
  1. Feelin' Groovy
    Devshed Supreme Being (6500+ posts)

    Join Date
    Aug 2001
    Location
    WDSMIA
    Posts
    10,135
    Rep Power
    5053

    MySQL access denied


    javax.servlet.ServletException: Invalid authorization specification: Access denied for user: 'root@localhost.localdomain' (Using password: YES)
    Suggestions as to why I can't seem to get around this? I use the same username and password in a PHP file to access a MySQL db and it works fine. Why would a request from a jsp file be denied?

    Let me know what other information I need to provide to help on this...

    Thanks for the newbie help in advance...
    Yawmark
    class Sig{public static void main(String...args){\u0066or(int
    \u0020$:"v\"ʲ\"vΤ\"".to\u0043h\u0061rArray()
    )System./*goto/*$/%\u0126//^\u002A\u002Fout.print((char)(($>>
    +(~'"'&'#'))+('<'>>('\\'/'.')/\u002Array.const(~1)\*\u002F)));}}
  2. #2
  3. Feelin' Groovy
    Devshed Supreme Being (6500+ posts)

    Join Date
    Aug 2001
    Location
    WDSMIA
    Posts
    10,135
    Rep Power
    5053
    I stumbled on the answer. I was specifying a password and didn't need to be...

    Thanks!
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2001
    Location
    NE Pa.
    Posts
    96
    Rep Power
    14
    Id like to see the code you are using for getting the driver & connecting. Id be willing to bet the url of the db is incorrect for your connection string. Ive seen this same error WAY too many times & 99% of the time I had used the wrong url...If you could post this code Ill look at it or send it to me ddalton@noln.com. Ill get back to you as soon as I get home from work
  6. #4
  7. Feelin' Groovy
    Devshed Supreme Being (6500+ posts)

    Join Date
    Aug 2001
    Location
    WDSMIA
    Posts
    10,135
    Rep Power
    5053
    Well, thanks, but like I said in the message above, I got it to work. The url was apparently correct, as it works now with the password not set.

    Here's the code:
    Code:
    conn = "jdbc:mysql://" + host + "/" + db + "?user=" + user + "$password=";
    Connection Conn = DriverManager.getConnection(conn);
    Yawmark
    class Sig{public static void main(String...args){\u0066or(int
    \u0020$:"v\"ʲ\"vΤ\"".to\u0043h\u0061rArray()
    )System./*goto/*$/%\u0126//^\u002A\u002Fout.print((char)(($>>
    +(~'"'&'#'))+('<'>>('\\'/'.')/\u002Array.const(~1)\*\u002F)));}}

IMN logo majestic logo threadwatch logo seochat tools logo