VAITP Dataset

← Back to the dataset

CVE-2026-114614

Authlib insecure transport check allows userinfo‑prefix loopback bypass, enabling cleartext redirects.

  • CVSS 2.6
  • CWE-601
  • Input Validation and Sanitization
  • Remote

Authlib is a Python library which builds OAuth and OpenID Connect servers. From 0.13 until 1.8.0, authlib.common.security.is_secure_transport() uses a textual prefix comparison for loopback HTTP exemptions, so a URL whose userinfo begins with a loopback host can be accepted even when its parsed host is an external non-loopback system. An external party able to supply a URL to OIDC RP-Initiated Logout registration, authorization-server metadata validation, or another call site can bypass the TLS-required guard and cause cleartext redirection or acceptance of cleartext endpoints. The issue does not bypass redirect URI exact matching and does not by itself forge tokens or authenticate users. The vulnerable authlib.common.security.is_secure_transport() implementation in authlib/common/security.py misinterprets the userinfo component before OIDC RP-Initiated Logout dynamic client registration and other consumers enforce transport security. This issue is fixed in version 1.8.0.

CVSS base score
2.6
Published
2026-10-22
OWASP
A02 Cryptographic Failures
Orthogonal defect classification
Checking
Code defect classification
Incorrect Check
Category
Input Validation and Sanitization
Subcategory
Insecure Parsing or Deserialization
Accessibility scope
Remote
Impact
Information Disclosure
Affected component
Authlib
Fixed by upgrading
Yes

Solution

Upgrade Authlib to version 1.8.0 or newer.

Vulnerable code sample

from urllib.parse import urlparse

def is_secure_transport(url: str) -> bool:
    """
    Return True if the URL uses HTTPS or is an HTTP URL that points to a loopback address.
    Vulnerable implementation checks the raw URL string for a loopback prefix.
    """
    # VULNERABLE: uses textual prefix check that can be fooled by userinfo containing a loopback host
    if url.startswith('https://'):
        return True
    if url.startswith('http://127.0.0.1') or url.startswith('http://localhost'):
        return True
    return False

Patched code sample

from urllib.parse import urlparse

def is_secure_transport(url: str) -> bool:
    """
    Return True if the URL uses HTTPS or is an HTTP URL that points to a loopback address.
    Fixed implementation parses the host component correctly.
    """
    # FIX: parses URL and validates the actual hostname instead of raw string prefix
    parsed = urlparse(url)
    if parsed.scheme == 'https':
        return True
    if parsed.scheme == 'http' and parsed.hostname in ('127.0.0.1', 'localhost'):
        return True
    return False

Published fix

Public sources link this CVE to the changes below. The code samples above were generated to illustrate the defect; these links lead to the code the project actually changed.

Cite this entry

@misc{vaitp:cve2026114614,
  title        = {{Authlib insecure transport check allows userinfo‑prefix loopback bypass, enabling cleartext redirects.}},
  author       = {Bogaerts, Fr\'ed\'eric and Ivaki, Naghmeh and Fonseca, Jos\'e},
  year         = {2026},
  note         = {VAITP Python Vulnerability Dataset, entry CVE-2026-114614},
  howpublished = {\url{https://netpack.pt/vaitp/vulnerability/CVE-2026-114614/}}
}

Download this entry as JSON Download the whole dataset

Introducing the "VAITP dataset": a specialized repository of Python vulnerabilities and patches, meticulously compiled for the use of the security research community. As Python's prominence grows, understanding and addressing potential security vulnerabilities become crucial. Crafted by and for the cybersecurity community, this dataset offers a valuable resource for researchers, analysts, and developers to analyze and mitigate the security risks associated with Python. Through the comprehensive exploration of vulnerabilities and corresponding patches, the VAITP dataset fosters a safer and more resilient Python ecosystem, encouraging collaborative advancements in programming security.

The supreme art of war is to subdue the enemy without fighting.

Sun Tzu – “The Art of War”

:: Shaping the future through research and ingenuity ::

Before you use the VAITP AI models

Please read and accept the following disclaimer:

By choosing "I understand and accept", you acknowledge that you understand and agree to these terms.