{"vuid":"VU#307983","idnumber":"307983","name":"Action Message Format (AMF3) Java implementations are vulnerable to insecure deserialization and XML external entities references","keywords":["amf","java","deserialization"],"overview":"Several Java implementations of AMF3 are vulnerable to insecure deserialization and XML external entities references.","clean_desc":"Several Java implementations of Action Message Format (AMF3) are vulnerable to one or more of the following implementation errors: CWE-502: Deserialization of Untrusted Data Some Java implementations of AMF3 deserializers derive class instances from java.io.Externalizable rather than the AMF3 specification's recommendation of flash.utils.IExternalizable. A remote attacker with the ability to spoof or control an RMI server connection may be able to send serialized Java objects that execute arbitrary code when deserialized. The reporter has identified the following products and versions as being affected, and CVE ID have been assigned as follows: - Atlassian JIRA, versions from 4.2.4 prior to version 6.3.0 - CVE-2017-5983\n- Flamingo amf-serializer by Exadel, version 2.2.0 - CVE-2017-3201\n- GraniteDS, version 3.1.1.GA - CVE-2017-3199\n- Pivotal/Spring spring-flex - CVE-2017-3203\n- WebORB for Java by Midnight Coders, version 5.1.1.0 - CVE-2017-3207 Products using these libraries may also be impacted. CWE-913: Improper Control of Dynamically-Managed Code Resources Some Java implementations of AMF3 deserializers may allow instantiation of arbitrary classes via their public parameter-less constructor and subsequently call arbitrary Java Beans setter methods. The ability to exploit this vulnerability depends on the availability of classes in the class path that make use of deserialization. A remote attacker with the ability to spoof or control information may be able to send serialized Java objects with pre-set properties that result in arbitrary code execution when deserialized. The reporter has identified the following products and versions as being affected, and CVE ID have been assigned as follows: - Flamingo amf-serializer by Exadel, version 2.2.0 - CVE-2017-3202\n- Flex BlazeDS , versions 4.6.0.23207 and 4.7.2 - CVE-2017-5641\n- GraniteDS, version 3.1.1.GA - CVE-2017-3200 Products using these libraries may also be impacted. CWE-611: Improper Restriction of XML External Entity Reference ('XXE') Some Java implementations of AMF3 deserializers allow external entity references (XXEs) from XML documents embedded within AMF3 messages. If the XML parsing is handled incorrectly it could potentially expose sensitive data on the server, denial of service, or server side request forgery. - Flamingo amf-serializer by Exadel, version 2.2.0 - CVE-2017-3206\n- Flex BlazeDS , version 4.6.0.23207 - CVE-2015-3269\n- GraniteDS, version 3.1.1.GA - CVE-2016-2340 (see VU#279472)\n- WebORB for Java by Midnight Coders, version 5.1.1.0 - CVE-2017-3208 Products using these libraries may also be impacted. More information is provided in the researcher's advisory.","impact":"A remote attacker with the ability to spoof or control a server connection may be able to send serialized Java objects that execute arbitrary code when deserialized.","resolution":"Apply an update if available CERT/CC recommends applying an update or patch to your product if available. Some vendors have responded that only out-of-support versions of products are impacted. In these cases, CERT/CC recommends updating your product to the latest supported version. More details are included for each vendor in the vendor records below.","workarounds":"Developers should use an updated JDK Developers should use an updated Java development kit (JDK). JDK 8 update 121, JDK 7 update 131 and JDK 6 update 141 implement basic serialization blacklisting filters, while more serialization protection measures are expected in the upcoming Java 9. For more information, please see JEP 290. Developers should be suspicious of deserialized data from untrusted sources Developers should in general be very suspicious of deserialized data from an untrusted source. For best practices, see the CERT Oracle Coding Standard for Java guidelines for Serialization, especially rules SER12-J and SER13-J. Use firewall rules or filesystem restrictions System administrators may be able to mitigate this issue for some applications by restricting access to the network and/or filesystem. If an affected application utilizes an open port accepting serialized objects, restricting access to the application may help mitigate the issue.","sysaffected":"","thanks":"Thanks to Markus Wulftange for reporting this vulnerability.","author":"This document was written by Garret Wassermann.","public":["http://codewhitesec.blogspot.com/2017/04/amf.html","http://openjdk.java.net/jeps/290","http://www.kb.cert.org/vuls/id/279472","http://www.adobe.com/go/amfspec","https://cwe.mitre.org/data/definitions/502.html","https://cwe.mitre.org/data/definitions/913.html","https://cwe.mitre.org/data/definitions/611.html"],"cveids":["CVE-2015-3269","CVE-2016-2340","CVE-2017-5641","CVE-2017-5983","CVE-2017-3199","CVE-2017-3200","CVE-2017-3201","CVE-2017-3202","CVE-2017-3203","CVE-2017-3206","CVE-2017-3207","CVE-2017-3208"],"certadvisory":"","uscerttechnicalalert":null,"datecreated":"2017-02-14T19:50:34Z","publicdate":"2017-04-04T00:00:00Z","datefirstpublished":"2017-04-04T14:54:29Z","dateupdated":"2017-04-14T15:08:34Z","revision":90,"vrda_d1_directreport":"1","vrda_d1_population":"2","vrda_d1_impact":"2","cam_widelyknown":"0","cam_exploitation":"0","cam_internetinfrastructure":"0","cam_population":"0","cam_impact":"0","cam_easeofexploitation":"0","cam_attackeraccessrequired":"0","cam_scorecurrent":"0","cam_scorecurrentwidelyknown":"0","cam_scorecurrentwidelyknownexploited":"0","ipprotocol":"","cvss_accessvector":"N","cvss_accesscomplexity":"M","cvss_authentication":null,"cvss_confidentialityimpact":"C","cvss_integrityimpact":"C","cvss_availabilityimpact":"C","cvss_exploitablity":null,"cvss_remediationlevel":"U","cvss_reportconfidence":"C","cvss_collateraldamagepotential":"ND","cvss_targetdistribution":"M","cvss_securityrequirementscr":"ND","cvss_securityrequirementsir":"ND","cvss_securityrequirementsar":"ND","cvss_basescore":"9.3","cvss_basevector":"AV:N/AC:M/Au:N/C:C/I:C/A:C","cvss_temporalscore":"8.4","cvss_environmentalscore":"6.299215776","cvss_environmentalvector":"CDP:ND/TD:M/CR:ND/IR:ND/AR:ND","metric":0.0,"vulnote":null}