There are Nova API calls that can accept a server name
as a regex parameter. For example, if the command
'nova list --name <some_pattern>' is invoked with
an incorrect value of the pattern, the nova-api makes
a request to database and returns Http 500 error. Seems
it's not convenient.
This fix checks the pattern. If it isn't correct,
the nova-api returns error 400 with a prompt of a bad regex.
Reviewed: https:/ /review. openstack. org/344945 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=d01695886f3 fb6ec1ffe4204e7 f4bc72737992cf
Committed: https:/
Submitter: Jenkins
Branch: master
commit d01695886f3fb6e c1ffe4204e7f4bc 72737992cf
Author: Anton Kremenetsky <email address hidden>
Date: Wed Jul 20 13:24:43 2016 -0400
Add server name verification in instance search
There are Nova API calls that can accept a server name
as a regex parameter. For example, if the command
'nova list --name <some_pattern>' is invoked with
an incorrect value of the pattern, the nova-api makes
a request to database and returns Http 500 error. Seems
it's not convenient.
This fix checks the pattern. If it isn't correct,
the nova-api returns error 400 with a prompt of a bad regex.
Change-Id: Iad63c668d09ec6 a82ace29700fb49 49c1acfbe1c
Closes-Bug: #1603728