Skip to content
Heist/ feed
Back to feed
Medium

Apache Hive: SQL injection vulnerability when processing delete column statistics requests via the HMS Thrift APIs

Type: advisorySources: OSV

SQL injection vulnerability in Hive Metastore Server (HMS) when processing delete column statistics requests via the Thrift APIs. The vulnerability is only exploitable by trusted/authorized users/applications that are allowed to call directly the Thrift APIs. In most real-world deployments, HMS is accessible to only a handful of applications (e.g., Hiveserver2) thus the vulnerability is not exploitable. Moreover, the vulnerable code cannot be reached when metastore.try.direct.sql property is set to false. This issue affects Apache Hive: from 4.1.0 before 4.2.0. Users are recommended to upgrade to version 4.2.0, which fixes the issue. Users who cannot upgrade directly are encouraged to set metastore.try.direct.sql property to false if the HMS Thrift APIs are exposed to general public.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2025-62728
Confirmed fixed CVEs
Not specified
Updated in this feed
6 Nov 2026, 01:18 UTC · Revision 1

Source evidence

Apache Hive: SQL injection vulnerability when processing delete column statistics requests via the HMS Thrift APIs

core-osv · Original source

Published 26 Nov 2025, 08:45 UTC

SQL injection vulnerability in Hive Metastore Server (HMS) when processing delete column statistics requests via the Thrift APIs. The vulnerability is only exploitable by trusted/authorized users/applications that are allowed to call directly the Thrift APIs. In most real-world deployments, HMS is accessible to only a handful of applications (e.g., Hiveserver2) thus the vulnerability is not exploitable. Moreover, the vulnerable code cannot be reached when metastore.try.direct.sql property is set to false. This issue affects Apache Hive: from 4.1.0 before 4.2.0. Users are recommended to upgrade to version 4.2.0, which fixes the issue. Users who cannot upgrade directly are encouraged to set metastore.try.direct.sql property to false if the HMS Thrift APIs are exposed to general public.

osv:CVE-2025-62728
Complete source record
{
  "id": "9fbf5b4a70ec90b3ff6251951f00c43b15b4da58fc64d0f6f6daab29d55f6eff",
  "url": "https://osv.dev/vulnerability/CVE-2025-62728",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Apache Hive: SQL injection vulnerability when processing delete column statistics requests via the HMS Thrift APIs",
    "summary": "SQL injection vulnerability in Hive Metastore Server (HMS) when processing delete column statistics requests via the Thrift APIs. The vulnerability is only exploitable by trusted/authorized users/applications that are allowed to call directly the Thrift APIs. In most real-world deployments, HMS is accessible to only a handful of applications (e.g., Hiveserver2) thus the vulnerability is not exploitable. Moreover, the vulnerable code cannot be reached when metastore.try.direct.sql property is set to false. This issue affects Apache Hive: from 4.1.0 before 4.2.0. Users are recommended to upgrade to version 4.2.0, which fixes the issue. Users who cannot upgrade directly are encouraged to set metastore.try.direct.sql property to false if the HMS Thrift APIs are exposed to general public.",
    "evidence": "osv:CVE-2025-62728",
    "products": [],
    "severity": "medium",
    "structured": {
      "id": "CVE-2025-62728",
      "aliases": [
        "CVE-2025-62728",
        "GHSA-932v-x9x2-vq29"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/apache/hive",
              "type": "GIT",
              "events": [
                {
                  "introduced": "75e40b7537c91a70ccaa31c397d21823c7528eeb"
                },
                {
                  "last_affected": "75e40b7537c91a70ccaa31c397d21823c7528eeb"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:apache:hive:4.1.0:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "4.1.0"
                      },
                      {
                        "last_affected": "4.1.0"
                      }
                    ],
                    "source": "CPE_STRING"
                  }
                ]
              }
            }
          ],
          "versions": [
            "4.1.0",
            "rel/release-4.1.0"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-62728.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:45.508772255Z",
      "provider": "osv",
      "references": [
        "https://repo.maven.apache.org/maven2",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/62xxx/CVE-2025-62728.json",
        "https://lists.apache.org/thread/yj65dd8dmzgy8p3nv8zy33v8knzg9o7g",
        "https://nvd.nist.gov/vuln/detail/CVE-2025-62728"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-89"
        ],
        "cna_assigner": "apache",
        "unresolved_ranges": [
          {
            "extracted_events": [
              {
                "range": [
                  {
                    "introduced": "4.1.0"
                  },
                  {
                    "fixed": "4.2.0"
                  }
                ],
                "source": "AFFECTED_FIELD",
                "strategy": "StandardRange"
              }
            ]
          }
        ],
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/62xxx/CVE-2025-62728.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2025-62728",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 513785,
  "published_at": "2025-11-26T08:45:37.472+00:00"
}