I want to encrypt/hide my connection string in my database.java class. I allready searched the internet but I didn't find anything usefull, maybe I searched the wrong keywords? Here is my current code.
conn = DriverManager.getConnection("jdbc:mysql://database/db", "username", "password");
How can I hide the username and password? So only my application can see it? And you can't see it when you extract the jar?
Thanks.