c - Memory failure in "?? ()" using GDB -
i'm trying trace segmentation fault using gdb
, i'm unable find exact line fault happening.
(gdb) backtrace #0 0x00110402 in __kernel_vsyscall () #1 0x007a5690 in raise () /lib/libc.so.6 #2 0x007a6f91 in abort () /lib/libc.so.6 #3 0x007dd9eb in __libc_message () /lib/libc.so.6 #4 0x007e59aa in _int_free () /lib/libc.so.6 #5 0x007e90f0 in free () /lib/libc.so.6 #6 0x080dc4e7 in crypto_free () #7 0x08c36668 in ?? () #8 0x08c44bac in ?? () #9 0x08100168 in bn_free () #10 0x00000009 in ?? () #11 0x08c44ba8 in ?? () #12 0x08108c07 in bn_mont_ctx_free () #13 0xffffffff in ?? () #14 0x08c36630 in ?? () #15 0x08112697 in rsa_eay_finish () #16 0x08c4c110 in ?? () #17 0x08c36630 in ?? () #18 0x081150af in rsa_free () #19 0xffffffff in ?? () #20 0x00000009 in ?? () #21 0x0821870d in ?? () #22 0x000000dd in ?? () #23 0x08c4c110 in ?? () #24 0x08c35e98 in ?? () #25 0x08136893 in evp_pkey_free () #26 0xffffffff in ?? () #27 0x0000000a in ?? () #28 0x08226017 in ?? () #29 0x00000189 in ?? () #30 0x007e90f0 in free () /lib/libc.so.6 #31 0x00000000 in ?? () (gdb)
how rid of ?? ()
, more precise solution? thank you.
first, getting complete stack trace here not you: any crash inside free
implementation due heap corruption. here have heap corruption glibc has detected , told on console.
knowing where corrupted block being free
d doesn't find block corrupted; use specialized tools valgrind or addresssanitizer that.
second, not getting file/line info because crash happening inside libc.so.6
, , have not installed debuginfo symbols it. how install debuginfo depends on linux distribution, have not told about.
last, reason have "apparently corrupt" stack addresses don't correspond symbols calls coming hand-coded assembly code (from libopenssl.a
), doesn't use frame pointers , doesn't have correct unwind descriptors. gdb needs 1 or other produce correct stack trace.
Comments
Post a Comment