CVE-2018-1315
Incorrect Permission Assignment for Critical Resource in Apache hive
Description
In Apache Hive 2.1.0 to 2.3.2, when 'COPY FROM FTP' statement is run using HPL/SQL extension to Hive, a compromised/malicious FTP server can cause the file to be written to an arbitrary location on the cluster where the command is run from. This is because FTP client code in HPL/SQL does not verify the destination location of the downloaded file. This does not affect hive cli user and hiveserver2 user as hplsql is a separate command line script and needs to be invoked differently.
Affected Maven artifacts (3)
| Artifact | Affected versions | Fixed in |
|---|---|---|
| org.apache.hive » hive | >= 2.1.0, < 2.3.3 | 2.3.3 |
| org.apache.hive » hive-exec | >= 2.1.0, < 2.3.3 | 2.3.3 |
| org.apache.hive » hive-service | >= 2.1.0, < 2.3.3 | 2.3.3 |
Blast radius
65% of the dependent artifacts (272) still pull an affected version in their latest release.
| Depth | Dependent versions |
|---|---|
| Direct | 28,173 |
| 2 hops | 12,759 |
| 3 hops | 8,958 |
| 4 hops | 2,428 |
| 5 hops | 825 |
| 6 hops | 301 |
Most used dependents
- org.apache.spark » spark-sql3,177 usages
- org.apache.spark » spark-core2,902 usages
- org.apache.spark » spark-mllib831 usages
- org.apache.spark » spark-streaming671 usages
- org.apache.spark » spark-hive633 usages
- org.apache.spark » spark-catalyst503 usages
- org.apache.hive » hive-metastore480 usages
- org.apache.hive » hive-jdbc404 usages
- org.apache.hive » hive-common305 usages
- org.apache.hive » hive-service301 usages
- org.apache.hive » hive-serde206 usages
- org.apache.spark » spark-graphx143 usages
- org.apache.spark » spark-yarn130 usages
- org.apache.oozie » oozie-core123 usages
- org.apache.spark » spark-repl110 usages
Computed from the dependency graph of build 20261202.2045 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.
References
| Advisory | NVD CVE-2018-1315 | nvd.nist.gov |
| Advisory | GitHub advisory GHSA-p639-xxv5-j383 | github.com |
| Web | thread.html/d5da94ef60312c01a8d2348466680d1b5fb70702c71a3e84e94f7933@<dev.hive.apache.org> | lists.apache.org |
