[Bug 286367] Linux Jail - Operation not permitted (/src/build/release/libzmq/src/libzmq_external/src/thread.cpp:345)

From: <bugzilla-noreply_at_freebsd.org>
Date: Sat, 26 Apr 2025 17:50:56 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=286367

            Bug ID: 286367
           Summary: Linux Jail - Operation not permitted
                    (/src/build/release/libzmq/src/libzmq_external/src/thr
                    ead.cpp:345)
           Product: Base System
           Version: 15.0-CURRENT
          Hardware: amd64
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: kern
          Assignee: bugs@FreeBSD.org
          Reporter: sporran-musing0p@icloud.com

Created attachment 259893
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=259893&action=edit
NOT OK in linux jail

Hi

I am trying to run a linux binary in a linux jail, but no luck.

I can run the binary doing directly "chroot /jails/testdebian" from the main
system.
But once, I try to do it in the jail itself (jexec testdebian bash), it fails.

The linux binary I try to run is
https://github.com/Beldex-Coin/beldex/releases/download/v4.1.0/beldex-linux-x86_64-v4.1.0.tar.xz


Here what I think is the relevant part of the strace 

STRACE PART OK RUNNING after CHROOT /jail/testdebian
-----------------------------------------------------

strace: pid 53710: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53710: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551473)
strace: pid 53710: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53710: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551471)
strace: pid 53710: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53710: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551472)
strace: pid 53710: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53710: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551459)
strace: pid 53710: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53710: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551384)
eventfd2(0, EFD_CLOEXEC)                = 20


STRACE PART NOTOK RUNNING in linux jail (/jail/testdebian)
----------------------------------------------------------
strace: pid 53716: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53716: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551473)
strace: pid 53716: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53716: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551471)
strace: pid 53716: entering, ptrace_syscall_info.op == 2
read(0, strace: pid 53716: exiting, ptrace_syscall_info.op == 1
NULL, 0)                        = -1 (errno 18446744073709551472)
strace: pid 53716: entering, ptrace_syscall_info.op == 2
syscall_0xffffffffffffffff(0x1, 0, 0, 0, 0, 0strace: pid 53716: exiting,
ptrace_syscall_info.op == 1
) = -1 (errno 18446744073709551615)
Operation not permitted
(/src/build/release/libzmq/src/libzmq_external/src/thread.cpp:345)
strace: pid 53716: entering, ptrace_syscall_info.op == 2
fchmod(0, 000strace: pid 53716: exiting, ptrace_syscall_info.op == 1





Attachments:
screen shot not ok

-- 
You are receiving this mail because:
You are the assignee for the bug.