FS#72978 - [libarchive] does not decode spaces in symlink paths

Attached to Project: Arch Linux
Opened by David Runge (dvzrv) - Saturday, 11 December 2021, 11:38 GMT
Last edited by Christian Hesse (eworm) - Monday, 03 January 2022, 10:59 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Christian Hesse (eworm)
Architecture All
Severity Low
Priority Normal
Reported Version 6.0.0
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Summary and Info:
As pointed out in  FS#72974  there is a warning for the alsa-ucm-conf package due to a symlink contained in it that has spaces in its name.

'/usr/share/alsa/ucm2/conf.d/simple-card/Librem 5 Devkit.conf' -> '../../NXP/iMX8/Librem_5_Devkit/Librem 5 Devkit.conf'

The above issue was discussed briefly in #archlinux-pacman on libera.chat and it appears that the underlying problem is that libarchive encodes spaces in the symlink path, while pacman is not decoding them.

Steps to Reproduce:

1. $ pacman -S alsa-ucm-conf
2. $ pacman -Qkk alsa-ucm-conf
This task depends upon

Closed by  Christian Hesse (eworm)
Monday, 03 January 2022, 10:59 GMT
Reason for closing:  Fixed
Additional comments about closing:  libarchive 3.5.2-2
Comment by Allan McRae (Allan) - Saturday, 11 December 2021, 14:23 GMT
From the libarchive source - archive_write_set_format_mtree.c, line 307 - we can see that ' ', '#' and '=' are replaced. There appears to be some functions in the mtree reading of libarchive that reverse this, but I have not figured that part out yet...
Comment by Allan McRae (Allan) - Saturday, 11 December 2021, 14:38 GMT
archive_read_support_format_mtree, line 1676 does not parse_escapes for the symlink path. So this is a libarchive bug, that appears easy to fix...
Comment by Allan McRae (Allan) - Saturday, 11 December 2021, 14:47 GMT
Patch for libarchive-3.5.2. Fixes this issue.
Comment by Allan McRae (Allan) - Saturday, 11 December 2021, 14:49 GMT
  • Field changed: Category (General → Packages: Core)
  • Field changed: Architecture (All → All)
  • Task reassigned to Christian Hesse (eworm)
Assigning to libarchive maintainer. Patch has not be submitted upstream.

Loading...