首页
社区
课程
招聘
求教!!!一句汇编码的实质作用
发表于: 2009-5-20 11:07 5454

求教!!!一句汇编码的实质作用

2009-5-20 11:07
5454
这是一个引导程序的前面几行,1.44M-img文件.
其中的"JMP FAR C031:00007C59"段间跳,究竟作用是什么?那里会是什么?BIOS的什么呢?它完成了什么?
由于是引导程序,没什么可跟踪的,也不会有其它什么程序在内存里,有的只有一个扇区的内容,最大也就是000001FF,
那么这个JMP FAR C031:00007C59着实让我不知去哪儿找资料了.求教高人了!!!


00000000:  EB 48                      JMP     SHORT 0000004A
00000002:  90                         NOP
00000003:  0000                       ADD     [EAX],AL
00000005:  0000                       ADD     [EAX],AL
00000007:  0000                       ADD     [EAX],AL
00000009:  0000                       ADD     [EAX],AL
0000000B:  0000                       ADD     [EAX],AL
0000000D:  0000                       ADD     [EAX],AL
0000000F:  0000                       ADD     [EAX],AL
00000011:  0000                       ADD     [EAX],AL
00000013:  0000                       ADD     [EAX],AL
00000015:  0000                       ADD     [EAX],AL
00000017:  0000                       ADD     [EAX],AL
00000019:  0000                       ADD     [EAX],AL
0000001B:  0000                       ADD     [EAX],AL
0000001D:  0000                       ADD     [EAX],AL
0000001F:  0000                       ADD     [EAX],AL
00000021:  0000                       ADD     [EAX],AL
00000023:  0000                       ADD     [EAX],AL
00000025:  0000                       ADD     [EAX],AL
00000027:  0000                       ADD     [EAX],AL
00000029:  0000                       ADD     [EAX],AL
0000002B:  0000                       ADD     [EAX],AL
0000002D:  0000                       ADD     [EAX],AL
0000002F:  0000                       ADD     [EAX],AL
00000031:  0000                       ADD     [EAX],AL
00000033:  0000                       ADD     [EAX],AL
00000035:  0000                       ADD     [EAX],AL
00000037:  0000                       ADD     [EAX],AL
00000039:  0000                       ADD     [EAX],AL
0000003B:  0000                       ADD     [EAX],AL
0000003D:  0003                       ADD     [EBX],AL
0000003F:  02FF                       ADD     BH,BH
00000041:  0000                       ADD     [EAX],AL
00000043:  8001 00                    ADD     BYTE PTR [ECX],0
00000046:  0000                       ADD     [EAX],AL
00000048:  0008                       ADD     [EAX],CL
0000004A:  FA                         CLI
0000004B:  EB 07                      JMP     SHORT 00000054
0000004D:  F6C2 80                    TEST    DL,80
00000050:  75 02                      JNZ     SHORT 00000054
00000052:  B2 80                      MOV     DL,80
00000054:  EA 597C0000 31C0           JMP     FAR C031:00007C59  '----这句的作用
0000005B:  8ED8                       MOV     DS,AX
0000005D:  8ED0                       MOV     SS,AX
0000005F:  BC 0020FBA0                MOV     ESP,A0FB2000
00000064:  40                         INC     EAX
00000065:  7C 3C                      JL      SHORT 000000A3
00000067:  FF7402 88                  PUSH    DWORD PTR [EDX+EAX-78]
0000006B:  C2 52BE                    RETN    BE52
0000006E:  7F 7D                      JG      SHORT 000000ED
00000070:  E8 3401F6C2                CALL    C2F601A9
00000075:  807454 B4 41               XOR     BYTE PTR [ESP+EDX*2-4C],41
0000007A:  BB AA55CD13                MOV     EBX,13CD55AA
0000007F:  5A                         POP     EDX
00000080:  52                         PUSH    EDX
00000081:  72 49                      JB      SHORT 000000CC
00000083:  81FB 55AA7543              CMP     EBX,4375AA55
00000089:  A0 417C84C0                MOV     AL,[C0847C41]
0000008E:  75 05                      JNZ     SHORT 00000095
00000090:  83E1 01                    AND     ECX,1
00000093:  74 37                      JE      SHORT 000000CC
00000095:  66:8B4C10 BE               MOV     CX,[EAX+EDX-42]
0000009A:  05 7CC644FF                ADD     EAX,FF44C67C
0000009F:  0166 8B                    ADD     [ESI-75],ESP
000000A2:  1E                         PUSH    DS
000000A3:  44                         INC     ESP
000000A4:  7C C7                      JL      SHORT 0000006D
000000A6:  04 10                      ADD     AL,10
000000A8:  00C7                       ADD     BH,AL
000000AA:  44                         INC     ESP
000000AB:  0201                       ADD     AL,[ECX]
000000AD:  0066 89                    ADD     [ESI-77],AH
000000B0:  5C                         POP     ESP
000000B1:  08C7                       OR      BH,AL
000000B3:  44                         INC     ESP
000000B4:  06                         PUSH    ES
000000B5:  0070 66                    ADD     [EAX+66],DH
000000B8:  31C0                       XOR     EAX,EAX
000000BA:  894404 66                  MOV     [ESP+EAX+66],EAX
000000BE:  89440C B4                  MOV     [ESP+ECX-4C],EAX
000000C2:  42                         INC     EDX
000000C3:  CD 13                      INT     13
000000C5:  72 05                      JB      SHORT 000000CC
000000C7:  BB 0070EB7D                MOV     EBX,7DEB7000
000000CC:  B4 08                      MOV     AH,8
000000CE:  CD 13                      INT     13
000000D0:  73 0A                      JNB     SHORT 000000DC
000000D2:  F6C2 80                    TEST    DL,80
000000D5:  0F84 EA00E98D              JE      8DE901C5
000000DB:  00BE 057CC644              ADD     [ESI+44C67C05],BH
000000E1:  FF00                       INC     DWORD PTR [EAX]
000000E3:  66:31C0                    XOR     AX,AX
000000E6:  88F0                       MOV AL, DH
....

000001F8:  0000                       ADD     [EAX],AL
000001FA:  0000                       ADD     [EAX],AL
000001FC:  0000                       ADD     [EAX],AL
000001FE:  55                         PUSH    EBP
000001FF:  AA                         STOS    BYTE PTR ES:[EDI]于 '----结束标志

[培训]内核驱动高级班,冲击BAT一流互联网大厂工作,每周日13:00-18:00直播授课

收藏
免费 0
支持
分享
最新回复 (8)
雪    币: 337
活跃值: (74)
能力值: ( LV9,RANK:140 )
在线值:
发帖
回帖
粉丝
2
结帖!谢谢论坛提供一方空间让大家交流.
2009-5-20 11:20
0
雪    币: 2067
活跃值: (82)
能力值: ( LV9,RANK:180 )
在线值:
发帖
回帖
粉丝
3
f-.- 这里也发? 别人要看.

BIOS会将Boot磁区载入内存 0000:7C00 处执行
所以用你这个列表来看等于是跳到 00000059

你应该用 16bit 的 debug 看, 如下才对:
0000:7C54 EA597C0000    JMP     0000:7C59
0000:7C59 31C0          XOR     AX,AX
0000:7C5B 8ED8          MOV     DS,AX
0000:7C5D 8ED0          MOV     SS,AX
0000:7C5F BC0020        MOV     SP,2000
0000:7C62 FB            STI
0000:7C63 A0407C        MOV     AL,[7C40]
0000:7C66 3CFF          CMP     AL,FF
0000:7C68 7402          JZ      7C6C
0000:7C6A 88C2          MOV     DL,AL
0000:7C6C 52            PUSH    DX
0000:7C6D BE7F7D        MOV     SI,7D7F
2009-5-20 11:27
0
雪    币: 1556
活跃值: (310)
能力值: ( LV4,RANK:40 )
在线值:
发帖
回帖
粉丝
4
org 7c00
2009-5-20 12:20
0
雪    币: 10
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
5
真是厉害,努力学习中
2009-5-20 18:38
0
雪    币: 1450
活跃值: (35)
能力值: (RANK:680 )
在线值:
发帖
回帖
粉丝
6
应该用系统自带16位Debug来看, 正点.
好好体会下实模式吧
2009-5-20 23:51
0
雪    币: 70
活跃值: (74)
能力值: ( LV4,RANK:50 )
在线值:
发帖
回帖
粉丝
7
这个很雷人滴说。。。。
2009-5-21 08:07
0
雪    币: 208
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
8
c000:7f69 应该是显卡BIOS的地址范围
2009-5-21 09:01
0
雪    币: 202
活跃值: (10)
能力值: ( LV2,RANK:10 )
在线值:
发帖
回帖
粉丝
9
3楼正解!
33c0,是 xor ax,ax.后面的是MOV     DS,AX ......。
找个软盘、或硬盘的MBR源码看看。
2009-5-21 16:36
0
游客
登录 | 注册 方可回帖
返回
//