Encrypte data into a table

M

Markus

Hallo

I hope some can help me I have a form where I am enter special type pin
numbers but I want the pin number to be encrypted and inserted into a SQL
table and I need to read the pin numbers out of the table again and decrypt
them. if any one has some code on how to do this it would be really a big
help


Regards
Markus.
 
6

'69 Camaro

Hi, Markus.
if any one has some code on how to do this it would be really a big
help

Sample VB code:

http://www.schneier.com/blowfish-download.html
http://www.di-mgt.com.au/cryptoBlowfishExDemo.html

Microsoft's CAPICOM and example code:

http://www.microsoft.com/downloads/...FamilyID=860EE43A-A843-462F-ABB5-FF88EA5896F6

HTH.

Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips.

(Please remove ZERO_SPAM from my reply E-mail address so that a message will
be forwarded to me.)
- - -
If my answer has helped you, please sign in and answer yes to the question
"Did this post answer your question?" at the bottom of the message, which
adds your question and the answers to the database of answers. Remember that
questions answered the quickest are often from those who have a history of
rewarding the contributors who have taken the time to answer questions
correctly.
 
M

Markus

Hallo

Do you maybe have a sample database where the code has been used That would
be a greate help

Markus
 
K

Klatuu

Here is a simple little routine than I use:

Public Function EncryptCode(iToDo As Integer, strPass As String, _
Optional iSeed As Integer) As String
Dim strValue As String
Dim lngMxx As Long
Dim lngPlace As Long

iSeed = IIf(iSeed = 0, 105, iSeed + 95)

For lngMxx = 1 To Len(strPass)
If iToDo = 1 Then
' encode
lngPlace = (Asc(Mid(strPass, lngMxx, 1)) + 2550 + iSeed - lngMxx)
Mod 255
Else
' decode
lngPlace = 255 - (Abs((Asc(Mid(strPass, lngMxx, 1)) - 2550 -
iSeed + lngMxx) Mod 255))
End If
strValue = strValue + Chr(lngPlace)
Next

EncryptCode = strValue

End Function
 
6

'69 Camaro

Hi, Markus.
Do you maybe have a sample database where the code has been used That
would
be a greate help

You may purchase one from the company I work for. If you don't go that
route, then if you find any simple algorithms on the Internet to copy, be
aware that simple algorithms are trivial to determine the key for decryption
and even more so when the algorithms don't use prime numbers.

HTH.

Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips.

(Please remove ZERO_SPAM from my reply E-mail address so that a message will
be forwarded to me.)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top