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.

Java Pwns Everyone…Again.

Posted August 30, 2012    BeyondTrust Research Team

Java has a nasty habit of getting you owned. This latest 0day is no exception to the long-lived trend of reliable Java-based exploitation. Here’s what you need to know:

How does it work?

The current exploitation method being employed in the wild right now leverages two zero day flaws in Java. The first flaw leverages an implementation issue (logic bug) within ClassFinder.findClass(), which is only present in Java 7. The method findClass() allows Java code to access restricted classes, when it should disallow such access. By using findClass() to gain access to restricted classes, the exploit is then able to use a reference for sun.awt.SunToolkit to access the getField() method. The second flaw, found in getField(), allows Java code to modify private fields (logic bug), which should normally be immutable when accessed externally (from outside the class it was declared in). The exploit uses getField() in order to modify the permissions of java.beans.Statement, which is then used to disable the Java Security Manager. At this point, the exploit is able to run code arbitrarily. No memory corruption occurs in the exploitation of these vulnerabilities. This makes the exploit 100% reliable for Java 7, across multiple platforms and through multiple browser-based attack vectors.

What can we do to mitigate this threat?

  1. Install the patch from Oracle for CVE-2012-4681.
  2. Audit your environment for systems that have Java. Determine what systems actually need Java and remove it according to your needs. Once you have reduced your Java footprint, you can further reduce your attack surface by restricting how Java runs; determine if a system needs Java for Internet facing applications or if it needs Java for desktop and internal applications. Configure systems that need Java granularly – more information on how to do this can be found in the links below.a. Controlling Java<Applet> Tags http://blogs.msdn.com/b/ieinternals/archive/2011/05/15/controlling-java-in-internet-explorer.aspx
    b. Controlling Java <Object> Tags (ActiveX) http://support.microsoft.com/kb/2751647

It is important to note that some security companies have incorrectly recommended mitigation strategies for Java which would only disable the loading of Java via Applet tags, but not via Object/ActiveX instantiation. To be blunt, if you had followed those recommendations, an attacker would have simply changed Applet tags to Object tags and owned your systems. So keep in mind when reviewing mitigations, even from “Quality” folks in the vulnerability management space, that your mileage may vary. ;-)

This constant panic over Java sucks…

Yes, yes it does. Java is a big, powerful, and widely used software package that is prone to gnarly vulnerabilities like the ones being exploited right now. As such, it will continue to garner a lot of attention from malicious entities. This exploit has already been folded into Metasploit and is being used actively in the BlackHole exploit kit. By limiting the use of Java within your organization, you’re effectively closing doors that attackers would otherwise stroll through. Following the aforementioned recommendations will help reduce the likelihood of exploitation and let you breathe a little easier.

BeyondTrust’s Retina Network Security Scanner (Retina Community is free) can audit for systems that are vulnerable to this issue:

17016 – Oracle Sun Java ClassFinder Vulnerability (CVE-2012-4681) – Windows – JDK
17017 – Oracle Sun Java ClassFinder Vulnerability (CVE-2012-4681) – Windows – JRE
17018 – Oracle Sun Java ClassFinder Vulnerability (CVE-2012-4681) – UNIX/Linux – JDK
17019 – Oracle Sun Java ClassFinder Vulnerability (CVE-2012-4681) – UNIX/Linux – JRE

 

Tags:
, , , , , , , ,

Leave a Reply

Additional articles

PBPS-screenshot-blog aug2014

Failing the Security Basics: Backoff Point-of-Sale Malware

Posted August 22, 2014    Marc Maiffret

At the beginning of this month, US-CERT issued a security alert relating to a string of breaches that had been targeting Point of Sale (POS) systems. The alert details that attackers were leveraging brute forcing tools to target common remote desktop applications such as Microsoft’s Remote Desktop, Apple Remote Desktop, Splashtop and LogMeIn among others….

Tags:
, , , , , ,

Troubleshooting Windows Privilege Management Rules with Policy Monitor

Posted August 21, 2014    Jason Silva

When defining and testing PowerBroker for Windows rules for production or pilots, customers sometimes tell us, “I don’t think this policy / program is working.” This is usually a case of the policy not properly triggering because of the way the rule was created. A unique feature of PowerBroker for Windows compared to other solutions is a client-side…

Tags:
, , ,
darren-mar-elia

BeyondTrust Webcast: Darren Mar-Elia’s 4 Active Directory Change Scenarios to Track

Posted August 20, 2014    Chris Burd

In our latest webcast, we joined Darren Mar-Elia, CTO at SDM Software, to discuss best practices for Active Directory (AD) change management. Here are some key takeaways from the presentation, followed by a link to a full-length video of the presentation. Mar-Elia kicks things off with a critical insight: that the best AD change management…

Tags:
, , , , , , ,