Fixed missing imports when dumping NTDS via vss
parent
7e6657eedb
commit
9262832b86
|
@ -1,4 +1,5 @@
|
||||||
from impacket.structure import Structure
|
from impacket.structure import Structure
|
||||||
|
from struct import unpack
|
||||||
|
|
||||||
# Structures
|
# Structures
|
||||||
# Taken from http://insecurety.net/?p=768
|
# Taken from http://insecurety.net/?p=768
|
||||||
|
|
|
@ -7,8 +7,11 @@ from binascii import hexlify, unhexlify
|
||||||
from struct import unpack
|
from struct import unpack
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from core.credentials.cryptocommon import CryptoCommon
|
from core.credentials.cryptocommon import CryptoCommon
|
||||||
|
from Crypto.Cipher import DES, ARC4
|
||||||
|
from core.credentials.commonstructs import SAMR_RPC_SID
|
||||||
from impacket.ese import ESENT_DB
|
from impacket.ese import ESENT_DB
|
||||||
import logging
|
import logging
|
||||||
|
import hashlib
|
||||||
import random
|
import random
|
||||||
import string
|
import string
|
||||||
import os
|
import os
|
||||||
|
|
|
@ -157,11 +157,7 @@ class DumpSecrets:
|
||||||
def cleanup(self):
|
def cleanup(self):
|
||||||
logging.info('Cleaning up... ')
|
logging.info('Cleaning up... ')
|
||||||
if self.__remoteOps:
|
if self.__remoteOps:
|
||||||
try:
|
self.__remoteOps.finish()
|
||||||
self.__remoteOps.finish()
|
|
||||||
except DCERPCException:
|
|
||||||
sleep(5)
|
|
||||||
self.__remoteOps.finish()
|
|
||||||
if self.__SAMHashes:
|
if self.__SAMHashes:
|
||||||
self.__SAMHashes.finish()
|
self.__SAMHashes.finish()
|
||||||
if self.__LSASecrets:
|
if self.__LSASecrets:
|
||||||
|
|
Loading…
Reference in New Issue