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

feat: Add HMAC-SHA256 signature method for OAuth 1.0 #711

Merged
merged 5 commits into from Aug 11, 2021
Merged

feat: Add HMAC-SHA256 signature method for OAuth 1.0 #711

merged 5 commits into from Aug 11, 2021

Conversation

svonduhn
Copy link
Contributor

@svonduhn svonduhn commented Aug 5, 2021

I have added OAuthHmacSha256Signer to enable using the signature method HMAC-SHA256.

Unit test/code coverage has been added in OAuthHmacSha256SignerTest.

This change is necessary for establishing connections to NetSuite as they will no longer accept HMAC-SHA1 as a signature method.

Fixes #702

This replaces pull request #703, which should be closed in favor of this one. The code is the same (two of the four files modified in the original PR were reverted back to their original versions), so there are only two new files, one class and a test class.

@svonduhn svonduhn requested a review from a team as a code owner August 5, 2021 14:42
@google-cla google-cla bot added the cla: yes This human has signed the Contributor License Agreement. label Aug 5, 2021
@TimurSadykov
Copy link
Member

@svonduhn you can run "mvn com.coveo:fmt-maven-plugin:format" to fix linter issues

@svonduhn
Copy link
Contributor Author

svonduhn commented Aug 6, 2021

@TimurSadykov thank you for that command. Those issues should now be fixed as well.

@TimurSadykov
Copy link
Member

@svonduhn There is still a linter error, but seems like unrelated to your change, i'm looking into it..

@TimurSadykov TimurSadykov self-assigned this Aug 10, 2021
@TimurSadykov
Copy link
Member

@svonduhn linter is fixed, you can merge if you are ready
We will release shortly after

@svonduhn
Copy link
Contributor Author

svonduhn commented Aug 11, 2021

@TimurSadykov I merged the fix commit into the pull request.

@TimurSadykov TimurSadykov merged commit c070f5f into googleapis:master Aug 11, 2021
@svonduhn svonduhn deleted the HmacSHA256 branch August 11, 2021 22:44
@TimurSadykov
Copy link
Member

@svonduhn thanks for contributing!

gcf-merge-on-green bot pushed a commit that referenced this pull request Aug 11, 2021
🤖 I have created a release \*beep\* \*boop\*
---
## [1.32.0](https://www.github.com/googleapis/google-oauth-java-client/compare/v1.31.5...v1.32.0) (2021-08-11)


### Features

* add `gcf-owl-bot[bot]` to `ignoreAuthors` ([#690](https://www.github.com/googleapis/google-oauth-java-client/issues/690)) ([2786401](https://www.github.com/googleapis/google-oauth-java-client/commit/27864015793eab524c83ba4fc345a1afc27d7a95))
* Add HMAC-SHA256 signature method for OAuth 1.0 ([#711](https://www.github.com/googleapis/google-oauth-java-client/issues/711)) ([c070f5f](https://www.github.com/googleapis/google-oauth-java-client/commit/c070f5f27d8034f681b7fc9a43825cfc7fd6f06f))


### Bug Fixes

* release scripts from issuing overlapping phases ([#664](https://www.github.com/googleapis/google-oauth-java-client/issues/664)) ([60fec2b](https://www.github.com/googleapis/google-oauth-java-client/commit/60fec2b9bbd5d632dff155a45a2ed0fa2f261c45))
* Revert "chore(deps): update dependency com.google.googlejavaformat:google-java-format to v1.10.0" to fix linter ([#713](https://www.github.com/googleapis/google-oauth-java-client/issues/713)) ([bbc9ea2](https://www.github.com/googleapis/google-oauth-java-client/commit/bbc9ea2865f30a12402869e427bc6ae3ebffc588))
* Update dependencies.sh to not break on mac ([#706](https://www.github.com/googleapis/google-oauth-java-client/issues/706)) ([39c2777](https://www.github.com/googleapis/google-oauth-java-client/commit/39c2777543ca46dc2e4c12bd5469e829c9a85c37))
---


This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
gcf-merge-on-green bot pushed a commit that referenced this pull request Aug 12, 2021
🤖 I have created a release \*beep\* \*boop\*
---
### [1.32.1](https://www.github.com/googleapis/google-oauth-java-client/compare/v1.32.0...v1.32.1) (2021-08-12)


### Features

* add `gcf-owl-bot[bot]` to `ignoreAuthors` ([#690](https://www.github.com/googleapis/google-oauth-java-client/issues/690)) ([2786401](https://www.github.com/googleapis/google-oauth-java-client/commit/27864015793eab524c83ba4fc345a1afc27d7a95))
* Add HMAC-SHA256 signature method for OAuth 1.0 ([#711](https://www.github.com/googleapis/google-oauth-java-client/issues/711)) ([c070f5f](https://www.github.com/googleapis/google-oauth-java-client/commit/c070f5f27d8034f681b7fc9a43825cfc7fd6f06f))


### Bug Fixes

* release scripts from issuing overlapping phases ([#664](https://www.github.com/googleapis/google-oauth-java-client/issues/664)) ([60fec2b](https://www.github.com/googleapis/google-oauth-java-client/commit/60fec2b9bbd5d632dff155a45a2ed0fa2f261c45))
* Revert "chore(deps): update dependency com.google.googlejavaformat:google-java-format to v1.10.0" to fix linter ([#713](https://www.github.com/googleapis/google-oauth-java-client/issues/713)) ([bbc9ea2](https://www.github.com/googleapis/google-oauth-java-client/commit/bbc9ea2865f30a12402869e427bc6ae3ebffc588))
* Update dependencies.sh to not break on mac ([#706](https://www.github.com/googleapis/google-oauth-java-client/issues/706)) ([39c2777](https://www.github.com/googleapis/google-oauth-java-client/commit/39c2777543ca46dc2e4c12bd5469e829c9a85c37))


This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
gcf-merge-on-green bot pushed a commit that referenced this pull request Aug 23, 2021
🤖 I have created a release \*beep\* \*boop\*
---
### [1.32.2](https://www.github.com/googleapis/google-oauth-java-client/compare/v1.32.1...v1.32.2) (2021-08-23)


### Features

* add `gcf-owl-bot[bot]` to `ignoreAuthors` ([#690](https://www.github.com/googleapis/google-oauth-java-client/issues/690)) ([2786401](https://www.github.com/googleapis/google-oauth-java-client/commit/27864015793eab524c83ba4fc345a1afc27d7a95))
* Add HMAC-SHA256 signature method for OAuth 1.0 ([#711](https://www.github.com/googleapis/google-oauth-java-client/issues/711)) ([c070f5f](https://www.github.com/googleapis/google-oauth-java-client/commit/c070f5f27d8034f681b7fc9a43825cfc7fd6f06f))


### Bug Fixes

* release scripts from issuing overlapping phases ([#664](https://www.github.com/googleapis/google-oauth-java-client/issues/664)) ([60fec2b](https://www.github.com/googleapis/google-oauth-java-client/commit/60fec2b9bbd5d632dff155a45a2ed0fa2f261c45))
* Revert "chore(deps): update dependency com.google.googlejavaformat:google-java-format to v1.10.0" to fix linter ([#713](https://www.github.com/googleapis/google-oauth-java-client/issues/713)) ([bbc9ea2](https://www.github.com/googleapis/google-oauth-java-client/commit/bbc9ea2865f30a12402869e427bc6ae3ebffc588))
* Update dependencies.sh to not break on mac ([#706](https://www.github.com/googleapis/google-oauth-java-client/issues/706)) ([39c2777](https://www.github.com/googleapis/google-oauth-java-client/commit/39c2777543ca46dc2e4c12bd5469e829c9a85c37))
---


This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
gcf-merge-on-green bot pushed a commit that referenced this pull request Aug 23, 2021
🤖 I have created a release \*beep\* \*boop\*
---
## [1.33.0](https://www.github.com/googleapis/google-oauth-java-client/compare/v1.32.2...v1.33.0) (2021-08-23)


### Features

* add `gcf-owl-bot[bot]` to `ignoreAuthors` ([#690](https://www.github.com/googleapis/google-oauth-java-client/issues/690)) ([2786401](https://www.github.com/googleapis/google-oauth-java-client/commit/27864015793eab524c83ba4fc345a1afc27d7a95))
* Add HMAC-SHA256 signature method for OAuth 1.0 ([#711](https://www.github.com/googleapis/google-oauth-java-client/issues/711)) ([c070f5f](https://www.github.com/googleapis/google-oauth-java-client/commit/c070f5f27d8034f681b7fc9a43825cfc7fd6f06f))


### Bug Fixes

* release scripts from issuing overlapping phases ([#664](https://www.github.com/googleapis/google-oauth-java-client/issues/664)) ([60fec2b](https://www.github.com/googleapis/google-oauth-java-client/commit/60fec2b9bbd5d632dff155a45a2ed0fa2f261c45))
* Revert "chore(deps): update dependency com.google.googlejavaformat:google-java-format to v1.10.0" to fix linter ([#713](https://www.github.com/googleapis/google-oauth-java-client/issues/713)) ([bbc9ea2](https://www.github.com/googleapis/google-oauth-java-client/commit/bbc9ea2865f30a12402869e427bc6ae3ebffc588))
* Update dependencies.sh to not break on mac ([#706](https://www.github.com/googleapis/google-oauth-java-client/issues/706)) ([39c2777](https://www.github.com/googleapis/google-oauth-java-client/commit/39c2777543ca46dc2e4c12bd5469e829c9a85c37))
---


This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

OAuthHmacSigner only supports HMAC-SHA1 (no ability to use HMAC-SHA256 which is required by NetSuite)
3 participants