Skip to content

App JWT returned in error responses < v2.0.0

Moderate
bradleyfalzon published GHSA-h4q8-96p6-jcgr Dec 19, 2022

Package

gomod ghinstallation (Go)

Affected versions

< 2.0.0

Patched versions

2.0.0

Description

Impact

In ghinstallation v1, when the request to refresh an installation token failed, the HTTP request and response would be returned for debugging.

ghinstallation/transport.go

Lines 172 to 174 in 24e56b3

if resp.StatusCode/100 != 2 {
return fmt.Errorf("request %+v received non 2xx response status %q with body %+v and TLS %+v", resp.Request, resp.Body, resp.Request, resp.TLS)
}

The request contained the bearer JWT for the App, and was returned back to clients. This token is short lived (10 minute maximum).

Patches

  • This has already been patched in d24f14f, and is available in releases >= v2.0.0.

References

Are there any links users can visit to find out more?

For more information

If you have any questions or comments about this advisory:

Severity

Moderate
5.0
/ 10

CVSS base metrics

Attack vector
Local
Attack complexity
High
Privileges required
Low
User interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
None
Availability
Low
CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:N/A:L

CVE ID

CVE-2022-39304

Weaknesses

Credits