Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-40565

URL scheme with IPv6 address is cumbersome

    • Icon: Bug Bug
    • Resolution: Done-Errata
    • Icon: Undefined Undefined
    • rhel-9.5
    • rhel-9.4
    • rear
    • None
    • rear-2.6-25.el9
    • None
    • Low
    • Upstream
    • rhel-sst-cs-system-management
    • ssg_core_services
    • 20
    • 25
    • 3
    • False
    • Hide

      None

      Show
      None
    • Yes
    • Red Hat Enterprise Linux
    • None
    • Bug Fix
    • Hide
      .ReaR now interprets square brackets enclosing IPv6 addresses in URLs as expected

      Previously, square brackets in `OUTPUT_URL` and `BACKUP_URL` were not interpreted correctly. Specifying an IPv6 address instead of a host name requires enclosing the address in square brackets, for example, [::1] for localhost. Since the brackets were not interpreted correctly, using an IPv6 address in a `sshfs://` or `nfs://` URL was not possible.

      As a consequence, if the user used a `sshfs://` or `nfs://` scheme in the `BACKUP_URL` or `OUTPUT_URL` with an IPv6 address enclosed in square brackets, ReaR aborted prematurely with an error message, for example:

      ----
      ERROR: Invalid scheme '' in BACKUP_URL
      ----

      With this update, ReaR is now fixed to not interpret square brackets as shell metacharacters when parsing `sshfs://` and `nfs://` URLs. Now, you can use IPv6 addresses enclosed in brackets in `BACKUP_URL` and `OUTPUT_URL` that use the `sshfs://` or `nfs://` scheme . For example:

      ----
      OUTPUT_URL=nfs://[2001:db8:ca2:6::101]/root/REAR
      ----

      Before this fix was implemented, it was possible to work around the bug by using quoting and backslash characters, for example:

      ----
      OUTPUT_URL="nfs://\[2001:db8:ca2:6::101\]/root/REAR"
      ----

      Note: If you have been using the workaround, remove the backslash characters after applying the update.
      Show
      .ReaR now interprets square brackets enclosing IPv6 addresses in URLs as expected Previously, square brackets in `OUTPUT_URL` and `BACKUP_URL` were not interpreted correctly. Specifying an IPv6 address instead of a host name requires enclosing the address in square brackets, for example, [::1] for localhost. Since the brackets were not interpreted correctly, using an IPv6 address in a `sshfs://` or `nfs://` URL was not possible. As a consequence, if the user used a `sshfs://` or `nfs://` scheme in the `BACKUP_URL` or `OUTPUT_URL` with an IPv6 address enclosed in square brackets, ReaR aborted prematurely with an error message, for example: ---- ERROR: Invalid scheme '' in BACKUP_URL ---- With this update, ReaR is now fixed to not interpret square brackets as shell metacharacters when parsing `sshfs://` and `nfs://` URLs. Now, you can use IPv6 addresses enclosed in brackets in `BACKUP_URL` and `OUTPUT_URL` that use the `sshfs://` or `nfs://` scheme . For example: ---- OUTPUT_URL=nfs://[2001:db8:ca2:6::101]/root/REAR ---- Before this fix was implemented, it was possible to work around the bug by using quoting and backslash characters, for example: ---- OUTPUT_URL="nfs://\[2001:db8:ca2:6::101\]/root/REAR" ---- Note: If you have been using the workaround, remove the backslash characters after applying the update.
    • Done
    • None

      What were you trying to do that didn't work?

      A customer is specifying an IPv6 address as backup location: OUTPUT_URL=nfs://[2001:db8:ca2:6::101]/root/REAR

      This doesn't work because the code is not parsing the address properly.
      Refer to https://github.com/rear/rear/pull/3242 for proposed Upstream PR.

      There are a lot of fixes to bring into ReaR for this to work.

      Please provide the package NVR for which bug is seen:

      All

      How reproducible:

      Always

      Steps to reproduce

      1. Set up 2 VMs with IPv6 addresses (2nd one acting as NFS or SSHFS server)
      2. Backup one VM to the other

      Expected results

      Works

      Actual results

      Fails in various places depending on URL scheme specified.

              rhn-support-pcahyna Pavel Cahyna
              rhn-support-rmetrich Renaud Métrich
              Pavel Cahyna Pavel Cahyna
              Jakub Haruda Jakub Haruda
              Mugdha Soni Mugdha Soni
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

                Created:
                Updated:
                Resolved: