Secure mysql and ease of programming

Hello,
How/what do I set up so that I do not have to include in all my jsp files the connection information to my mysql database for my application? It is tedious to have to set up the try...catch..finally stuff everytime I want to have a query in my jsp files. I am using mysql and jakarta-tomcat-4.0.4.
David

Why don't you write a Database class, then when you want to access the database you can just create an instance of this class and call a method that does the connection, the trys & catches etc.
eg you could have a method with signature
public ResultSet exQuery(String query) etc etc.
Much better practice to only have one class that accesses the database - esp if you want to change drivers, connection methods etc in the future.

Similar Messages

  • MySQL and Java - getting program to work

    I am setting up mysql to run sql from a Java program on my pc at home and probably biting off more than I can chew. I get these messages when executing the java program ExecuteSQL.java:
    Exception in thread "main" java.lang.NoClassDefFoundError: Test2 <wrong name: MyProjects/test2/Test2>
    at java.lang.ClassLoader.defineClass0<Native Method>
    at java.lang.ClassLoader.defineClass<Unknown Source>
    at java.security.SecurityClassLoader.defineClass<Unknown Source>
    at java.net.URLClassLoader.defineClass<Unknown Source>
    at java.net.URLClassLoader.access$100<Unknown Source>
    at java.net.URLClassLoader$1.run<Unknown Source>
    at java.security.AccessController.ddPrivileged<Native Method>
    at java.lang.ClassLoader.findClass<Unknown Source>
    at java.lang.ClassLoader.loadClass<Unknown Source>
    at sun.misc.Launcher$AppClassLoader.loadClass<Unknown Source>
    at java.lang.ClassLoader.loadClass<Unknown Source>
    at java.lang.ClassLoader.loadClassInternal<Unknown Source>
    This is what I did.
    I created a folder on my C: drive named MySQL.
    I downloaded these two zip files form the MySQL website
         * mysql-connector-java-3.0.11-stable
         * mysql-4.0.18-win.zip
    Installed both of these in folder MySQL.
    I modified this line in the program ("ExecuteSQL" 1st pgm in chapter 17) I got from "Java Examples In a Nutshell" and compiled it into directory jwork.
    String driver = "com.mysql.jdbc.driver", url = "jdbc:mysql://", user = "", password = "";
    The readme file talks about putting a jar file in $JAVA_HOME/jre/lib/ext.
    the word "Java_Home" (I now know) is not literally the name but represents the
    name of the folder where the JDK to be used exists. So I put a copy of
    mysql-connector-java-3.0.11-stable-bin.jar in folder C:\JDK14/jre/lib/ext.
    Then I get a ClassNotFoundException error com.mysql.jdbc.driver.
    After finding
    http://forum.java.sun.com/thread.jsp?forum=31&thread=439796
    and
    http://forum.java.sun.com/thread.jsp?forum=31&thread=499888
    and others, I copied (a second copy) the jar file to the directory where I am create my java objects.
    Then I unzipped it to that directory, creating three folders that hold the unzipped objects.
    I tried executing the program again. I get the messages at the top of this post.
    The Manifest file is in one of the three folders unzipped to my java work directory.
    In the second of the two above threads, jsalonen says:
    the problem can be solved by mentioning mysql.jar in the Class-Path attribute
    in the manifest of the jar file:
    In this "manifest" file, there are only three lines and I added a fourth and it looks like this
    (there are two, one in directory MySQL\META-INF and one in directory jwork\META-INF:
    Manifest-Version: 1.0
    Ant-Version: Apache Ant 1.6.1
    Created-By: 1.4.0_01-b03 (Sun Microsystems Inc.)
    Main-Class:jwork\ExecuteSQL
    How do I "mention" mysql.jar in the class path attribute?
    In the index.list file (in the directory with the manifest file, do I need to add anything to refer that "com.mysql.jdbc.driver" is the driver?
    Do I need index.list in MySQL\META-INF ?
    Thank you for your help. The program ExecuteSQL follows.
    * Copyright (c) 2000 David Flanagan. All rights reserved.
    * This code is from the book Java Examples in a Nutshell, 2nd Edition.
    * It is provided AS-IS, WITHOUT ANY WARRANTY either expressed or implied.
    * You may study, use, and modify it for any non-commercial purpose.
    * You may distribute it non-commercially as long as you retain this notice.
    * For a commercial use license, or to purchase the book (recommended),
    * visit http://www.davidflanagan.com/javaexamples2.
    /** package com.davidflanagan.examples.sql; */
    import java.sql.*;
    import java.io.*;
    * A general-purpose SQL interpreter program.
    public class ExecuteSQL {
    public static void main(String[] args) {
    Connection conn = null; // Our JDBC connection to the database server
    try {
    String driver = "com.mysql.jdbc.driver", url = "jdbc:mysql://",
    user = "", password = "";
    // Parse all the command-line arguments
    for(int n = 0; n < args.length; n++) {
    if (args[n].equals("-d")) driver = args[++n];
    else if (args[n].equals("-u")) user = args[++n];
    else if (args[n].equals("-p")) password = args[++n];
    else if (url == null) url = args[n];
    else throw new IllegalArgumentException("Unknown argument.");
    // The only required argument is the database URL.
    if (url == null)
    throw new IllegalArgumentException("No database specified");
    // If the user specified the classname for the DB driver, load
    // that class dynamically. This gives the driver the opportunity
    // to register itself with the DriverManager.
    if (driver != null) Class.forName(driver);
    // Now open a connection the specified database, using the
    // user-specified username and password, if any. The driver
    // manager will try all of the DB drivers it knows about to try to
    // parse the URL and connect to the DB server.
    conn = DriverManager.getConnection(url, user, password);
    // Now create the statement object we'll use to talk to the DB
    Statement s = conn.createStatement();
    // Get a stream to read from the console
    BufferedReader in =
              new BufferedReader(new InputStreamReader(System.in));
    // Loop forever, reading the user's queries and executing them
    while(true) {
    System.out.print("sql> "); // prompt the user
    System.out.flush(); // make the prompt appear now.
    String sql = in.readLine(); // get a line of input from user
    // Quit when the user types "quit".
    if ((sql == null) || sql.equals("quit")) break;
    // Ignore blank lines
    if (sql.length() == 0) continue;
    // Now, execute the user's line of SQL and display results.
    try {
    // We don't know if this is a query or some kind of
    // update, so we use execute() instead of executeQuery()
    // or executeUpdate() If the return value is true, it was
    // a query, else an update.
    boolean status = s.execute(sql);
              // Some complex SQL queries can return more than one set
              // of results, so loop until there are no more results
    do {
    if (status) { // it was a query and returns a ResultSet
    ResultSet rs = s.getResultSet(); // Get results
    printResultsTable(rs, System.out); // Display them
    else {
    // If the SQL command that was executed was some
    // kind of update rather than a query, then it
    // doesn't return a ResultSet. Instead, we just
    // print the number of rows that were affected.
    int numUpdates = s.getUpdateCount();
    System.out.println("Ok. " + numUpdates +
                             " rows affected.");
    // Now go see if there are even more results, and
    // continue the results display loop if there are.
    status = s.getMoreResults();
    } while(status || s.getUpdateCount() != -1);
    // If a SQLException is thrown, display an error message.
    // Note that SQLExceptions can have a general message and a
    // DB-specific message returned by getSQLState()
    catch (SQLException e) {
    System.err.println("SQLException: " + e.getMessage()+ ":" +
                        e.getSQLState());
    // Each time through this loop, check to see if there were any
    // warnings. Note that there can be a whole chain of warnings.
    finally { // print out any warnings that occurred
              SQLWarning w;
    for(w=conn.getWarnings(); w != null; w=w.getNextWarning())
    System.err.println("WARNING: " + w.getMessage() +
                             ":" + w.getSQLState());
    // Handle exceptions that occur during argument parsing, database
    // connection setup, etc. For SQLExceptions, print the details.
    catch (Exception e) {
    System.err.println(e);
    if (e instanceof SQLException)
    System.err.println("SQL State: " +
                        ((SQLException)e).getSQLState());
    System.err.println("Usage: java ExecuteSQL [-d <driver>] " +
                   "[-u <user>] [-p <password>] <database URL>");
    // Be sure to always close the database connection when we exit,
    // whether we exit because the user types 'quit' or because of an
    // exception thrown while setting things up. Closing this connection
    // also implicitly closes any open statements and result sets
    // associated with it.
    finally {
    try { conn.close(); } catch (Exception e) {}
    * This method attempts to output the contents of a ResultSet in a
    * textual table. It relies on the ResultSetMetaData class, but a fair
    * bit of the code is simple string manipulation.
    static void printResultsTable(ResultSet rs, OutputStream output)
         throws SQLException
    // Set up the output stream
    PrintWriter out = new PrintWriter(output);
    // Get some "meta data" (column names, etc.) about the results
    ResultSetMetaData metadata = rs.getMetaData();
    // Variables to hold important data about the table to be displayed
    int numcols = metadata.getColumnCount(); // how many columns
    String[] labels = new String[numcols]; // the column labels
    int[] colwidths = new int[numcols]; // the width of each
    int[] colpos = new int[numcols]; // start position of each
    int linewidth; // total width of table
    // Figure out how wide the columns are, where each one begins,
    // how wide each row of the table will be, etc.
    linewidth = 1; // for the initial '|'.
    for(int i = 0; i < numcols; i++) {             // for each column
    colpos[i] = linewidth; // save its position
    labels[i] = metadata.getColumnLabel(i+1); // get its label
    // Get the column width. If the db doesn't report one, guess
    // 30 characters. Then check the length of the label, and use
    // it if it is larger than the column width
    int size = metadata.getColumnDisplaySize(i+1);
    if (size == -1) size = 30; // Some drivers return -1...
         if (size > 500) size = 30; // Don't allow unreasonable sizes
    int labelsize = labels.length();
    if (labelsize > size) size = labelsize;
    colwidths[i] = size + 1; // save the column the size
    linewidth += colwidths[i] + 2; // increment total size
    // Create a horizontal divider line we use in the table.
    // Also create a blank line that is the initial value of each
    // line of the table
    StringBuffer divider = new StringBuffer(linewidth);
    StringBuffer blankline = new StringBuffer(linewidth);
    for(int i = 0; i < linewidth; i++) {
    divider.insert(i, '-');
    blankline.insert(i, " ");
    // Put special marks in the divider line at the column positions
    for(int i=0; i<numcols; i++) divider.setCharAt(colpos[i]-1,'+');
    divider.setCharAt(linewidth-1, '+');
    // Begin the table output with a divider line
    out.println(divider);
    // The next line of the table contains the column labels.
    // Begin with a blank line, and put the column names and column
    // divider characters "|" into it. overwrite() is defined below.
    StringBuffer line = new StringBuffer(blankline.toString());
    line.setCharAt(0, '|');
    for(int i = 0; i < numcols; i++) {
    int pos = colpos[i] + 1 + (colwidths[i]-labels[i].length())/2;
    overwrite(line, pos, labels[i]);
    overwrite(line, colpos[i] + colwidths[i], " |");
    // Then output the line of column labels and another divider
    out.println(line);
    out.println(divider);
    // Now, output the table data. Loop through the ResultSet, using
    // the next() method to get the rows one at a time. Obtain the
    // value of each column with getObject(), and output it, much as
    // we did for the column labels above.
    while(rs.next()) {
    line = new StringBuffer(blankline.toString());
    line.setCharAt(0, '|');
    for(int i = 0; i < numcols; i++) {
    Object value = rs.getObject(i+1);
              if (value != null)
              overwrite(line, colpos[i] + 1, value.toString().trim());
    overwrite(line, colpos[i] + colwidths[i], " |");
    out.println(line);
    // Finally, end the table with one last divider line.
    out.println(divider);
    out.flush();
    /** This utility method is used when printing the table of results */
    static void overwrite(StringBuffer b, int pos, String s) {
    int slen = s.length(); // string length
    int blen = b.length(); // buffer length
    if (pos+slen > blen) slen = blen-pos; // does it fit?
    for(int i = 0; i < slen; i++) // copy string into buffer
    b.setCharAt(pos+i, s.charAt(i));

    Don't put those JARs in the lib/ext directory. Only language extensions (e.g., packages that start with "javax") belong in there.
    Learn how to set the CLASSPATH properly for starters:
    http://java.sun.com/j2se/1.4.2/docs/tooldocs/windows/classpath.html
    You might want to look at the JDBC tutorial, too:
    http://java.sun.com/docs/books/tutorial/jdbc/
    Do one thing at a time. Get the program to work, then worry about packaging it into an executable JAR.

  • After the latest Security Update 2012-001 (Mac OS X 10.6.8) my Adobe Photoshop CS 8, Dreamweaver 8, and InDesign CS programs crash when I try to save a file.

    After the latest Security Update 2012-001 (Mac OS X 10.6.8) my Adobe Photoshop CS 8, Dreamweaver 8, and InDesign CS programs crash when I try to save a file. HELP!!!

    Howdy,
    Apparently some are reporting that this causes the older PowerPC (PPC) applications that are supported in 10.6 via 'Rosetta' to crash upon attempting to open/save/print using any dialog box, or fail in other similar ways such as simply not printing or quitting, or freezing/hanging/crashing of the application.
    I have read of some companies that have indeed submitted proper bug reports to Apple, but that is not a guarantee of a bug-fix being issued.
    You might wish to read:
    http://www.macintouch.com/readerreports/snowleopard/index.html#d02feb2012
    If you are unsure if you are still using PowerPC apps, if the application is currently running, look under the 'Activity Monitior' (in Applications -> Utilities), or alternatively you could check in the System Profiler, Applications. Check the column "Type".
    Here is a fairly simple way you can restore you system and restore you applications functionality again, if you don't have a recent clone or good Time Machine backup that you can restore from. If you do, restore from your backup prior to having installed the Security Update 2012-001.
    Time Machine restore: http://support.apple.com/kb/ht1427
    If you are restoring a backup made by a Mac to the same Mac
    With your backup drive connected, start up your Mac from the Lion recovery partition (Command-R at startup) or Mac OS X v10.6 installation disc. Then use the "Restore From Time Machine Backup" utility. Select the backup prior to your issues, and it will be restored back to the state it was in at that time.
    If you can't easily restore from a backup, you can instead do the following:
    - You first start by reinstalling your OS X 10.6.x, this will preserve all your user data, your applications, no worries there.
    - Then install the Mac OS X 10.6.8 Update Combo v1.1 (links provided below)
    - Make sure you're printers are showing up correctly in your system preferences, if not, re-add the printers
    - Then finally, run the Apple Software Update (by pulling down the Apple Menu), and install any and all remaining updates, except do not then re-install the Security Update 2012-001. It is possible that you may have to reboot after installing some of the updates, and you may even need to run it a 2nd time to make sure that you've got all updates, except NOT the Security Update 2012-001.
    Links for 10.6.8 Update Combo v1.1:
    http://support.apple.com/kb/DL1399
    or the link to directly download this 1.09GB combo updater:
    http://support.apple.com/downloads/DL1399/en_US/MacOSXUpdCombo10.6.8.dmg
    Cheers,
    Daniel Feldman
    =======================
      MacMind
      Certified Member of the
      Apple Consultants Network
      Apple Certified (ACHDS)
      E-mail:  [email protected] 
      Phone:   1-408-454-6649
      URL : www.MacMind.com
    =======================

  • How can I sync security between Plannig, HSS and EAS?

    Hi,
    I think that I've trouble with security. Many answers at this forum contain that I need to sync security between Plannig, HSS and EAS?
    How can I do it on EPM11.1.1.3?

    Hi,
    If you feel that Shared Services is not in sync with Planning then you can use the [provisonusers |http://download.oracle.com/docs/cd/E12825_01/epm.111/hp_admin/ch03s13.html] utility.
    If you want to sync essbase with Shared Services you can either right click security in EAS and refresh from HSS or use Maxl.
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • I use Earthlink for email but want to change.  What else do Apple-users like for emails?  I use MBA and iPod Touch.  My concerns are security and ease of changing pswds --had a scary experience at Elink.

    I use Earthlink for email but want to change.  What else do Apple-users like?  I use MBA mid 2012 and iPod 5 touch.  Concerns are email security and ease of changing pswds.

    Apple has made several well-publicised statements regarding their commitment to privacy and the security of their various iCloud services. If they were to fall short of a goal they stated so prominently for so long, it would have a material effect on the company's value, not to mention being extremely embarrassing. I think they're pretty serious about it.
    Like anything else though, iCloud is as secure as the passwords you use. To change your iCloud password read iCloud: Change your iCloud account password.

  • Performance with MySQL and Database connectivity toolbox

    Hi!
    I'm having quite some problems with the performance of MySQL and Database connectivity toolbox. However, I'm very happy with the ease of using database connectivity toolbox. The background is:
    I have 61 variables (ints and floats) which I would like to save in the MySQL-database. This is no problem, however, the loop time increases from 8ms to 50ms when using the database. I have concluded that it has to do with the DB Tools Insert Data.vi and I think that I have some kind of performance issue with this VI. The CPU never reach more the 15% of its maximum performance. I use a default setup and connect through ODBC.
    My questions are:
    1. I would like to save 61 variables each 8-10ms, is this impossible using this solution?
    2. Is there any way of increasing the performance of the DB Tools Insert Data.vi or use any other VI?
    3. Is there any way of adjusting the MySQL setup to achieve better performance?
    Thank you very much for your time.
    Regards,
    Mattias

    First of all, thank you very much for your time. All of you have been really good support to me.
    >> Is your database on a different computer?  Does your loop execute 61 times? 
    Database is on the same computer as the MySQL server.
    The loop saves 61 values at once to the database, in one SQL-statement.
    I have now added the front panel and block diagram for my test-VI. I have implemented the queue system and separate loops for producer and consumer. However, since the queue is building up faster then the consumer loop consumes values, the queue is building up quite fast and the disc starts working.
    The test database table that I add data to is created by a simple:
    create table test(aa int, bb char(15));
    ...I'm sure that this can be improved in some way.
    I always open and close the connection to the database "outside the loop". However, it still takes some 40-50 ms to save the data to the database table - so, unfortunatly no progress to far. I currently just want to save the data.
    Any more advise will be gratefully accepted.
    Regards,
    Mattias
    Message Edited by mattias@hv on 10-23-2007 07:50 AM
    Attachments:
    front panel 2.JPG ‏101 KB
    block diagram.JPG ‏135 KB

  • It will not allow me to download itunes it will run it then do securtiy check and then say program can not be downloaded, it will not allow me to download itunes it will run it then do securtiy check and then say program can not be downloaded

    im trying to downlaod itunes to my computer i have windows 7 home preimum 32bit so i meet what u need to downlaod it but i will hit run or save either or it will start downloading then it will run the security check and then say that the program can not be downloaded i have norton virus as my protection on my computer i turned it off and trieed again and it still is doing the same thing it will not allow me to download itunes

    Try disable all restrictions
    Settings>General>Restrictions

  • I downloaded the latest Firefox security update and my computer will no longer access the internet in any fashion, despite the fact that I'm still connected to the internet. Other browsers no longer work either.

    Immediately after I downloaded the latest firefox security update my computer will no longer access the internet. I still have a fine wireless connection but Firefox, Internet Explorer, Itunes, and every other program will no longer access the internet, saying there is a connection error. I even tried restoring my system to a previous date but it said that a security program was preventing it from doing so.

    What's the security program called? Is it '''Win 7 Security''' by any chance? There's a rogue AV app that will prevent internet access by that name. It comes in many different flavours, but it's basically the same product with different names depending on the operating system its aimed at. See screenshot.
    Do you have another computer you can use to download Malwarebytes? Or can you get a friend to download it for you and copy it to a USB drive? Download from here: http://www.malwarebytes.org/products/malwarebytes_free
    You can use the USB drive to transfer the program to your own PC and then install it.

  • MySQL and JDBC Classpath errors

    I am new to Java and installed MySql and also installed mysql-connectorJ driver. I can compile the code below, but when I go to run it, I get "Exception in thread "main" java.lang.NoClassDefFoundError: JDBCDemo/class" error. I can't figure out what I am doing wrong.
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.SQLException;
    public class JDBCDemo {
         public static void main(String[] args) {
              try{  
    Class.forName("com.mysql.jdbc.Driver");
              catch (Exception e)
                   e.printStackTrace();
    I have a the following environment variable called MySQL_Driver located at "C:\Program Files\Java\jdk1.5.0_06\lib".
    Path = "%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\Common Files\Roxio Shared\DLLShared;%JAVA_HOME%;%JAVA_HOME%\lib;%JAVA_VM%\bin;%JAVA_VM%\lib;C:\Program Files\Microsoft SQL Server\80\Tools\BINN;C:\Program Files\QuickTime\QTSystem\;%MySQL_Driver%"

    What is your CLASSPATH set to as you need to make sure that the driver is in the path as well as the directory/jar where the JDBCDemo app lives.
    Try explictly specifying everything via the -classpath option on your java command line

  • HT5312 How to restart my account security question and passworld ID?

    I went to restart my security questions and ID passworld went  download programs today

    Welcome to the user to User Technical Support Forum provided by Apple.
    amalmb wrote:
    I went to restart my security questions 
    If by Restart you mean Reset... But you have Forgotten them...
    See Here > Apple ID: Contacting Apple for help with Apple ID account security
              Ask to speak with the Account Security Team...
      Or Email Here  >  Apple  Support  iTunes Store  Contact
    amalmb wrote:
    ...  ID passworld...
    Changing your Apple ID  >  http://support.apple.com/kb/HT5621
    Note:
    Anything Downloaded with a Particular Apple ID is tied to that Apple ID and Cannot be Merged or Transferred to a Different Apple ID
    Apple ID FAQs  >  http://support.apple.com/kb/HT5622

  • Using MySql and PHP with Dreamweaver on a Mac

    Hello all,
    As always if the answers to these questions are obscenely
    obvious please humour me.
    I use XHTML and CSS in my websites and realise that it is
    time that I dabbled with SSI. So I've started using PHP.
    However, I have been following the installation directions of
    MySql and am running into problems. I am installing the relavent
    software and am then unable to find it on my Mac, the startup files
    are there but the actual MySql data appears to not be installed
    despite my computer telling me it is...... I am using a G3 running
    OSX 10.4 is this good enough? I noticed talk of needing a PowerPC
    or Intel mac. Is this the case?
    Also, would I need MySql installed on my actual computer if
    the my servers have it already? And does Dreamweaver 8 have both of
    these programs installed as standard?
    If you could help out I would be very appreciative as I would
    like to learn this stuff and I appear to be struggling at the
    outset....
    Cheers
    M.A

    M.A.Wilson wrote:
    > However, I have been following the installation
    directions of MySql and am
    > running into problems. I am installing the relavent
    software and am then unable
    > to find it on my Mac, the startup files are there but
    the actual MySql data
    > appears to not be installed despite my computer telling
    me it is...... I am
    > using a G3 running OSX 10.4 is this good enough? I
    noticed talk of needing a
    > PowerPC or Intel mac. Is this the case?
    MySQL is a relational database management system that
    comprises a
    database server and several utility programs. Although you
    install it
    like any other program on a Mac, the similarity stops there.
    First, the point about PowerPC and Intel Macs is that there
    are
    different versions of the MySQL installer for each type of
    processor.
    I'm pretty sure that a G3 is OK, but you must choose the
    PowerPC version
    of MySQL, not the 64-bit or x86 (Intel Mac) version.
    Once you have installed MySQL, you need to drag the
    MySQL.PrefPane icon
    from the disk image onto your System Preferences. This
    installs a
    Preference Pane that enables you to start and stop MySQL. The
    Preference
    Pane has an option to start up MySQL automatically, but in my
    experience, it doesn't work on Tiger. You need to open the
    Preference
    Pane, and click Start MySQL Server each time you start your
    computer.
    The best way to work with MySQL is to use a graphical
    interface, such as
    phpMyAdmin. As Osgood has mentioned, I have written a book
    about PHP and
    Dreamweaver, which goes into all the necessary details. It's
    also very
    Mac-friendly with separate instructions where necessary for
    PC and Mac.
    More details here:
    http://foundationphp.com/dreamweaver8/
    David Powers
    Author, "Foundation PHP for Dreamweaver 8" (friends of ED)
    Author, "Foundation PHP 5 for Flash" (friends of ED)
    http://foundationphp.com/

  • Securing mysql initial accounts

    Hi                                                                                                                                           
    MySQL by default in the install process create 2 users: root and anonymous, each one connecting through 'localhost' and trought the actual 'hostname', so there are 4 accounts with empty passwords in the grant tables.                                                                 
    But in the wiki they only mention the root account, and they only explain howto set the password for one account, leaving empty the password of the other root account.                                                                                                       
    In the MySQL reference manual: http://dev.mysql.com/doc/mysql/en/defau … leges.html they explain one must give passwords to the two root
    accounts and either give passwords or delete the anonymous accounts.                                                                       
    I don't know if this is something we must add to the wiki.

    matthew stuart wrote:
    > I am in the process of installing MySQL and PHP on my
    Mac and I have come to a
    > section that is called 'Securing MySQL on Mac OSX'.
    >
    > Basically it states that MySQL is up and running with a
    default account of
    > 'root' and it's not password protected and so I need to
    plug that security gap.
    >
    > I've always used root as my account when working on PC's
    but having read this
    > in David's book, I am now concerned; does this mean that
    I am open to attack
    > from a potential hacker if I don't password protect
    MySQL?
    >
    > It mentions that root in MySQL has nothing to do with
    the root of Mac OSX, but
    > I need to know if MySQL being unprotected in this way
    has opened a door for
    > hackers.
    Is your computer behind a firewall? Can your computer be seen
    on the
    internet? If not, then its only people inside your network
    that can see
    your computer and access it.
    To be safe, just give the mysql root user a nice secure
    password.
    I always create a mysql user for front end connections, with
    limited
    permissions, and then another one for back end connections,
    with
    relevant permissions for its tasks.
    Dooza
    Posting Guidelines
    http://www.adobe.com/support/forums/guidelines.html
    How To Ask Smart Questions
    http://www.catb.org/esr/faqs/smart-questions.html

  • Client Security Solution and Office 2010's Word and Outlook

    I purchased my system June 16, 2009 with Vista downgraded to XP Pro so I was not able to purchase a upgrade disk from Lenovo to upgrade to Win 7 (deadline was June 22). This week I purchased the Windows 7,retail  64 bit Home Premium upgrade package at a local store.
    I did the upgrade (clean install) Windows 7 64 bit Home Premium on my ThinkPad T400 type 2764-CTO. Also successfully installed all Win 7, 64 bit ThinkVantage software with System Update 4.
    I manually Installed the file z909zis1032us00.exe Client Security Solution 8.3 for Windows 7 (64-bit only) Version: 8.30.0032.00 Note: When upgrading from Windows XP To use TPM with Win 7 erase TPM in the BIOS configuration utility. In the Security and Security Chip menu, locate the option to clear the security device referred to as Security Chip and clear. If not done you can install but not use the program.
    Then I had this issue with Client Security - Password Manager version 8.30.00.32.00 and Office 2010's Word & Outlook. This was before I spotted a tread with the same issue between Password Manager 3.20.0320.00 and Office 2007.
    I noticed that whenever I run Word 2010 or Outlook in conjunction with Client Security SolutionI I could not select text. I could no longer use CSS because of it...
    I called Lenovo and was told that they do not support retail version of Win 7. (Remember they refuse to sell me their version a week earlier). Because I dint know what to do, I deactivated the TPM in Client Security and it solve the problem in both Word & Outlook.
    On the following automatic System Update at the Lenovo site the system pick up something was wrong with Client Security (it did not when the TPM was activated???) and offered to download and install "Client Security Solution Office 2007 Patch 64bit". I did and following installation I re activated the TPM. The problem in Word & Outlook was no longer there.
    Then on the next system update the system offered to download and install "Patch for IE crash with Password Manager (Win7) version 1.0". I had not experience that problem but downloaded and let the system install it anyway.
    So the problem is not restricted to version 8. 3.20.0320.00 and Office 2007 as reported in the other thread. Because the patch was automatically downloaded fron the web site (Client Security Solution Office 2007 Patch 64bit)  I do not know if it is the same patch the was offered in that thread.
    I hope this will help other people having the same problem.
    Claude

    Hi All,
    May i know the version of the CSS? Is it Windows 7 CSS 8.3 ? 32 bit or 64 bit? Would love to know more in detailed for i could report to the development team.
    Thanks!
    Regards,
    Cleo
    WW Social Media
    T61, T410, x240, Z500, Flex 14
    Important Note: If you need help, post your question in the forum, and include your system type, model number and OS. Do not post your serial number.
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution"!
    Follow @LenovoForums on Twitter!
    How to send a private message? --> Check out this article.
    English Community   Deutsche Community   Comunidad en Español   Русскоязычное Сообщество

  • Tiger going crazy on iBook G4 with new security update and Safari 3

    I'm running 10.4.11, 1.42GHz PPC G4 with 1.5GB of SDRAM.
    So I ran software update where I noticed new Security Update and Safari update.
    I tried to run the new Safari - Nothing, it's dead, no action! ( could hear hard drive but no action)
    Today I tried running 'Software Update', it's spinning it's wheels, over and over again.
    I'm sure Apple is working on sending me an email, as they got the skinny when the program crashed I forwarded the system message.
    So a bit frustrated hear, I'm using Safari and getting to know Camino.
    The Biggest frustration is that 'Mail' will not boot up so I use my internet to check mail, bummer.
    So lets hope we get some info soon.
    Loyal Apple User
    Ken

    If you are operating behind a proxy server, maybe this will help.
    With regards to crashes from behind a proxy server, I came up with a work around!
    I have been using Automatic proxy configuration using a .pac file. That seems to be causing the error.
    After inspecting the .pac file, and following the if, ifelse path, at the very bottom is a proxy address and port for unclassified connections. Mine looks like this
    proxy.sun.ac.za Port :####
    I have put this into my System Preferences for all connection types, manually. This is found under, System Preferences: Built-in Ethernet: Configure Manually...
    Then you need to go through the box on the left and check each box. As you do so, paste the default proxy address and port in the open boxes on the right.
    Hope this work around helps. My Quicktime is still not working for my older .avi files.
    bmyia

  • Upgraded my touch smart 520-1070 to windows 8 and now no program under hp touch smart works?

    Upgraded my touch smart 520-1070 to Windows 8 and now no program under hp touch smart works (HP MUsic, HP Touch Smart Magic Canvas, etc)? Everything worked fine under Windows 7. No other problems with the Window 8 installation. It was very smooth.
    Any Fixes or patches available?

    Please see "HP - Upgrading from Windows 7 to Windows 8" for more information on limitations and requirements of upgrading a HP Windows 7 computer to Windows 8.
    Not all Windows 8 features may be available on all Windows 7 computers. Your computer may require additional hardware, software, firmware, and/or a BIOS upgrade to install and run Windows 8.
    Secure boot is not available on any HP Consumer Desktop or All-in-One computers.
    If you purchased your computer prior to October 1st , 2011, HP has not tested or developed drivers for your model computer. Therefore an upgrade of your computer may be difficult or impossible.
    HP recommends installing the 64-bit version of Windows 8 for desktop computers.
    Not all Windows 8 features will be available on all computers, and your particular experience with Windows 8 is determined by the capabilities of your computer.
    Software designed for Windows 7 or earlier operating systems may not work after installing Windows 8.
    HP provides Windows 8 compatible software and updated drivers to support only specific computer models.
    You might not be able to view DVD movies after upgrading. If you currently use a DVD codec to play DVD movies, such as the encoder that comes with Windows 7 Professional, this encoder may not be available after upgrading to Windows 8. To continue to play DVDs after you upgrade, go to http://windows.microsoft.com/en-US/windows-8/feature-packs to download Windows Media Center or purchase DVD playback software.
    If you currently use DVD playback software from HP, the Windows 8 installation process helps you determine if your playback software is compatible with Windows 8 or if an update is required. If the software is compatible and you perform an In-place Upgrade, you have the option to keep this software during the upgrade. If you perform a Clean Install you must reinstall the software after the upgrade.
    Windows 7 PCs with touch will not have full Windows 8 touch capabilities after upgrade. HP PCs with touch input hardware designed for Windows 7 will provide a comparable experience for only two touch point applications after the upgrade to Windows 8. HP Windows PCs with touch input hardware will not support Windows 8 applications that require more than two simultaneous touch points.
    WARNING:HP Linkup, HP Application Assistant, HP TouchSmart Magic Canvas and all other HP TouchSmart applications are not compatible with Windows 8 and must be uninstalled before upgrading. Content created using the TouchSmart applications such as Graffiti will not be available after upgrading.
    Frank
    {------------ Please click the "White Kudos" Thumbs Up to say THANKS for helping.
    Please click the "Accept As Solution" on my post, if my assistance has solved your issue. ------------V
    This is a user supported forum. I am a volunteer and I don't work for HP.
    HP 15t-j100 (on loan from HP)
    HP 13 Split x2 (on loan from HP)
    HP Slate8 Pro (on loan from HP)
    HP a1632x - Windows 7, 4GB RAM, AMD Radeon HD 6450
    HP p6130y - Windows 7, 8GB RAM, AMD Radeon HD 6450
    HP p6320y - Windows 7, 8GB RAM, NVIDIA GT 240
    HP p7-1026 - Windows 7, 6GB RAM, AMD Radeon HD 6450
    HP p6787c - Windows 7, 8GB RAM, NVIDIA GT 240

Maybe you are looking for

  • SSRS report with tabular model - MDX query to filter parameter data based on Tuple value.

    Hello Everyone, I am working on SSRS report in which a tabular model is being used as a backend. I want to filter the report parameters which are dependent to other parameters. Like, country, state, and cities drop downs. All are multi-select paramet

  • HpEenvy 4500 Printer Woes and Windows 8.1

    Has anyone figured out how to get the Hp Envy 4500 Printer to keep on printing in Windows 8.1? We have called tech support twice, they remotely accessed our computer to set the drivers correctly. At first the printer worked right maybe once or twice

  • RFBIBL00  and LSMW

    Hello abapers, I have a problem. My upload file is structured therefore: |Header data|Item1 data|Item2 data How I can make to divide the record, in LSMW, so as to register FI document? Thank. Bye.

  • I need a logic

    Hi, Could anyone plz give me a logic for the following: If i have some mail ids ending with .infy.com ,.tcs.com and some other ids in my database.And i just want to  retrive only the mail ids ending with *.infy.com from the database so what is the lo

  • Weird! error handling not functioning

    hi all we have method A:   public int issueItemWorkOrder( String sWORKON ) throws SQLException, Exception {calling method B:   public float getQtyAvailable( String sITEM ) throws SQLException, Exception {method B raises an exception that is not being