Your message dated Tue, 15 Oct 2024 17:17:17 +0200
with message-id 
<zswmuqxr4mhabrg4wxebfrfmmu3lfoyotsmwx2qabtwdy2f...@tarta.nabijaczleweli.xyz>
and subject line Re: Bug#489741: netpipes: timelimit shall die when impossible 
to run the command
has caused the Debian Bug report #489741,
regarding netpipes: timelimit shall die when impossible to run the command
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
489741: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=489741
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: netpipes
Version: 4.2-3
Severity: normal


Use case:

mac@margarita:~$ touch /tmp/a
mac@margarita:~$ timelimit 10 /tmp/a
timelimit: Unable to exec /tmp/a (Permission denied)

Here timelimit hangs forever... although the primary usage of timelimit
is specifically to stop the command after a given time.

So... when run from a crontab, the user ends up with thousands of
"timelimit" processes running, all <defunct>.

When the command is not executable, timelimit shall:
1) (preferred) just die or
2) die after <time> seconds

Mac

-- System Information:
Debian Release: 4.0
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18.1dedibox_r6_final
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)

Versions of packages netpipes depends on:
ii  libc6                  2.3.6.ds1-13etch5 GNU C Library: Shared libraries

netpipes recommends no packages.

-- no debconf information



--- End Message ---
--- Begin Message ---
Control: tags -1 - unreproducible
Version: 4.2-4

"Can't reproduce this in newer version" means fixed, not unreproducible.

4.2-4 and later versions don't behave like this.

$ strace -f netpipes_4.2-3_amd64/usr/bin/timelimit 10 ./f
execve("netpipes_4.2-3_amd64/usr/bin/timelimit", 
["netpipes_4.2-3_amd64/usr/bin/tim"..., "10", "./f"], 0x7ffc9150caa8 /* 30 vars 
*/) = 0
brk(NULL)                               = 0x55755154e000
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x7f5979c05000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
newfstatat(3, "", {st_mode=S_IFREG|0644, st_size=93966, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 93966, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f5979bee000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\20t\2\0\0\0\0\0"..., 
832) = 832
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 
784, 64) = 784
newfstatat(3, "", {st_mode=S_IFREG|0755, st_size=1922136, ...}, AT_EMPTY_PATH) 
= 0
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 
784, 64) = 784
mmap(NULL, 1970000, PROT_READ, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f5979a0d000
mmap(0x7f5979a33000, 1396736, PROT_READ|PROT_EXEC, 
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x26000) = 0x7f5979a33000
mmap(0x7f5979b88000, 339968, PROT_READ, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 
0x17b000) = 0x7f5979b88000
mmap(0x7f5979bdb000, 24576, PROT_READ|PROT_WRITE, 
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1ce000) = 0x7f5979bdb000
mmap(0x7f5979be1000, 53072, PROT_READ|PROT_WRITE, 
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f5979be1000
close(3)                                = 0
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x7f5979a0a000
arch_prctl(ARCH_SET_FS, 0x7f5979a0a740) = 0
set_tid_address(0x7f5979a0aa10)         = 25177
set_robust_list(0x7f5979a0aa20, 24)     = 0
rseq(0x7f5979a0b060, 0x20, 0, 0x53053053) = 0
mprotect(0x7f5979bdb000, 16384, PROT_READ) = 0
mprotect(0x55754f563000, 4096, PROT_READ) = 0
mprotect(0x7f5979c37000, 8192, PROT_READ) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, 
rlim_max=RLIM64_INFINITY}) = 0
munmap(0x7f5979bee000, 93966)           = 0
clone(child_stack=NULL, 
flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLDstrace: Process 25178 
attached
, child_tidptr=0x7f5979a0aa10) = 25178
[pid 25177] rt_sigaction(SIGCHLD, {sa_handler=0x55754f561229, sa_mask=[], 
sa_flags=SA_RESTORER, sa_restorer=0x7f5979a49050}, NULL, 8) = 0
[pid 25177] clock_nanosleep(CLOCK_REALTIME, 0, {tv_sec=10, tv_nsec=0},  
<unfinished ...>
[pid 25178] set_robust_list(0x7f5979a0aa20, 24) = 0
[pid 25178] execve("./f", ["./f"], 0x7ffeba700108 /* 30 vars */) = -1 EACCES 
(Permission denied)
[pid 25178] --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, 
si_addr=0x79ba32f6} ---
[pid 25178] +++ killed by SIGSEGV +++
<... clock_nanosleep resumed>{tv_sec=9, tv_nsec=998487708}) = ? 
ERESTART_RESTARTBLOCK (Interrupted by signal)
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_KILLED, si_pid=25178, si_uid=1000, 
si_status=SIGSEGV, si_utime=0, si_stime=0} ---
rt_sigreturn({mask=[]})                 = -1 EINTR (Interrupted system call)
wait4(25178, [{WIFSIGNALED(s) && WTERMSIG(s) == SIGSEGV}], 0, NULL) = 25178
exit_group(1)                           = ?
+++ exited with 1 +++


$ strace -f netpipes_4.2-4_amd64/usr/bin/timelimit 10 ./f
execve("netpipes_4.2-4_amd64/usr/bin/timelimit", 
["netpipes_4.2-4_amd64/usr/bin/tim"..., "10", "./f"], 0x7fff2d1318b8 /* 30 vars 
*/) = 0
brk(NULL)                               = 0x557f5787b000
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x7f568ebe9000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
newfstatat(3, "", {st_mode=S_IFREG|0644, st_size=93966, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 93966, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f568ebd2000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\20t\2\0\0\0\0\0"..., 
832) = 832
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 
784, 64) = 784
newfstatat(3, "", {st_mode=S_IFREG|0755, st_size=1922136, ...}, AT_EMPTY_PATH) 
= 0
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 
784, 64) = 784
mmap(NULL, 1970000, PROT_READ, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f568e9f1000
mmap(0x7f568ea17000, 1396736, PROT_READ|PROT_EXEC, 
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x26000) = 0x7f568ea17000
mmap(0x7f568eb6c000, 339968, PROT_READ, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 
0x17b000) = 0x7f568eb6c000
mmap(0x7f568ebbf000, 24576, PROT_READ|PROT_WRITE, 
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1ce000) = 0x7f568ebbf000
mmap(0x7f568ebc5000, 53072, PROT_READ|PROT_WRITE, 
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f568ebc5000
close(3)                                = 0
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x7f568e9ee000
arch_prctl(ARCH_SET_FS, 0x7f568e9ee740) = 0
set_tid_address(0x7f568e9eea10)         = 25809
set_robust_list(0x7f568e9eea20, 24)     = 0
rseq(0x7f568e9ef060, 0x20, 0, 0x53053053) = 0
mprotect(0x7f568ebbf000, 16384, PROT_READ) = 0
mprotect(0x557f577d4000, 4096, PROT_READ) = 0
mprotect(0x7f568ec1b000, 8192, PROT_READ) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, 
rlim_max=RLIM64_INFINITY}) = 0
munmap(0x7f568ebd2000, 93966)           = 0
clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, 
child_tidptr=0x7f568e9eea10) = 25810
rt_sigaction(SIGCHLD, {sa_handler=0x557f577d25b0, sa_mask=[], 
sa_flags=SA_RESTORER, sa_restorer=0x7f568ea2d050}, strace: Process 25810 
attached
NULL, 8) = 0
[pid 25809] clock_nanosleep(CLOCK_REALTIME, 0, {tv_sec=10, tv_nsec=0},  
<unfinished ...>
[pid 25810] set_robust_list(0x7f568e9eea20, 24) = 0
[pid 25810] execve("./f", ["./f"], 0x7ffe450f34c8 /* 30 vars */) = -1 EACCES 
(Permission denied)
[pid 25810] write(2, "timelimit: Unable to exec ./f (P"..., 49timelimit: Unable 
to exec ./f (Permission denied)) = 49
[pid 25810] exit_group(1)               = ?
[pid 25810] +++ exited with 1 +++
<... clock_nanosleep resumed>{tv_sec=9, tv_nsec=999509660}) = ? 
ERESTART_RESTARTBLOCK (Interrupted by signal)
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=25810, si_uid=1000, 
si_status=1, si_utime=0, si_stime=0} ---
rt_sigreturn({mask=[]})                 = -1 EINTR (Interrupted system call)
wait4(25810, [{WIFEXITED(s) && WEXITSTATUS(s) == 1}], 0, NULL) = 25810
exit_group(1)                           = ?
+++ exited with 1 +++


$ strace -f timelimit.netpipes 10 ./f
execve("/bin/timelimit.netpipes", ["timelimit.netpipes", "10", "./f"], 
0x7ffe2bb5e6e8 /* 30 vars */) = 0
brk(NULL)                               = 0x55cbba856000
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x7fa75ee7d000
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
newfstatat(3, "", {st_mode=S_IFREG|0644, st_size=93966, ...}, AT_EMPTY_PATH) = 0
mmap(NULL, 93966, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fa75ee66000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\20t\2\0\0\0\0\0"..., 
832) = 832
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 
784, 64) = 784
newfstatat(3, "", {st_mode=S_IFREG|0755, st_size=1922136, ...}, AT_EMPTY_PATH) 
= 0
pread64(3, "\6\0\0\0\4\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0@\0\0\0\0\0\0\0"..., 
784, 64) = 784
mmap(NULL, 1970000, PROT_READ, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fa75ec85000
mmap(0x7fa75ecab000, 1396736, PROT_READ|PROT_EXEC, 
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x26000) = 0x7fa75ecab000
mmap(0x7fa75ee00000, 339968, PROT_READ, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 
0x17b000) = 0x7fa75ee00000
mmap(0x7fa75ee53000, 24576, PROT_READ|PROT_WRITE, 
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1ce000) = 0x7fa75ee53000
mmap(0x7fa75ee59000, 53072, PROT_READ|PROT_WRITE, 
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7fa75ee59000
close(3)                                = 0
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x7fa75ec82000
arch_prctl(ARCH_SET_FS, 0x7fa75ec82740) = 0
set_tid_address(0x7fa75ec82a10)         = 33161
set_robust_list(0x7fa75ec82a20, 24)     = 0
rseq(0x7fa75ec83060, 0x20, 0, 0x53053053) = 0
mprotect(0x7fa75ee53000, 16384, PROT_READ) = 0
mprotect(0x55cbb9001000, 4096, PROT_READ) = 0
mprotect(0x7fa75eeaf000, 8192, PROT_READ) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, 
rlim_max=RLIM64_INFINITY}) = 0
munmap(0x7fa75ee66000, 93966)           = 0
clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, 
child_tidptr=0x7fa75ec82a10) = 33162
rt_sigaction(SIGCHLD, {sa_handler=0x55cbb8e00ed0, sa_mask=[], 
sa_flags=SA_RESTORER, sa_restorer=0x7fa75ecc1050}, strace: Process 33162 
attached
NULL, 8) = 0
[pid 33161] clock_nanosleep(CLOCK_REALTIME, 0, {tv_sec=10, tv_nsec=0},  
<unfinished ...>
[pid 33162] set_robust_list(0x7fa75ec82a20, 24) = 0
[pid 33162] execve("./f", ["./f"], 0x7fffdc415658 /* 30 vars */) = -1 EACCES 
(Permission denied)
[pid 33162] write(2, "timelimit.netpipes: Unable to ex"..., 
60timelimit.netpipes: Unable to exec ./f (Permission denied).
) = 60
[pid 33162] exit_group(1)               = ?
[pid 33162] +++ exited with 1 +++
<... clock_nanosleep resumed>{tv_sec=9, tv_nsec=999319934}) = ? 
ERESTART_RESTARTBLOCK (Interrupted by signal)
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=33162, si_uid=1000, 
si_status=1, si_utime=0, si_stime=0} ---
rt_sigreturn({mask=[]})                 = -1 EINTR (Interrupted system call)
wait4(33162, [{WIFEXITED(s) && WEXITSTATUS(s) == 1}], 0, NULL) = 33162
exit_group(1)                           = ?
+++ exited with 1 +++

Attachment: signature.asc
Description: PGP signature


--- End Message ---

Reply via email to