Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions ip.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ int main(){
banner();
size_t i;
char ip[100], *token;
unsigned int dec[3];
unsigned int dword, dec[3];
const char deli[2] = ".";
const char *http = "[+] http://";

Expand All @@ -70,7 +70,13 @@ int main(){


puts("\n[~] Obfuscated IPs :\n");
printf("[+] http://%u\n\n",(*dec << 24)|(*(dec+1) << 16)|(*(dec+2) << 8)|*(dec+3));
printf("%s", http);
printf("%u\n",dword=(*dec << 24)|(*(dec+1) << 16)|(*(dec+2) << 8)|*(dec+3));
printf("%s", http);
printf("0x%X\n",dword);
printf("%s", http);
printf("0%o\n\n",dword);

printf("%s", http);
for(i=0;i<4;i++) printf( i == 3 ? "0x%02X\n" : "0x%02X.",dec[i]);
printf("%s", http);
Expand Down Expand Up @@ -121,11 +127,6 @@ int main(){
printf("%s", http);
for(i=0;i<4;i++)
printf( i >= 1 ? i == 3 ? "%04o\n" : "%04o." : "0x%02X.",dec[i]);
printf("%s", http);
for(i=0;i<2;i++)
printf( i >= 1 ? "%04o." : "0x%02X.",dec[i]);
printf("%u\n",(*(dec+2) << 8)|*(dec+3));

#ifndef __unix__
system("pause > nul");
#endif
Expand Down