-
Bug
-
Resolution: Unresolved
-
Undefined
-
None
-
rhel-10.1
-
No
-
None
-
rhel-pt-c-libs
-
None
-
False
-
False
-
-
None
-
None
-
None
-
None
-
Unspecified
-
Unspecified
-
Unspecified
-
-
ppc64le
-
None
What were you trying to do that didn't work?
When I am running strace, I see the following:
:: [ 08:31:45 ] :: [ BEGIN ] :: Running 'strace --stack-traces -e getrandom -o trace -ff ./harness' :: [ 08:31:45 ] :: [ BEGIN ] :: Running 'cat trace.3587' ... getrandom("\xbd\x53\x5d\x8c\xfc\x52\xcf\x5b\x7a\xb4\xc5\x5b\x81\x3d\x92\x7e\x94\xc7\xd5\x24\x97\x1a\xff\x32\x58\x66\x51\xfd\x99\xeb\xc6\x9a", 32, 0) = 32 > [vdso: 71171](__c_kernel_getrandom+0x414) [0x1544] > [vdso: 71171](+0x43) [0x7ab] > /usr/lib64/libc.so.6(getrandom_vdso+0xa3) [0x4dd83] > /usr/lib64/libcrypto.so.3.5.1(ossl_pool_acquire_entropy+0xfb) [0x36980b] > /usr/lib64/libcrypto.so.3.5.1(seed_get_seed.lto_priv.0+0x53) [0x369da3] > /usr/lib64/libcrypto.so.3.5.1(get_entropy+0xd3) [0x35e703] > /usr/lib64/libcrypto.so.3.5.1(ossl_prov_drbg_instantiate+0x183) [0x35f563] > /usr/lib64/libcrypto.so.3.5.1(drbg_ctr_instantiate_wrapper.lto_priv.0+0xe7) [0x366677] > /usr/lib64/libcrypto.so.3.5.1(EVP_RAND_instantiate+0x8b) [0x19e75b] > /usr/lib64/libcrypto.so.3.5.1(rand_new_drbg+0x37f) [0x24610f] > /usr/lib64/libcrypto.so.3.5.1(rand_get0_primary+0x2fb) [0x2465eb] > /usr/lib64/libcrypto.so.3.5.1(rand_get0_public+0x7f) [0x24712f] > /usr/lib64/libcrypto.so.3.5.1(RAND_bytes_ex+0x177) [0x247367] > /usr/lib64/libcrypto.so.3.5.1(RAND_bytes+0x2f) [0x24740f] > /tmp/tmp.sqXGhlKHOd/harness(main+0x37) [0x100008d3] > /usr/lib64/libc.so.6(__libc_start_call_main+0x93) [0x2aba3] > /usr/lib64/libc.so.6(__libc_start_main@@GLIBC_2.34+0x1ab) [0x2adeb]
So in the trace, there is the getrandom_vdso function running, but in ltrace:
:: [ 05:34:42 ] :: [ BEGIN ] :: Running 'ltrace -x *getrandom_vdso* -f --where 10 -o ltrace ./harness_with_priv' :: [ 05:34:42 ] :: [ BEGIN ] :: Running 'cat ltrace' 82965 __libc_start_main([ "SHELL=/bin/bash", "__INTERNAL_RPM_ASSERTED_PACKAGES"..., "HISTCONTROL=ignoredups", "__INTERNAL_PERSISTENT_DATA=/var/"...... ] <unfinished ...> 82965 RAND_bytes(0x7fffc5bed0c8, 16, 0x7fffc5bed548, 0x7fffc5bed798) = 1 > harness_with_priv(main+0x38) [10000934] > libc.so.6(__libc_start_call_main+0x93) [7fffb59aaba3] > libc.so.6(__libc_start_main@@GLIBC_2.34+0x1ab) [7fffb59aadeb]82965 fork() = 82966 > harness_with_priv(main+0x70) [1000096c] > libc.so.6(__libc_start_call_main+0x93) [7fffb59aaba3] > libc.so.6(__libc_start_main@@GLIBC_2.34+0x1ab) [7fffb59aadeb]82965 exit(0 <unfinished ...> 82966 <... fork resumed> ) = 0 82966 RAND_bytes(0x7fffc5bed0c8, 16, 0, 2568 <no return ...> 82965 +++ exited (status 0) +++ 82966 <... RAND_bytes resumed> ) = 1 82966 RAND_priv_bytes(0x7fffc5bed0c8, 16, 0x1003f9a0350, 0) = 1 82966 exit(0 <no return ...> 82966 +++ exited (status 0) +++
The same code in x86_64 with the same versions gives:
'getrandom("\\x26\\xd2\\x10\\x34\\x84\\x4f\\x8b\\xa5\\x0a\\x8a\\x82\\x85\\x68\\xae\\x10\\xad\\xb7\\xed\\xa5\\x87\\xf4\\x3d\\x94\\x05\\xeb\\x9f\\x42\\x9e\\xfa\\xfe\\x13\\xdd", 32, 0) = 32\r\r'
> [vdso: 4265](__vdso_getrandom+0x2e8) [0x13a8]
> /usr/lib64/libc.so.6(getrandom_vdso+0x8e) [0x4408e]
> /usr/lib64/libcrypto.so.3.5.1(ossl_pool_acquire_entropy+0x9d) [0x27e55d]
> /usr/lib64/libcrypto.so.3.5.1(seed_get_seed.lto_priv.0+0x30) [0x27e980]
> /usr/lib64/libcrypto.so.3.5.1(get_entropy+0x9d) [0x2797ed]
> /usr/lib64/libcrypto.so.3.5.1(ossl_prov_drbg_instantiate+0x163) [0x27a2b3]
> /usr/lib64/libcrypto.so.3.5.1(drbg_ctr_instantiate_wrapper.lto_priv.0+0x83) [0x27ce73]
> /usr/lib64/libcrypto.so.3.5.1(EVP_RAND_instantiate+0x58) [0x14c9e8]
> /usr/lib64/libcrypto.so.3.5.1(rand_new_drbg+0x324) [0x1c0b84]
> /usr/lib64/libcrypto.so.3.5.1(rand_get0_primary+0x1c2) [0x1c0e82]
> /usr/lib64/libcrypto.so.3.5.1(rand_get0_public+0x3a) [0x1c15ca]
> /usr/lib64/libcrypto.so.3.5.1(RAND_bytes_ex+0xc7) [0x1c1717]
> /tmp/tmp.fingertipt/harness_with_priv(main+0x1f) [0x401195]
> /usr/lib64/libc.so.6(__libc_start_call_main+0x7d) [0x2a30d]
> /usr/lib64/libc.so.6(__libc_start_main@@GLIBC_2.34+0x88) [0x2a3c8]
> /tmp/tmp.fingertipt/harness_with_priv(_start+0x24) [0x4010b4]
... 4424 getrandom_vdso@libc.so.6(0x20f2bf00, 48, 0, 1) = 48 > libcrypto.so.3(ossl_pool_acquire_entropy+0x9f) [7efea467e55f] > libcrypto.so.3(seed_get_seed.lto_priv.0+0x30) [7efea467e980] > libcrypto.so.3(get_entropy+0x9d) [7efea46797ed] > libcrypto.so.3(ossl_prov_drbg_instantiate+0x163) [7efea467a2b3] > libcrypto.so.3(drbg_ctr_instantiate_wrapper.lto_priv.0+0x83) [7efea467ce73] > libcrypto.so.3(EVP_RAND_instantiate+0x58) [7efea454c9e8] > libcrypto.so.3(rand_new_drbg+0x324) [7efea45c0b84] > libcrypto.so.3(rand_get0_primary+0x1c2) [7efea45c0e82] > libcrypto.so.3(rand_get0_public+0x3a) [7efea45c15ca] > libcrypto.so.3(RAND_bytes_ex+0xc7) [7efea45c1717] > harness_with_priv(main+0x1f) [401195] ...
Not sure if the problem is in ltrace or in vdso that is changing something in ppc64le, but I guess since the function is called, ltrace should detect it.
What is the impact of this issue to you?
moderate to low
Please provide the package NVR for which the bug is seen:
ltrace-0.7.91-52.el10.ppc64le
glibc-2.39-46.el10_0.ppc64le
How reproducible is this bug?:
always (at least in one machine, I think I haven't seen it in all machines)
Steps to reproduce
- ltrace -x getrandom_vdso -f --where 10 -o ltrace ./harness
Expected results
print something like:
3725 getrandom_vdso@libc.so.6(0x294b7f00, 48, 0, 1) = 48 > libcrypto.so.3(ossl_pool_acquire_entropy+0x9f) [7f432767e55f] > libcrypto.so.3(seed_get_seed.lto_priv.0+0x30) [7f432767e980] > libcrypto.so.3(get_entropy+0x9d) [7f43276797ed] > libcrypto.so.3(ossl_prov_drbg_instantiate+0x163) [7f432767a2b3] > libcrypto.so.3(drbg_ctr_instantiate_wrapper.lto_priv.0+0x83) [7f432767ce73] > libcrypto.so.3(EVP_RAND_instantiate+0x58) [7f432754c9e8] > libcrypto.so.3(rand_new_drbg+0x324) [7f43275c0b84] > libcrypto.so.3(rand_get0_primary+0x1c2) [7f43275c0e82] > libcrypto.so.3(rand_get0_public+0x3a) [7f43275c15ca] > libcrypto.so.3(RAND_bytes_ex+0xc7) [7f43275c1717] > harness(main+0x1f) [401185]
Actual results
prints nothing about getrandom_vdso