Bug 1787105 - Change hammer auth login oauth option to oidc
Summary: Change hammer auth login oauth option to oidc
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Hammer
Version: 6.7.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: 6.7.0
Assignee: Rahul Bajaj
QA Contact: Nikhil Kathole
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-12-31 06:49 UTC by Nikhil Kathole
Modified: 2020-04-14 15:54 UTC (History)
6 users (show)

Fixed In Version: tfm-rubygem-hammer_cli_foreman-0.19.6-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-04-14 15:54:09 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 28628 0 Normal Closed Add additional information to make oauth options description specific 2021-01-15 00:50:10 UTC
Red Hat Product Errata RHBA-2020:1455 0 None None None 2020-04-14 15:54:21 UTC

Description Nikhil Kathole 2019-12-31 06:49:25 UTC
Description of problem:

As all of the option under hammer auth login oauth are related to oidc and protocol we are using for authentication is openidc, it is calid to change from oauth to oidc.


Version-Release number of selected component (if applicable):
Satellite 6.7 snap 7
tfm-rubygem-hammer_cli-0.19.0-2.el7sat.noarch

How reproducible:
always

Steps to Reproduce:
1. # hammer auth login oauth -h
Usage:
    hammer auth login oauth [OPTIONS]

Options:
 -a, --oidc-authorization-endpoint OPENIDC-AUTHORIZATION-ENDPOINT Openidc provider URL which issues authentication code
 -c, --oidc-client-id OPENIDC-CLIENT-ID                           Client id used in the Openidc provider
 -f, --two-factor                                                 Authenticate with two factor
 -h, --help                                                       Print help
 -p, --password PASSWORD                                          Password to access the remote system
 -r, --oidc-redirect-uri OPENIDC-REDIRECT-URI                     Redirect URI for the authencation code grant flow
 -t, --oidc-token-endpoint OPENIDC-TOKEN-ENDPOINT                 Openidc provider URL which issues access token
 -u, --username USERNAME                                          Username to access the remote system

Actual results:

Command is hammer auth login oauth 


Expected results:
Command should be hammer auth login oidc

Additional info:

Also there is typo, good to have it fixed

-r, --oidc-redirect-uri OPENIDC-REDIRECT-URI                     Redirect URI for the authencation code grant flow 

s/authencation/authentication

Comment 3 Nikhil Kathole 2019-12-31 08:53:48 UTC
Also please update help description for 

-a, --oidc-authorization-endpoint OPENIDC-AUTHORIZATION-ENDPOINT Openidc provider URL which issues authentication code

to 

-a, --oidc-authorization-endpoint OPENIDC-AUTHORIZATION-ENDPOINT Openidc provider URL which issues authentication code (two factor only)

Comment 4 Rahul Bajaj 2020-01-03 10:49:12 UTC
Hello Nikhil,

Thank you for observing the typo's in there and reporting that.

The main issue about remaining the `oauth` to `oidc` is in my opinion not a good idea. 
Reasoning: OpenID Connect(OIDC) uses simple JSON Web Tokens (JWT), which we obtain using flows(password grant and code flow) conforming to the OAuth 2.0 specifications.
So OAuth is responsible for getting us the token with the help of OIDC. SO options specify the OpenID provider and its features while we are actually using OAuth to perform
the required task.

Let me know if you are not convinced with the above explanation :) 

Thank you,

Comment 5 Bryan Kearney 2020-01-07 11:08:36 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/28628 has been resolved.

Comment 6 Nikhil Kathole 2020-01-15 16:58:12 UTC
VERIFIED

Version tested:
Satellite 6.7 snap 8

# hammer auth login oauth -h
Usage:
    hammer auth login oauth [OPTIONS]

Options:
 -a, --oidc-authorization-endpoint OPENIDC-AUTHORIZATION-ENDPOINT Openidc provider URL which issues authentication code (two factor only)
 -c, --oidc-client-id OPENIDC-CLIENT-ID                           Client id used in the Openidc provider
 -f, --two-factor                                                 Authenticate with two factor
 -h, --help                                                       Print help
 -p, --password PASSWORD                                          Password to access the remote system
 -r, --oidc-redirect-uri OPENIDC-REDIRECT-URI                     Redirect URI for the authentication code grant flow
 -t, --oidc-token-endpoint OPENIDC-TOKEN-ENDPOINT                 Openidc provider URL which issues access token
 -u, --username USERNAME                                          Username to access the remote system

Comment 9 errata-xmlrpc 2020-04-14 15:54:09 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:1455


Note You need to log in before you can comment on or make changes to this bug.