CVE Vulnerabilities

CVE-2021-21290

Creation of Temporary File With Insecure Permissions

Published: Feb 08, 2021 | Modified: Nov 07, 2023
CVSS 3.x
5.5
MEDIUM
Source:
NVD
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
CVSS 2.x
1.9 LOW
AV:L/AC:M/Au:N/C:P/I:N/A:N
RedHat/V2
RedHat/V3
6.2 MODERATE
CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
Ubuntu
MEDIUM

Netty is an open-source, asynchronous event-driven network application framework for rapid development of maintainable high performance protocol servers & clients. In Netty before version 4.1.59.Final there is a vulnerability on Unix-like systems involving an insecure temp file. When nettys multipart decoders are used local information disclosure can occur via the local system temporary directory if temporary storing uploads on the disk is enabled. On unix-like systems, the temporary directory is shared between all user. As such, writing to this directory using APIs that do not explicitly set the file/directory permissions can lead to information disclosure. Of note, this does not impact modern MacOS Operating Systems. The method File.createTempFile on unix-like systems creates a random file, but, by default will create this file with the permissions -rw-r–r–. Thus, if sensitive information is written to this file, other local users can read this information. This is the case in nettys AbstractDiskHttpData is vulnerable. This has been fixed in version 4.1.59.Final. As a workaround, one may specify your own java.io.tmpdir when you start the JVM or use DefaultHttpDataFactory.setBaseDir(…) to set the directory to something that is only readable by the current user.

Weakness

Opening temporary files without appropriate measures or controls can leave the file, its contents and any function that it impacts vulnerable to attack.

Affected Software

Name Vendor Start Version End Version
Netty Netty * 4.1.59 (excluding)
AMQ Clients 2.y for RHEL 7 RedHat qpid-proton-0:0.33.0-6.el7_9 *
AMQ Clients 2.y for RHEL 8 RedHat qpid-proton-0:0.33.0-8.el8 *
Red Hat AMQ 7.8.2 RedHat netty *
Red Hat AMQ 7.9.0 RedHat netty *
Red Hat AMQ Online 1.7.0 GA RedHat netty *
Red Hat AMQ Streams 1.8.0 RedHat netty *
Red Hat build of Eclipse Vert.x 4.0.3 RedHat netty *
Red Hat build of Quarkus 2.2.3 RedHat netty *
Red Hat Data Grid 8.2.0 RedHat netty *
Red Hat EAP-XP 2.0.0 via EAP 7.3.x base RedHat netty *
Red Hat EAP-XP via EAP 7.3.x base RedHat netty *
Red Hat Fuse 7.10 RedHat netty *
Red Hat JBoss Enterprise Application Platform 7 RedHat netty *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-artemis-wildfly-integration-0:1.0.4-1.redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-bouncycastle-0:1.68.0-2.redhat_00005.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-hal-console-0:3.2.14-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-infinispan-0:9.4.22-3.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-ironjacamar-0:1.4.30-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-jboss-genericjms-0:2.0.9-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-jboss-marshalling-0:2.0.11-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-jboss-server-migration-0:1.7.2-6.Final_redhat_00007.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-jboss-weld-3.1-api-0:3.1.0-6.SP3_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-jgroups-kubernetes-0:1.0.16-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-mod_cluster-0:1.4.3-2.Final_redhat_00002.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-netty-0:4.1.60-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-resteasy-0:3.11.4-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-undertow-0:2.0.35-1.SP1_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-velocity-0:2.3.0-1.redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-weld-core-0:3.1.6-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-wildfly-0:7.3.7-1.GA_redhat_00002.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-wildfly-elytron-0:1.10.12-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-wildfly-http-client-0:1.0.26-1.Final_redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-xalan-j2-0:2.7.1-36.redhat_00013.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 6 RedHat eap7-yasson-0:1.0.9-1.redhat_00001.1.el6eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-artemis-wildfly-integration-0:1.0.4-1.redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-bouncycastle-0:1.68.0-2.redhat_00005.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-hal-console-0:3.2.14-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-infinispan-0:9.4.22-3.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-ironjacamar-0:1.4.30-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-jboss-genericjms-0:2.0.9-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-jboss-marshalling-0:2.0.11-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-jboss-server-migration-0:1.7.2-6.Final_redhat_00007.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-jboss-weld-3.1-api-0:3.1.0-6.SP3_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-jgroups-kubernetes-0:1.0.16-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-mod_cluster-0:1.4.3-2.Final_redhat_00002.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-netty-0:4.1.60-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-resteasy-0:3.11.4-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-undertow-0:2.0.35-1.SP1_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-velocity-0:2.3.0-1.redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-weld-core-0:3.1.6-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-wildfly-0:7.3.7-1.GA_redhat_00002.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-wildfly-elytron-0:1.10.12-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-wildfly-http-client-0:1.0.26-1.Final_redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-xalan-j2-0:2.7.1-36.redhat_00013.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 7 RedHat eap7-yasson-0:1.0.9-1.redhat_00001.1.el7eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-artemis-wildfly-integration-0:1.0.4-1.redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-bouncycastle-0:1.68.0-2.redhat_00005.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-hal-console-0:3.2.14-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-infinispan-0:9.4.22-3.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-ironjacamar-0:1.4.30-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-jboss-genericjms-0:2.0.9-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-jboss-marshalling-0:2.0.11-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-jboss-server-migration-0:1.7.2-6.Final_redhat_00007.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-jboss-weld-3.1-api-0:3.1.0-6.SP3_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-jgroups-kubernetes-0:1.0.16-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-mod_cluster-0:1.4.3-2.Final_redhat_00002.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-netty-0:4.1.60-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-resteasy-0:3.11.4-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-undertow-0:2.0.35-1.SP1_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-velocity-0:2.3.0-1.redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-weld-core-0:3.1.6-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-wildfly-0:7.3.7-1.GA_redhat_00002.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-wildfly-elytron-0:1.10.12-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-wildfly-http-client-0:1.0.26-1.Final_redhat_00001.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-xalan-j2-0:2.7.1-36.redhat_00013.1.el8eap *
Red Hat JBoss Enterprise Application Platform 7.3 for RHEL 8 RedHat eap7-yasson-0:1.0.9-1.redhat_00001.1.el8eap *
Red Hat Satellite 6.10 for RHEL 7 RedHat satellite-0:6.10.2-1.el7sat *
Red Hat Satellite 6.10 for RHEL 7 RedHat satellite-0:6.10.2-1.el7sat *
Red Hat Satellite 6.11 for RHEL 7 RedHat candlepin-0:4.1.13-1.el7sat *
Red Hat Satellite 6.11 for RHEL 8 RedHat candlepin-0:4.1.13-1.el8sat *
Red Hat Single Sign-On 7.4.7 RedHat netty *
RHDM 7.12.1 RedHat netty *
RHPAM 7.12.1 RedHat netty *
Netty Ubuntu bionic *
Netty Ubuntu esm-apps/bionic *
Netty Ubuntu esm-apps/focal *
Netty Ubuntu esm-apps/xenial *
Netty Ubuntu focal *
Netty Ubuntu groovy *
Netty Ubuntu hirsute *
Netty Ubuntu impish *
Netty Ubuntu jammy *
Netty Ubuntu kinetic *
Netty Ubuntu lunar *
Netty Ubuntu mantic *
Netty Ubuntu trusty *
Netty Ubuntu xenial *

Potential Mitigations

References