Skip to content

Unable to delete accesskey with double quotes #5181

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

Closed
JadeVane opened this issue Apr 1, 2025 · 7 comments
Closed

Unable to delete accesskey with double quotes #5181

JadeVane opened this issue Apr 1, 2025 · 7 comments

Comments

@JadeVane
Copy link

JadeVane commented Apr 1, 2025

Expected behavior

Unable to delete accesskey with double quotes

Actual behavior

Be able to delete accesskey with double quotes

Steps to reproduce the behavior

  1. Add an accesskey with double quotes by the web console, for example, d8fe08"0sd"f08080fes
  2. Delete this accesskey in the web console, an error occurred:
The specified service account is not found
  1. Try to delete the accesskey using mc tool by ./mc admin user svcacct rm myminio 'd8fe08"0sd"f08080fes', encountered an error again:
mc: <ERROR> Unable to remove the specified service account. The specified service account is not found.

mc --version

  • (paste output of mc --version)
mc version RELEASE.2023-12-07T22-13-17Z (commit-id=1ba9435365a772d6b4cab225458306a70dfb2309)
Runtime: go1.21.5 linux/amd64
Copyright (c) 2015-2023 MinIO, Inc.
License GNU AGPLv3 <https://www.gnu.org/licenses/agpl-3.0.html>

System information

Linux version 6.1.0-31-amd64 ([email protected]) (gcc-12 (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40) #1 SMP PREEMPT_DYNAMIC Debian 6.1.128-1 (2025-02-07)

@taran-p
Copy link
Contributor

taran-p commented Apr 4, 2025

I am unable to replicate this, deleting the account in both console and mc worked for me. Does the key appear in mc admin accesskey list myminio?

@JadeVane
Copy link
Author

JadeVane commented Apr 7, 2025

No, the actual command executed is different from expected

Image

@harshavardhana
Copy link
Member

With all the unnecessary ways to name your credentials, why do you make your life harder?

@harshavardhana
Copy link
Member

It is pefectly fine, you are adding new characters on the command line, just use what is presented.

mc admin user add play/ d8fe08\"0sd\"f08080fes
Enter Secret Key: 
Added user `d8fe08"0sd"f08080fes` successfully.

mc admin user add play/ d8fe08\"0sd\"f08080fes
Enter Secret Key: 
Added user `d8fe08"0sd"f08080fes` successfully.

mc admin user rm play/ d8fe08\"0sd\"f08080fes
Removed user `d8fe08"0sd"f08080fes` successfully.

@JadeVane
Copy link
Author

JadeVane commented Apr 7, 2025

With all the unnecessary ways to name your credentials, why do you make your life harder?

This is not an expected behavior, nor is it the result I desired. I use KeePass to manage passwords and incidentally used it to generate a key. I forgot that this is the usual method for generating passwords containing special characters, so it inadvertently produced this invalid key.

This was a human error, but firstly, MinIO did not validate the key and successfully generated it. However, after successful import, it triggered an error. Therefore, I don't believe this should be considered as working as intended.

@JadeVane
Copy link
Author

JadeVane commented Apr 7, 2025

Moreover, the issue remains unresolved because this wasn't an error caused by hacking—it was a human mistake that could easily occur under normal circumstances, so this problem shouldn't be closed either.

@minio minio locked as resolved and limited conversation to collaborators Apr 7, 2025
@klauspost
Copy link
Contributor

@JadeVane We are not going to prioritize this, as it is an unreasonable edge case.

You are welcome to debug and send in a fix for it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants