[openstack-dev] [nova][oslo.utils] Bug-1680130 Check validation of UUID length

Lance Bragstad lbragstad at gmail.com
Mon Apr 24 18:20:06 UTC 2017


We had to do similar things in keystone in order to validate uuid-ish types
(just not as fancy) [0] [1]. If we didn't have to worry about being
backwards compatible with non-uuid formats, it would be awesome to have one
implementation for checking that.

[0]
https://github.com/openstack/keystone/blob/6c6589d2b0f308cb788b37b29ebde515304ee41e/keystone/identity/schema.py#L69
[1]
https://github.com/openstack/keystone/blob/6c6589d2b0f308cb788b37b29ebde515304ee41e/keystone/common/validation/parameter_types.py#L38-L45

On Mon, Apr 24, 2017 at 1:05 PM, Matt Riedemann <mriedemos at gmail.com> wrote:

> On 4/24/2017 12:58 PM, Sean Dague wrote:
>
>>
>> Which uses is_uuid_like to do the validation -
>> https://github.com/openstack/nova/blob/1106477b78c80743e6443
>> abc30911b24a9ab7b15/nova/api/validation/validators.py#L85-L87
>>
>> We assumed (as did many others) that is_uuid_like was strict enough for
>> param validation. It is apparently not.
>>
>> Either it needs to be fixed to be so, or some other function needs to be
>> created that is, that people can cut over to.
>>
>>         -Sean
>>
>>
> Well kiss my grits. I had always assumed that was built into jsonschema.
>
> --
>
> Thanks,
>
> Matt
>
>
> __________________________________________________________________________
> OpenStack Development Mailing List (not for usage questions)
> Unsubscribe: OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20170424/0721558c/attachment.html>


More information about the OpenStack-dev mailing list