Bug 1624328

Summary: [admin] RoleBinding tab for Roles don't show correct rolebindings
Product: OpenShift Container Platform Reporter: XiaochuanWang <xiaocwan>
Component: Management ConsoleAssignee: Samuel Padgett <spadgett>
Status: CLOSED ERRATA QA Contact: Yadan Pei <yapei>
Severity: low Docs Contact:
Priority: medium    
Version: 3.11.0CC: aos-bugs, jokerman, mmccomas
Target Milestone: ---   
Target Release: 4.5.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Previously the Role Bindings tab on the web console ClusterRole details page could show bindings for a namespaced Role with the same name. The tab now correctly shows only bindings for this ClusterRole.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-07-13 17:11:03 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
correct verification screenshot none

Description XiaochuanWang 2018-08-31 08:37:50 UTC
Description of problem:
Create Role and ClusterRole with same name. Create a Role binding for Role, and check the ClusterRole page -> Role Binding sub page. It also display the binding.

Version-Release number of selected component (if applicable):
registry.reg-aws.openshift.com:443/openshift3/ose-console                   v3.11               e174a3b28f9a 
oc v3.11.0-0.25.0
kubernetes v1.11.0+d4cacc0

How reproducible:
always

Steps to Reproduce:
1. Create namespaced Role and ClusterRole with same name.
$ oc get role -n yapei-2
NAME
example1
# oc get clusterrole | grep example
example1

2. Create a RoleBinding for namespaced Role
# oc get rolebinding -n yapei-2 
NAME                    ROLE                    USERS          GROUPS                           SERVICE ACCOUNTS   SUBJECTS                                                        
example1rb              yapei-2/example1        yapei1                                                             
# oc get clusterrolebinding | grep example
none returned

3. check the ClusterRole page -> Role Binding sub page.

Actual results:
3. ClusterRole also displays the binding.
Name            Role Ref     .....
RB:example1rb   R:example1    .....

Expected results:
3. ClusterRole should not display the binding.

Additional info:

Comment 4 XiaochuanWang 2020-05-06 07:52:43 UTC
Created attachment 1685583 [details]
correct verification screenshot

Comment 5 XiaochuanWang 2020-05-06 07:54:07 UTC
Thanks for the fix!
This is not reproduced now (refer to "correct verification screenshot")
Verified on 4.5.0-0.nightly-2020-05-06-003431

Comment 7 errata-xmlrpc 2020-07-13 17:11:03 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:2409