-
Notifications
You must be signed in to change notification settings - Fork 595
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
Support OAuth2 authentication #1346
Conversation
0059af6
to
ece4e10
Compare
30afc8f
to
9baf8fc
Compare
@jonproch117 - I'm working on reviewing this PR now. I should be able to get it released by the end of August. Sorry about the confusion! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for all of your excellent work, @MarcialRosales
I am going to move IOAuth2Client
and related classes to their own project (and thus dll
that is published to NuGet). The reason being that only a fraction of the users of the .NET client will need the OAuth2 code, and most will not want to have the extra dependencies on System.Net.Http.Json
and System.Text.Json
.
I'll start work on that tomorrow!
Excellent @lukebakken ! Good call on splitting that dependency. We just need to make it clear in the documentation to include this extra DLL when using OAuth2 authentication/authorization. Shall I create that doc's PR or will you do it? |
Go right ahead. I think it should be pretty clear to end-users but best to make it as obvious as possible. |
3cb1f0a
to
2df1e82
Compare
Change test assertion Restore original test The new test did work in Unix but failed on Windows Fix whitespace, remove use of #nullable, do not remove UserName / Password from connection factory Do not make unnecessary API changes Add tls-gen as a submodule, start getting bash scripts to pass shellcheck Bash script refactoring Use full docker options Clean up OAuth2 test Program Remove unused code in start-rabbitmq.sh Start to move OAuth2 code to its own project Finish moving OAuth2 code to its own project Remove OAuth2 from APIApproval Add OAuth2 API approval test and move verified output into each directory Version the RabbitMQ.Client.OAuth2 project independently of the RabbitMQ.Client project Fix lack of whitespaces, use TimeSpan to represent a duration rather than a long. Fix APIApproval Fix project refs, use forward slashes
2df1e82
to
5914434
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MarcialRosales before merging, would you please review my changes? If you would run through your test scenarios in your env one more time I would appreciate it as well. Thanks!
@jonproch117 - if you'd like to test this out, please see the following beta releases:
I'm working on documentation at this time. You can see an example of how to use the new library via our test code here: https://github.com/rabbitmq/rabbitmq-dotnet-client/tree/6.x/projects/TestApplications/OAuth2 |
@lukebakken This is working for me. Thanks! |
Follow-up to: * #956 * #1346 UAA service, RabbitMQ mounts for UAA Source code checkout happens _after_ service containers are started Use conventional-actions/docker-run@v1 Start adding test project for OAuth2 Converting OAuth2 test program to Xunit Run OAuth2 tests using `dotnet test` Refactor test to use async/await when available Remove TestApplications/OAuth2 Simplify APIApproval a bit
Follow-up to: * #956 * #1346 UAA service, RabbitMQ mounts for UAA Source code checkout happens _after_ service containers are started Use conventional-actions/docker-run@v1 Start adding test project for OAuth2 Converting OAuth2 test program to Xunit Run OAuth2 tests using `dotnet test` Refactor test to use async/await when available Remove TestApplications/OAuth2 Simplify APIApproval a bit
Follow-up to: * #956 * #1346 UAA service, RabbitMQ mounts for UAA Source code checkout happens _after_ service containers are started Use conventional-actions/docker-run@v1 Start adding test project for OAuth2 Converting OAuth2 test program to Xunit Run OAuth2 tests using `dotnet test` Refactor test to use async/await when available Remove TestApplications/OAuth2 Simplify APIApproval a bit Ensure main workflow does NOT run OAuth2 tests
Follow-up to: * #956 * #1346 UAA service, RabbitMQ mounts for UAA Source code checkout happens _after_ service containers are started Use conventional-actions/docker-run@v1 Start adding test project for OAuth2 Converting OAuth2 test program to Xunit Run OAuth2 tests using `dotnet test` Refactor test to use async/await when available Remove TestApplications/OAuth2 Simplify APIApproval a bit
Follow-up to: * #956 * #1346 UAA service, RabbitMQ mounts for UAA Source code checkout happens _after_ service containers are started Use conventional-actions/docker-run@v1 Start adding test project for OAuth2 Converting OAuth2 test program to Xunit Run OAuth2 tests using `dotnet test` Refactor test to use async/await when available Remove TestApplications/OAuth2 Simplify APIApproval a bit
@jonproch117 thank you! I will release version 6.6.0 today. |
Fixes #956
Proposed Changes
Enable the following mechanisms via two attributes added to the ConnectionFactory:
This PR is accompanied by another PR on the rabbitmq-website to update the .Net Client guide.
Acceptance Tests
Via TestApplications/OAuth2, it is possible to test end-to-end the following flows:
scope
.To do:
Types of Changes
What types of changes does your code introduce to this project?
Put an
x
in the boxes that applyThis PR is accompanied by another docs' PR