Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 518764 - Missing pax flag for net-libs/nodejs-0.10.30 binaries
Summary: Missing pax flag for net-libs/nodejs-0.10.30 binaries
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Hardened (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: The Gentoo Linux Hardened Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-08-01 22:14 UTC by Thomas Sigurdsen
Modified: 2014-08-02 12:11 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Complete strace.out (strace.out,27.00 KB, text/plain)
2014-08-01 22:14 UTC, Thomas Sigurdsen
Details
emerge --info (emerge-info-2014-08-01,15.55 KB, text/plain)
2014-08-01 22:15 UTC, Thomas Sigurdsen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Sigurdsen 2014-08-01 22:14:08 UTC
Created attachment 382042 [details]
Complete strace.out

Both commands 'node' and 'npm' stopped from segmentation faults. This happened on a system where nodejs had just been emerged for the first time. Reproducible for both regular user and root.

Running 'paxctl-ng -vm /usr/bin/node' made 'node' and 'npm' commands work as expected. This pax setting should possibly be done by the ebuild.

# strace -o /tmp/strace.out -s 2000  -f node; cat /tmp/strace.out
bash: line 1: 30548 Segmentation fault      strace -o /tmp/strace.out -s 2000 -f node
30553 execve("/usr/bin/node", ["node"], [/* 35 vars */]) = 0
30553 brk(0)                            = 0xcc1ddda76b0
30553 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x70492c647000
30553 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
30553 open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
30553 fstat(3, {st_mode=S_IFREG|0644, st_size=88390, ...}) = 0
30553 mmap(NULL, 88390, PROT_READ, MAP_PRIVATE, 3, 0) = 0x70492c631000
30553 close(3)                          = 0
...
... Cut possibly unimportant info, see attachment for the entire file.
...
30553 mmap(0xee30ca80000, 4096, PROT_NONE, MAP_PRIVATE|MAP_ANONYMOUS|MAP_NORESERVE, -1, 0) = 0x70492c646000
30553 mmap(0x70492c646000, 4096, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = -1 EPERM (Operation not permitted)
30553 munmap(0x70492c646000, 4096)      = 0
30553 mmap(0x10388ca53000, 4096, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = -1 EPERM (Operation not permitted)
30553 --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_addr=0x20} ---
30553 +++ killed by SIGSEGV +++
Comment 1 Thomas Sigurdsen 2014-08-01 22:15:04 UTC
Created attachment 382044 [details]
emerge --info
Comment 2 Thomas Sigurdsen 2014-08-02 12:11:59 UTC
Ebuild already contains pax marking:

/usr/portage/net-libs/nodejs/nodejs-0.10.30.ebuild:68:
    pax-mark -m "${ED}"/usr/bin/node

Not sure how this got messed up on my system as I have not touched pax since system install long before I installed nodejs. Closing ticket nonetheless as it probably is a misconfiguration on my part.