1 |
On Tue, 20 Jul 2004 01:32:56 +0200 |
2 |
pageexec@××××××××.hu wrote: |
3 |
|
4 |
> > same again, with CFLAGS="-fno-stack-protector-all |
5 |
> > -fno-stack-protector-fno-pie -g -ggdb -fno-omit-frame-pointer" |
6 |
> > FEATURES="nostrip" as suggested: |
7 |
> |
8 |
> i guess that's because the sigsegv occurs in glibc or ld.so, so you'd |
9 |
> have to emerge glibc again without stripping it (which is a good idea |
10 |
> anyway when you have to troubleshoot a system). |
11 |
> |
12 |
> > warning: exec file is newer than core file. |
13 |
> |
14 |
> looks like this core file was generated previously, so that can also |
15 |
> contribute for gdb not matching the addresses, try again with ulimit |
16 |
> -c unlimited. |
17 |
> |
18 |
> > (gdb) x/8i $pc |
19 |
> > 0x40014dce: Cannot access memory at address 0x40014dce |
20 |
> |
21 |
> hmm, did you run cpufreqd from within gdb as i suggested? |
22 |
> |
23 |
> |
24 |
> -- |
25 |
> gentoo-hardened@g.o mailing list |
26 |
> |
27 |
|
28 |
Sorry, bit confused, I've never used gdb before so bear with me. Erm, I |
29 |
was using cpufreqd with -fno-pie etc. so then it was working, and |
30 |
specifying an old core, guess that doesn't help... I've recompiled |
31 |
without -fno-stack-protector -no-pie etc. but with debugging and run it |
32 |
within gdb (without specifying a core file, starting with 'gdb |
33 |
/usr/sbin/cpufreqd'), hopefully this helps more: |
34 |
|
35 |
(gdb) run cpufreqd |
36 |
Starting program: /usr/sbin/cpufreqd cpufreqd |
37 |
warning: Unable to find dynamic linker breakpoint function. |
38 |
GDB will be unable to debug shared library initializers |
39 |
and track explicitly loaded dynamic code. |
40 |
Warning: |
41 |
Cannot insert breakpoint -2. |
42 |
Error accessing memory address 0x16b0: Input/output error. |
43 |
|
44 |
(gdb) bt |
45 |
#0 0x256b9800 in ?? () |
46 |
(gdb) info registers |
47 |
No selected frame. |
48 |
(gdb) x/8i $pc |
49 |
0x256b9800: mov %esp,%eax |
50 |
0x256b9802: call 0x256b983d |
51 |
0x256b9807: mov %eax,%edi |
52 |
0x256b9809: call 0x256b97f0 |
53 |
0x256b980e: add $0x12d72,%ebx |
54 |
0x256b9814: mov 0xfffffef0(%ebx),%eax |
55 |
0x256b981a: pop %edx |
56 |
0x256b981b: lea (%esp,%eax,4),%esp |
57 |
(gdb) x/16x $sp |
58 |
0x5d900310: 0x00000002 0x5d900431 0x5d900444 |
59 |
0x00000000 0x5d900320: 0x5d90044d 0x5d900475 0x5d9004de |
60 |
0x5d9004eb 0x5d900330: 0x5d9004f6 0x5d900506 0x5d900510 |
61 |
0x5d90051e 0x5d900340: 0x5d900532 0x5d900554 |
62 |
0x5d900573 0x5d9005e0 |
63 |
|
64 |
|
65 |
So it will help to recompile glibc with nostrip etc.? Thanks again, |
66 |
|
67 |
Barry |
68 |
|
69 |
-- |
70 |
gentoo-hardened@g.o mailing list |