![]() |
UNIX Time Is..... 1745855550
|
||||||
|
NTLM Spoofing
|
NTLM and is a part of NBNS (NetBios Name Service) was designed with small office networks in mind where all
the computers are friendly, of the same operating system, and the network is closed off from the rest of the world. A
real LAN (Local Area Network) and not connected to a public network. On a network like this NTLM is not an issue
and actually works quite well.
NTLM comes from the days of NT4 since Windows 2000 Active Directory has been used for authentication in a Windows Domain. A Windows Domain uses what Microsoft calls Active Directory which a combination of open protocols, Kerbous5 for encryption, LDAP for directory services and DNS for domain lookups. These three protocols are TCP or TCP/UDP protocols and use point to point communications between the client and the server service. NTLM uses ARP broadcasts which send the login information to all the client on the network. From Wikipedia: https://en.wikipedia.org/wiki/NTLM NTLM is still used in the following situations:
When a user goes to connect to a service using a computer name Windows looks at the following to
resolve the name to IP address. One would ask how does a name lookup get past DNS to do a lookup? Well by design. Windows may use DNS for lookups in a domain but the system still likes to use the shorten version of the machine name to their NetBios name so instead of using DNS the machine will send an ARP broadcast over the network. The domain controller by default will still accept this for login. So instead of my machine logging in as say //ATL-BOWEAVER.corp.companyname.net it logs in as //ATL-BOWEAVER. Along in these broadcast packets is my machine name my IP address my user name and my password that anyone passively listening on the network with a packet sniffer such as Wireshark and easily capture. Basically NTLM is screaming your user name a password over the cube walls. AD/DNS is a quiet conversation between two people. Here is a great article on exactly how easily it is done. There's no since in re-inventing the wheel
and these people did a great job of laying this all out. So I'll use their site as the example. From the site. Cracking the hash:
Yes! 3.4 seconds to crack the hash! Run that through one more step and you get:
You will note he cracks this hashed password in 3.4 seconds. The NTLMv2 does take a second step to crack but still takes no time to crack. The tools to do this are readily available on the Internet for free. According to Microsoft the work around listed is to set up “failed login attempts” to disable the account. The problem with this is with this exploit you as you can see you already have the password when you attempt to login so you login with the first try. Active Directory and DNS Name LookupsActive Directory is designed to be a secure centrally manage service directory. As mentioned earlier Active Directory is actually three different services working together using secure communications between the client and the services. Being combined in this way Active Directory provides not only user login but also provides Machine Name lookups for not only machines on the internal network but also from the public networks. When your machine boots up on the network it talks to a DHCP server to get an IP address along with that address it gets the network information needed to communicate to where it is supposed to part of this information is the DNS servers to resolve machine names to addresses. On a Windows Domain this address will be the Active Directory servers normally which also handle DNS. So when your machine needs to look up and address it makes a point to point call to the AD and doesn't broadcast its information over the whole network. Login information is handled through an encrypted tunnel using Kerbous5 for encryption. Kerbous doesn't use a hash or hash/salt combination, it uses a private key and a random salt to hash a public key. This key changes every 15 minutes of so. This means a captured key must be cracked and used before the 15 minutes is up. After 15 minutes the key you captured isn't any good. Fixing the ProblemBefore disabling NBNS and NTLM some issues need to be resolved and the Internal DNS structure tested. It has been noticed by this Engineer looking at scan reports and asset lists that machines are known and listed by only their NetBios name. In a lot of these reports there is a column for the FQDN but nothing is listed there. There always something listed under the NetBios Name column. This must change. DNS Name ResolutionDNS name resolution standards are set in RFC 1591. A true FQDN (Fully Qualified Domain Name) must meet this structure. A lot of DNS structures within Fiserv do not meet this standard. We have domains ending with a TLD (Top Level Domain) such as .local .corp and .galaxy. These are not FQDNs they are not “Qualified” to the standard. Also reverse lookups of IP addresses must be maintained. Application Audit ToolHere are some tools and also how to restrict NTLM. NTLM Authentication on IISHow to disable NTLM on IIS: This explains how to turn it on. Do the reverse. For Windows 2008 Server: Disabling NTLM on any Windows Server 2003 to 2008R2Disabling NTLM on any Windows Server 2003 to 2008R2 |