encryption with asp...

Results 1 to 2 of 2

Thread: encryption with asp...

  1. #1
    Join Date
    Dec 1969

    Default encryption with asp...

    Hi all.<BR>I want to encrypt the data in a system that I&#039;m creating.<BR>The data will be stored in an access db.<BR><BR>I never used any encryption and I know nothing about it.. where can I learn more about this subject and what are the best ways to do it??<BR><BR>thanks.

  2. #2
    Join Date
    Dec 1969

    Default RE: encryption with asp...

    I use this little function I found on the web:<BR><BR> Public Function RndCrypt(ByVal Cc, ByVal Password)<BR> &#039;* Purpose : Used to encrypt credit cards and passwords. Found this<BR> &#039;* on the Web and it works.<BR> Dim SK<BR> Dim K<BR> Dim Result<BR><BR> &#039; init randomizer for password<BR> Rnd -1<BR> Randomize Len(Password)<BR> &#039; (((K Mod 256) Xor Asc(Mid$(Password, K, 1))) Xor Fix(256 * Rnd)) -&#062; makes sure that a<BR> &#039; password like "pass12" does NOT give the same result as the password "sspa12" or "12pass"<BR> &#039; or "1pass2" etc. (or any combination of the same letters)<BR><BR> For K = 1 To Len(Password)<BR> SK = SK + (((K Mod 256) Xor Asc(Mid(Password, K, 1))) Xor Fix(256 * Rnd))<BR> Next<BR><BR> &#039; init randomizer for encryption/decryption<BR> Rnd -1<BR> Randomize SK<BR><BR> &#039; encrypt/decrypt every character using the randomizer<BR> For K = 1 To Len(Cc)<BR> Result = Result & CStr(Chr(Fix(256 * Rnd) Xor Asc(Mid(Cc, K, 1))))<BR> Next<BR><BR> RndCrypt = Result<BR> End Function<BR><BR>Cc is the string you want to encrypt/decrypt<BR>Password is a BIG honking string to encrypt/decrypt against.<BR><BR>Hope this helps!<BR><BR>Sparky

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts