{"id":"CVE-2022-0871","aliases":["CVE-2022-0871","GHSA-gw5h-h6hj-f56g","GO-2022-0369"],"related":[],"kind":"vulnerability","state":"published","title":"Missing Authorization in gogs/gogs","summary":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Missing Authorization in GitHub repository gogs/gogs prior to 0.12.5.","source":"cvelist"},{"lang":"en","text":"### 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 <username>` 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.","format":"markdown","source":"ghsa"},{"lang":"en","text":"Gogs vulnerable to improper PAM authorization handling in gogs.io/gogs","format":"markdown","source":"go"},{"lang":"es","text":"Una Autorización Inapropiada en el repositorio de GitHub gogs/gogs versiones anteriores a 0.12.5","source":"nvd"}],"published":"2022-03-11T00:00:00.000Z","modified":"2026-06-17T04:21:24.367Z","severity":{"scorer":"@huntrdev","scheme":"CVSS:3.0","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","score":8.2,"rating":"HIGH"},"severities":[{"scorer":"@huntrdev","scheme":"CVSS:3.0","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","score":8.2,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.0","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N","score":8.2,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","score":9.1,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:M/Au:N/C:P/I:P/A:N","score":5.8,"rating":"MEDIUM"}],"cwes":["CWE-862"],"affected":[{"ranges":[{"type":"custom","introduced":"unspecified","fixed":"0.12.5","status":"affected"}],"vendor":"gogs","product":"gogs/gogs","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.12.5"}],"ecosystem":"Go","package":"gogs.io/gogs","purl":"pkg:golang/gogs.io/gogs","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.12.5"}],"ecosystem":"Go","package":"gogs.io/gogs","purl":"pkg:golang/gogs.io/gogs","source":"go"},{"ranges":[{"status":"affected","fixed":"0.12.5"}],"vendor":"gogs","product":"gogs","cpe":"cpe:2.3:a:gogs:gogs:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://huntr.dev/bounties/ea82cfc9-b55c-41fe-ae58-0d0e0bd7ab62","tags":["exploit","issue-tracking","patch","third-party-advisory","web","x-transferred"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/gogs/gogs/commit/64102be2c90e1b47dbdd379873ba76c80d4b0e78","tags":["patch","third-party-advisory","web","x-transferred"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/gogs/gogs/security/advisories/GHSA-gw5h-h6hj-f56g","tags":["advisory","web"],"sources":["ghsa","go"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-0871","tags":["advisory"],"sources":["ghsa","go"]},{"url":"https://github.com/gogs/gogs/issues/6810","tags":["web"],"sources":["ghsa","go"]},{"url":"https://github.com/gogs/gogs","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"@huntrdev","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-0871","url":"https://www.cve.org/CVERecord?id=CVE-2022-0871","licence":"CVE Terms of Use","modified":"2024-08-02T23:40:04.494Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-gw5h-h6hj-f56g","url":"https://github.com/advisories/GHSA-gw5h-h6hj-f56g","licence":"CC-BY-4.0","modified":"2024-08-21T14:56:55.682Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2022-0369","url":"https://pkg.go.dev/vuln/GO-2022-0369","licence":"CC-BY-4.0","modified":"2026-03-03T04:50:10.806Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-0871","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-0871","licence":"Public domain","modified":"2026-06-17T04:21:24.367Z"}],"updatedAt":"2026-11-25T22:58:10.045Z","epss":{"score":0.0124,"percentile":0.6999,"date":"2026-12-01T12:00:22.000Z"}}