Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.

Fix detecting GitHub Enterprise Server behind a HAProxy - #2562

Merged
jcansdale merged 9 commits into
masterfrom
fixes/2560-IsGitHubApiException
Mar 18, 2021
Merged

Fix detecting GitHub Enterprise Server behind a HAProxy#2562
jcansdale merged 9 commits into
masterfrom
fixes/2560-IsGitHubApiException

Conversation

@jcansdale

@jcansdale jcansdale commented Oct 26, 2020

Copy link
Copy Markdown
Collaborator

The X-GitHub-Request-Id header is used to check whether an error is returned from a GitHub or GitHub Enterprise server instance. If the server is behind a HAProxy, the header will be converted to lower case. We were only checking for a case sensitive X-GitHub-Request-Id header and not detecting GHES instances behind a HAProxy proxy.

What this PR does

  • Check any casing of the X-GitHub-Request-Id header

Credits

This bug was discovered and documented by @osmanager in #2560. Thankyou!

Related

Fixes #2560

@jcansdale jcansdale changed the title Fix detecting GitHub API Exception Fix detecting GitHub Enterprise Server behind a HAProxy Oct 26, 2020
@jcansdale
jcansdale merged commit bccca13 into master Mar 18, 2021
@jcansdale
jcansdale deleted the fixes/2560-IsGitHubApiException branch March 18, 2021 14:49
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Report Solution for GHE Connecting Bug

1 participant