用MD5加密以下为MD5文件内的源代码,然后在别的网页中嵌入,用md5(字段名)就可以实现加密效果了
--------------------
<%
Private Const BITS_TO_A_BYTE = 8
Private Const BYTES_TO_A_WORD = 4
Private Const BITS_TO_A_WORD = 32
Private m_lOnBits(30)
Private m_l2Power(30)
Private Function LShift(lValue, iShiftBits)
If iShiftBits = 0 Then
LShift = lValue
Exit Function
ElseIf iShiftBits = 31 Then
If lValue And 1 Then
LShift = &H80000000
Else
LShift = 0
End If
Exit Function
ElseIf iShiftBits < 0 Or iShiftBits > 31 Then
ErrRaise 6
End If
If (lValue And m_l2Power(31 - iShiftBits)) Then
LShift = ((lValue And m_lOnBits(31 - (iShiftBits + 1))) m_l2Power(iShiftBits)) Or &H80000000
Else
LShift = ((lValue And m_lOnBits(31 - iShiftBits)) m_l2Power(iShiftBits))
End If
End Function
Private Function RShift(lValue, iShiftBits)
If iShiftBits = 0 Then
RShift = lValue
Exit Function
ElseIf iShiftBits = 31 Then
If lValue And &H80000000 Then
RShift = 1
Else
RShift = 0
End If
Exit Function
ElseIf iShiftBits < 0 Or iShiftBits > 31 Then
ErrRaise 6
End If
RShift = (lValue And &H7FFFFFFE) \ m_l2Power(iShiftBits)
If (lValue And &H80000000) Then
RShift = (RShift Or (&H40000000 \ m_l2Power(iShiftBits - 1)))
End If
End Function
Private Function RotateLeft(lValue, iShiftBits)
RotateLeft = LShift(lValue, iShiftBits) Or RShift(lValue, (32 - iShiftBits))
End Function
Private Function AddUnsigned(lX, lY)
Dim lX4
Dim lY4
Dim lX8
Dim lY8
Dim lResult
lX8 = lX And &H80000000
lY8 = lY And &H80000000
lX4 = lX And &H40000000
lY4 = lY And &H40000000
lResult = (lX And &H3FFFFFFF) + (lY And &H3FFFFFFF)
If lX4 And lY4 Then
lResult = lResult Xor &H80000000 Xor lX8 Xor lY8
ElseIf lX4 Or lY4 Then
If lResult And &H40000000 Then
lResult = lResult Xor &HC0000000 Xor lX8 Xor lY8
Else
lResult = lResult Xor &H40000000 Xor lX8 Xor lY8
End If
Else
lResult = lResult Xor lX8 Xor lY8
End If
AddUnsigned = lResult
End Function
Private Function md5_F(x, y, z)
md5_F = (x And y) Or ((Not x) And z)
End Function
Private Function md5_G(x, y, z)
md5_G = (x And z) Or (y And (Not z))
End Function
Private Function md5_H(x, y, z)
md5_H = (x Xor y Xor z)
End Function
Private Function md5_I(x, y, z)
md5_I = (y Xor (x Or (Not z)))
End Function
Private Sub md5_FF(a, b, c, d, x, s, ac)
a = AddUnsigned(a, AddUnsigned(AddUnsigned(md5_F(b, c, d), x), ac))
a = RotateLeft(a, s)
a = AddUnsigned(a, b)
End Sub
Private Sub md5_GG(a, b, c, d, x, s, ac)
a = AddUnsigned(a, AddUnsigned(AddUnsigned(md5_G(b, c, d), x), ac))
a = RotateLeft(a, s)
a = AddUnsigned(a, b)
End Sub
Private Sub md5_HH(a, b, c, d, x, s, ac)
a = AddUnsigned(a, AddUnsigned(AddUnsigned(md5_H(b, c, d), x), ac))
a = RotateLeft(a, s)
a = AddUnsigned(a, b)
End Sub
Private Sub md5_II(a, b, c, d, x, s, ac)
a = AddUnsigned(a, AddUnsigned(AddUnsigned(md5_I(b, c, d), x), ac))
a = RotateLeft(a, s)
a = AddUnsigned(a, b)
End Sub
Private Function ConvertToWordArray(sMessage)
Dim lMessageLength
Dim lNumberOfWords
Dim lWordArray()
Dim lBytePosition
Dim lByteCount
Dim lWordCount
Const MODULUS_BITS = 512
Const CONGRUENT_BITS = 448
lMessageLength = Len(sMessage)
lNumberOfWords = (((lMessageLength + ((MODULUS_BITS - CONGRUENT_BITS) \ BITS_TO_A_BYTE)) \ (MODULUS_BITS \ BITS_TO_A_BYTE)) + 1) (MODULUS_BITS \ BITS_TO_A_WORD)
ReDim lWordArray(lNumberOfWords - 1)
lBytePosition = 0
lByteCount = 0
Do Until lByteCount >= lMessageLength
lWordCount = lByteCount \ BYTES_TO_A_WORD
lBytePosition = (lByteCount Mod BYTES_TO_A_WORD) BITS_TO_A_BYTE
lWordArray(lWordCount) = lWordArray(lWordCount) Or LShift(Asc(Mid(sMessage, lByteCount + 1, 1)), lBytePosition)
lByteCount = lByteCount + 1
Loop
lWordCount = lByteCount \ BYTES_TO_A_WORD
lBytePosition = (lByteCount Mod BYTES_TO_A_WORD) BITS_TO_A_BYTE
lWordArray(lWordCount) = lWordArray(lWordCount) Or LShift(&H80, lBytePosition)
lWordArray(lNumberOfWords - 2) = LShift(lMessageLength, 3)
lWordArray(lNumberOfWords - 1) = RShift(lMessageLength, 29)
ConvertToWordArray = lWordArray
End Function
Private Function WordToHex(lValue)
Dim lByte
Dim lCount
For lCount = 0 To 3
lByte = RShift(lValue, lCount BITS_TO_A_BYTE) And m_lOnBits(BITS_TO_A_BYTE - 1)
WordToHex = WordToHex & Right("0" & Hex(lByte), 2)
Next
End Function
Public Function MD5(sMessage)
m_lOnBits(0) = CLng(1)
m_lOnBits(1) = CLng(3)
m_lOnBits(2) = CLng(7)
m_lOnBits(3) = CLng(15)
m_lOnBits(4) = CLng(31)
m_lOnBits(5) = CLng(63)
m_lOnBits(6) = CLng(127)
m_lOnBits(7) = CLng(255)
m_lOnBits(8) = CLng(511)
m_lOnBits(9) = CLng(1023)
m_lOnBits(10) = CLng(2047)
m_lOnBits(11) = CLng(4095)
m_lOnBits(12) = CLng(8191)
m_lOnBits(13) = CLng(16383)
m_lOnBits(14) = CLng(32767)
m_lOnBits(15) = CLng(65535)
m_lOnBits(16) = CLng(131071)
m_lOnBits(17) = CLng(262143)
m_lOnBits(18) = CLng(524287)
m_lOnBits(19) = CLng(1048575)
m_lOnBits(20) = CLng(2097151)
m_lOnBits(21) = CLng(4194303)
m_lOnBits(22) = CLng(8388607)
m_lOnBits(23) = CLng(16777215)
m_lOnBits(24) = CLng(33554431)
m_lOnBits(25) = CLng(67108863)
m_lOnBits(26) = CLng(134217727)
m_lOnBits(27) = CLng(268435455)
m_lOnBits(28) = CLng(536870911)
m_lOnBits(29) = CLng(1073741823)
m_lOnBits(30) = CLng(2147483647)
m_l2Power(0) = CLng(1)
m_l2Power(1) = CLng(2)
m_l2Power(2) = CLng(4)
m_l2Power(3) = CLng(8)
m_l2Power(4) = CLng(16)
m_l2Power(5) = CLng(32)
m_l2Power(6) = CLng(64)
m_l2Power(7) = CLng(128)
m_l2Power(8) = CLng(256)
m_l2Power(9) = CLng(512)
m_l2Power(10) = CLng(1024)
m_l2Power(11) = CLng(2048)
m_l2Power(12) = CLng(4096)
m_l2Power(13) = CLng(8192)
m_l2Power(14) = CLng(16384)
m_l2Power(15) = CLng(32768)
m_l2Power(16) = CLng(65536)
m_l2Power(17) = CLng(131072)
m_l2Power(18) = CLng(262144)
m_l2Power(19) = CLng(524288)
m_l2Power(20) = CLng(1048576)
m_l2Power(21) = CLng(2097152)
m_l2Power(22) = CLng(4194304)
m_l2Power(23) = CLng(8388608)
m_l2Power(24) = CLng(16777216)
m_l2Power(25) = CLng(33554432)
m_l2Power(26) = CLng(67108864)
m_l2Power(27) = CLng(134217728)
m_l2Power(28) = CLng(268435456)
m_l2Power(29) = CLng(536870912)
m_l2Power(30) = CLng(1073741824)
Dim x
Dim k
Dim AA
Dim BB
Dim CC
Dim DD
Dim a
Dim b
Dim c
Dim d
Const S11 = 7
Const S12 = 12
Const S13 = 17
Const S14 = 22
Const S21 = 5
Const S22 = 9
Const S23 = 14
Const S24 = 20
Const S31 = 4
Const S32 = 11
Const S33 = 16
Const S34 = 23
Const S41 = 6
Const S42 = 10
Const S43 = 15
Const S44 = 21
x = ConvertToWordArray(sMessage)
a = &H67452301
b = &HEFCDAB89
c = &H98BADCFE
d = &H10325476
For k = 0 To UBound(x) Step 16
AA = a
BB = b
CC = c
DD = d
md5_FF a, b, c, d, x(k + 0), S11, &HD76AA478
md5_FF d, a, b, c, x(k + 1), S12, &HE8C7B756
md5_FF c, d, a, b, x(k + 2), S13, &H242070DB
md5_FF b, c, d, a, x(k + 3), S14, &HC1BDCEEE
md5_FF a, b, c, d, x(k + 4), S11, &HF57C0FAF
md5_FF d, a, b, c, x(k + 5), S12, &H4787C62A
md5_FF c, d, a, b, x(k + 6), S13, &HA8304613
md5_FF b, c, d, a, x(k + 7), S14, &HFD469501
md5_FF a, b, c, d, x(k + 8), S11, &H698098D8
md5_FF d, a, b, c, x(k + 9), S12, &H8B44F7AF
md5_FF c, d, a, b, x(k + 10), S13, &HFFFF5BB1
md5_FF b, c, d, a, x(k + 11), S14, &H895CD7BE
md5_FF a, b, c, d, x(k + 12), S11, &H6B901122
md5_FF d, a, b, c, x(k + 13), S12, &HFD987193
md5_FF c, d, a, b, x(k + 14), S13, &HA679438E
md5_FF b, c, d, a, x(k + 15), S14, &H49B40821
md5_GG a, b, c, d, x(k + 1), S21, &HF61E2562
md5_GG d, a, b, c, x(k + 6), S22, &HC040B340
md5_GG c, d, a, b, x(k + 11), S23, &H265E5A51
md5_GG b, c, d, a, x(k + 0), S24, &HE9B6C7AA
md5_GG a, b, c, d, x(k + 5), S21, &HD62F105D
md5_GG d, a, b, c, x(k + 10), S22, &H2441453
md5_GG c, d, a, b, x(k + 15), S23, &HD8A1E681
md5_GG b, c, d, a, x(k + 4), S24, &HE7D3FBC8
md5_GG a, b, c, d, x(k + 9), S21, &H21E1CDE6
md5_GG d, a, b, c, x(k + 14), S22, &HC33707D6
md5_GG c, d, a, b, x(k + 3), S23, &HF4D50D87
md5_GG b, c, d, a, x(k + 8), S24, &H455A14ED
md5_GG a, b, c, d, x(k + 13), S21, &HA9E3E905
md5_GG d, a, b, c, x(k + 2), S22, &HFCEFA3F8
md5_GG c, d, a, b, x(k + 7), S23, &H676F02D9
md5_GG b, c, d, a, x(k + 12), S24, &H8D2A4C8A
md5_HH a, b, c, d, x(k + 5), S31, &HFFFA3942
md5_HH d, a, b, c, x(k + 8), S32, &H8771F681
md5_HH c, d, a, b, x(k + 11), S33, &H6D9D6122
md5_HH b, c, d, a, x(k + 14), S34, &HFDE5380C
md5_HH a, b, c, d, x(k + 1), S31, &HA4BEEA44
md5_HH d, a, b, c, x(k + 4), S32, &H4BDECFA9
md5_HH c, d, a, b, x(k + 7), S33, &HF6BB4B60
md5_HH b, c, d, a, x(k + 10), S34, &HBEBFBC70
md5_HH a, b, c, d, x(k + 13), S31, &H289B7EC6
md5_HH d, a, b, c, x(k + 0), S32, &HEAA127FA
md5_HH c, d, a, b, x(k + 3), S33, &HD4EF3085
md5_HH b, c, d, a, x(k + 6), S34, &H4881D05
md5_HH a, b, c, d, x(k + 9), S31, &HD9D4D039
md5_HH d, a, b, c, x(k + 12), S32, &HE6DB99E5
md5_HH c, d, a, b, x(k + 15), S33, &H1FA27CF8
md5_HH b, c, d, a, x(k + 2), S34, &HC4AC5665
md5_II a, b, c, d, x(k + 0), S41, &HF4292244
md5_II d, a, b, c, x(k + 7), S42, &H432AFF97
md5_II c, d, a, b, x(k + 14), S43, &HAB9423A7
md5_II b, c, d, a, x(k + 5), S44, &HFC93A039
md5_II a, b, c, d, x(k + 12), S41, &H655B59C3
md5_II d, a, b, c, x(k + 3), S42, &H8F0CCC92
md5_II c, d, a, b, x(k + 10), S43, &HFFEFF47D
md5_II b, c, d, a, x(k + 1), S44, &H85845DD1
md5_II a, b, c, d, x(k + 8), S41, &H6FA87E4F
md5_II d, a, b, c, x(k + 15), S42, &HFE2CE6E0
md5_II c, d, a, b, x(k + 6), S43, &HA3014314
md5_II b, c, d, a, x(k + 13), S44, &H4E0811A1
md5_II a, b, c, d, x(k + 4), S41, &HF7537E82
md5_II d, a, b, c, x(k + 11), S42, &HBD3AF235
md5_II c, d, a, b, x(k + 2), S43, &H2AD7D2BB
md5_II b, c, d, a, x(k + 9), S44, &HEB86D391
a = AddUnsigned(a, AA)
b = AddUnsigned(b, BB)
c = AddUnsigned(c, CC)
d = AddUnsigned(d, DD)
Next
MD5 = LCase(WordToHex(a) & WordToHex(b) & WordToHex(c) & WordToHex(d))
' MD5=LCase(WordToHex(b) & WordToHex(c)) 'I crop this to fit 16byte database password :D
End Function
%>
if not rsPointbof then
rsPointMovePrevious
else
rsPointMoveNext
end if
假如他不是最上面一跳可以上移 否则下一一条
ActiveServerPages,ASP0126(0x80004005)-->找不到包含文件
MicrosoftOLEDBProviderforODBCDrivers(0x80040E21)-->sql语句出错(数据类型不匹配或表名(字段名)错误或表处于编辑状态,或表不存在于conn打开的数据库中)
MicrosoftOLEDBProviderforODBCDrivers(0x80040E14)-->sql语句出错(字段名错误,或数据类型不匹配)
MicrosoftOLEDBProviderforODBCDrivers(0x80040E07)-->sql语句出错(要插入或更新的字段的类型与变量数据类型不匹配)
MicrosoftOLEDBProviderforODBCDrivers(0x80040E57)-->sql语句出错(要插入或更新的数据溢出)
MicrosoftOLEDBProviderforODBCDrivers(0x80040E10)-->sql语句出错(update字段名或要更新的数据类型错误)
MicrosoftOLEDBProviderforODBCDrivers(0x80004005)-->sql语句出错(要插入或更新的字段的数值不能为空值)
MicrosoftOLEDBProviderforODBCDrivers(0x80004005) -->打开数据库出错,没有在指定目录发现数据库
MicrosoftOLEDBProviderforODBCDrivers(0x80040E37)-->没有发现表
MicrosoftVBscript运行时错误(0x800A000D)-->错误引用rs变量(rs对像已关闭或未定义)
MicrosoftVBscript运行时错误(0x800A01C2)-->vbscript脚本错误(vbscript语句出错)
MicrosoftVBscript运行时错误(0x800A0006)-->vbscript脚本错误(溢出错误)
MicrosoftVBscript编译器错误(0x800A040E)-->缺少loop
MicrosoftVBscript编译器错误(0x800A03EA)-->缺少if或endif
MicrosoftVBscript编译器错误(0x800A03EE)--> 语句未结束(缺少")")
MicrosoftVBscript编译器错误(0x800A03F6)-->if语句出错(缺少endif)
MicrosoftVBscript运行时错误(0x800A005B)-->缺少set
MicrosoftVBscript运行时错误(0x800A0005)-->变量未定义
MicrosoftVBscript编译器错误(0x800A03F9)-->if语句缺少then
MicrosoftVBscript编译器错误(0x800A0411)-->dim语句定义错误
MicrosoftVBscript编译器错误(0x800A0408)-->sql语句错误()
Microsoft VBScript 运行时错误 (0x800A01B6)错误原因:set rs=servercreate你少了 set
ADODBRecordset(0x800A0BB9)-->sql语句出错(sql语句或conn语句未定义或对一个rs属性进行赋值时发生错误)
ADODBRecordset(0x800A0CC1)-->rs对像出错(rs对像本身不存在或错误地引用了一个不存在的字段名)
ADODBRecordset(0x800A0BCD)-->rs对像出错(记录集中没有记录却对记录集进行 *** 作)
ADODBRecordset(0x800A0E78)-->rs对像出错(记录集不存在,缺少rsopen语句)
ADODBRecordset(0x800A0CC1) -->rs对像出错(引用了一个不存在的字段名)
ADODBRecordset(0x800A0E7D)-->conn定义错误
ADODBRecordset(0x800A0CB3)-->数据库以只读方式打开,无法更新数据
如果 VBScript 语句结构违反了一个或多个 VBScript 脚本语言语法规则,就会产生 VBScript 语法错误。
错误通常在执行程序前,编译程序时产生。 以下是53个语法错误:
错误编号 描述
十进制 十六进制 说明
1001 800A03E9 内存不足
1002 800A03EA 语法错误
1003 800A03EB 缺少“:”
1005 800A03ED 需要 '('
1006 800A03EE 需要 ')'
1007 800A03EF 缺少“]”
1010 800A03F2 需要标识符
1011 800A03F3 需要 '='
1012 800A03F4 需要 'If'
1013 800A03F5 需要 'To'
1014 800A03F6 需要 'End'
1015 800A03F7 需要 'Function'
1016 800A03F8 需要 'Sub'
1017 800A03F9 需要 'Then'
1018 800A03FA 需要 'Wend'
1019 800A03FB 需要 'Loop'
1020 800A03FC 需要 'Next'
1021 800A03FD 需要 'Case'
1022 800A03FE 需要 'Select'
1023 800A03FF 需要表达式
1024 800A0400 需要语句
1025 800A0401 需要语句的结束
1026 800A0402 需要整数常数
1027 800A0403 需要 'While' 或 'Until'
1028 800A0404 需要 'While,'、 'Until,' 或语句未结束
1029 800A0405 需要 'With'
1030 800A0406 标识符太长
1031 800A0407 无效的数
1032 800A0408 无效的字符
1033 800A0409 未结束的串常量
1034 800A040A 未结束的注释
1037 800A040D 无效使用关键字 'Me'
1038 800A040E 'loop' 没有 'do'
1039 800A040F 无效 'exit' 语句
1040 800A0410 无效 'for' 循环控制变量
1041 800A0411 名称重定义
1042 800A0412 必须为行的第一个语句
1043 800A0413 不能赋给非Byval参数
1044 800A0414 调用 Sub 时不能使用圆括号
1045 800A0415 需要文字常数
1046 800A0416 需要 'In'
1047 800A0417 需要 'Class'
1048 800A0418 必须在一个类的内部定义
1049 800A0419 在属性声明中需要 Let , Set 或 Get
1050 800A041A 需要 'Property'
1051 800A041B 参数数目必须与属性说明一致
1052 800A041C 在类中不能有多个缺省的属性/方法
1053 800A041D 类初始化或终止不能带参数
1054 800A041E Property Let 或 Set 至少应该有一个参数
1055 800A041F 不需要的 'Next'
1056 800A0420 只能在 ‘Property’ 或 ’Function’ 或 ’Sub’ 上指定 ’Default’
1057 800A0421 说明 'Default' 必须同时说明 'Public' "
1058 800A0422 只能在 Property Get 中指定 'Default'
VBScript 运行时错误
如果 VBScript 脚本执行系统无法实施的 *** 作,则会产生 VBScript 运行时错误。只有在运行脚本、为变量表达式赋值或
分配内存时,才会产生 VBScript 运行时错误。 以下是65个运行时错误:
错误编号 描述
十进制 十六进制 说明
5 800A0005 无效过程调用或参数
6 800A0006 溢出
7 800A0007 内存不足
9 800A0009 下标越界
10 800A000A 该数组为定长的或临时被锁定
11 800A000B 被零除
13 800A000D 类型不匹配
14 800A000E 字符串空间溢出
17 800A0011 无法执行请求的 *** 作
28 800A001C 堆栈溢出
35 800A0023 未定义 Sub 或 Function
48 800A0030 加载 DLL 错误
51 800A0033 内部错误
52 800A0034 坏文件名或数
53 800A0035 文件未找到
54 800A0036 坏文件模式
55 800A0037 文件已经打开
57 800A0039 设备I/O错误
58 800A003A 文件已经存在
61 800A003D 磁盘空间已满
62 800A003E 输入超出文件尾
67 800A0043 文件太多
68 800A0044 设备不可用
70 800A0046 权限禁用
71 800A0047 磁盘未准备好
74 800A004A 不能用不同的驱动器重新命名
75 800A004B 路径/文件访问错误
76 800A004C 路径未找到
91 800A005B 未设置对象变量
92 800A005C For 循环未初始化
94 800A005E 非法使用 Null
322 800A0142 不能建立所需临时文件
424 800A01A8 需要对象
429 800A01AD ActiveX 部件无法创建对象
430 800A01AE 类不支持自动化
432 800A01B0 在自动化 *** 作中未找到文件名或类名
438 800A01B6 对象不支持该属性或方法
440 800A01B8 Automation错误
445 800A01BD 对象不支持此 *** 作
446 800A01BE 对象不支持指定的参数
447 800A01BF 对象不支持当前的区域设置
448 800A01C0 未找到命名参数
449 800A01C1 参数不可选
450 800A01C2 错误的参数个数或无效的参数属性值
451 800A01C3 对象不是一个集合
453 800A01C5 指定的dll函数未找到
455 800A01C7 代码源锁错误
457 800A01C9 这个键已经是本集合的一个元素关联
458 800A01CA 变量使用了一个 VBScript 中不支持的自动化(Automation)类型
462 800A01CE 远程服务器不存在或不能访问
481 800A01E1 无效
500 800A01F4 变量未定义
501 800A01F5 违法的分配
502 800A01F6 脚本对象不安全
503 800A01F7 对象不能安全初始化
504 800A01F8 对象不能安全创建
505 800A01F9 无效的或不合格的引用
506 800A01FA 类未被定义
507 800A01FB 发生异常
5016 800A1398 需要正则表达式对象
5017 800A1399 正则表达式中的语法错误
5018 800A139A 错误的数量词
5019 800A139B 在正则表达式中需要 ']'
5020 800A139C 在正则表达式中需要 ')'
5021 800A139D 字符集越界
32811 800A802B 元素未找到
以上就是关于access数据库问题全部的内容,包括:access数据库问题、VB编程连接ACCESS数据库,想向上一条移动时,出现事实错误424要求对象。、JSP删除ACCESS数据库中一条记录,为什么会出现"参数不足,期待是 1"等相关内容解答,如果想了解更多相关内容,可以关注我们,你们的支持是我们更新的动力!
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)