3
I am using the function below to make the conversion of byte array
for a string
, but when analyzing the compiled code I note that the string
is clearly shown (using an Hex editor), what I do not desire.
char arr_code[] = {79, 99, 117, 108, 116, 97, 100, 111, 32, 110, 111, 32, 99, 195, 179, 100, 105, 103, 111, 32, 99, 111, 109, 112, 105, 108, 97, 100, 111};
char *byte_arr = (char*)malloc(sizeof(char));
memcpy(byte_arr, arr_code, sizeof arr_code);
char *str_code = byte_arr;
In case the string
of byte array
is Ocultado no código compilado
and is exposed in compiled code even though it is not clearly defined in the C script, because this occurs?
How can I get the code to be compiled without outworking of byte array
stay exposed?
I think it was important to know why you need it, might not even need to hide in C.
– Jorge B.
The api url is being exposed, which would give a little foot so that someone would try to get more information and finally try to obtain or defraud a legitimate communication with the server. The false sense of security already helps, since the code is too long. @Jorgeb.
– Florida
char *byte_arr = (char*)malloc(sizeof(char));
will only allocate1
byte– pmg
I’ve already made the necessary changes to avoid this @pmg thanks for giving me that touch.
– Florida