You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2022/09/07 07:56:41 UTC

[GitHub] [cloudstack] neogismm opened a new pull request, #6713: new commit squashing all commits from PR #6524

neogismm opened a new pull request, #6713:
URL: https://github.com/apache/cloudstack/pull/6713

   ### Description
   
   This PR is to add functionality for OAuth 2.0 authentication with Google as IDP.
   
   Progress:
   
   - [x] Obtain client id/secret from Google API console
   - [x] Create a Util class for the core methods
   - [x] Create a Servlet class that handles redirect URLs for a successful or failed auth flow
   - [x] Method to check if the user is already logged in
   - [ ] Check if the user is a new or existing user (implement checking methods with cloudstack database)
   - [x] Logout method
   - [ ] Make changes in UI
   
   NB: Progress milestones to be added/edited as I grow my understanding of the codebase.
    
   <!--- Describe your changes in DETAIL - And how has behavior functionally changed. -->
   
   <!-- For new features, provide link to FS, dev ML discussion etc. -->
   <!-- In case of bug fix, the expected and actual behaviours, steps to reproduce. -->
   
   <!-- When "Fixes: #<id>" is specified, the issue/PR will automatically be closed when this PR gets merged -->
   <!-- For addressing multiple issues/PRs, use multiple "Fixes: #<id>" -->
   <!-- Fixes: # -->
   
   <!--- ********************************************************************************* -->
   <!--- NOTE: AUTOMATATION USES THE DESCRIPTIONS TO SET LABELS AND PRODUCE DOCUMENTATION. -->
   <!--- PLEASE PUT AN 'X' in only **ONE** box -->
   <!--- ********************************************************************************* -->
   
   ### Types of changes
   
   - [ ] Breaking change (fix or feature that would cause existing functionality to change)
   - [x] New feature (non-breaking change which adds functionality)
   - [ ] Bug fix (non-breaking change which fixes an issue)
   - [ ] Enhancement (improves an existing feature and functionality)
   - [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
   
   ### Feature/Enhancement Scale or Bug Severity
   
   #### Feature/Enhancement Scale
   
   - [x] Major
   - [ ] Minor
   
   #### Bug Severity
   
   - [ ] BLOCKER
   - [ ] Critical
   - [ ] Major
   - [ ] Minor
   - [ ] Trivial
   
   
   ### Screenshots (if appropriate):
   
   
   ### How Has This Been Tested?
   <!-- Please describe in detail how you tested your changes. -->
   <!-- Include details of your testing environment, and the tests you ran to -->
   <!-- see how your change affects other areas of the code, etc. -->
   
   
   <!-- Please read the [CONTRIBUTING](https://github.com/apache/cloudstack/blob/main/CONTRIBUTING.md) document -->
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [GSOC] OAuth feature addition [cloudstack]

Posted by "DaanHoogland (via GitHub)" <gi...@apache.org>.
DaanHoogland commented on PR #6713:
URL: https://github.com/apache/cloudstack/pull/6713#issuecomment-1786773838

   @neogismm @harikrishna-patnala , can we close this?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [GSOC] OAuth feature addition [cloudstack]

Posted by "shwstppr (via GitHub)" <gi...@apache.org>.
shwstppr commented on PR #6713:
URL: https://github.com/apache/cloudstack/pull/6713#issuecomment-1744586442

   @neogismm cc @harikrishna-patnala is this still relevant with the new PR #7996 ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [GSOC] OAuth feature addition [cloudstack]

Posted by "DaanHoogland (via GitHub)" <gi...@apache.org>.
DaanHoogland closed pull request #6713: [GSOC] OAuth feature addition
URL: https://github.com/apache/cloudstack/pull/6713


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [cloudstack] codecov[bot] commented on pull request #6713: [GSOC] OAuth feature addition

Posted by GitBox <gi...@apache.org>.
codecov[bot] commented on PR #6713:
URL: https://github.com/apache/cloudstack/pull/6713#issuecomment-1239140380

   # [Codecov](https://codecov.io/gh/apache/cloudstack/pull/6713?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#6713](https://codecov.io/gh/apache/cloudstack/pull/6713?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (2f0087e) into [main](https://codecov.io/gh/apache/cloudstack/commit/687a21c116c241b319a7fdce0aba6ec36afeb66b?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (687a21c) will **decrease** coverage by `0.00%`.
   > The diff coverage is `0.00%`.
   
   ```diff
   @@             Coverage Diff              @@
   ##               main    #6713      +/-   ##
   ============================================
   - Coverage      5.90%    5.89%   -0.01%     
   + Complexity     3946     3945       -1     
   ============================================
     Files          2454     2464      +10     
     Lines        242749   242867     +118     
     Branches      37991    37999       +8     
   ============================================
   - Hits          14325    14323       -2     
   - Misses       226839   226960     +121     
   + Partials       1585     1584       -1     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/cloudstack/pull/6713?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...rg/apache/cloudstack/oauth2/OAuth2AuthManager.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvT0F1dGgyQXV0aE1hbmFnZXIuamF2YQ==) | `0.00% <0.00%> (ø)` | |
   | [...pache/cloudstack/oauth2/OAuth2AuthManagerImpl.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvT0F1dGgyQXV0aE1hbmFnZXJJbXBsLmphdmE=) | `0.00% <0.00%> (ø)` | |
   | [...che/cloudstack/oauth2/OAuth2UserAuthenticator.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvT0F1dGgyVXNlckF1dGhlbnRpY2F0b3IuamF2YQ==) | `0.00% <0.00%> (ø)` | |
   | [...java/org/apache/cloudstack/oauth2/OAuth2Utils.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvT0F1dGgyVXRpbHMuamF2YQ==) | `0.00% <0.00%> (ø)` | |
   | [...stack/oauth2/api/command/AuthorizeOauthSSOCmd.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvYXBpL2NvbW1hbmQvQXV0aG9yaXplT2F1dGhTU09DbWQuamF2YQ==) | `0.00% <0.00%> (ø)` | |
   | [...ack/oauth2/api/response/OauthProviderResponse.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvYXBpL3Jlc3BvbnNlL09hdXRoUHJvdmlkZXJSZXNwb25zZS5qYXZh) | `0.00% <0.00%> (ø)` | |
   | [...dstack/oauth2/googleAuth/LoginCallbackServlet.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvZ29vZ2xlQXV0aC9Mb2dpbkNhbGxiYWNrU2VydmxldC5qYXZh) | `0.00% <0.00%> (ø)` | |
   | [...che/cloudstack/oauth2/googleAuth/LoginServlet.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvZ29vZ2xlQXV0aC9Mb2dpblNlcnZsZXQuamF2YQ==) | `0.00% <0.00%> (ø)` | |
   | [...he/cloudstack/oauth2/googleAuth/LogoutServlet.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvZ29vZ2xlQXV0aC9Mb2dvdXRTZXJ2bGV0LmphdmE=) | `0.00% <0.00%> (ø)` | |
   | [...e/cloudstack/oauth2/googleAuth/ProfileServlet.java](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cGx1Z2lucy91c2VyLWF1dGhlbnRpY2F0b3JzL29hdXRoMi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvY2xvdWRzdGFjay9vYXV0aDIvZ29vZ2xlQXV0aC9Qcm9maWxlU2VydmxldC5qYXZh) | `0.00% <0.00%> (ø)` | |
   | ... and [1 more](https://codecov.io/gh/apache/cloudstack/pull/6713/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | |
   
   :mega: We’re building smart automated test selection to slash your CI/CD build times. [Learn more](https://about.codecov.io/iterative-testing/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [GSOC] OAuth feature addition [cloudstack]

Posted by "DaanHoogland (via GitHub)" <gi...@apache.org>.
DaanHoogland commented on PR #6713:
URL: https://github.com/apache/cloudstack/pull/6713#issuecomment-1787279086

   @neogismm @harikrishna-patnala I am closing this as #7996 is merged. Please reopen or create a new PR if anything else needs addressing.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [cloudstack] sonarcloud[bot] commented on pull request #6713: [GSOC] OAuth feature addition

Posted by GitBox <gi...@apache.org>.
sonarcloud[bot] commented on PR #6713:
URL: https://github.com/apache/cloudstack/pull/6713#issuecomment-1239106621

   SonarCloud Quality Gate failed.&nbsp; &nbsp; [![Quality Gate failed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/failed-16px.png 'Quality Gate failed')](https://sonarcloud.io/dashboard?id=apache_cloudstack&pullRequest=6713)
   
   [![Bug](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/common/bug-16px.png 'Bug')](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=BUG) [![A](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/RatingBadge/A-16px.png 'A')](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=BUG) [0 Bugs](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=BUG)  
   [![Vulnerability](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/common/vulnerability-16px.png 'Vulnerability')](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=VULNERABILITY) [![B](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/RatingBadge/B-16px.png 'B')](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=VULNERABILITY) [3 Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=VULNERABILITY)  
   [![Security Hotspot](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/common/security_hotspot-16px.png 'Security Hotspot')](https://sonarcloud.io/project/security_hotspots?id=apache_cloudstack&pullRequest=6713&resolved=false&types=SECURITY_HOTSPOT) [![A](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/RatingBadge/A-16px.png 'A')](https://sonarcloud.io/project/security_hotspots?id=apache_cloudstack&pullRequest=6713&resolved=false&types=SECURITY_HOTSPOT) [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_cloudstack&pullRequest=6713&resolved=false&types=SECURITY_HOTSPOT)  
   [![Code Smell](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/common/code_smell-16px.png 'Code Smell')](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=CODE_SMELL) [![A](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/RatingBadge/A-16px.png 'A')](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=CODE_SMELL) [23 Code Smells](https://sonarcloud.io/project/issues?id=apache_cloudstack&pullRequest=6713&resolved=false&types=CODE_SMELL)
   
   [![0.0%](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/CoverageChart/0-16px.png '0.0%')](https://sonarcloud.io/component_measures?id=apache_cloudstack&pullRequest=6713&metric=new_coverage&view=list) [0.0% Coverage](https://sonarcloud.io/component_measures?id=apache_cloudstack&pullRequest=6713&metric=new_coverage&view=list)  
   [![7.2%](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/Duplications/10-16px.png '7.2%')](https://sonarcloud.io/component_measures?id=apache_cloudstack&pullRequest=6713&metric=new_duplicated_lines_density&view=list) [7.2% Duplication](https://sonarcloud.io/component_measures?id=apache_cloudstack&pullRequest=6713&metric=new_duplicated_lines_density&view=list)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [GSOC] OAuth feature addition [cloudstack]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #6713:
URL: https://github.com/apache/cloudstack/pull/6713#issuecomment-1786769093

   This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org