aspose file tools*
The moose likes JDBC and the fly likes Encryption in SQL Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Encryption in SQL" Watch "Encryption in SQL" New topic
Author

Encryption in SQL

Ramesh Pramuditha Rathnayake
Ranch Hand

Joined: Oct 31, 2012
Posts: 169
    
    1

I have some questions....

Is there a way to decrypt MySQL password..? Or any software have been made..? (Password get from " Select Password('password') ")

I think that, it is possible to decrypt the password get from that command. Can we get more secure password to SQL...? Then how can we get it..?


Ramesh-X
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39549
    
  27
Passwords are generalls stored hashed (or digested), not encrypted. That means it is impossible to recover the password, as there is no decrpytion.

What is the underlying problem you're trying to solve?


Ping & DNS - updated with new look and Ping home screen widget
Ramesh Pramuditha Rathnayake
Ranch Hand

Joined: Oct 31, 2012
Posts: 169
    
    1

I want to know a better way to make a password. Is there any way to do it..?

Thank you for the reply...!
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39549
    
  27
What do you mean by "make a password"? And in which way do you want to improve on it?
Ramesh Pramuditha Rathnayake
Ranch Hand

Joined: Oct 31, 2012
Posts: 169
    
    1

make password means, create a password like in Select Password() command..

I have to know a way to improve its privacy. That means, ensure no one could break it..
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39549
    
  27
I have no idea what "Select Password() " does, and -I suspect- neither do a lot of other folks. So we can't say how that might be improved. If you search for "choosing a strong password" or some such phrase on Google, I'm sure you'll get lots of results.
Ramesh Pramuditha Rathnayake
Ranch Hand

Joined: Oct 31, 2012
Posts: 169
    
    1

Thank you for the reply..
Supun Lakshan Dissanayake
Ranch Hand

Joined: Oct 26, 2012
Posts: 131

Ulf Dittmer wrote:I have no idea what "Select Password() " does


imagine you create a table in mysql database and you store it for login data.
if somebody knows mysql commands he can read login data in previously mentioned table.
Isn't a security issue??

so you MUST encrypt secure data you insert into your table.

SELECT PASSWORD(123); command encrypts 123 into unrecognizable(you can read it but doesn't make any sense) string. So even you can't extract 123 from encrypted data.


Are you better than me? Then please show me my mistakes..
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 36514
    
  16
The password() function does not (I think) encrypt anything. What it does is to work out a hash, rather like an SHA. It gives the hash of the password string, but it is not possible to reconstruct the password from that hash.

[Add: That sounds just what what Ulf said nearly two weeks ago.]
Ramesh Pramuditha Rathnayake
Ranch Hand

Joined: Oct 31, 2012
Posts: 169
    
    1

Campbell Ritchie wrote:The password() function does not (I think) encrypt anything. What it does is to work out a hash, rather like an SHA. It gives the hash of the password string, but it is not possible to reconstruct the password from that hash.

[Add: That sounds just what what Ulf said nearly two weeks ago.]


What does mean by hash of the password..? Can we get hash in manual way..?
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 36514
    
  16
It is a sort of hash code. You can calculate it manually if you can find out the algorithm used.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Encryption in SQL
 
Similar Threads
Spring DataSource Defination With Secured Password
Encryption and Decryption - DB2 and JPA
password in memory
Encryption/Decryption using java or oracle
How to store passwords securly