You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
472 B
C
27 lines
472 B
C
#include <stdio.h>
|
|
#include <string.h>
|
|
#include <unistd.h>
|
|
#include <stdint.h>
|
|
#define SIZE (1024*1024)
|
|
|
|
int main() {
|
|
FILE *in = fopen("antideb", "r");
|
|
FILE *out = fopen("antideb_patched", "wb");
|
|
|
|
char buffer[SIZE];
|
|
size_t bytes;
|
|
|
|
while (0 < (bytes = fread(buffer, 1, sizeof(buffer), in)))
|
|
fwrite(buffer, 1, bytes, out);
|
|
|
|
long int offset = 0x5fa;
|
|
uint8_t new = 0x74;
|
|
|
|
fseek(out, offset, SEEK_SET);
|
|
|
|
fputc(new, out);
|
|
fclose(in);
|
|
fclose(out);
|
|
return 0;
|
|
}
|