/

CVE-2026-54650

Severity:

HIGH RISK

(8.6)

Path Traversal (CWE-22) in openhole HTTP Tunneling Proxy

CVE-2026-54650

Deferred

Vulnerability type

Category:

Path Traversal

CWE:

CWE-22

Impact:

Unauthorized Access to Local Paths and Endpoints

Severity:

HIGH RISK

(8.6)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

A path traversal flaw in openhole's HTTP tunneling proxy mishandles percent-encoded path segments, allowing encoded . and / characters to be interpreted by the backend as directory navigation.

When exposed services rely on path-based isolation, an attacker sending crafted URLs through an openhole tunnel can traverse paths on the local service, potentially accessing unintended endpoints or resources.

A path traversal flaw in openhole's HTTP tunneling proxy mishandles percent-encoded path segments, allowing encoded . and / characters to be interpreted by the backend as directory navigation.

When exposed services rely on path-based isolation, an attacker sending crafted URLs through an openhole tunnel can traverse paths on the local service, potentially accessing unintended endpoints or resources.

Affected context

This vulnerability affects deployments using openhole to expose localhost services to the internet, particularly in versions that forward HTTP requests via openhole-server in internal/server/public_proxy.go.

It becomes relevant when:

  • The backend local service interprets URL paths for routing or file access.
  • Security boundaries are assumed based on specific URL prefixes or directories.
  • Percent-encoded sequences in paths are not normalized or validated before reaching the tunneled service.

This vulnerability affects deployments using openhole to expose localhost services to the internet, particularly in versions that forward HTTP requests via openhole-server in internal/server/public_proxy.go.

It becomes relevant when:

  • The backend local service interprets URL paths for routing or file access.
  • Security boundaries are assumed based on specific URL prefixes or directories.
  • Percent-encoded sequences in paths are not normalized or validated before reaching the tunneled service.

Exploit preconditions

  • Attack surface: Public HTTP endpoint provided by openhole that proxies requests to a local service.
  • Required access: Network access to the exposed openhole tunnel; no local system access is required.
  • Trigger point: Sending HTTP requests with specially crafted r.URL.Path containing percent-encoded dot segments (%2e) and slashes (%2f) through the tunnel.
  • Why exploitation is possible: The proxy forwards r.URL.Path directly rather than using r.URL.EscapedPath(), allowing encoded . and / to be decoded by the backend and interpreted as ../ or /, enabling traversal beyond the intended path scope.
  • Attack surface: Public HTTP endpoint provided by openhole that proxies requests to a local service.
  • Required access: Network access to the exposed openhole tunnel; no local system access is required.
  • Trigger point: Sending HTTP requests with specially crafted r.URL.Path containing percent-encoded dot segments (%2e) and slashes (%2f) through the tunnel.
  • Why exploitation is possible: The proxy forwards r.URL.Path directly rather than using r.URL.EscapedPath(), allowing encoded . and / to be decoded by the backend and interpreted as ../ or /, enabling traversal beyond the intended path scope.

Why this happens

The root cause is improper normalization and handling of user-controlled URL paths in a reverse-proxy/tunneling context.

By forwarding r.URL.Path unchanged, the proxy fails to preserve the original escaped target and effectively delegates decoding and interpretation of encoded special characters to the backend.

This maps to CWE-22: Path Traversal, where attacker-controlled path elements (including encoded dot segments and separators) bypass intended restrictions, allowing access to unintended routes or resources behind the proxy.

The root cause is improper normalization and handling of user-controlled URL paths in a reverse-proxy/tunneling context.

By forwarding r.URL.Path unchanged, the proxy fails to preserve the original escaped target and effectively delegates decoding and interpretation of encoded special characters to the backend.

This maps to CWE-22: Path Traversal, where attacker-controlled path elements (including encoded dot segments and separators) bypass intended restrictions, allowing access to unintended routes or resources behind the proxy.

Potential impact

  • Access to backend endpoints that should not be reachable via the public tunnel.
  • Bypassing path-based access controls or routing constraints enforced by the local service.
  • Interaction with administrative or internal-only HTTP paths exposed on localhost.
  • Potential chained impact if internal endpoints allow configuration changes, data exfiltration, or further code execution.
  • Access to backend endpoints that should not be reachable via the public tunnel.
  • Bypassing path-based access controls or routing constraints enforced by the local service.
  • Interaction with administrative or internal-only HTTP paths exposed on localhost.
  • Potential chained impact if internal endpoints allow configuration changes, data exfiltration, or further code execution.

General mitigation guidance

Effective mitigation focuses on strict path normalization and isolation in proxy components and backend services:

  • Normalize and validate request paths at the proxy boundary, rejecting or rewriting requests with encoded dot segments and directory traversal patterns.
  • Use APIs (such as EscapedPath equivalents) that preserve the exact original request target and avoid reinterpreting encoded special characters unintentionally.
  • Implement explicit routing rules that whitelist allowed path prefixes, rather than relying on default or catch-all routing to backend services.
  • Design local services assuming that any internet-exposed proxy can be manipulated, enforcing their own path validation and avoiding sensitive functions being reachable solely by path structure.

Effective mitigation focuses on strict path normalization and isolation in proxy components and backend services:

  • Normalize and validate request paths at the proxy boundary, rejecting or rewriting requests with encoded dot segments and directory traversal patterns.
  • Use APIs (such as EscapedPath equivalents) that preserve the exact original request target and avoid reinterpreting encoded special characters unintentionally.
  • Implement explicit routing rules that whitelist allowed path prefixes, rather than relying on default or catch-all routing to backend services.
  • Design local services assuming that any internet-exposed proxy can be manipulated, enforcing their own path validation and avoiding sensitive functions being reachable solely by path structure.

How teams detect issues like this

Detection typically combines code-centric and traffic-centric approaches:

  • Static analysis and code review focused on proxy components, flagging direct forwarding of Path fields without normalization or validation, and searching for patterns that manipulate URL paths before backend dispatch.
  • Security tests that send URLs containing encoded .., %2e, %2f, and mixed-encoding patterns to identify traversal behavior across tunnels and reverse proxies.
  • Runtime monitoring and logging of suspicious paths, such as requests containing repeated dot segments, mixed encoded and decoded separators, or unexpected directory ascents, with alerts on anomalies.
  • Integration of automated security testing tools into CI pipelines to scan for common path traversal antipatterns in proxy and routing layers.

Detection typically combines code-centric and traffic-centric approaches:

  • Static analysis and code review focused on proxy components, flagging direct forwarding of Path fields without normalization or validation, and searching for patterns that manipulate URL paths before backend dispatch.
  • Security tests that send URLs containing encoded .., %2e, %2f, and mixed-encoding patterns to identify traversal behavior across tunnels and reverse proxies.
  • Runtime monitoring and logging of suspicious paths, such as requests containing repeated dot segments, mixed encoded and decoded separators, or unexpected directory ascents, with alerts on anomalies.
  • Integration of automated security testing tools into CI pipelines to scan for common path traversal antipatterns in proxy and routing layers.

Sources

SourceLink
github.comgithub.com/bablilayoub/openhole/commit/a28c27adde2a7ed0c347b730c8707208c0f78ed3
github.comgithub.com/bablilayoub/openhole/releases/tag/v0.1.2
github.comgithub.com/bablilayoub/openhole/security/advisories/GHSA-fh2f-xfxc-q9cc

Frequently asked

questions

Yes. An attacker who can send requests to the internet-facing openhole tunnel can exploit the path traversal by crafting URLs with percent-encoded dot segments and separators.

The attacker only needs network access to the exposed openhole endpoint. No authentication is inherently required at the tunneling layer unless separately configured by the operator or the backend service.

Ensure the proxy preserves and uses the escaped request target when forwarding (e.g., EscapedPath-style APIs), normalize paths to remove traversal sequences, and apply strict routing rules that confine requests to explicitly allowed paths.

Treat URL paths as untrusted input, centralize path normalization and validation in gateway and proxy layers, perform security-focused code reviews on routing and tunneling components, and include automated tests that probe for encoded traversal behavior in exposed endpoints.

Yes. An attacker who can send requests to the internet-facing openhole tunnel can exploit the path traversal by crafting URLs with percent-encoded dot segments and separators.

The attacker only needs network access to the exposed openhole endpoint. No authentication is inherently required at the tunneling layer unless separately configured by the operator or the backend service.

Ensure the proxy preserves and uses the escaped request target when forwarding (e.g., EscapedPath-style APIs), normalize paths to remove traversal sequences, and apply strict routing rules that confine requests to explicitly allowed paths.

Treat URL paths as untrusted input, centralize path normalization and validation in gateway and proxy layers, perform security-focused code reviews on routing and tunneling components, and include automated tests that probe for encoded traversal behavior in exposed endpoints.

Find out what's already
exploitable in your codebase.