diff --git a/chaos_monkey/exploit/sambacry.py b/chaos_monkey/exploit/sambacry.py index 22b3a3f2b..7bf8533ef 100644 --- a/chaos_monkey/exploit/sambacry.py +++ b/chaos_monkey/exploit/sambacry.py @@ -161,13 +161,14 @@ class SambaCryExploiter(HostExploiter): return writable_shares_creds_dict def get_credentials_list(self): - user_password_pairs = self._config.get_exploit_user_password_pairs() + creds = self._config.get_exploit_user_password_or_hash_product() # Add empty credentials for anonymous shares. credentials_list = [{'username': '', 'password': '', 'lm_hash': '', 'ntlm_hash': ''}] - for user, password in user_password_pairs: - credentials_list.append({'username': user, 'password': password, 'lm_hash': '', 'ntlm_hash': ''}) + for user, password, lm_hash, ntlm_hash in creds: + credentials_list.append( + {'username': user, 'password': password, 'lm_hash': lm_hash, 'ntlm_hash': ntlm_hash}) return credentials_list