CVE-2021-4236
CRITICAL 9.8CVSS 3.1Websocket requests did not call AuthenticateMethod
Web Sockets do not execute any AuthenticateMethod methods which may be set, leading to a nil pointer dereference if the returned UserData pointer is assumed to be non-nil, or authentication bypass. This issue only affects WebSockets with an AuthenticateMethod hook. Request handlers that do not explicitly use WebSockets are not vulnerable.
- Published
- 27 Dec 2022
- Last modified
- 17 Jun 2026
- Assigned by
- security@golang.org
- NVD status
- Modified
- Weakness
- CWE-304CWE-400CWE-476
- Also known as
- GHSA-5gjg-jgh4-gppmGHSA-jpgg-cp2x-qrw3GO-2021-0107
- Sources
- NVDJSONOSV GHSA-5gjg-jgh4-gppmJSONOSV GHSA-jpgg-cp2x-qrw3JSONOSV GO-2021-0107JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | CRITICAL 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| NVD | 134c704f-9b21-4f2e-91b3-4a467353bcc0 (Secondary) | CVSS 3.1 | CRITICAL 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| OSV | GitHub | CVSS 3.1 | CRITICAL 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | web_project | webcpe:2.3:a:web_project:web:*:*:*:*:*:go:*:* |
>= 1.4.0, < 1.5.2 | 1.5.2 |
| OSV | Go | github.com/ecnepsnai/web | >= 1.4.0, < 1.5.2 | 1.5.2 |
References
- https://github.com/ecnepsnai/web/commit/5a78f8d5c41ce60dcf9f61aaf47a7a8dc3e0002f · Patch, Third Party Advisory, WEB, FIX
- https://pkg.go.dev/vuln/GO-2021-0107 · Exploit, Patch, Third Party Advisory, WEB
- https://github.com/ecnepsnai/web/security/advisories/GHSA-5gjg-jgh4-gppm · WEB
- https://nvd.nist.gov/vuln/detail/CVE-2021-4236 · ADVISORY
- https://github.com/ecnepsnai/web · PACKAGE
History
- 25 Nov 2026 20:35 UTC · NVD: first stored (published 27 Dec 2022)
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 28 Jul 2021)
- 25 Nov 2026 20:13 UTC · OSV: first stored (published 28 Dec 2022)
- 25 Nov 2026 20:13 UTC · OSV: first stored (published 23 Jun 2021)