[lkml]   [2010]   [Jan]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: Did we really need to clear the IF flag at prepare_singlestep() of x86 kprobes?
    On Wed, Jan 13, 2010 at 12:06 AM, Arjan van de Ven <> wrote:
    > On Tue, 12 Jan 2010 19:09:35 +0800
    > Dongdong Deng <> wrote:
    >> Hi Kprobe experts,
    >> I have a doubt about the handling "X86_EFLAGS_IF" at
    >> prepare_singlestep(), Could you give me some suggestions?
    > iirc it was a security thing; we used to have some exploits
    > due to the linux-abi entry points which caused a mess, and this
    > was put there as defensive programming.

    Hi Arjan,

    Thanks for your explain. :)

    Do you means that the user will modify the IF? for example: through
    "p->pre_handler(p, regs)" .

    But I couldn't image the affect that if user modify the IF flag, could
    you give me a detail info about security thing?


    Before linux 2.5, the debug tarp was initalized as trap gate:

    linux-2.4.37/arch/i386/kernel/traps.c:966: set_trap_gate(1,&debug);

    I know kprobes have a long history, Is it possible that the interrupt
    flag of kprobes was introduced at that time?


    > I could totally misremember this as well of course.
    > --
    > Arjan van de Ven        Intel Open Source Technology Centre
    > For development, discussion and tips for power savings,
    > visit
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2010-01-13 06:29    [W:0.045 / U:72.152 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site