BeyondTrust

Security in Context: The BeyondTrust Blog

Welcome to Security in Context

Bringing you news and commentary on solutions and strategies for protecting critical IT infrastructure in the context of your business.

DLL Preloading Attacks in the Wild

Posted August 24, 2010    The eEye Research Team

After several public discussions and the swift patching of Apple iTunes, Microsoft has issued the security advisory KB2269637  to address DLL Hijacking or Preloading vulnerabilities within all versions of Microsoft Windows. This advisory covers a 10 year old flaw within the Windows operating system and how it handles the loading of Dynamic Link Libraries (.DLL or .SYS) files using LoadLibrary and SearchPath API calls. When an application attempts to load a library without specifying the full path, Microsoft Windows will perform a DLL search in order to load the file. Based off the current Microsoft DLL ‘Safe’ Search Order specifications, the order is as follows:

  • The directory from which the application loaded
  • The system directory
  • The 16-bit system directory
  • The Windows directory
  • The current working directory
  • The directories that are listed in the PATH environment variable

An exploitable scenario would look similar to the following:

  • Upon opening a file, the vulnerable application changes the current working directory to the destination directory of the last opened file.
  • An application attempts loads a DLL without specifying a full path of the target DLL.
  • Windows searches through the directories in the DLL Search Order and discovers the DLL in the current working directory where the opened file resides.

A malicious individual could potentially leverage the vulnerability using WebDAV or network shares after convincing a user into downloading their malicious file which would trigger the DLL Search order. The attackers would then plant a malicious DLL in the remote directory that would then be loaded by the vulnerable application.

The eEye Research team has witnessed several variations of this attack method in which attackers are targeting known WebDAV services, such as SharePoint servers to successfully compromise users. Alternative strategies are using archive files, such as the commonly found and trusted .zip and .rar file formats in order to deliver both a trusted file and exploit to end users.

For current mitigation strategies:

Administrators are highly advised to restrict WebDAV / PROPFIND requests completely (ideal) or to only trusted servers. This would prevent most attackers from deploying web-based attacks and exploit tool kits against your environment.

Targeted attacks and secondary attack vectors will come in the form of email or IM delivered archive files (zip, rar, 7zip, z, etc.) Administrators are also advised to parse/filter these for any DLL or .SYS files prior to delivering these to clients.

Keep in mind, that Microsoft’s current work around, CWDIllegalInDllSearch patch, may potentially break some poorly written applications; it is advised that the patch is rolled out to test environments prior to rolling it out to mission critical systems.

The issue is quickly becoming a hot topic within the security community as the vulnerability does not affect just a single application or environment; it has the potential to allow attackers to exploit hundreds of applications within the Windows environment. Furthermore, even with a fix from Microsoft the vulnerability has the potential to linger for months or even years due to bad programming practices from developers. For many of you, this may start to resemble the ATL vulnerabilities that plagued Microsoft last year; and in many circumstances it is very similar; just with a slight twist.

It should be noted for eEye Digital Security customers that we have released vulnerability audits for Retina if you are running audits version 2260 or higher. We will continue to add Retina audits for any new applications that are discovered to be vulnerable.

Leave a Reply

Additional articles

PowerBroker Password Safe Password Age Report

Reshaping Privileged Password Management with Password Safe 5.2

Posted July 21, 2014    Martin Cannard

Today, we’re pleased to unveil the latest edition of our privileged password management solution, PowerBroker Password Safe. I’ll start with a brief intro of what’s new and then tell you a little about the driving factors behind Password Safe development. New features for mitigating password risk and ensuring accountability enterprise-wide Here’s the 10,000-foot overview of…

Tags:
, , ,
PowerBroker for Windows tamper protection

PowerBroker for Windows 6.6 Tamper Protection

Posted July 18, 2014    Morey Haber

I have a bone to pick: Stopping an administrator from performing an action on a system is futile endeavor. As an administrator, there is always a way to circumvent a solution’s from tampered protection. Really! By default, Windows administrators have unrestricted access to the system – and even though an application, hardened configuration, or group policy…

Tags:
, ,
PowerBroker for Windows can be configured to automatically identify the end user’s language preference

Implementing Least Privilege Around the World with PowerBroker for Windows

Posted July 17, 2014    Morey Haber

BeyondTrust recognizes that international, multilingual businesses have unique operating challenges, especially when it comes to implementing enterprise software. PowerBroker for Windows is a least-privilege solution often deployed across thousands of systems spanning multiple geographies and protecting users of diverse backgrounds. Earlier this year, PowerBroker for Windows introduces new data privacy features for EMEA and APAC,…

Tags:
, ,