Repository navigation
fix(console): validate bucket name characters before submission - #325
Merged
Merged
Conversation
Catch invisible and unsupported characters in the shared bucket name validator so the create form can identify the invalid input before issuing a permission check or S3 request.
8 of 16 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request
Description
The bucket name in rustfs/rustfs#9805 contains two zero-width spaces (
U+200B) after the first letter. The Create Bucket form accepted the input and only showed a generic error after submission.The shared bucket name validator now checks the allowed character set. The form shows a localized error linked to the name field, disables Create, and excludes the invalid name from permission probes. Correcting the value clears the error and allows creation.
Type of Change
Testing
All 1,315 tests passed. Chrome reproduced the missing error on
mainand verified the inline error, disabled Create button, and corrected input on desktop and mobile. The corrected desktop submission returned HTTP 200 against a local RustFS 1.0.0-beta.7 instance.Checklist
Related Issues
Closes rustfs/rustfs#9805
Screenshots (if applicable)
Both desktop screenshots use the original input with two zero-width spaces.
Mobile with Chinese localization
Additional Notes
The existing trim behavior is preserved for surrounding whitespace.