Open 5m1le71ger opened 9 years ago
Interesting! I will have a look at it. Thanks for the tip 5m1le71ger.
(I hope you aren't using this for anything that is not educational, as it will be vulnerable to timing attacks and so on. This was just a fun and direct implementation of the theory in order to understand AES better :smile: )
in the function ' base64_decode', //////////////////////// char * str = new char[ret.size()]; strcpy(str, ret.c_str()); ///////////////////////
the strcpy is very DANGER, the alloc memory of str must add one as following:
and, u must free the new memory ,at 恰当的时候