I have encripted password column in my table. I use VB6 code below to check password but it doesn't work. I think i have to call a function to decrypt it. Where and which function do i use in my sql code below with text1.text.


.......WHERE psw=' " & text1.text & " '

Recommended Answers

All 6 Replies

Umm.. Is it related to php ? :-/

Sorry, this is wrong place for this post.
I do apologise

Moved to VB section

Call Decript function before check. ......WHERE Decript(psw)=' " & text1.text & " ' Or
You can encript inputed pasw before check ......WHERE psw=' " & Encript(text1.text) & " '

Thank you Jx,

I have done it with your solution and solved. In Insert clause encrypt text1 with "AES_ENCRYPT". After i used code below to check text1.

....WHERE AES_DECRYPT(psw, 'text_key') = '" & Text1.Text & "';

You're Welcome...
Happy coding :)

commented: nice work +1
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.