Retr0-code / hash-dumper

Windows NTLM hash dump utility written in C language, that supports Windows and Linux. Hashes can be dumped in realtime or from already saved SAM and SYSTEM hives.
GNU Affero General Public License v3.0
15 stars 3 forks source link

Memory Leaks #30

Open Retr0-code opened 11 months ago

Retr0-code commented 11 months ago

Description

Using full leak check in valgrind, was found out that 1300 bytes of data were leaked

To Reproduce

Command used

$ valgrind --leak-check all ./hash_dumper --sam hives/sam --system hives/system

Expected behavior

Expected to free all used memory

Solution

Create deletion functions for core structures of hive and create end label in every function where will be full cleanup, than on error just goto label