| 54 | } |
| 55 | |
| 56 | char* Encryption::Decrypt(const char * key, int keysize, const char * data, bool addZero) { |
| 57 | int size = strlen(data); |
| 58 | char * encrdata = SU::HexToData(data, size, false); |
| 59 | if (!encrdata) |
| 60 | return NULL; |
| 61 | |
| 62 | size = size/2; |
| 63 | char * decdata = DES_encrypt(key, keysize, encrdata, size, addZero, DES_DECRYPT); |
| 64 | SU::FreeChar(encrdata); |
| 65 | |
| 66 | return decdata; |
| 67 | } |
| 68 | |
| 69 | int Encryption::FreeData(char * data) { |
| 70 | return SU::FreeChar(data); |
nothing calls this directly
no outgoing calls
no test coverage detected