diff options
Diffstat (limited to 'asm/task.s')
| -rw-r--r-- | asm/task.s | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -6,6 +6,8 @@ task_pusha: push $0x8 // code segment push $userfunc + push $0x666 + pusha push %ds @@ -17,13 +19,15 @@ task_pusha: now stack looks like: - param // esp+64 + param // esp+68 returnaddy eflags code segment userfunc + 0x666 + eax // rest by popa ecx edx @@ -40,7 +44,7 @@ task_pusha: */ - mov 64(%esp),%eax // get address of alternative stack where we want to simulate the pusha + mov 68(%esp),%eax // get address of alternative stack where we want to simulate the pusha mov (%esp),%ecx mov %ecx,(%eax) @@ -87,6 +91,9 @@ task_pusha: mov 56(%esp),%ecx mov %ecx,56(%eax) + mov 60(%esp),%ecx + mov %ecx,60(%eax) + pop %gs pop %fs pop %es @@ -97,5 +104,6 @@ task_pusha: pop %eax pop %eax pop %eax + pop %eax ret |
