Encrypt your data using an ASP encryption algorithm

Source: Internet
Author: User
Using an ASP encryption algorithm to encrypt your data profile
First, a brief introduction to the background of encryption. Because the United States prohibits several cryptographic algorithms from exporting encrypted digits (such as SSL's 40-bit encryption limit), this article describes a simple character encryption algorithm that an ASP can use, rather than a restricted encryption algorithm. In fact, the encryption algorithm introduced here for the general application is enough to decrypt people for a while. Its encryption base is the simplest Vernum password method, which I will introduce in my next article.
Its rationale is that there is a need to encrypt the
PlainText and a randomly generated decryption key file. The two files are then combined to generate the ciphertext.
(plaintext) combination (key) = encrypted ciphertext
So this article is about the code that generates the key. We assume that the key we generated is a 512-bit long key, which is enough to encrypt a text character. The code is as follows:
keygen.asp file
<%
'******************************
' Keygen.asp
'******************************
Const g_keylocation = "C:key.txt"
Const G_keylen = 512
On Error Resume Next
Call Writekeytofile (KeyGeN (G_keylen), g_keylocation)
If ERR <> 0 Then
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.