Bug 968952
Summary: | Alias name with ONLY dot should not be valid alias name | |||
---|---|---|---|---|
Product: | OpenShift Online | Reporter: | Gaoyun Pei <gpei> | |
Component: | Master | Assignee: | Abhishek Gupta <abhgupta> | |
Status: | CLOSED CURRENTRELEASE | QA Contact: | libra bugs <libra-bugs> | |
Severity: | medium | Docs Contact: | ||
Priority: | medium | |||
Version: | 2.x | CC: | abhgupta, jhou, xtian | |
Target Milestone: | --- | |||
Target Release: | --- | |||
Hardware: | Unspecified | |||
OS: | Unspecified | |||
Whiteboard: | ||||
Fixed In Version: | devenv_3295 | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 969112 (view as bug list) | Environment: | ||
Last Closed: | 2013-06-11 04:14:12 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: |
Description
Gaoyun Pei
2013-05-30 10:52:42 UTC
Bug 969112 has been created as a clone of this bug to capture the issue where trying to delete the alias with just a DOT as the name results in deleting the application. This bug is now focused on ensuring that we have the right alias name validations for creating an alias. Lowering the severity since the REST API is able to successfully delete the alias and this is just a matter of adding a validation. Take a look at the first response to the question posted on stackoverflow for some suggestions on the regex validation. http://stackoverflow.com/questions/8848981/looking-to-build-some-regex-to-validate-domain-names-rfc-952-rfc-1123 Fixed with --> https://github.com/openshift/origin-server/pull/2697 Commit pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/ebc0c36918a92d57a000ddab8bd20cd1748aa632 Fix for bug 968952 - Fixing application alias validation regex Fix will be pushed to stage tomorrow. This bug was fixed on devenv_3296, move it to VERIFIED. [root@ip-10-165-27-170 ~]# rhc alias add app1 .. Invalid Server Alias '..' specified [root@ip-10-165-27-170 ~]# rhc alias add app1 . Invalid Server Alias '.' specified [root@ip-10-165-27-170 ~]# rhc alias add app1 a.. Invalid Server Alias 'a..' specified [root@ip-10-165-27-170 ~]# rhc alias add app1 ..a Invalid Server Alias '..a' specified [root@ip-10-165-27-170 ~]# curl -k -H 'Accept: application/xml' --user hhh:r https://localhost/broker/rest/domains/y/applications/app1/events -X POST -d event=add-alias -d alias=a.. <?xml version="1.0" encoding="UTF-8"?> <response> <status>unprocessable_entity</status> <type nil="true"></type> <data> <datum nil="true"></datum> </data> <messages> <message> <severity>error</severity> <text>Invalid Server Alias 'a..' specified</text> <exit-code>105</exit-code> <field nil="true"></field> </message> </messages> <version>1.4</version> <supported-api-versions> <supported-api-version>1.0</supported-api-version> <supported-api-version>1.1</supported-api-version> <supported-api-version>1.2</supported-api-version> <supported-api-version>1.3</supported-api-version> <supported-api-version>1.4</supported-api-version> </supported-api-versions> <errors/> </response> |