[GH-ISSUE #1320] 0.9.44.10 -> 0.9.46: libstdc++.so cannot be loaded #902

Closed
opened 2026-05-05 07:05:51 -06:00 by gitea-mirror · 7 comments
Owner

Originally created by @uzytkownik on GitHub (May 30, 2017).
Original GitHub issue: https://github.com/netblue30/firejail/issues/1320

I run into multiple programs failing to load C++ library under the firejail. Downgrading fixed the problem.

Originally created by @uzytkownik on GitHub (May 30, 2017). Original GitHub issue: https://github.com/netblue30/firejail/issues/1320 I run into multiple programs failing to load C++ library under the firejail. Downgrading fixed the problem.
gitea-mirror 2026-05-05 07:05:51 -06:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@netblue30 commented on GitHub (May 30, 2017):

What distribution are you using?

<!-- gh-comment-id:304856041 --> @netblue30 commented on GitHub (May 30, 2017): What distribution are you using?
Author
Owner

@uzytkownik commented on GitHub (May 30, 2017):

Gentoo with gcc 6.3.0.

<!-- gh-comment-id:304912325 --> @uzytkownik commented on GitHub (May 30, 2017): Gentoo with gcc 6.3.0.
Author
Owner

@netblue30 commented on GitHub (May 30, 2017):

We had this problem about a year ago on Gentoo and we ended up commenting out "blacklist /usr/bin/gcc" line in /etc/firejail/disable-devel.inc - see #674 and #824. Go in this file and comment out (add a #) to all lines in gcc section of the file. One of them is creating the problem. If you run " find / -name libstdc++.so.6" what does it say?

<!-- gh-comment-id:305016997 --> @netblue30 commented on GitHub (May 30, 2017): We had this problem about a year ago on Gentoo and we ended up commenting out "blacklist /usr/bin/gcc" line in /etc/firejail/disable-devel.inc - see #674 and #824. Go in this file and comment out (add a #) to all lines in gcc section of the file. One of them is creating the problem. If you run " find / -name libstdc++.so.6" what does it say?
Author
Owner

@uzytkownik commented on GitHub (Jun 3, 2017):

# grep libstdc++.so.6 /var/db/pkg/sys-devel/gcc-6.3.0/CONTENTS  | awk '{print $2}'
/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so
/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6
/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6.0.22
/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so
/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6
/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6.0.22
/usr/lib/debug/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6.0.22.debug
/usr/lib/debug/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6.0.22.debug
/usr/share/gdb/auto-load/usr/lib64/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6.0.22-gdb.py
/usr/share/gdb/auto-load/usr/lib64/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6.0.22-gdb.py

I commented out all lines in GCC section and it didn't helped.

<!-- gh-comment-id:305993130 --> @uzytkownik commented on GitHub (Jun 3, 2017): ``` # grep libstdc++.so.6 /var/db/pkg/sys-devel/gcc-6.3.0/CONTENTS | awk '{print $2}' /usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so /usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6 /usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6.0.22 /usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so /usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6 /usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6.0.22 /usr/lib/debug/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6.0.22.debug /usr/lib/debug/usr/lib/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6.0.22.debug /usr/share/gdb/auto-load/usr/lib64/gcc/x86_64-pc-linux-gnu/6.3.0/libstdc++.so.6.0.22-gdb.py /usr/share/gdb/auto-load/usr/lib64/gcc/x86_64-pc-linux-gnu/6.3.0/32/libstdc++.so.6.0.22-gdb.py ``` I commented out all lines in GCC section and it didn't helped.
Author
Owner

@netblue30 commented on GitHub (Jun 4, 2017):

Does it work if you start the sandboxes with --noprofile? (firejail --noprofile program)

<!-- gh-comment-id:306062002 --> @netblue30 commented on GitHub (Jun 4, 2017): Does it work if you start the sandboxes with --noprofile? (firejail --noprofile program)
Author
Owner

@bitthief commented on GitHub (Jul 4, 2017):

I have also stumbled upon this problem on two different Gentoo Hardened systems trying to run KeePassXC. After some diagnosing (stracing the KeePassXC bin), I found that the issue comes from the fact that KeePassXC was trying to read /etc/ld.so.cache.
The fix was trivial, the keepassxc.profile contains the following line:
private-etc fonts
Simply changing it resolved the issue:
private-etc ld.so.cache,fonts

<!-- gh-comment-id:312956245 --> @bitthief commented on GitHub (Jul 4, 2017): I have also stumbled upon this problem on two different Gentoo Hardened systems trying to run KeePassXC. After some diagnosing (stracing the KeePassXC bin), I found that the issue comes from the fact that KeePassXC was trying to read /etc/ld.so.cache. The fix was trivial, the keepassxc.profile contains the following line: `private-etc fonts` Simply changing it resolved the issue: `private-etc ld.so.cache,fonts`
Author
Owner

@Fred-Barclay commented on GitHub (Jul 5, 2017):

Thanks @bitthief. I've changed the keepassxc profile to contain ld.so.cache in private-etc.

@uzytkownik Can you test if adding keepassxc to a profile makes a difference, and if so, can you list which profiles you're having trouble with?

<!-- gh-comment-id:312972208 --> @Fred-Barclay commented on GitHub (Jul 5, 2017): Thanks @bitthief. I've changed the keepassxc profile to contain `ld.so.cache` in private-etc. @uzytkownik Can you test if adding keepassxc to a profile makes a difference, and if so, can you list which profiles you're having trouble with?
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#902
No description provided.