Improper Validation of Hostname in x.509 Certificate in ovirt-engine-sdk-python

ovirt-engine-sdk-python Updated 02 Oct 2025

Summary

17/05/2022
Yes i
High
5.9

CVE-2014-0161: ovirt-engine-sdk-python improper validation of hostname in x.509 certificate. Affects ovirt-engine-sdk-python across 2 version ranges.

< 3.4.0.7 >= 3.5.0.0, < 3.5.0.4

Fixed in 3.4.0.7 or 3.5.0.4, depending on the release line you run. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

ovirt-engine-sdk-python is a Python library that provides a high-level API to interact with the oVirt Engine API. It allows users to manage virtualization resources such as virtual machines, storage domains, and networks. The library is widely used in various projects and applications that integrate with the oVirt virtualization platform. However, versions before 3.4.0.7 and 3.5.0.4 of ovirt-engine-sdk-python are vulnerable to an issue related to the improper validation of the hostname in x.509 certificates used in TLS/SSL sessions.

Vulnerability Detail

The vulnerability in ovirt-engine-sdk-python arises from the failure to verify that the hostname of the remote endpoint matches the Common Name (CN) or subjectAltName specified by its x.509 certificate. This oversight opens up the possibility of man-in-the-middle attacks, where an attacker can impersonate a remote endpoint by presenting a valid certificate with a different hostname. By exploiting this vulnerability, an attacker could intercept and manipulate the communication between the client and the server, potentially leading to unauthorized access, data leakage, or other malicious activities.

How To Fix

Fixed versions by release line

The minimum fixed version depends on the release line you run.

  • < 3.4.0.7 3.4.0.7
    pip install --upgrade "ovirt-engine-sdk-python==3.4.0.7"
  • >= 3.5.0.0, < 3.5.0.4 3.5.0.4
    pip install --upgrade "ovirt-engine-sdk-python==3.5.0.4"

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Workaround

As a temporary workaround, users can implement additional validation checks in their applications to verify the hostname of the remote endpoint during the TLS/SSL handshake. This can be done by comparing the hostname extracted from the x.509 certificate with the expected hostname. Here is an example of how to perform this validation in Python using the ssl module:

import ssl

def verify_hostname(cert, hostname):
    cert_hostname = cert.match_hostname(hostname)
    if cert_hostname is not None:
        raise ssl.CertificateError(f'Hostname mismatch: {cert_hostname}')

# Usage:
context = ssl.create_default_context()
# Load the certificate chain
context.load_cert_chain(certfile='path/to/certificate.pem', keyfile='path/to/private_key.pem')
# Verify the hostname
verify_hostname(context.getpeercert(), 'example.com')

Please note that this workaround should be considered temporary and it is highly recommended to apply the official fix by upgrading to a patched version of ovirt-engine-sdk-python.

Conclusion

In conclusion, the vulnerability in ovirt-engine-sdk-python allows for the impersonation of remote endpoints through the use of valid but mismatched x.509 certificates. This can lead to various security risks and unauthorized access. It is crucial to upgrade to a fixed version of ovirt-engine-sdk-python (3.4.0.7 or above) or implement the provided workaround to mitigate the risk. For further support and assistance in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for ovirt-engine-sdk-python →

Share this vulnerability

FAQ

ovirt-engine-sdk-python is a Python library that provides a high-level API to interact with the oVirt Engine API. It allows users to manage virtualization resources such as virtual machines, storage domains, and networks.

This vulnerability could allow man-in-the-middle attackers to spoof remote endpoints by presenting a valid certificate with a different hostname. This can lead to unauthorized access, data manipulation, or other malicious activities.

Versions before 3.4.0.7 and 3.5.0.4 of ovirt-engine-sdk-python are affected by this vulnerability.

To fix this vulnerability, it is recommended to upgrade to a fixed version of ovirt-engine-sdk-python (version 3.4.0.7 or above).

Yes, as a temporary workaround, you can implement additional validation checks in your application to verify the hostname of the remote endpoint during the TLS/SSL handshake.

How To Fix

Fixed versions by release line

The minimum fixed version depends on the release line you run.

  • < 3.4.0.7 3.4.0.7
    pip install --upgrade "ovirt-engine-sdk-python==3.4.0.7"
  • >= 3.5.0.0, < 3.5.0.4 3.5.0.4
    pip install --upgrade "ovirt-engine-sdk-python==3.5.0.4"

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback