Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LP-2039105: do not duplicate the oauth headers in case of retry #104

Merged
merged 1 commit into from
Oct 12, 2023

Conversation

r00ta
Copy link
Contributor

@r00ta r00ta commented Oct 11, 2023

Bugfix for https://bugs.launchpad.net/maas/+bug/2039105.

The bug is that in case of retry, the oauth headers are duplicated in the requests and MAAS nginx reject the request with 400. The fix is actually to use http.Header.Set instead of http.Header.Add in order to set or replace the "Authentication" header.

@jujubot
Copy link
Contributor

jujubot commented Oct 11, 2023

Thanks for opening a pull request! Please follow the instructions here to ensure your pull request is ready for review. Then, a maintainer will review your patch.

@hpidcock @anvial

1 similar comment
@jujubot
Copy link
Contributor

jujubot commented Oct 11, 2023

Thanks for opening a pull request! Please follow the instructions here to ensure your pull request is ready for review. Then, a maintainer will review your patch.

@hpidcock @anvial

@SimonRichardson
Copy link
Member

/merge

@jujubot jujubot merged commit 39eac57 into juju:v2 Oct 12, 2023
jujubot added a commit to juju/juju that referenced this pull request Oct 12, 2023
#16423

This PR aims to bump the gomaasapi package so to include juju/gomaasapi#104 

- [x] Code style: imports ordered, good names, simple structure, etc
- [x] Comments saying why design decisions were made
- [x] Go unit tests, with comments saying what you're testing
- [x] [Integration tests](https://github.com/juju/juju/tree/main/tests), with comments saying what you're testing
- [x] [doc.go](https://discourse.charmhub.io/t/readme-in-packages/451) added or updated in changed packages

## Links

**Launchpad bug:** [https://bugs.launchpad.net/maas/+bug/2039105](https://bugs.launchpad.net/maas/+bug/2039105)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants