Oracle WebLogic Java Deserialization Vulnerability (CVE-2018-2628)

 Overview

Vulnerability in the Oracle WebLogic Server component of Oracle Fusion Middleware (subcomponent: WLS Core Components). Supported versions that are affected are 10.3.6.0, 12.1.3.0, 12.2.1.2 and 12.2.1.3. Easily exploitable vulnerability allows unauthenticated attacker with network access via T3 to compromise Oracle WebLogic Server via unsafe deserialization of Java objects. Successful attacks of this vulnerability can result in takeover of Oracle WebLogic Server.

In a vulnerable system, WebLogic administrators can identify possible Java deserialization attacks if similar exceptions are seen in their WebLogic logs:

To exploit the CVE-2018-2628 vulnerability, the first step is to establish a socket connection with the T3 service available on the service port of WebLogic Server. Therefore, the attack can be blocked by controlling access to the T3 protocol. WebLogic Server provides a default connection filter called weblogic.security.net.ConnectionFilterImpl. This filter accepts all inbound connections. It is advisable to configure a rule through this filter to control access to T3 and T3S protocols.

Connection filter from Weblogic Console

  1. Access the administration console of WebLogic Server.
  2. Click Base_domain in the left pane and then click the Security and Filter tabs successively to open the filter configuration page.
  3. Type security.net.ConnectionFilterImplin the Connection Filter field and * * 7001 deny t3 t3s in the Connection Filter Rules field.

Note : Protocols specifies the protocols to be filtered. (The value must be http, https, t3, t3s, iiop, iiops,  and/or ftp.) If no protocol is specified, all protocols will be filtered.

  1. Click Save. Then this rule takes effect immediately without needing a restart.

 

Connection filter through Weblogic Server command line

  1.  Access the WebLogic Server through command line Go to basefolder/weblogic/version-directory/user-projects/base-domain/config.
  2. Vi Config.xml and update for  weblogic connection filter lines as  below nodemanager line.

             <connection-filter>weblogic.security.net.ConnectionFilterImpl</connection-filter>

           <connection-filter-rule>10.1.xx.xx 10.1.xx.xx 7001 deny http</connection-filter-rule>

           <connection-logger-enabled>true</connection-logger-enabled>

 

Note : Protocols specifies the protocols to be filtered. (The value must be http, https, t3, t3s, iiop, iiops,  and/or ftp.) If no protocol is specified, all protocols will be filtered.

  1. Click Save. Then this rule takes effect immediately without needing a restart . but restarting domain is recommended.