{"id":"CVE-2022-0871","aliases":["ALPINE-CVE-2022-0871","EUVD-2022-1432","GHSA-gw5h-h6hj-f56g","GO-2022-0369"],"status":"published","title":"Missing Authorization in gogs/gogs","description":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","severity":{"version":"3.0","score":8.2,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-08","score":0.0124,"percentile":0.69347,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-862"],"published":"2022-03-11T00:00:00Z","modified":"2026-11-03T07:31:04Z","fixes":[{"ecosystem":"Go","package":"gogs.io/gogs","fixed_in":["0.12.5"],"sources":["ghsa","osv"]},{"ecosystem":"Alpine:v3.15","package":"gogs","fixed_in":["0.12.6-r0"],"sources":["osv"]},{"ecosystem":"Alpine:v3.16","package":"gogs","fixed_in":["0.12.6-r0"],"sources":["osv"]},{"ecosystem":"Alpine:v3.17","package":"gogs","fixed_in":["0.12.6-r0"],"sources":["osv"]},{"ecosystem":"Alpine:v3.18","package":"gogs","fixed_in":["0.12.6-r0"],"sources":["osv"]},{"ecosystem":"Alpine:v3.19","package":"gogs","fixed_in":["0.12.6-r0"],"sources":["osv"]},{"ecosystem":"Alpine:v3.20","package":"gogs","fixed_in":["0.12.6-r0"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"Go","package":"gogs.io/gogs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.12.5"}]}]},{"source":"osv","ecosystem":"Alpine:v3.15","package":"gogs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.12.6-r0"}]}]},{"source":"osv","ecosystem":"Alpine:v3.16","package":"gogs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.12.6-r0"}]}]},{"source":"osv","ecosystem":"Alpine:v3.17","package":"gogs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.12.6-r0"}]}]},{"source":"osv","ecosystem":"Alpine:v3.18","package":"gogs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.12.6-r0"}]}]},{"source":"osv","ecosystem":"Alpine:v3.19","package":"gogs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.12.6-r0"}]}]},{"source":"osv","ecosystem":"Alpine:v3.20","package":"gogs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.12.6-r0"}]}]},{"source":"osv","ecosystem":"Go","package":"gogs.io/gogs","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"0.12.5"}]}]},{"source":"osv","ecosystem":"Go","package":"gogs.io/gogs","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"0.12.5"}]}]}],"products":[{"vendor":"gogs","product":"gogs"},{"vendor":"gogs","product":"gogs/gogs"}],"references":[{"url":"https://huntr.dev/bounties/ea82cfc9-b55c-41fe-ae58-0d0e0bd7ab62","tags":["x_transferred","Exploit","Issue Tracking","Patch","Third Party Advisory","web"]},{"url":"https://github.com/gogs/gogs/commit/64102be2c90e1b47dbdd379873ba76c80d4b0e78","tags":["x_transferred","Patch","Third Party Advisory","fix","web"]},{"url":"https://github.com/gogs/gogs/security/advisories/GHSA-gw5h-h6hj-f56g","tags":["web","advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-0871","tags":["advisory"]},{"url":"https://github.com/gogs/gogs/issues/6810","tags":["web"]},{"url":"https://github.com/advisories/GHSA-gw5h-h6hj-f56g"},{"url":"https://security.alpinelinux.org/vuln/CVE-2022-0871","tags":["advisory"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/0xxx/CVE-2022-0871.json","tags":["advisory"]},{"url":"https://github.com/gogs/gogs","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2022-0871","title":"Missing Authorization in gogs/gogs","description":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","status":"published","published":"2022-03-11T00:00:00Z","modified":"2024-08-02T23:40:04.494Z","cvss":[{"version":"3.0","score":8.2,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","level":"high","assessor":"cna"}],"cwes":["CWE-862"],"updated_at":"2026-11-02T14:34:41.34666Z"}],"euvd":[{"id":"EUVD-2022-1432","description":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","status":"published","published":"2022-03-11T00:00:00Z","modified":"2024-08-02T23:40:04Z","cvss":[{"version":"3.0","score":8.2,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","level":"high"}],"updated_at":"2026-11-03T03:26:03.912978Z"}],"ghsa":[{"id":"GHSA-gw5h-h6hj-f56g","title":"Gogs vulnerable to improper PAM authorization handling","description":"### Impact\n\nExpired PAM accounts and accounts with expired passwords are continued to be seen as valid. Installations use PAM as authentication sources are affected.\n\n### Patches\n\nExpired PAM accounts and accounts with expired passwords are no longer being seen as valid. Users should upgrade to 0.12.5 or the latest 0.13.0+dev.\n\n### Workarounds\n\nIn addition to marking PAM accounts as expired, also disable/lock them. Running `usermod -L \u003cusername\u003e` will add an exclamation mark to the password hash and would result in wrong passwords responses when trying to login. \n\n### References\n\nhttps://huntr.dev/bounties/ea82cfc9-b55c-41fe-ae58-0d0e0bd7ab62/\n\n### For more information\n\nIf you have any questions or comments about this advisory, please post on https://github.com/gogs/gogs/issues/6810.\n","status":"published","published":"2022-03-14T22:58:37Z","modified":"2023-06-30T22:11:07Z","cvss":[{"version":"3.0","score":8.2,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","level":"high"}],"cwes":["CWE-862"],"updated_at":"2026-11-02T14:36:55.91458Z"}],"nvd":[{"id":"CVE-2022-0871","description":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","status":"published","published":"2022-03-11T12:15:07.667Z","modified":"2026-06-17T04:21:24.367Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical","assessor":"primary"},{"version":"3.0","score":8.2,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","level":"high","assessor":"secondary"},{"version":"2.0","score":5.8,"vector":"AV:N/AC:M/Au:N/C:P/I:P/A:N","level":"medium","assessor":"primary"}],"cwes":["CWE-862"],"updated_at":"2026-11-02T14:07:13.7085Z"}],"osv":[{"id":"ALPINE-CVE-2022-0871","description":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","status":"published","published":"2022-03-11T12:15:07.667Z","modified":"2026-11-03T07:31:04.054910534Z","cvss":[{"version":"3.1","score":9.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","level":"critical"}],"updated_at":"2026-11-03T07:50:01.054176Z"},{"id":"CVE-2022-0871","title":"Missing Authorization in gogs/gogs","description":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","status":"published","published":"2022-03-11T00:00:00Z","modified":"2026-10-28T02:30:40.25750479Z","cvss":[{"version":"3.0","score":8.2,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","level":"high"}],"cwes":["CWE-862"],"updated_at":"2026-11-02T15:44:23.245966Z"},{"id":"GHSA-gw5h-h6hj-f56g","title":"Gogs vulnerable to improper PAM authorization handling","description":"### Impact\n\nExpired PAM accounts and accounts with expired passwords are continued to be seen as valid. Installations use PAM as authentication sources are affected.\n\n### Patches\n\nExpired PAM accounts and accounts with expired passwords are no longer being seen as valid. Users should upgrade to 0.12.5 or the latest 0.13.0+dev.\n\n### Workarounds\n\nIn addition to marking PAM accounts as expired, also disable/lock them. Running `usermod -L \u003cusername\u003e` will add an exclamation mark to the password hash and would result in wrong passwords responses when trying to login. \n\n### References\n\nhttps://huntr.dev/bounties/ea82cfc9-b55c-41fe-ae58-0d0e0bd7ab62/\n\n### For more information\n\nIf you have any questions or comments about this advisory, please post on https://github.com/gogs/gogs/issues/6810.\n","status":"published","published":"2022-03-14T22:58:37Z","modified":"2024-08-21T14:56:55.682477Z","cvss":[{"version":"3.0","score":8.2,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","level":"high"}],"cwes":["CWE-862"],"updated_at":"2026-11-02T15:46:48.191583Z"},{"id":"GO-2022-0369","title":"Gogs vulnerable to improper PAM authorization handling in gogs.io/gogs","description":"Gogs vulnerable to improper PAM authorization handling in gogs.io/gogs","status":"published","published":"2024-08-21T14:30:31Z","modified":"2026-03-03T04:50:10.80603Z","updated_at":"2026-11-02T15:47:00.604718Z"}]}}
