Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- #include<stdlib.h>
- #include<string.h>
- char buff[]="\xAA\x89\xC4\xFE\x46\x78\xF0\xD0\x03\xE7\xF7\xFD\xF4\xE7\xB9\xB5\x1B\xC9\x50\x73";
- int main(int argc,char** argv)
- {
- char username[strlen(argv[1])+1],truepass[50],temppass[4]="\x00\x00\x00\x00",temp,temppass2[4];
- int i,z;
- strcpy(username,argv[1]);
- for(i=1;i<=strlen(argv[1]);i++)
- {
- temp=username[i];
- username[i]^=buff[(i-1)%5];
- buff[(i-1)%5]=temp;
- }
- username[i]='\0';
- for(i=strlen(argv[1]);i>=1;i--)
- {
- temp=username[i];
- username[i]^=buff[((strlen(argv[1])-i)%5)+5];
- buff[((strlen(argv[1])-i)%5)+5]=temp;
- }
- for(i=1;i<=strlen(argv[1]);i++)
- {
- temp=username[i];
- username[i]^=buff[((i-1)%5)+10];
- buff[((i-1)%5)+10]=temp;
- }
- for(i=strlen(argv[1]);i>=1;i--)
- {
- temp=username[i];
- username[i]^=buff[((strlen(argv[1])-i)%5)+15];
- buff[((strlen(argv[1])-i)%5)+15]=temp;
- }
- for(i=1;i<=strlen(argv[1]);i++)
- temppass[(i-1)%4]+=username[i]&0xFF;
- for(i=0;i<4;i++)
- temppass2[i]=temppass[3-i]&0xFF;
- for(i=0;i<4;i++)
- z|=(temppass2[i]&0xFF)<<2*(12-i*4);
- for(i=0;z!=0;i++,z/=0x0A&0xFFFFFFFF)
- truepass[i]=(((z&0xFFFFFFFF)%0x0A)+0x30)&0xFF;
- truepass[i]='\0';
- printf("\n\nUsername : %s\nSerial : ",argv[1]);
- for(i=strlen(truepass)-1;i>=0;i--)
- printf("%c",truepass[i]);
- printf("\n\n");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement