Access的解密方法Private Function GetPassword(ByVal sFile As String) As String Dim sSource(1 To 40) As Byte Const iUBound2000 = 40 Const iUBound97 = 15 Dim i As Integer, k As Integer Dim sIn97 As Variant, sIn2000 As Variant, sOut97() As Long, sOut2000() As Long 'Access 97数据库未加密时的原始数据 sIn97 = Array(&H86, &HFB, &HEC, &H37, &H5D, _ &H44, &H9C, &HFA, &HC6, &H5E, _ &H28, &HE6, &H13, &HB6, &H8A) 'Access 2000数据库未加密时的原始数据 sIn2000 = Array(&H14, &H74, &HEC, &H37, &HCF, _ &HCB, &H9C, &HFA, &H54, &HD1, &H28, &HE6, _ &H81, &H39, &H8A, &H60, &HC6, &H1B, &H7B, _ &H36, &H67, &HFD, &HDF, &HB1, &HE5, &H7B, _ &H13, &H43, &H5D, &H20, &HB1, &H33, &HA6, _ &HEE, &H79, &H5B, &H0, &H3A, &H7C, &H2A) If IsArray(sIn97) Then ReDim sOut97(1 To UBound(sIn97)) As Long If IsArray(sIn2000) Then ReDim sOut2000(1 To UBound(sIn2000)) As Long On Error GoTo errGetPassword Open sFile For Binary Access Read Shared As #1 Get #1, 67, sSource Close #1 For i = 1 To iUBound2000 If iUBound97 >= i Then sOut97(i) = sIn97(i) Xor sSource(i) sOut2000(i) = sIn2000(i) Xor sSource(i) Next i For i = 1 To iUBound97 If sOut97(i) = 0 Then Exit For Else k = 1 End If Next i GetPassword = "" '假设为Access 97数据库 If k = 0 Then GetPassword = "未设密码" Else For i = 1 To iUBound97 If sOut97(i) > 0 Then GetPassword = GetPassword & Chr(sOut97(i)) Next i GetPassword = StrZToStr(GetPassword) '如果获取密码失败则假设数据库为Access 2000数据库 If GetPassword = "" Then k = 0 For i = 1 To iUBound2000 If sOut2000(i) = 0 Then Exit For Else k = 1 End If Next i If k = 0 Then GetPassword = "未设密码" Else For i = 1 To iUBound2000 If sOut2000(i) > 0 Then GetPassword = GetPassword & Chr(sOut2000(i)) Next i GetPassword = StrZToStr(GetPassword) End If End If End If Exit Function errGetPassword: MsgBox Err.Description, vbExclamation + vbOKOnly, App.ProductName On Error Resume Next Close #1 End Function 以上代码来自: SourceCode Explorer(源代码数据库) 复制时间: 2002-08-12 22:15:55 当前版本: 1.0.725 软件作者: Shawls 个人主页: Http://Shawls.Yeah.Net E-Mail: [email protected] QQ: 9181729
wo zhi dao ,wait for me!!!!!!!!! if lcase(right(text1.text,3))<>mdb then msgbox"...............",vbokonly,"..." exit sub end if dim strbyte(13) as byte open text1.text for binary access read as #1 get #1, 67, strbyte close #1 dim strpw strpw="" if (strbytes(0) xor 134)=0 then msgbox"没有密码",vbokonly,"tishi" else strpw=strpw&chr(strbytes(0) xor &H86) strpw=strpw&chr(strbytes(1) xor &HFB) strpw=strpw&chr(strbytes(2) xor &HEC) strpw=strpw&chr(strbytes(3) xor &H37) strpw=strpw&chr(strbytes(4) xor &H5D) strpw=strpw$chr(strbytes(5) xor &H44) strpw=strpw&chr(strbytes(6) xor &H9C) strpw=strpw&chr(strbytes(7) xor &HFA) strpw=strpw&chr(strbytes(8) xor &HC6) strpw=strpw&chr(strbytes(9) xor &H5E) strpw=strpw&chr(strbytes(10) xor &H28) strpw=strpw&chr(strbytes(11) xor &HF6) strpw=strpw&chr(strbytes(12) xor &H13) text2.text="你的密码:"+strpw end if
Dim sSource(1 To 40) As Byte
Const iUBound2000 = 40
Const iUBound97 = 15
Dim i As Integer, k As Integer
Dim sIn97 As Variant, sIn2000 As Variant, sOut97() As Long, sOut2000() As Long
'Access 97数据库未加密时的原始数据
sIn97 = Array(&H86, &HFB, &HEC, &H37, &H5D, _
&H44, &H9C, &HFA, &HC6, &H5E, _
&H28, &HE6, &H13, &HB6, &H8A)
'Access 2000数据库未加密时的原始数据
sIn2000 = Array(&H14, &H74, &HEC, &H37, &HCF, _
&HCB, &H9C, &HFA, &H54, &HD1, &H28, &HE6, _
&H81, &H39, &H8A, &H60, &HC6, &H1B, &H7B, _
&H36, &H67, &HFD, &HDF, &HB1, &HE5, &H7B, _
&H13, &H43, &H5D, &H20, &HB1, &H33, &HA6, _
&HEE, &H79, &H5B, &H0, &H3A, &H7C, &H2A)
If IsArray(sIn97) Then ReDim sOut97(1 To UBound(sIn97)) As Long
If IsArray(sIn2000) Then ReDim sOut2000(1 To UBound(sIn2000)) As Long
On Error GoTo errGetPassword
Open sFile For Binary Access Read Shared As #1
Get #1, 67, sSource
Close #1
For i = 1 To iUBound2000
If iUBound97 >= i Then sOut97(i) = sIn97(i) Xor sSource(i)
sOut2000(i) = sIn2000(i) Xor sSource(i)
Next i
For i = 1 To iUBound97
If sOut97(i) = 0 Then
Exit For
Else
k = 1
End If
Next i
GetPassword = ""
'假设为Access 97数据库
If k = 0 Then
GetPassword = "未设密码"
Else
For i = 1 To iUBound97
If sOut97(i) > 0 Then GetPassword = GetPassword & Chr(sOut97(i))
Next i
GetPassword = StrZToStr(GetPassword)
'如果获取密码失败则假设数据库为Access 2000数据库
If GetPassword = "" Then
k = 0
For i = 1 To iUBound2000
If sOut2000(i) = 0 Then
Exit For
Else
k = 1
End If
Next i
If k = 0 Then
GetPassword = "未设密码"
Else
For i = 1 To iUBound2000
If sOut2000(i) > 0 Then GetPassword = GetPassword & Chr(sOut2000(i))
Next i
GetPassword = StrZToStr(GetPassword)
End If
End If
End If
Exit Function
errGetPassword:
MsgBox Err.Description, vbExclamation + vbOKOnly, App.ProductName
On Error Resume Next
Close #1
End Function 以上代码来自: SourceCode Explorer(源代码数据库)
复制时间: 2002-08-12 22:15:55
当前版本: 1.0.725
软件作者: Shawls
个人主页: Http://Shawls.Yeah.Net
E-Mail: [email protected]
QQ: 9181729
if lcase(right(text1.text,3))<>mdb then
msgbox"...............",vbokonly,"..."
exit sub
end if
dim strbyte(13) as byte
open text1.text for binary access read as #1
get #1, 67, strbyte
close #1
dim strpw
strpw=""
if (strbytes(0) xor 134)=0 then
msgbox"没有密码",vbokonly,"tishi"
else
strpw=strpw&chr(strbytes(0) xor &H86)
strpw=strpw&chr(strbytes(1) xor &HFB)
strpw=strpw&chr(strbytes(2) xor &HEC)
strpw=strpw&chr(strbytes(3) xor &H37)
strpw=strpw&chr(strbytes(4) xor &H5D)
strpw=strpw$chr(strbytes(5) xor &H44)
strpw=strpw&chr(strbytes(6) xor &H9C)
strpw=strpw&chr(strbytes(7) xor &HFA)
strpw=strpw&chr(strbytes(8) xor &HC6)
strpw=strpw&chr(strbytes(9) xor &H5E)
strpw=strpw&chr(strbytes(10) xor &H28)
strpw=strpw&chr(strbytes(11) xor &HF6)
strpw=strpw&chr(strbytes(12) xor &H13)
text2.text="你的密码:"+strpw
end if
文件大小:1476KB
更新日期:2001-8-13
运行环境:Win95/Win98/Win2000
http://soft.km169.net/soft/html/1203.htm
http://216.239.33.208/search?q=advanced+access+password+recovery&ie=UTF-8&oe=UTF-8&hl=en&btnG=Google+Search
http://yousoft.hi.com.cn/accesspwd.rar
可以解开!!试过N个