修改MAC地址

Signed-off-by: kevin <kevin@lmve.net>
This commit is contained in:
2022-04-25 11:28:19 +08:00
parent 517bbaf4e7
commit 4b86bbd27f
2 changed files with 35 additions and 13 deletions
+23 -1
View File
@@ -140,11 +140,28 @@ char tryunlock(char *dir)
{
buff[0xf00+a]=id[a];
}
//change MAC ADD
if(fseek(bios,0x1000,SEEK_SET))
{
printf("ERROR. -0\n");
}else
{
for(a=0;a<32;a++)
{
id[a]=0;
}
fread(id,6,1,bios);
for(a=0;a<6;a++)
{
buff[0x1000+a]=id[a];
}
for(a=0;a<256;a++)
{
outputdir[a]=0;
}
printf("id: %s \n",id);
printf("MAC: %02X%02X%02X%02X%02X%02X \n",id[0],id[1],id[2],id[3],id[4],id[5]);
sprintf(outputdir,"%s%s",inputdir,"_unlock.bin");
printf("Output flie %s",outputdir);
output_bios=fopen(outputdir,"wb");
@@ -158,6 +175,11 @@ char tryunlock(char *dir)
}
printf("\n\n");
}
}
}
Binary file not shown.