Authorware版算法源码公布:(既然已经被人破解了,那么就公布算法源代码吧)
pass := EntryText
nPassLen := CharCount(pass)
if nPassLen<4 then
Quit(0)
else
user:=ReadExtFile("c:\\u.dat")
if IOStatus<>0 then --文件不存在或者出错
Quit(0)
else
nUserLen:=CharCount(user)
if nUserLen<6 then --用户名长度小于6位
Quit(0)
end if
end if
end if
repeat while nUserLen>0
c:=SubStr(user,nUserLen,nUserLen)
ps := ps + Code(c)*Day-Minute+Year**Number(SubStr(String(Minute),1,1))+Day**Number(SubStr(String(Minute),1,1))
ps := ps*nUserLen
nUserLen:=nUserLen-1
end repeat
if CharCount(ps)>20 then --如果位数太长,只取前20位
ps := SubStr(ps, 1, 20)
end if
nPsLen := CharCount(String(ps))
if nPassLen<>nPsLen then
Quit(0)
else
p1 := Number(pass)
p2 := Number(ps)
if p1<>p2 then
Quit(0)
end if
end if