Yes, I think the local fix is the way to go.
(You forgot to Cc: debian-user@lists.debian.org.
Consider to send your mail to the list address, too. I too would then resend my following reply to the list.)
Your problem is one that plagues Linux. You compile and link against
one version of a library, and then you runtime link against another
version.
I consider it a
security bug since essentially random libraries are being loaded at
runtime.
To fix the problem yourself, add an RPATH to your LDFLAGS when
building your program:
-Wl,-rpath=/path/to/expected/libz -Wl,--enable-new-dtags
I'm new with Debian bug reporting and thus need some help with that.
pigz 2.6-1 on Debian 12.5 fails to execute due to a fixed bug on
upstream https://github.com/madler/pigz/issues/111
pigz 2.6-1 on Debian 12.5 fails to execute due to a fixed bug on
upstream https://github.com/madler/pigz/issues/111
Installing the version from sid resolves the issue which is clearly not optimal. I think the fix should be backported.
Can someone help me to file a bug report?
https://www.debian.org/Bugs/Reporting
On Tue, Apr 2, 2024 at 6:24 PM Chung Jonathan <jchung@student.ethz.ch> wrote:install in a VM indeed works as expected.
Dear Franco Martelli, dear Thomas Schmitt,
Sorry for the potential duplication. This mail should now also go to the list.
I believe I found the problem which was on my side. I do have libz.so.1.3, since I manually compiled grpc on my machine and this also uses a newer version of zlib appearently. So this is not a Debian problem but rather specific to my setup. A clean
Do you still think a bug report is worth it?
Your problem is one that plagues Linux. You compile and link against
one version of a library, and then you runtime link against another
version. This should have been fixed for users a long time ago, but
the folks responsible leave users to suffer it. I consider it a
security bug since essentially random libraries are being loaded at
runtime.
To fix the problem yourself, add an RPATH to your LDFLAGS when
building your program:
-Wl,-rpath=/path/to/expected/libz -Wl,--enable-new-dtags
The loader will encounter the RPATH when loading your executable, and
load the correct library for your program.
Hi,
Chung Jonathan wrote:
Yes, I think the local fix is the way to go.
I wrote:
(You forgot to Cc: debian-user@lists.debian.org.
Consider to send your mail to the list address, too. I too would
then
resend my following reply to the list.)
Since my "following reply" is quoted in Jonathan Chung's reply to the
list
i don't have to resend it. (I gave my opinion that the problem is not
a
bug in the context of Debian 12 or 13 and pointed to https://wiki.debian.org/BuildingTutorial for a private fix of the
problem.)
Jeffrey Walton wrote:
Your problem is one that plagues Linux. You compile and link
against
one version of a library, and then you runtime link against another version.
This should not be a problem with a well maintained library which
cares
to stay ABI compatible with its older releases.
In the present case it was a bug in the loading program pigz which
prevented zlib from being usable.
I consider it a
security bug since essentially random libraries are being loaded at runtime.
To fix the problem yourself, add an RPATH to your LDFLAGS when
building your program:
-Wl,-rpath=/path/to/expected/libz -Wl,--enable-new-dtags
Well, this is nearly as unflexible as static compilation but does not
seem to prevent the use of a replaced library at the given path.
Using .so files has its advantages and disadvantages. For a distro
the
advantage (without the pigz bug) is that customers of different
versions
of a library can be consolidated to using the newest available
version.
An advantage for the user is that bugs in a library can be fixed
without
the need for re-building all its customers.
Have a nice day :)
Thomas
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 546 |
Nodes: | 16 (2 / 14) |
Uptime: | 07:25:18 |
Calls: | 10,388 |
Calls today: | 3 |
Files: | 14,061 |
Messages: | 6,416,825 |
Posted today: | 1 |