regex in cinder_type provider fails on properties with characters not in \w

Bug #1932272 reported by Ebbex
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
puppet-cinder
Fix Released
Medium
Unassigned

Bug Description

The fix introduced in https://review.opendev.org/c/openstack/puppet-cinder/+/682936 for handling osc >= 4.0.0 uses a regex that doesn't take account for characters outside of \w. Which caused a issue for us where we use dashes ('-') in the volume_backend_name property.

Changed in puppet-cinder:
status: New → In Progress
Changed in puppet-cinder:
importance: Undecided → Medium
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to puppet-cinder (master)

Reviewed: https://review.opendev.org/c/openstack/puppet-cinder/+/796409
Committed: https://opendev.org/openstack/puppet-cinder/commit/62899eba67f134a92fb863b5a9b6dcfc3e18aa56
Submitter: "Zuul (22348)"
Branch: master

commit 62899eba67f134a92fb863b5a9b6dcfc3e18aa56
Author: Erik Berg <email address hidden>
Date: Tue Jun 15 11:10:57 2021 +0200

    Allow for '-' in volume type property values

    There's no validation going on (yet) in cinder as to which characters
    are allowed in properties. So this change alters the regex to cast a
    wide net catching '-' and other possible valid variations.

    Also update unit-test to cover this scenario.

    Closes-Bug: #1932272
    Change-Id: I564528663a3d2f83136b98ed46e09e373a9ad6de

Changed in puppet-cinder:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to puppet-cinder (stable/wallaby)

Fix proposed to branch: stable/wallaby
Review: https://review.opendev.org/c/openstack/puppet-cinder/+/797108

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to puppet-cinder (stable/wallaby)

Reviewed: https://review.opendev.org/c/openstack/puppet-cinder/+/797108
Committed: https://opendev.org/openstack/puppet-cinder/commit/fee24886422bf1dcdad64da33e022b01b0324fdb
Submitter: "Zuul (22348)"
Branch: stable/wallaby

commit fee24886422bf1dcdad64da33e022b01b0324fdb
Author: Erik Berg <email address hidden>
Date: Tue Jun 15 11:10:57 2021 +0200

    Allow for '-' in volume type property values

    There's no validation going on (yet) in cinder as to which characters
    are allowed in properties. So this change alters the regex to cast a
    wide net catching '-' and other possible valid variations.

    Also update unit-test to cover this scenario.

    Closes-Bug: #1932272
    Change-Id: I564528663a3d2f83136b98ed46e09e373a9ad6de
    (cherry picked from commit 62899eba67f134a92fb863b5a9b6dcfc3e18aa56)

tags: added: in-stable-wallaby
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to puppet-cinder (stable/victoria)

Fix proposed to branch: stable/victoria
Review: https://review.opendev.org/c/openstack/puppet-cinder/+/797384

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to puppet-cinder (stable/victoria)

Reviewed: https://review.opendev.org/c/openstack/puppet-cinder/+/797384
Committed: https://opendev.org/openstack/puppet-cinder/commit/9ece2cff0ef9365ff0ee4599a37f010da877ad22
Submitter: "Zuul (22348)"
Branch: stable/victoria

commit 9ece2cff0ef9365ff0ee4599a37f010da877ad22
Author: Erik Berg <email address hidden>
Date: Tue Jun 15 11:10:57 2021 +0200

    Allow for '-' in volume type property values

    There's no validation going on (yet) in cinder as to which characters
    are allowed in properties. So this change alters the regex to cast a
    wide net catching '-' and other possible valid variations.

    Also update unit-test to cover this scenario.

    Closes-Bug: #1932272
    Change-Id: I564528663a3d2f83136b98ed46e09e373a9ad6de
    (cherry picked from commit 62899eba67f134a92fb863b5a9b6dcfc3e18aa56)
    (cherry picked from commit fee24886422bf1dcdad64da33e022b01b0324fdb)

tags: added: in-stable-victoria
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to puppet-cinder (stable/ussuri)

Fix proposed to branch: stable/ussuri
Review: https://review.opendev.org/c/openstack/puppet-cinder/+/797569

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to puppet-cinder (stable/ussuri)

Reviewed: https://review.opendev.org/c/openstack/puppet-cinder/+/797569
Committed: https://opendev.org/openstack/puppet-cinder/commit/d0bdfc2fdec0881960692819c179a9b189860e9b
Submitter: "Zuul (22348)"
Branch: stable/ussuri

commit d0bdfc2fdec0881960692819c179a9b189860e9b
Author: Erik Berg <email address hidden>
Date: Tue Jun 15 11:10:57 2021 +0200

    Allow for '-' in volume type property values

    There's no validation going on (yet) in cinder as to which characters
    are allowed in properties. So this change alters the regex to cast a
    wide net catching '-' and other possible valid variations.

    Also update unit-test to cover this scenario.

    Closes-Bug: #1932272
    Change-Id: I564528663a3d2f83136b98ed46e09e373a9ad6de
    (cherry picked from commit 62899eba67f134a92fb863b5a9b6dcfc3e18aa56)
    (cherry picked from commit fee24886422bf1dcdad64da33e022b01b0324fdb)
    (cherry picked from commit 9ece2cff0ef9365ff0ee4599a37f010da877ad22)

tags: added: in-stable-ussuri
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to puppet-cinder (stable/train)

Fix proposed to branch: stable/train
Review: https://review.opendev.org/c/openstack/puppet-cinder/+/798321

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to puppet-cinder (stable/train)

Reviewed: https://review.opendev.org/c/openstack/puppet-cinder/+/798321
Committed: https://opendev.org/openstack/puppet-cinder/commit/263c6b11fcd21f3dec8bd72e876f74ab400840c2
Submitter: "Zuul (22348)"
Branch: stable/train

commit 263c6b11fcd21f3dec8bd72e876f74ab400840c2
Author: Erik Berg <email address hidden>
Date: Tue Jun 15 11:10:57 2021 +0200

    Allow for '-' in volume type property values

    There's no validation going on (yet) in cinder as to which characters
    are allowed in properties. So this change alters the regex to cast a
    wide net catching '-' and other possible valid variations.

    Also update unit-test to cover this scenario.

    Closes-Bug: #1932272
    Change-Id: I564528663a3d2f83136b98ed46e09e373a9ad6de
    (cherry picked from commit 62899eba67f134a92fb863b5a9b6dcfc3e18aa56)
    (cherry picked from commit fee24886422bf1dcdad64da33e022b01b0324fdb)
    (cherry picked from commit 9ece2cff0ef9365ff0ee4599a37f010da877ad22)
    (cherry picked from commit d0bdfc2fdec0881960692819c179a9b189860e9b)

tags: added: in-stable-train
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/puppet-cinder 19.1.0

This issue was fixed in the openstack/puppet-cinder 19.1.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/puppet-cinder 16.4.0

This issue was fixed in the openstack/puppet-cinder 16.4.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/puppet-cinder 18.5.0

This issue was fixed in the openstack/puppet-cinder 18.5.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/puppet-cinder 17.5.0

This issue was fixed in the openstack/puppet-cinder 17.5.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/puppet-cinder train-eol

This issue was fixed in the openstack/puppet-cinder train-eol release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.