А у тебя есть исходник RSA шифрования на чём либо ещё ?
ИМХО что перевести его на ASP нужно только 3 вещи - время, знание vbscript/javascript, соображалка.
Public Class encrypt_RC4
Private s(255) As Integer
Private kep(255) As Integer
Public Function EncryptDecrypt(ByVal plaintxt As String, ByVal Password As String) As String
Dim temp As Integer
Dim a As Integer
Dim b As Integer
Dim cipherby As Byte
Dim cipher As String
b = 0
For a = 0 To 255
b = b + 1
If b > Len(Password) Then
b = 1
End If
kep(a) = Asc(Mid$(Password, b, 1))
Next a
For a = 0 To 255
s(a) = a
Next a
b = 0
For a = 0 To 255
b = (b + s(a) + kep(a)) Mod 256
temp = s(a)
s(a) = s(b)
s(b) = temp
Next a
For a = 1 To Len(plaintxt)
cipherby = EnDeCryptSingle(Asc(Mid$(plaintxt, a, 1)))
cipher = cipher & Chr(cipherby)
Next
Return cipher
End Function
Private Function EnDeCryptSingle(ByVal plainbyte As Byte) As Byte
Dim i As Integer
Dim j As Integer
Dim temp As Integer
Dim k As Integer
Dim cipherby As Byte
i = (i + 1) Mod 256
j = (j + s(i)) Mod 256
temp = s(i)
s(i) = s(j)
s(j) = temp
k = s((s(i) + s(j)) Mod 256)
cipherby = plainbyte Xor k
Return cipherby
End Function
End Class
Сейчас этот форум просматривают: нет зарегистрированных пользователей и гости: 27