程序测试系统:win98
编译工具:turboc2
以下为cmospass的源代码:cmospass.c
代码:
--------------------------------------------------------------------------------
#include
#include
#include
void main()
{
int n;
char comspass;
char temp=0;
printf("/nThis program only is tested at win98 and award bios!!/n");
printf("The password of the cmos is:");
outportb(0x70,0x1d);
comspass=inportb(0x71);
for(n=6;n>=0;n-=2)
{ temp=cmospass;
temp>>=n;
temp=temp&0x03;
printf("%d",temp);
}
outportb(0x70,0x1c);
result=inportb(0x71);
for(n=6;n>=0;n-=2)
{ temp=cmospass;
temp>>=n;
temp=temp&0x03;
printf("%d",temp);
}
printf("/n--By red");
printf("/n--http://red123.oicp.net!!");
printf("/n----2004.01.04---- /n");
}
编译工具:turboc2
以下为cmospass的源代码:cmospass.c
代码:
--------------------------------------------------------------------------------
#include
#include
#include
void main()
{
int n;
char comspass;
char temp=0;
printf("/nThis program only is tested at win98 and award bios!!/n");
printf("The password of the cmos is:");
outportb(0x70,0x1d);
comspass=inportb(0x71);
for(n=6;n>=0;n-=2)
{ temp=cmospass;
temp>>=n;
temp=temp&0x03;
printf("%d",temp);
}
outportb(0x70,0x1c);
result=inportb(0x71);
for(n=6;n>=0;n-=2)
{ temp=cmospass;
temp>>=n;
temp=temp&0x03;
printf("%d",temp);
}
printf("/n--By red");
printf("/n--http://red123.oicp.net!!");
printf("/n----2004.01.04---- /n");
}