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

[BUG] remove admin role by email address not working in CLI #645

Open
RufusJWB opened this issue Aug 8, 2024 · 0 comments
Open

[BUG] remove admin role by email address not working in CLI #645

RufusJWB opened this issue Aug 8, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@RufusJWB
Copy link
Contributor

RufusJWB commented Aug 8, 2024

Describe the Bug

Removing of an admin role by WITH_DNEMAILADDRESS not working in the CLI.

To Reproduce

sh-5.1$ bin/ejbca.sh roles listroles           
2024-08-08 21:09:31,051+0000 INFO  [org.ejbca.ui.cli.roles.ListRolesCommand] (main) 'Super Administrator Role'  (3 members)
sh-5.1$ bin/ejbca.sh roles listadmins --role 'Super Administrator Role'
2024-08-08 21:10:06,226+0000 INFO  [org.ejbca.ui.cli.roles.ListAdminsCommand] (main) 'ManagementCA' WITH_COMMONNAME TYPE_EQUALCASE "SuperAdmin" ""
2024-08-08 21:10:06,241+0000 INFO  [org.ejbca.ui.cli.roles.ListAdminsCommand] (main) 'EE Auth 2021' WITH_DNEMAILADDRESS TYPE_EQUALCASEINS "[email protected]" ""
2024-08-08 21:10:06,242+0000 INFO  [org.ejbca.ui.cli.roles.ListAdminsCommand] (main) [Admin not bound to CA or provider] USERNAME TYPE_EQUALCASE "ejbca" ""
sh-5.1$ bin/ejbca.sh roles removeadmin --role 'Super Administrator Role' --caname 'EE Auth 2021' --with 'WITH_DNEMAILADDRESS' --value '[email protected]'
2024-08-08 21:11:15,102+0000 INFO  [org.ejbca.ui.cli.roles.RemoveAdminCommand] (main) Match TokenType is assumed to be 'CertificateAuthenticationToken'.
2024-08-08 21:11:15,241+0000 INFO  [org.ejbca.ui.cli.roles.RemoveAdminCommand] (main) Using 'TYPE_EQUALCASE' implied by 'WITH_DNEMAILADDRESS'.
2024-08-08 21:11:15,260+0000 INFO  [org.ejbca.ui.cli.roles.RemoveAdminCommand] (main) Could not find any matching admin in role 'Super Administrator Role'.
sh-5.1$ 

Expected Behavior

The correct match type should be implied.

sh-5.1$ bin/ejbca.sh roles removeadmin --role 'Super Administrator Role' --caname 'EE Auth 2021' --with 'WITH_DNEMAILADDRESS' --value '[email protected]' --type 'TYPE_EQUALCASEINS'
2024-08-08 21:16:19,614+0000 INFO  [org.ejbca.ui.cli.roles.RemoveAdminCommand] (main) Match TokenType is assumed to be 'CertificateAuthenticationToken'.
2024-08-08 21:16:19,851+0000 INFO  [org.ejbca.ui.cli.roles.RemoveAdminCommand] (main) Removed role member: 'EE Auth 2021' WITH_DNEMAILADDRESS TYPE_EQUALCASEINS '[email protected]' from role 'Super Administrator Role'
sh-5.1$ 

Screenshots and Logs

see above

Product Deployment

Please complete the following information:

  • Deployment format: container
  • Version 8.3.2

Desktop

n/a

Additional Context

n/a

@RufusJWB RufusJWB added the bug Something isn't working label Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant