CVE-2026-30247: WeKnora: SSRF via Redirection

Published Mar 5, 2026
·
Updated

Summary

The application's "Import document via URL" feature is vulnerable to Server-Side Request Forgery (SSRF) through HTTP redirects. While the backend implements comprehensive URL validation (blocking private IPs, loopback addresses, reserved hostnames, and cloud metadata endpoints), it fails to validate redirect targets. An attacker can bypass all protections by using a redirect chain, forcing the server to access internal services. Additionally, Docker-specific internal addresses like host.docker.internal are not blocked.

Details

The /api/v1/knowledge-bases/{id}/knowledge/url endpoint validates the initial URL but follows HTTP redirects without re-validating the destination. This allows attackers to: 1. Submit a URL to an attacker-controlled domain (passes validation) 2. Have that domain respond with a 307 redirect to an internal service 3. The backend automatically follows the redirect without checking if the destination is restricted 4. The internal service response is exposed to the attacker

Validation Gaps - The IsSSRFSafeURL() function (in internal/utils/security.go) validates the initial URL thoroughly, but there's no validation of HTTP redirect targets - host.docker.internal is not in the restrictedHostnames list - Docker-specific IP ranges (172.17.0.0/16 for bridge networks) are not explicitly blocked - The code validates parsed.Hostname() from the initial URL, but redirect Location headers bypass this check

Root Cause Analysis The backend makes the security mistake of trusting the server's HTTP client library to be secure. In Go, when using http.Get() or similar functions, the standard library will automatically follow redirects up to 10 times by default. The SSRF validation only checks the URL passed to the endpoint, not intermediate redirects.

PoC

Step 1: Set up an attacker-controlled server that responds with a redirect:

http HTTP/1.1 307 Temporary Redirect Location: http://host.docker.internal:7777 Content-Type: text/html Access-Control-Allow-Origin: Step 2: Send the request with a clean URL:

http POST /api/v1/knowledge-bases/dbadd153-9e60-4213-9553-9f78dbcba0dc/knowledge/url HTTP/1.1 Host: localhost Content-Type: application/json Authorization: Bearer <validtoken>

{"url":"https://attacker-domain.com","tagid":""}

The URL https://attacker-domain.com passes all validation checks because: ✓ Valid https:// scheme ✓ Not an IP address (it's a domain) ✓ Not in restricted hostnames ✓ Doesn't resolve to a private IP (assuming attacker controls a public domain)

Step 3: The backend's HTTP client follows the redirect to http://host.docker.internal:7777, which: ✗ Is not validated ✗ host.docker.internal is not in the blocklist ✗ Successfully accesses the internal service

Impact

Vulnerability Type: Server-Side Request Forgery (SSRF) via HTTP Redirect

Who is Impacted: - The organization running the application - Internal services and databases accessible from the application container - Services in the Docker network (other containers, internal infrastructure) - Sensitive data stored in internal services

Potential Consequences: - Access to internal databases (PostgreSQL, MongoDB, MySQL) running in Docker - Information disclosure from internal services (Redis cache, configuration servers) - Access to Docker container metadata and environment variables - Lateral movement to other containers in the same Docker network - Exfiltration of sensitive configuration, API keys, or database credentials - Potential RCE if internal services have exploitable vulnerabilities

Other sources

WeKnora is an LLM-powered framework designed for deep document understanding and semantic retrieval. Prior to version 0.2.12, the application's "Import document via URL" feature is vulnerable to Server-Side Request Forgery (SSRF) through HTTP redirects. While the backend implements comprehensive URL validation (blocking private IPs, loopback addresses, reserved hostnames, and cloud metadata endpoints), it fails to validate redirect targets. An attacker can bypass all protections by using a redirect chain, forcing the server to access internal services. Additionally, Docker-specific internal addresses like host.docker.internal are not blocked. This issue has been patched in version 0.2.12.

MITRE

Affected Software

2 affected componentsFixes available
go/github.com/Tencent/WeKnora<=0.2.11
0.2.12
Tencent WeKnora<0.2.12

Event History

Mar 5, 2026
Advisory Published
via GitHub·09:49 PM
Data Sourced
via GitHub·09:49 PM
DescriptionSeverityWeaknessAffected Software
Mar 7, 2026
CVE Published
via MITRE·03:33 AM
Data Sourced
via MITRE·03:33 AM
DescriptionSeverityWeakness
Data Sourced
via NVD·04:15 AM
DescriptionSeverityWeaknessAffected Software
Feb 18, 58167
Event
via FIRST·12:09 AM
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-30247?

CVE-2026-30247 is classified as a high severity vulnerability due to the risk of SSRF attacks.

2

How do I fix CVE-2026-30247?

To mitigate CVE-2026-30247, upgrade WeKnora to version 0.2.12 or later to implement the necessary security controls.

3

What type of vulnerability is CVE-2026-30247?

CVE-2026-30247 is a Server-Side Request Forgery (SSRF) vulnerability associated with HTTP redirections.

4

Which versions of WeKnora are affected by CVE-2026-30247?

Versions of WeKnora from 0.2.11 and below are affected by CVE-2026-30247.

5

What can happen if CVE-2026-30247 is exploited?

If exploited, CVE-2026-30247 may allow an attacker to access internal services by manipulating server-side requests.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203