CWE-295
AllowedImproper Certificate Validation
Abstraction: Base · Status: Draft
The product does not validate, or incorrectly validates, a certificate.
1913 vulnerabilities reference this CWE, most recent first.
GHSA-946V-J885-6J5F
Vulnerability from github – Published: 2022-08-26 00:03 – Updated: 2022-09-01 00:00Odyssey passes to server unencrypted bytes from man-in-the-middle When Odyssey is configured to use certificate Common Name for client authentication, a man-in-the-middle attacker can inject arbitrary SQL queries when a connection is first established, despite the use of SSL certificate verification and encryption. This is similar to CVE-2021-23214 for PostgreSQL.
{
"affected": [],
"aliases": [
"CVE-2021-43766"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-08-25T18:15:00Z",
"severity": "HIGH"
},
"details": "Odyssey passes to server unencrypted bytes from man-in-the-middle When Odyssey is configured to use certificate Common Name for client authentication, a man-in-the-middle attacker can inject arbitrary SQL queries when a connection is first established, despite the use of SSL certificate verification and encryption. This is similar to CVE-2021-23214 for PostgreSQL.",
"id": "GHSA-946v-j885-6j5f",
"modified": "2022-09-01T00:00:22Z",
"published": "2022-08-26T00:03:30Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2021-43766"
},
{
"type": "WEB",
"url": "https://github.com/yandex/odyssey/issues/376,"
},
{
"type": "WEB",
"url": "https://www.postgresql.org/support/security/CVE-2021-23214"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-9495-4RPC-2JCG
Vulnerability from github – Published: 2022-05-24 16:58 – Updated: 2024-04-04 02:10The Twitter Kit framework through 3.4.2 for iOS does not properly validate the api.twitter.com SSL certificate. Although the certificate chain must contain one of a set of pinned certificates, there are certain implementation errors such as a lack of hostname verification. NOTE: this is an end-of-life product.
{
"affected": [],
"aliases": [
"CVE-2019-16263"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2019-10-07T12:15:00Z",
"severity": "HIGH"
},
"details": "The Twitter Kit framework through 3.4.2 for iOS does not properly validate the api.twitter.com SSL certificate. Although the certificate chain must contain one of a set of pinned certificates, there are certain implementation errors such as a lack of hostname verification. NOTE: this is an end-of-life product.",
"id": "GHSA-9495-4rpc-2jcg",
"modified": "2024-04-04T02:10:00Z",
"published": "2022-05-24T16:58:02Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-16263"
},
{
"type": "WEB",
"url": "https://blog.appicaptor.com/2019/10/04/vulnerable-library-warning-twitterkit-for-ios"
},
{
"type": "WEB",
"url": "https://github.com/twitter-archive/twitter-kit-ios/blob/ac42e1351a66afa5ff7718d04d64a905dafe1f41/TwitterCore/TwitterCore/Networking/Security/TWTRServerTrustEvaluator.m#L75-L81"
},
{
"type": "WEB",
"url": "https://www.sit.fraunhofer.de/fileadmin/dokumente/CVE/Advisory_TwitterKit_for_iOS_CVE-2019-16263.pdf"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-94H4-GPX9-W23J
Vulnerability from github – Published: 2022-05-17 02:47 – Updated: 2022-05-17 02:47WAON "Service Application" for Android 1.4.1 and earlier does not verify SSL certificates.
{
"affected": [],
"aliases": [
"CVE-2016-4832"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-04-21T14:59:00Z",
"severity": "MODERATE"
},
"details": "WAON \"Service Application\" for Android 1.4.1 and earlier does not verify SSL certificates.",
"id": "GHSA-94h4-gpx9-w23j",
"modified": "2022-05-17T02:47:51Z",
"published": "2022-05-17T02:47:51Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2016-4832"
},
{
"type": "WEB",
"url": "http://jvn.jp/en/jp/JVN68364327/index.html"
},
{
"type": "WEB",
"url": "http://jvndb.jvn.jp/ja/contents/2016/JVNDB-2016-000124.html"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/91789"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-94JQ-Q5V2-76WJ
Vulnerability from github – Published: 2021-11-24 21:02 – Updated: 2024-09-12 21:14Connections initialized by the AWS IoT Device SDK v2 for Java (versions prior to 1.3.3), Python (versions prior to 1.5.18), C++ (versions prior to 1.12.7) and Node.js (versions prior to 1.5.1) did not verify server certificate hostname during TLS handshake when overriding Certificate Authorities (CA) in their trust stores on Windows. This issue has been addressed in aws-c-io submodule versions 0.9.13 onward. This issue affects: Amazon Web Services AWS IoT Device SDK v2 for Java versions prior to 1.3.3 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for Python versions prior to 1.5.18 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for C++ versions prior to 1.12.7 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for Node.js versions prior to 1.5.3 on Microsoft Windows.
{
"affected": [
{
"package": {
"ecosystem": "Maven",
"name": "software.amazon.awssdk.iotdevicesdk:aws-iot-device-sdk"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.3.3"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "npm",
"name": "aws-iot-device-sdk-v2"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.5.1"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "PyPI",
"name": "awsiotsdk"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.5.18"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2021-40828"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": true,
"github_reviewed_at": "2021-11-24T20:33:58Z",
"nvd_published_at": "2021-11-23T00:15:00Z",
"severity": "MODERATE"
},
"details": "Connections initialized by the AWS IoT Device SDK v2 for Java (versions prior to 1.3.3), Python (versions prior to 1.5.18), C++ (versions prior to 1.12.7) and Node.js (versions prior to 1.5.1) did not verify server certificate hostname during TLS handshake when overriding Certificate Authorities (CA) in their trust stores on Windows. This issue has been addressed in aws-c-io submodule versions 0.9.13 onward. This issue affects: Amazon Web Services AWS IoT Device SDK v2 for Java versions prior to 1.3.3 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for Python versions prior to 1.5.18 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for C++ versions prior to 1.12.7 on Microsoft Windows. Amazon Web Services AWS IoT Device SDK v2 for Node.js versions prior to 1.5.3 on Microsoft Windows.",
"id": "GHSA-94jq-q5v2-76wj",
"modified": "2024-09-12T21:14:08Z",
"published": "2021-11-24T21:02:24Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2021-40828"
},
{
"type": "WEB",
"url": "https://github.com/aws/aws-iot-device-sdk-java-v2/commit/67950ad2a02f2f9355c310b69dc9226b017f32f2"
},
{
"type": "WEB",
"url": "https://github.com/aws/aws-iot-device-sdk-js-v2/commit/4be41394f1aee979e6f4b012fcb01eecabd0c08d"
},
{
"type": "WEB",
"url": "https://github.com/aws/aws-iot-device-sdk-python-v2/commit/fd4c0ba04b35eab9e20c635af5548fcc5a92d8be"
},
{
"type": "ADVISORY",
"url": "https://github.com/advisories/GHSA-94jq-q5v2-76wj"
},
{
"type": "WEB",
"url": "https://github.com/aws/aws-iot-device-sdk-cpp-v2"
},
{
"type": "WEB",
"url": "https://github.com/aws/aws-iot-device-sdk-java-v2"
},
{
"type": "WEB",
"url": "https://github.com/aws/aws-iot-device-sdk-js-v2"
},
{
"type": "WEB",
"url": "https://github.com/aws/aws-iot-device-sdk-python-v2"
},
{
"type": "WEB",
"url": "https://github.com/awslabs/aws-c-io"
},
{
"type": "WEB",
"url": "https://github.com/pypa/advisory-database/tree/main/vulns/awsiotsdk/PYSEC-2021-861.yaml"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:A/AC:H/PR:H/UI:R/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
},
{
"score": "CVSS:4.0/AV:A/AC:L/AT:P/PR:H/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "Improper certificate management in AWS IoT Device SDK v2"
}
GHSA-94Q2-3CFP-G294
Vulnerability from github – Published: 2025-03-14 18:30 – Updated: 2025-03-14 18:30An improper certificate validation vulnerability [CWE-295] in FortiNAC-F version 7.2.4 and below may allow a remote and unauthenticated attacker to perform a Man-in-the-Middle attack on the HTTPS communication channel between the FortiOS device, an inventory, and FortiNAC-F.
{
"affected": [],
"aliases": [
"CVE-2023-48785"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-03-14T16:15:27Z",
"severity": "MODERATE"
},
"details": "An improper certificate validation vulnerability [CWE-295] in FortiNAC-F version 7.2.4 and below may allow a remote and unauthenticated attacker to perform a Man-in-the-Middle attack on the HTTPS communication channel between the FortiOS device, an inventory, and FortiNAC-F.",
"id": "GHSA-94q2-3cfp-g294",
"modified": "2025-03-14T18:30:50Z",
"published": "2025-03-14T18:30:50Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-48785"
},
{
"type": "WEB",
"url": "https://fortiguard.com/psirt/FG-IR-23-288"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-94V3-77J7-VM48
Vulnerability from github – Published: 2026-07-21 20:41 – Updated: 2026-07-21 20:41Summary
Gitea's internal API HTTP client (modules/private/internal.go) hardcodes TLSClientConfig.InsecureSkipVerify = true with no configuration override. It is the only outbound TLS client in the codebase that cannot be made to verify its peer's certificate — webhook, migrations, MinIO, LDAP, SMTP, Redis and incoming-mail all expose a secure-by-default SkipVerify toggle, this one does not.
When an operator configures internal communication over HTTPS to a non-loopback target (LOCAL_ROOT_URL=https:/// in a split-host / multi-pod topology), the gitea serv / gitea hook subprocess that calls the internal API will accept ANY TLS certificate. An attacker with on-path position on that internal segment can MITM the connection and capture the static high-privilege INTERNAL_TOKEN, which is the sole authentication for every /api/internal/* endpoint (server shutdown/restart, SSH key authorization, git command execution, repo hooks, mail send, runner-token generation).
Severity is deployment-dependent: High for split-host HTTPS deployments; Low/Informational for the default single-host / unix-socket / HTTP-loopback deployment, where the call is loopback and not interceptable without local access (which already exposes the token directly). This report is rated for the affected configuration and the underlying defense-in-depth defect. Details
Affected component: modules/private/internal.go
The internal API transport hardcodes certificate-verification bypass:
var internalAPITransport = sync.OnceValue(func() http.RoundTripper {
return &http.Transport{
DialContext: dialContextInternalAPI,
TLSClientConfig: &tls.Config{
InsecureSkipVerify: true, // hardcoded, no config gate
ServerName: setting.Domain, // SNI only; NOT used for validation while skip=true
},
}
})
Because InsecureSkipVerify is true, ServerName is used only for SNI and any certificate (any CN, self-signed) is accepted; there is no accidental safety net.
Verified exploit chain (read against main @ aab9737651, 2026-06-13):
-
TLS path is reached whenever LOCAL_ROOT_URL scheme is https — http.Transport applies TLSClientConfig only for https requests. (modules/private/internal.go:56-64)
-
The dialer connects to the real host from the URL, with no loopback pinning: dialContextInternalAPI -> d.DialContext(ctx, network, address), where address is the host:port from LOCAL_ROOT_URL. (modules/private/internal.go:37-54)
-
The client runs as a SEPARATE process, so a real socket is used and can cross hosts:
- Built-in and external SSH both exec "gitea serv key-N" (modules/ssh/ssh.go:109,123; models/asymkey/ssh_key_authorized_keys.go via authorized_keys command=).
-
Git hooks exec "gitea hook ...". These subprocesses call back to LOCAL_ROOT_URL. Same host => loopback; split host => network hop.
-
INTERNAL_TOKEN is sent on every internal request as a static bearer header: Header("X-Gitea-Internal-Auth", "Bearer "+setting.InternalToken) (modules/private/internal.go:80)
-
A captured token is accepted and is the SOLE gate for all internal routes: authInternal() does subtle.ConstantTimeCompare(header, setting.InternalToken) and nothing else. (routers/private/internal.go:24-42). The server code even comments: "// TODO: use something like JWT or HMAC to avoid passing the token in the clear" (routers/private/internal.go:32)
-
Amplifier: internal routes are mounted on the main public listener, not a loopback-only socket: r.Mount("/api/internal", private.Routes()) (routers/init.go:185) so a stolen token is replayable by anyone who can reach the Gitea HTTP port.
Inconsistency / root cause: every other outbound TLS client is configurable and secure-by-default (services/webhook/deliver.go Webhook.SkipTLSVerify; services/migrations/http_client.go Migrations.SkipTLSVerify; modules/storage/minio.go MINIO_INSECURE_SKIP_VERIFY; LDAP/SMTP SkipVerify; incoming-mail SkipTLSVerify). The internal API client alone is hardcoded insecure with no opt-out. The InsecureSkipVerify line has been present since 2017 (#1471), so all releases are affected. PoC
Goal: capture the live INTERNAL_TOKEN from a real Gitea subprocess call and replay it.
Note: a self-contained TLS test (e.g. Python ssl.CERT_NONE accepting a self-signed cert) only restates the flag's definition and does NOT involve Gitea. The steps below exercise the real path.
-
Configure Gitea so the internal client uses HTTPS to an interceptable target: [server] PROTOCOL = https LOCAL_ROOT_URL = https://127.0.0.1:8443/
-
Run a rogue TLS listener on 127.0.0.1:8443 presenting ANY self-signed certificate, logging the X-Gitea-Internal-Auth request header. Minimal handler:
# python3 rogue.py import http.server, ssl, subprocess subprocess.run(["openssl","req","-x509","-newkey","rsa:2048","-keyout","k.pem","-out","c.pem", "-days","1","-nodes","-subj","/CN=127.0.0.1"], check=True) class H(http.server.BaseHTTPRequestHandler): def handle_one(self): pass def do_GET(self): self._h() def do_POST(self): self._h() def _h(self): a = self.headers.get("X-Gitea-Internal-Auth","") if "Bearer" in a: print("[!] CAPTURED TOKEN:", a.replace("Bearer ","")) self.send_response(200); self.end_headers(); self.wfile.write(b'{"err":"","user_msg":""}') def log_message(self,*a): pass s = http.server.HTTPServer(("127.0.0.1",8443), H) ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER); ctx.load_cert_chain("c.pem","k.pem") s.socket = ctx.wrap_socket(s.socket, server_side=True) s.serve_forever()
-
Trigger a real internal call through a subprocess path: perform an SSH git operation against the instance (e.g.
git clone ssh://git@<host>:<port>/owner/repo.git). sshd/built-in SSH execsgitea serv, which issues the internal API request to LOCAL_ROOT_URL and presents the token to the rogue listener. -
Observe at the listener: [!] CAPTURED TOKEN:
-
Confirm the token is privileged by replaying it directly against the Gitea HTTP port: curl -k https://:/api/internal/manager/processes \ -H "X-Gitea-Internal-Auth: Bearer " A 200 with process data confirms full internal-API access (the same token also reaches /api/internal/manager/shutdown, /ssh/authorized_keys, /serv/command/..., etc.).
In a production split-host deployment, step 2 is replaced by on-path interception (ARP spoofing on the shared segment, a malicious sidecar/pod, or DNS/route manipulation) rather than a localhost listener; the client behaviour (trusting the rogue cert and sending the token) is identical. Impact
Type: CWE-295 Improper Certificate Validation -> man-in-the-middle -> theft of the static high-privilege INTERNAL_TOKEN -> full internal-API compromise.
Who is impacted: operators who run internal communication over HTTPS to a non-loopback target (split-host / multi-pod / separate SSH or hook host with LOCAL_ROOT_URL=https:///) on a network segment where an attacker can obtain on-path position. With the token, an attacker can: shut down / restart the server (DoS), authorize SSH keys, execute git serv commands, control pre/post/proc-receive hooks, change default branches, restore repos, send mail as Gitea, and generate Actions runner tokens.
NOT practically impacted: default single-host, unix-socket (http+unix), or HTTP-loopback deployments, where the internal call is loopback and not interceptable without local code execution (which already exposes INTERNAL_TOKEN from app.ini, making MITM unnecessary).
{
"affected": [
{
"package": {
"ecosystem": "Go",
"name": "code.gitea.io/gitea"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.27.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-54481"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": true,
"github_reviewed_at": "2026-07-21T20:41:25Z",
"nvd_published_at": null,
"severity": "HIGH"
},
"details": "Summary\n\nGitea\u0027s internal API HTTP client (modules/private/internal.go) hardcodes\nTLSClientConfig.InsecureSkipVerify = true with no configuration override. It is the only\noutbound TLS client in the codebase that cannot be made to verify its peer\u0027s certificate \u2014\nwebhook, migrations, MinIO, LDAP, SMTP, Redis and incoming-mail all expose a secure-by-default\nSkipVerify toggle, this one does not.\n\nWhen an operator configures internal communication over HTTPS to a non-loopback target\n(LOCAL_ROOT_URL=https://\u003chost\u003e/ in a split-host / multi-pod topology), the gitea serv / gitea hook\nsubprocess that calls the internal API will accept ANY TLS certificate. An attacker with on-path\nposition on that internal segment can MITM the connection and capture the static high-privilege\nINTERNAL_TOKEN, which is the sole authentication for every /api/internal/* endpoint (server\nshutdown/restart, SSH key authorization, git command execution, repo hooks, mail send, runner-token\ngeneration).\n\nSeverity is deployment-dependent: High for split-host HTTPS deployments; Low/Informational for the\ndefault single-host / unix-socket / HTTP-loopback deployment, where the call is loopback and not\ninterceptable without local access (which already exposes the token directly). This report is\nrated for the affected configuration and the underlying defense-in-depth defect.\nDetails\n\nAffected component: modules/private/internal.go\n\nThe internal API transport hardcodes certificate-verification bypass:\n\n var internalAPITransport = sync.OnceValue(func() http.RoundTripper {\n return \u0026http.Transport{\n DialContext: dialContextInternalAPI,\n TLSClientConfig: \u0026tls.Config{\n InsecureSkipVerify: true, // hardcoded, no config gate\n ServerName: setting.Domain, // SNI only; NOT used for validation while skip=true\n },\n }\n })\n\nBecause InsecureSkipVerify is true, ServerName is used only for SNI and any certificate (any CN,\nself-signed) is accepted; there is no accidental safety net.\n\nVerified exploit chain (read against main @ aab9737651, 2026-06-13):\n\n1. TLS path is reached whenever LOCAL_ROOT_URL scheme is https \u2014 http.Transport applies\n TLSClientConfig only for https requests. (modules/private/internal.go:56-64)\n\n2. The dialer connects to the real host from the URL, with no loopback pinning:\n dialContextInternalAPI -\u003e d.DialContext(ctx, network, address), where address is the host:port\n from LOCAL_ROOT_URL. (modules/private/internal.go:37-54)\n\n3. The client runs as a SEPARATE process, so a real socket is used and can cross hosts:\n - Built-in and external SSH both exec \"gitea serv key-N\" (modules/ssh/ssh.go:109,123;\n models/asymkey/ssh_key_authorized_keys.go via authorized_keys command=).\n - Git hooks exec \"gitea hook ...\".\n These subprocesses call back to LOCAL_ROOT_URL. Same host =\u003e loopback; split host =\u003e network hop.\n\n4. INTERNAL_TOKEN is sent on every internal request as a static bearer header:\n Header(\"X-Gitea-Internal-Auth\", \"Bearer \"+setting.InternalToken) (modules/private/internal.go:80)\n\n5. A captured token is accepted and is the SOLE gate for all internal routes:\n authInternal() does subtle.ConstantTimeCompare(header, setting.InternalToken) and nothing else.\n (routers/private/internal.go:24-42). The server code even comments:\n \"// TODO: use something like JWT or HMAC to avoid passing the token in the clear\"\n (routers/private/internal.go:32)\n\n6. Amplifier: internal routes are mounted on the main public listener, not a loopback-only socket:\n r.Mount(\"/api/internal\", private.Routes()) (routers/init.go:185)\n so a stolen token is replayable by anyone who can reach the Gitea HTTP port.\n\nInconsistency / root cause: every other outbound TLS client is configurable and secure-by-default\n(services/webhook/deliver.go Webhook.SkipTLSVerify; services/migrations/http_client.go\nMigrations.SkipTLSVerify; modules/storage/minio.go MINIO_INSECURE_SKIP_VERIFY; LDAP/SMTP SkipVerify;\nincoming-mail SkipTLSVerify). The internal API client alone is hardcoded insecure with no opt-out.\nThe InsecureSkipVerify line has been present since 2017 (#1471), so all releases are affected.\nPoC\n\nGoal: capture the live INTERNAL_TOKEN from a real Gitea subprocess call and replay it.\n\nNote: a self-contained TLS test (e.g. Python ssl.CERT_NONE accepting a self-signed cert) only\nrestates the flag\u0027s definition and does NOT involve Gitea. The steps below exercise the real path.\n\n1. Configure Gitea so the internal client uses HTTPS to an interceptable target:\n [server]\n PROTOCOL = https\n LOCAL_ROOT_URL = https://127.0.0.1:8443/\n\n2. Run a rogue TLS listener on 127.0.0.1:8443 presenting ANY self-signed certificate, logging the\n X-Gitea-Internal-Auth request header. Minimal handler:\n\n # python3 rogue.py\n import http.server, ssl, subprocess\n subprocess.run([\"openssl\",\"req\",\"-x509\",\"-newkey\",\"rsa:2048\",\"-keyout\",\"k.pem\",\"-out\",\"c.pem\",\n \"-days\",\"1\",\"-nodes\",\"-subj\",\"/CN=127.0.0.1\"], check=True)\n class H(http.server.BaseHTTPRequestHandler):\n def handle_one(self):\n pass\n def do_GET(self): self._h()\n def do_POST(self): self._h()\n def _h(self):\n a = self.headers.get(\"X-Gitea-Internal-Auth\",\"\")\n if \"Bearer\" in a: print(\"[!] CAPTURED TOKEN:\", a.replace(\"Bearer \",\"\"))\n self.send_response(200); self.end_headers(); self.wfile.write(b\u0027{\"err\":\"\",\"user_msg\":\"\"}\u0027)\n def log_message(self,*a): pass\n s = http.server.HTTPServer((\"127.0.0.1\",8443), H)\n ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER); ctx.load_cert_chain(\"c.pem\",\"k.pem\")\n s.socket = ctx.wrap_socket(s.socket, server_side=True)\n s.serve_forever()\n\n3. Trigger a real internal call through a subprocess path: perform an SSH git operation against the\n instance (e.g. `git clone ssh://git@\u003chost\u003e:\u003cport\u003e/owner/repo.git`). sshd/built-in SSH execs\n `gitea serv`, which issues the internal API request to LOCAL_ROOT_URL and presents the token to\n the rogue listener.\n\n4. Observe at the listener:\n [!] CAPTURED TOKEN: \u003cINTERNAL_TOKEN\u003e\n\n5. Confirm the token is privileged by replaying it directly against the Gitea HTTP port:\n curl -k https://\u003cgitea-host\u003e:\u003cport\u003e/api/internal/manager/processes \\\n -H \"X-Gitea-Internal-Auth: Bearer \u003cINTERNAL_TOKEN\u003e\"\n A 200 with process data confirms full internal-API access (the same token also reaches\n /api/internal/manager/shutdown, /ssh/authorized_keys, /serv/command/..., etc.).\n\nIn a production split-host deployment, step 2 is replaced by on-path interception (ARP spoofing on\nthe shared segment, a malicious sidecar/pod, or DNS/route manipulation) rather than a localhost\nlistener; the client behaviour (trusting the rogue cert and sending the token) is identical.\nImpact\n\nType: CWE-295 Improper Certificate Validation -\u003e man-in-the-middle -\u003e theft of the static\nhigh-privilege INTERNAL_TOKEN -\u003e full internal-API compromise.\n\nWho is impacted: operators who run internal communication over HTTPS to a non-loopback target\n(split-host / multi-pod / separate SSH or hook host with LOCAL_ROOT_URL=https://\u003cremote\u003e/) on a\nnetwork segment where an attacker can obtain on-path position. With the token, an attacker can:\nshut down / restart the server (DoS), authorize SSH keys, execute git serv commands, control\npre/post/proc-receive hooks, change default branches, restore repos, send mail as Gitea, and\ngenerate Actions runner tokens.\n\nNOT practically impacted: default single-host, unix-socket (http+unix), or HTTP-loopback\ndeployments, where the internal call is loopback and not interceptable without local code execution\n(which already exposes INTERNAL_TOKEN from app.ini, making MITM unnecessary).",
"id": "GHSA-94v3-77j7-vm48",
"modified": "2026-07-21T20:41:25Z",
"published": "2026-07-21T20:41:25Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/go-gitea/gitea/security/advisories/GHSA-94v3-77j7-vm48"
},
{
"type": "PACKAGE",
"url": "https://github.com/go-gitea/gitea"
},
{
"type": "WEB",
"url": "https://github.com/go-gitea/gitea/releases/tag/v1.27.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:A/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Gitea: Internal API HTTP client hardcodes InsecureSkipVerify:true with no config override"
}
GHSA-9555-FVR7-FM2H
Vulnerability from github – Published: 2022-05-13 01:30 – Updated: 2025-04-20 03:48Cyberduck before 4.4.4 on Windows does not properly validate X.509 certificate chains, which allows man-in-the-middle attackers to spoof FTP-SSL servers via a certificate issued by an arbitrary root Certification Authority.
{
"affected": [],
"aliases": [
"CVE-2014-2845"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-11-15T18:29:00Z",
"severity": "MODERATE"
},
"details": "Cyberduck before 4.4.4 on Windows does not properly validate X.509 certificate chains, which allows man-in-the-middle attackers to spoof FTP-SSL servers via a certificate issued by an arbitrary root Certification Authority.",
"id": "GHSA-9555-fvr7-fm2h",
"modified": "2025-04-20T03:48:29Z",
"published": "2022-05-13T01:30:22Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2014-2845"
},
{
"type": "WEB",
"url": "https://cyberduck.io/changelog"
},
{
"type": "WEB",
"url": "http://secunia.com/advisories/58426"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/archive/1/532039/100/0/threaded"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-95FC-G4GJ-MQMX
Vulnerability from github – Published: 2025-04-25 15:12 – Updated: 2025-05-05 22:02Impact
A vulnerability has been identified in Steve where by default it was using an insecure option that did not validate the certificate presented by the remote server while performing a TLS connection. This could allow the execution of a man-in-the-middle (MitM) attack against services using Steve.
For example, Rancher relies on Steve as a dependency for its user interface (UI) to proxy requests to Kubernetes clusters. Users who have the permission to create a service in Rancher’s local cluster can take over Rancher’s UI and display their own UI to gather sensitive information. This is only possible when the setting ui-offline-preferred is manually set to remote (by default Rancher sets it to dynamic). This enables further attacks such as cross-site scripting (XSS), or tampering the UI to collect passwords from other users etc.
Please consult the associated MITRE ATT&CK - Technique - Adversary-in-the-Middle for further information about this category of attack.
Patches
Patched versions of Steve include releases v0.2.1, v0.3.3, v0.4.4 and v0.5.13.
This vulnerability is addressed by changing Steve to always verify a server’s certificate based on Go’s TLS settings.
Workarounds
If you can't upgrade to a fixed version, please make sure that you are only using Steve to connect to trusted servers.
References
If you have any questions or comments about this advisory: - Reach out to the SUSE Rancher Security team for security related inquiries. - Open an issue in the Rancher repository. - Verify with our support matrix and product support lifecycle.
{
"affected": [
{
"package": {
"ecosystem": "Go",
"name": "github.com/rancher/steve"
},
"ranges": [
{
"events": [
{
"introduced": "0.2.0"
},
{
"fixed": "0.2.1"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Go",
"name": "github.com/rancher/steve"
},
"ranges": [
{
"events": [
{
"introduced": "0.3.0"
},
{
"fixed": "0.3.3"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Go",
"name": "github.com/rancher/steve"
},
"ranges": [
{
"events": [
{
"introduced": "0.4.0"
},
{
"fixed": "0.4.4"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Go",
"name": "github.com/rancher/steve"
},
"ranges": [
{
"events": [
{
"introduced": "0.5.0"
},
{
"fixed": "0.5.13"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2023-32198"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": true,
"github_reviewed_at": "2025-04-25T15:12:44Z",
"nvd_published_at": null,
"severity": "HIGH"
},
"details": "### Impact\nA vulnerability has been identified in Steve where by default it was using an insecure option that did not validate the certificate presented by the remote server while performing a TLS connection. This could allow the execution of a man-in-the-middle (MitM) attack against services using Steve.\n\nFor example, Rancher relies on Steve as a dependency for its user interface (UI) to proxy requests to Kubernetes clusters. Users who have the permission to create a service in Rancher\u2019s local cluster can take over Rancher\u2019s UI and display their own UI to gather sensitive information. This is only possible when the setting `ui-offline-preferred` is manually set to `remote` (by default Rancher sets it to `dynamic`). This enables further attacks such as cross-site scripting (XSS), or tampering the UI to collect passwords from other users etc.\n\nPlease consult the associated [MITRE ATT\u0026CK - Technique - Adversary-in-the-Middle](https://attack.mitre.org/techniques/T1557/) for further information about this category of attack.\n\n### Patches\nPatched versions of Steve include releases `v0.2.1`, `v0.3.3`, `v0.4.4` and `v0.5.13`.\n\nThis vulnerability is addressed by changing Steve to always verify a server\u2019s certificate based on Go\u2019s TLS settings.\n\n### Workarounds\nIf you can\u0027t upgrade to a fixed version, please make sure that you are only using Steve to connect to trusted servers.\n\n### References\nIf you have any questions or comments about this advisory:\n- Reach out to the [SUSE Rancher Security team](https://github.com/rancher/rancher/security/policy) for security related inquiries.\n- Open an issue in the [Rancher](https://github.com/rancher/rancher/issues/new/choose) repository.\n- Verify with our [support matrix](https://www.suse.com/suse-rancher/support-matrix/all-supported-versions/) and [product support lifecycle](https://www.suse.com/lifecycle/).",
"id": "GHSA-95fc-g4gj-mqmx",
"modified": "2025-05-05T22:02:01Z",
"published": "2025-04-25T15:12:44Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/rancher/steve/security/advisories/GHSA-95fc-g4gj-mqmx"
},
{
"type": "PACKAGE",
"url": "https://github.com/rancher/steve"
},
{
"type": "WEB",
"url": "https://pkg.go.dev/vuln/GO-2025-3648"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:C/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Steve doesn\u2019t verify a server\u2019s certificate and is susceptible to man-in-the-middle (MitM) attacks"
}
GHSA-965H-392X-2MH5
Vulnerability from github – Published: 2026-04-16 21:16 – Updated: 2026-04-16 21:16Name constraints for URI names were ignored and therefore accepted.
Note this library does not provide an API for asserting URI names, and URI name constraints are otherwise not implemented. URI name constraints are now rejected unconditionally.
Since name constraints are restrictions on otherwise properly-issued certificates, this bug is reachable only after signature verification and requires misissuance to exploit.
{
"affected": [
{
"package": {
"ecosystem": "crates.io",
"name": "rustls-webpki"
},
"ranges": [
{
"events": [
{
"introduced": "0.101.0"
},
{
"fixed": "0.103.12"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "crates.io",
"name": "rustls-webpki"
},
"ranges": [
{
"events": [
{
"introduced": "0.104.0-alpha.1"
},
{
"fixed": "0.104.0-alpha.6"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": true,
"github_reviewed_at": "2026-04-16T21:16:22Z",
"nvd_published_at": null,
"severity": "LOW"
},
"details": "Name constraints for URI names were ignored and therefore accepted.\n\nNote this library does not provide an API for asserting URI names, and URI name constraints are otherwise not implemented. URI name constraints are now rejected unconditionally.\n\nSince name constraints are restrictions on otherwise properly-issued certificates, this bug is reachable only after signature verification and requires misissuance to exploit.",
"id": "GHSA-965h-392x-2mh5",
"modified": "2026-04-16T21:16:23Z",
"published": "2026-04-16T21:16:22Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/rustls/webpki/security/advisories/GHSA-965h-392x-2mh5"
},
{
"type": "PACKAGE",
"url": "https://github.com/rustls/webpki"
},
{
"type": "WEB",
"url": "https://rustsec.org/advisories/RUSTSEC-2026-0098.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:N/I:L/A:N",
"type": "CVSS_V3"
}
],
"summary": "webpki: Name constraints for URI names were incorrectly accepted"
}
GHSA-972M-28WJ-HR23
Vulnerability from github – Published: 2022-05-17 02:48 – Updated: 2025-04-20 03:36DMMFX Trade for Android 1.5.0 and earlier, DMMFX DEMO Trade for Android 1.5.0 and earlier, and GAITAMEJAPAN FX Trade for Android 1.4.0 and earlier do not verify SSL certificates.
{
"affected": [],
"aliases": [
"CVE-2016-4818"
],
"database_specific": {
"cwe_ids": [
"CWE-295"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-04-20T18:59:00Z",
"severity": "MODERATE"
},
"details": "DMMFX Trade for Android 1.5.0 and earlier, DMMFX DEMO Trade for Android 1.5.0 and earlier, and GAITAMEJAPAN FX Trade for Android 1.4.0 and earlier do not verify SSL certificates.",
"id": "GHSA-972m-28wj-hr23",
"modified": "2025-04-20T03:36:21Z",
"published": "2022-05-17T02:48:13Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2016-4818"
},
{
"type": "WEB",
"url": "https://jvn.jp/en/jp/JVN40898764/995849/index.html"
},
{
"type": "WEB",
"url": "http://fx.dmm.com/information/press/2016/2016053001"
},
{
"type": "WEB",
"url": "http://jvn.jp/en/jp/JVN40898764/index.html"
},
{
"type": "WEB",
"url": "http://jvndb.jvn.jp/en/contents/2016/JVNDB-2016-000092.html"
},
{
"type": "WEB",
"url": "http://www.gaitamejapan.com/support/news/2016/2016053001"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N",
"type": "CVSS_V3"
}
]
}
Mitigation
Certificates should be carefully managed and checked to assure that data are encrypted with the intended owner's public key.
Mitigation
If certificate pinning is being used, ensure that all relevant properties of the certificate are fully validated before the certificate is pinned, including the hostname.
CAPEC-459: Creating a Rogue Certification Authority Certificate
An adversary exploits a weakness resulting from using a hashing algorithm with weak collision resistance to generate certificate signing requests (CSR) that contain collision blocks in their "to be signed" parts. The adversary submits one CSR to be signed by a trusted certificate authority then uses the signed blob to make a second certificate appear signed by said certificate authority. Due to the hash collision, both certificates, though different, hash to the same value and so the signed blob works just as well in the second certificate. The net effect is that the adversary's second X.509 certificate, which the Certification Authority has never seen, is now signed and validated by that Certification Authority.
CAPEC-475: Signature Spoofing by Improper Validation
An adversary exploits a cryptographic weakness in the signature verification algorithm implementation to generate a valid signature without knowing the key.