IPv6 address not wrapped when parsing driver info and adding default schema/authority

Bug #2036454 reported by Harald Jensås
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ironic
Fix Released
Undecided
Unassigned

Bug Description

When 'redfish_address' is an IPv6 address the parsing of driver info does not wrap the address in brackets when adding schema/authority.

Node d3a4d3c6-5ba1-48d0-a65d-36eea229dcef did not pass power credentials validation: Invalid Redfish address https://2001:DB8::1 set in driver_info/redfish_address on node d3a4d3c6-5ba1-48d0-a65d-36eea229dcef

Expected result:

  https://[2001:DB8::1]

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/ironic/+/895729

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

Reviewed: https://review.opendev.org/c/openstack/ironic/+/895729
Committed: https://opendev.org/openstack/ironic/commit/72037b596af140f4930f2c2f17c397be01e89f0f
Submitter: "Zuul (22348)"
Branch: master

commit 72037b596af140f4930f2c2f17c397be01e89f0f
Author: Harald Jensås <email address hidden>
Date: Mon Sep 18 20:56:29 2023 +0200

    redfish_address - wrap_ipv6 address

    When parsing redfish driver info wrap IPv6 address in brackets
    before appending default scheme/authority.

    Updated common.utils.wrap_ipv6() to ignore ValueError, e.g
    simply return the string if ip is not an ipv6 address string.

    Related: RHBZ#2239356
    Closes-Bug: #2036454
    Change-Id: Icefd96d6873474b4cfb7fbf3d8337cd42fd63ca6

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

Fix proposed to branch: stable/2023.1
Review: https://review.opendev.org/c/openstack/ironic/+/895795

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic 23.0.0

This issue was fixed in the openstack/ironic 23.0.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (stable/zed)

Fix proposed to branch: stable/zed
Review: https://review.opendev.org/c/openstack/ironic/+/896208

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (stable/yoga)

Fix proposed to branch: stable/yoga
Review: https://review.opendev.org/c/openstack/ironic/+/896209

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (stable/xena)

Fix proposed to branch: stable/xena
Review: https://review.opendev.org/c/openstack/ironic/+/896210

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (stable/wallaby)

Fix proposed to branch: stable/wallaby
Review: https://review.opendev.org/c/openstack/ironic/+/896376

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (stable/2023.1)

Reviewed: https://review.opendev.org/c/openstack/ironic/+/895795
Committed: https://opendev.org/openstack/ironic/commit/9e90dbed6f15343bdfe07a7a5e1c42bd6bf1f9d0
Submitter: "Zuul (22348)"
Branch: stable/2023.1

commit 9e90dbed6f15343bdfe07a7a5e1c42bd6bf1f9d0
Author: Harald Jensås <email address hidden>
Date: Mon Sep 18 20:56:29 2023 +0200

    redfish_address - wrap_ipv6 address

    When parsing redfish driver info wrap IPv6 address in brackets
    before appending default scheme/authority.

    Updated common.utils.wrap_ipv6() to ignore ValueError, e.g
    simply return the string if ip is not an ipv6 address string.

    Related: RHBZ#2239356
    Closes-Bug: #2036454
    Change-Id: Icefd96d6873474b4cfb7fbf3d8337cd42fd63ca6
    (cherry picked from commit 72037b596af140f4930f2c2f17c397be01e89f0f)

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (stable/zed)

Reviewed: https://review.opendev.org/c/openstack/ironic/+/896208
Committed: https://opendev.org/openstack/ironic/commit/ba97ec80e375711f923bd5676b599df497644903
Submitter: "Zuul (22348)"
Branch: stable/zed

commit ba97ec80e375711f923bd5676b599df497644903
Author: Harald Jensås <email address hidden>
Date: Mon Sep 18 20:56:29 2023 +0200

    redfish_address - wrap_ipv6 address

    When parsing redfish driver info wrap IPv6 address in brackets
    before appending default scheme/authority.

    Updated common.utils.wrap_ipv6() to ignore ValueError, e.g
    simply return the string if ip is not an ipv6 address string.

    Related: RHBZ#2239356
    Closes-Bug: #2036454
    Change-Id: Icefd96d6873474b4cfb7fbf3d8337cd42fd63ca6
    (cherry picked from commit 72037b596af140f4930f2c2f17c397be01e89f0f)

tags: added: in-stable-zed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (stable/yoga)

Reviewed: https://review.opendev.org/c/openstack/ironic/+/896209
Committed: https://opendev.org/openstack/ironic/commit/dcf5af5606106c27ecbb63d9acc679c6f98142d5
Submitter: "Zuul (22348)"
Branch: stable/yoga

commit dcf5af5606106c27ecbb63d9acc679c6f98142d5
Author: Harald Jensås <email address hidden>
Date: Mon Sep 18 20:56:29 2023 +0200

    redfish_address - wrap_ipv6 address

    When parsing redfish driver info wrap IPv6 address in brackets
    before appending default scheme/authority.

    Updated common.utils.wrap_ipv6() to ignore ValueError, e.g
    simply return the string if ip is not an ipv6 address string.

    Related: RHBZ#2239356
    Closes-Bug: #2036454
    Change-Id: Icefd96d6873474b4cfb7fbf3d8337cd42fd63ca6
    (cherry picked from commit 72037b596af140f4930f2c2f17c397be01e89f0f)

tags: added: in-stable-yoga
tags: added: in-stable-wallaby
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (stable/wallaby)

Reviewed: https://review.opendev.org/c/openstack/ironic/+/896376
Committed: https://opendev.org/openstack/ironic/commit/c31db88e96a797621c035a21c4f7cfd39b00ef8f
Submitter: "Zuul (22348)"
Branch: stable/wallaby

commit c31db88e96a797621c035a21c4f7cfd39b00ef8f
Author: Harald Jensås <email address hidden>
Date: Mon Sep 18 20:56:29 2023 +0200

    redfish_address - wrap_ipv6 address

    When parsing redfish driver info wrap IPv6 address in brackets
    before appending default scheme/authority.

    Updated common.utils.wrap_ipv6() to ignore ValueError, e.g
    simply return the string if ip is not an ipv6 address string.

    Conflicts:
      ironic/tests/unit/drivers/modules/redfish/test_utils.py

    Related: RHBZ#2239356
    Closes-Bug: #2036454
    Change-Id: Icefd96d6873474b4cfb7fbf3d8337cd42fd63ca6
    (cherry picked from commit 72037b596af140f4930f2c2f17c397be01e89f0f)

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (stable/xena)

Reviewed: https://review.opendev.org/c/openstack/ironic/+/896210
Committed: https://opendev.org/openstack/ironic/commit/6835640c515191b2b0a697fc4d065e575bc1e0c2
Submitter: "Zuul (22348)"
Branch: stable/xena

commit 6835640c515191b2b0a697fc4d065e575bc1e0c2
Author: Harald Jensås <email address hidden>
Date: Mon Sep 18 20:56:29 2023 +0200

    redfish_address - wrap_ipv6 address

    When parsing redfish driver info wrap IPv6 address in brackets
    before appending default scheme/authority.

    Updated common.utils.wrap_ipv6() to ignore ValueError, e.g
    simply return the string if ip is not an ipv6 address string.

    Related: RHBZ#2239356
    Closes-Bug: #2036454
    Change-Id: Icefd96d6873474b4cfb7fbf3d8337cd42fd63ca6
    (cherry picked from commit 72037b596af140f4930f2c2f17c397be01e89f0f)

tags: added: in-stable-xena
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic 20.1.3

This issue was fixed in the openstack/ironic 20.1.3 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic 21.1.1

This issue was fixed in the openstack/ironic 21.1.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic wallaby-eom

This issue was fixed in the openstack/ironic wallaby-eom release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic xena-eom

This issue was fixed in the openstack/ironic xena-eom release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/ironic 21.4.1

This issue was fixed in the openstack/ironic 21.4.1 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.