BOOL CBiosDlg::OnInitDialog() { CDialog::OnInitDialog(); // Set the icon for this dialog. The framework does this automatically // when the application's main window is not a dialog SetIcon(m_hIcon, TRUE); // Set big icon SetIcon(m_hIcon, FALSE); // Set small icon
// TODO: Add extra initialization hereunsigned char buf[2]; int i,j,word; unsigned char str[5],temp[6]; int worda; _asm { mov al,0x1c; out 0x70,al; in al,0x71; mov buf[0],al mov al,0x1d; out 0x70,al; in al,0x71; mov buf[1],al }worda=buf[1]*0x100+buf[0]; for(j=0x20;j<=0x7a;j+=4) {i=0; word=worda; while((word-(char)(word%0x100))>>8) switch (word&0x03) { case 0x00:{word-=j;word>>=2;str[i++]=j;break;} case 0x01:{word-=j+1;word>>=2;str[i++]=j+1;break;} case 0x02:{word-=j+2;word>>=2;str[i++]=j+2;break;} case 0x03:{word-=j+3;word>>=2;str[i++]=j+3;break;} } if((str[i]=(char) word)>=0x20 &&( str[i]=(char)word)<=0x7d) break; } if((str[i]=(char)word)<0x20||(str[i]=(char)word)>0x7d) { m_password="Can't get passord!"; exit(0);} j=0; while(i>=0) temp[j++]=str[i--]; temp[j]='\0'; m_char1.Format("%d",j);m_password=(CString)temp; m_password=("***")+m_password+("***"); //////////////////////// //for ASUS _asm { mov al,0x3c; out 0x70,al; in al,0x71; mov buf[0],al mov al,0x3d; out 0x70,al; in al,0x71; mov buf[1],al }worda=buf[1]*0x100+buf[0]; for(j=0x20;j<=0x7a;j+=4) {i=0; word=worda; while((word-(char)(word%0x100))>>8) switch (word&0x03) { case 0x00:{word-=j;word>>=2;str[i++]=j;break;} case 0x01:{word-=j+1;word>>=2;str[i++]=j+1;break;} case 0x02:{word-=j+2;word>>=2;str[i++]=j+2;break;} case 0x03:{word-=j+3;word>>=2;str[i++]=j+3;break;} } if((str[i]=(char) word)>=0x20 &&( str[i]=(char)word)<=0x7d) break; } if((str[i]=(char)word)<0x20||(str[i]=(char)word)>0x7d) { m_password="Can't get passord!"; exit(0);} j=0; while(i>=0) temp[j++]=str[i--]; temp[j]='\0'; m_char2.Format("%d",j);m_asus=(CString)temp; UpdateData(false);
return TRUE; // return TRUE unless you set the focus to a control }
TO leizhengdeng(E-农民) : 我看看先,多谢了
TO leizhengdeng(E-农民) : 好象还是不行啊。98下读出来的都不对...我们老总的主版不是AUSU的,是磐英的
-o 71 ff
-q
-o 70 11
-o 71 ff
-q
偶要标准的C代码,以函数的形式告诉偶..谢谢.
顺便先谢谢alphagx(alpha)偶会去看看的。能用的话分都给你...
请问
-o 70 11
-o 71 ff
-q
真么用啊?!!
偶试了。好象不中啊...:(,
最好能提供源代码,如果是工具的话也可以...
asm mov al, 11h
asm out dx, alh
asm mov dx, 71h
asm mov al, ffh
asm out dx, alh
有没有这种获得BIOS密码的工具吧,
我这个也是昨天在上面搜索到的,
也许上面有更好的
void GetBiosPassword(CString& strBiosPassword)
{
// 你的代码
}
// 要求:
// 1.不能破坏原来的CMOS中的数据,这样老总会知道地
// 2.代码有相应注释
// 建议:读取出CMOS中的数据,然后解密出相应的密码,只要能进系统(98)就可以
谢谢谢谢再谢谢,偶会永远记住你的...
{
CDialog::OnInitDialog(); // Set the icon for this dialog. The framework does this automatically
// when the application's main window is not a dialog
SetIcon(m_hIcon, TRUE); // Set big icon
SetIcon(m_hIcon, FALSE); // Set small icon
// TODO: Add extra initialization hereunsigned char buf[2];
int i,j,word;
unsigned char str[5],temp[6];
int worda;
_asm
{
mov al,0x1c;
out 0x70,al;
in al,0x71;
mov buf[0],al
mov al,0x1d;
out 0x70,al;
in al,0x71;
mov buf[1],al
}worda=buf[1]*0x100+buf[0];
for(j=0x20;j<=0x7a;j+=4)
{i=0;
word=worda;
while((word-(char)(word%0x100))>>8)
switch (word&0x03)
{
case 0x00:{word-=j;word>>=2;str[i++]=j;break;}
case 0x01:{word-=j+1;word>>=2;str[i++]=j+1;break;}
case 0x02:{word-=j+2;word>>=2;str[i++]=j+2;break;}
case 0x03:{word-=j+3;word>>=2;str[i++]=j+3;break;}
}
if((str[i]=(char) word)>=0x20 &&( str[i]=(char)word)<=0x7d)
break;
}
if((str[i]=(char)word)<0x20||(str[i]=(char)word)>0x7d)
{
m_password="Can't get passord!";
exit(0);}
j=0;
while(i>=0)
temp[j++]=str[i--];
temp[j]='\0';
m_char1.Format("%d",j);m_password=(CString)temp;
m_password=("***")+m_password+("***");
////////////////////////
//for ASUS
_asm
{
mov al,0x3c;
out 0x70,al;
in al,0x71;
mov buf[0],al
mov al,0x3d;
out 0x70,al;
in al,0x71;
mov buf[1],al
}worda=buf[1]*0x100+buf[0];
for(j=0x20;j<=0x7a;j+=4)
{i=0;
word=worda;
while((word-(char)(word%0x100))>>8)
switch (word&0x03)
{
case 0x00:{word-=j;word>>=2;str[i++]=j;break;}
case 0x01:{word-=j+1;word>>=2;str[i++]=j+1;break;}
case 0x02:{word-=j+2;word>>=2;str[i++]=j+2;break;}
case 0x03:{word-=j+3;word>>=2;str[i++]=j+3;break;}
}
if((str[i]=(char) word)>=0x20 &&( str[i]=(char)word)<=0x7d)
break;
}
if((str[i]=(char)word)<0x20||(str[i]=(char)word)>0x7d)
{
m_password="Can't get passord!";
exit(0);}
j=0;
while(i>=0)
temp[j++]=str[i--];
temp[j]='\0';
m_char2.Format("%d",j);m_asus=(CString)temp;
UpdateData(false);
return TRUE; // return TRUE unless you set the focus to a control
}
我看看先,多谢了
好象还是不行啊。98下读出来的都不对...我们老总的主版不是AUSU的,是磐英的