亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? the boot sector.html

?? 1000 HOWTOs for various needs [WINDOWS]
?? HTML
?? 第 1 頁 / 共 2 頁
字號:
<html>

<head>

<title>The Boot Sector</title>

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

</head>

<body bgcolor="#000000" text="#ffffff" link="#ffffff" vlink="#ffffff">

<div align="center">

<table width="680" border="0" cellspacing="2" cellpadding="2" align="center">

  <tr>

    <td width="693">

      <pre>

                        :::::::::   ::::::::  :::::::::  ::::::::::

                        :+:    :+: :+:    :+: :+:    :+: :+:

                        +:+    +:+ +:+        +:+    +:+ +:+

                        +#++:++#+  +#++:++#++ +#++:++#:  :#::+::#

                        +#+    +#+        +#+ +#+    +#+ +#+

                        #+#    #+# #+#    #+# #+#    #+# #+#

                        #########   ########  ###    ### ###



              	             <a href="http://blacksun.box.sk" target="_blank">http://blacksun.box.sk</a>

              	             <a href="http://awc.rejects.net" target="_blank">http://awc.rejects.net</a>

                           _____________________________

    ______________________I       <b>   Topic:</b>             I_____________________

   \                      I                             I                    /

    \     HTML by:        I      <b>The Boot Sector</b>        I   Written by:     /

    >                     I                             I                  <

   /      <a href="mailto:black_mesa@hacktik.org">Martin L.</a>       I_____________________________I   <a href="mailto:fu@ckz.org">Ralph</a>           \

  /___________________________>                    <_________________________\</pre>

    </td>

  </tr>

</table>

</div>

<p>Version: 1.0 Date: 7/31/00</p>

<h3>TOC</h3>

<ol>

  <li><a href="#1">Introduction</a><ul>

  <li><a href="#1a">What you need</a></li></ul></li>

  <li><a href="2">Basic hard drive/BIOS shit</a></li>

  <li><a href="3">Making a Boot Sector</a></li>

  <li><a href="4">Making a program to write a boot sector</a></li>

  <li><a href="5">Other</a></li>

</ol>

<a name="1"><h3><u>1. Introduction</u></h3>

<blockquote>

<p>Well usually I give you a specific purpose at this point, but in this case I can't.

I was just in the mood to write something on boot sectors so I did it.  And maybe

(hopefully) someone out there can make use of this info.  This thing will most likely

became part of a larger tutorial, maybe something on assembly or on OS design.

After having consumed this text file you should know enough to design and create your

own boot sector, maybe for a virus, or an OS, or...?</a>

</blockquote>

<a name="1a"><h3><u>What you need</u></h3>

<blockquote>

<p>Before reading this you should have a basic knowledge of assembly.  If you don't, read

my other tutorial, it's called Sk00l m3 ASM!!#@$!@# and is available from awc.rejects.net

We will be using 2 different programs to code this shit: NASM and TASM.  NASM is freely

available from <a href="http://www.web-sites.co.uk/nasm/" target="_blank">http://www.web-sites.co.uk/nasm/</a>, but TASM you have to buy.  I don't like

piracy, but if you're just gonna use TASM this once, don't bother spending $150 on it.

There are plenty of sites that have a copy.</p>

<p>Why am I using 2 different programs?  Well I have always used NASM to make simple

programs as it's good at creating efficient memory copies.  I always use TASM to make

programs a bit more complex.  In the end however it comes down to the answer "why not??".

However, it shouldn't be hard at all to make the TASM program in NASM (or the other way

around), just change a few things here and there.  If enough people come bitch to me, I'll

rewrite all the code for NASM/TASM.</p></blockquote>

<a name="2"><h3><u>2. Basic hard drive/BIOS shit</u></h3>

<blockquote>

<p>As soon as you flip that switch, your CPU starts executing shit located at F000:FFF0.

This area contains the BIOS, Basic Input/Output System.  This code is written in assembly

and is stored in chips called EPROMs in your computer.  This code will perform something

known as POST, Power On Self Test.  This checks for installed devices and checks if they

all work.  In particular it checks for the video card and runs the video BIOS usually

located at C000h.  Next it checks for other ROMs to see if they have installed BIOSes.

Usually it then finds and executes the hard drive BIOS located at C8000h.  Then it starts

something like a "system inventory" where it checks for other installed devices and

tests them.  It does some more stuff that's all basicly useless for us right now,

until it finally transfers control over to the operating system.  That's the part that

we're interested in.  Back in the old days, only one OS was installed on a computer.

If you bought a certain computer, you could only run the OS that was made for it.

Nothing else.  Obviosly that wasn't such a good thing as you would have to buy a new

computer if you wanted a different OS, so BIOS makers came up with the Boot Sector.

In case you didn't know yet, a Sector is the smallest area your hard drive can access.

According to the ATA standards each sector is exactly 512 bytes.  However ATA standards

only apply to hard drives, things like floopies can use whatever they want.

Knowing this we can move on to the boot sector.</p>

</blockquote>

<h3><u>3. Making a Boot Sector</u></h3>

<blockquote>

<p>After the BIOS has successfully completed the POST it calls interrupt 19h.  You can

actually see this by dumping the memory located at F000:FFF0.  For example, on my box

I used debug with the following result:<br>

<i>-d f000:fff0</i><br>

F000:FFF0  CD 19 E0 00 F0 31 31 2F-32 36 2F 39 39 00 FC 81   .....11/26/99...</p>

<p>As you should know, CD = INT.  INT 19h attempts to read in the Boot Sector of the 1st

floppy disk.  If it fails it does the same thing on the 1st hard drive.  If that fails

it returns an error message.  A valid boot sector must have its last two bytes set to

AA55h.  Assuming a valid boot sector is found, the code is loaded into memory at location

0000:7C00 and interrupt 19h jumps there to start executing the code.  Since a boot sector

has to fit into one sector (512 bytes) it can't really do much, usually it does a search

for another file on another sector, then executes it.  Our boot sector won't do that.

For now it is enough that it displays a message and reboots when you press a key.  Since

DOS is not loaded yet, we have to use BIOS interupts to do all this.  First we display a

messages using interupt 10h.  Next we wait for the user to press a key using interrupt

16h, and finally we make a FAR jump to FFFF:0000 which we restart the computer.  So lets

code this bitch:</p>

<p>First we use the code</p>

<table>

<tr>

  <td>&nbsp;</td>

  <td>MOV AX,0x0003</td>

</tr>

<tr>

  <td>&nbsp;</td>

  <td>INT 0x10</td>

</tr>

<tr>

  <td colspan="2">to get into video mode.  The registers have to be set up like this:</td>

</tr>

<tr>

  <td>AH</td><td>Function number (00h, video)</td>

</tr>

<tr>

  <td>AL</td><td>Video Mode (03, 80x25x16)</td>

</tr>

<tr>

  <td colspan="2">Next we print the message using:</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV AX,0x1301</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV BX,0x0007</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV CX,0x23</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV BP,MSG</td>

</tr>

<tr>

  <td>&nbsp;</td><td>ADD BP,0x7C00</td>

</tr>

<tr>

  <td>&nbsp;</td><td>INT 0x10</td>

</tr>

<tr>

  <td>AH</td><td>Function number (13h: print string)</td>

</tr>

<tr>

  <td>AL</td><td>Write Mode (01h: string is characters only, attribute in BL, cursor moved)</td>

</tr>

<tr>

  <td>BH</td><td>Video Page number (00h)</td>

</tr>

<tr>

  <td>BL</td><td>Attributes of characters (07h)</td>

</tr>

<tr>

  <td>CX</td><td>Length of string, excluding any attributes (23h = 35 characters)</td>

</tr>

<tr>

  <td>BP</td>

  <td>ES:BP must point to the string, since a boot sector starts at 07C00, we add that

     to BP after we loaded it.  You could also set the entry point of the program to

     07C00, or change the data segment register to point to 07C00, but since it's just

     one instruction, this is fine for now.</td>

</tr>

<tr>

  <td colspan="2">Now we wait for the key to be pressed:</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV AH,0x00</td>

</tr>

<tr>

  <td>&nbsp;</td><td>INT 0x16</td>

</tr>

</table>

<p><b>Registers:</b><br>

AH - 00, Read keyboard buffer, wait till full if not already.<br>

The buffer will be empty since the computer didn't get time to put anything into it yet.

Finally we reboot the computer by simply jumping to 0000:FFFF:</p>

<blockquote>

<p>DB 0xEA<br>

     DW 0x0000<br>

     DW 0xFFFF</p>

</blockquote>

<p>This looks a bit wierd but it's actualy quite simple.  When declaring "variables" in

assembly, the assembler simply puts the value into a memory location.  Usually you

use interrupts or something to point to them in order to use and manipulate them, but we

could also put code there.  This is what we're doing here.  If you get a Hex to Mnemonix

chart you will notice that EA is a Far Jump.  So we put that into memory, followed by

the location to jump to.</p>

<p>Next we fill the the remaining memory with NULL:<br>

<blockquote>

     TIMES 510-($-$$) DB 0</p>

</blockquote>

<p>This could also be done in TASM with something like TIMES 510 DUP (0).

Finally we have to add those two bytes to the end so that the BIOS will know that this is

a valid boot sector. This is done with the simple statement:<br>

<blockquote>

SIGNATURE DW 0xAA55</p>

</blockquote>

<p>Here is the full code to everything we just discussed:</p>

<table>

<tr>

  <td colspan="2"><b>START:</b></td>

</tr>

<tr>

  <td width="25">&nbsp;</td>

  <td>MOV AX,0x0003</td>

</tr>

<tr>

  <td>&nbsp;</td><td>INT 0x10</td>

</tr>

<tr>

  <td colspan="2"><b>PRINT_STRING:</b></td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV AX,0x1301</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV BX,0x0007</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV CX,0x23</td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV BP,MSG</td>

</tr>

<tr>

  <td>&nbsp;</td><td>ADD BP,0x7C00</td>

</tr>

<tr>

  <td>&nbsp;</td><td>INT 0x10</td>

</tr>

<tr>

  <td colspan="2"><b>WAIT_FOR_KEY_PRESS:</b></td>

</tr>

<tr>

  <td>&nbsp;</td><td>MOV AH,0x00</td>

</tr>

<tr>

  <td>&nbsp;</td><td>INT 0x16</td>

</tr>

<tr>

  <td colspan="2"><b>REBOOT:</b></td>

</tr>

<tr>

  <td>&nbsp;</td><td>DB 0xEA</td>

</tr>

<tr>

  <td>&nbsp;</td><td>DW 0x0000</td>

</tr>

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
中国av一区二区三区| 欧美一区二区三区精品| 高清在线不卡av| 国产成人精品三级| 成人免费毛片嘿嘿连载视频| 国内精品伊人久久久久影院对白| 秋霞午夜av一区二区三区| 蜜桃精品在线观看| 国产主播一区二区| 日本二三区不卡| 欧美日韩视频在线观看一区二区三区| 不卡的av电影| 91精品免费观看| 国产精品久久久久久久久免费桃花 | 美女视频一区二区三区| 亚洲h精品动漫在线观看| 国产精品欧美一级免费| 亚洲国产你懂的| 国精产品一区一区三区mba视频| 99综合电影在线视频| 欧美中文字幕不卡| 国产精品午夜在线观看| 视频一区中文字幕| 色琪琪一区二区三区亚洲区| 精品免费视频一区二区| 亚洲一区二区三区在线看| 精品无码三级在线观看视频| 欧美日韩中文一区| 1区2区3区国产精品| 国产激情一区二区三区四区| 欧美精品电影在线播放| 一区二区三区在线视频免费 | 精品久久久久久综合日本欧美| 国产精品网站在线播放| 国产一级精品在线| 欧洲精品中文字幕| wwwwxxxxx欧美| 国产一区二区伦理片| 3d动漫精品啪啪1区2区免费| 亚洲一区二区综合| 欧美性猛片xxxx免费看久爱| 亚洲图片另类小说| 99久久精品免费观看| 国产精品拍天天在线| 国产成人免费xxxxxxxx| 国产免费观看久久| 成人黄色片在线观看| 亚洲欧美偷拍卡通变态| 在线亚洲免费视频| 日韩高清在线一区| 日韩欧美123| 国产精品主播直播| 亚洲欧美激情视频在线观看一区二区三区| 国产精选一区二区三区| 国产精品免费视频网站| 在线观看www91| 精品一二三四区| 亚洲天堂福利av| 欧美日本一区二区在线观看| 一区二区三区.www| 欧美在线观看一区| 狠狠色伊人亚洲综合成人| 国产精品国产三级国产普通话三级 | 久久成人精品无人区| 亚洲欧洲成人自拍| 欧美成人a视频| 在线观看91精品国产入口| 国产一区二区三区四区在线观看| 亚洲美女区一区| 国产午夜亚洲精品羞羞网站| 日本二三区不卡| av电影天堂一区二区在线| 日本免费在线视频不卡一不卡二| 综合色天天鬼久久鬼色| 久久亚洲精精品中文字幕早川悠里 | 欧美日韩国产大片| 欧美日韩免费观看一区三区| 高清在线观看日韩| 一区二区免费视频| 亚洲视频图片小说| 中文字幕一区二区三区精华液| 日韩精品一区二区在线| 欧美日韩的一区二区| 欧美视频三区在线播放| 欧美四级电影网| 91黄色激情网站| 欧美最猛性xxxxx直播| 色综合天天综合网天天狠天天| 不卡视频在线观看| 97国产一区二区| 欧美日韩一区二区在线观看视频| 欧美体内she精视频| 51久久夜色精品国产麻豆| 91精品啪在线观看国产60岁| 欧美一区二区三区四区视频| 欧美mv日韩mv| 欧美激情在线一区二区三区| 中文字幕一区二区三区av| 亚洲一区二区三区国产| 狠狠色丁香婷综合久久| 成人综合在线观看| 欧美日韩久久一区二区| 欧美电影免费观看完整版| 久久精品一区二区三区不卡| 亚洲国产精品成人综合| 国产精品卡一卡二卡三| 婷婷久久综合九色综合绿巨人 | 欧美三级日韩在线| 精品对白一区国产伦| 亚洲一区二区三区三| 国产毛片精品视频| 欧美美女bb生活片| 国产精品美女久久福利网站| 亚洲一区二区三区在线播放| 国产一区二区三区国产| 欧洲亚洲精品在线| 中文成人av在线| 国产裸体歌舞团一区二区| 欧美人成免费网站| 亚洲免费在线电影| 盗摄精品av一区二区三区| 久久只精品国产| 精品无码三级在线观看视频 | 亚洲国产精品一区二区久久 | 中文字幕在线观看一区二区| 欧美精品三级在线观看| 欧美精品一区二区三区蜜桃| 琪琪久久久久日韩精品| 欧美日韩一区二区三区不卡| 国产精品美女久久福利网站| 99re在线精品| 亚洲综合一区二区精品导航| 97久久精品人人做人人爽| 自拍偷自拍亚洲精品播放| 成人h动漫精品| 亚洲在线免费播放| 日韩一级大片在线观看| 国内精品免费在线观看| 欧美极品另类videosde| 99综合电影在线视频| 亚洲午夜精品17c| 欧美电影在线免费观看| 老司机午夜精品99久久| 中文字幕免费不卡在线| 在线欧美日韩国产| 日本怡春院一区二区| 国产精品热久久久久夜色精品三区 | 97久久超碰精品国产| 午夜激情久久久| 欧美成人一区二区三区片免费 | 精品国产免费一区二区三区四区| 久久成人羞羞网站| 一区二区三区免费网站| 91精品国产aⅴ一区二区| 成人aa视频在线观看| 理论电影国产精品| 亚洲国产乱码最新视频| 中文文精品字幕一区二区| 欧美美女黄视频| 色久优优欧美色久优优| 久久精品免费看| 亚洲一二三四在线观看| 国产亚洲欧美中文| 精品久久国产97色综合| 欧美日韩高清一区二区三区| av电影天堂一区二区在线观看| 六月婷婷色综合| 香蕉影视欧美成人| 亚洲国产一区二区三区青草影视 | a亚洲天堂av| 裸体在线国模精品偷拍| 日韩av一级片| 三级欧美在线一区| 蜜臀久久99精品久久久久久9| 亚洲第一成人在线| 久久精品综合网| 国产欧美一区二区精品性| 26uuu亚洲综合色| www国产精品av| 国产日本一区二区| 国产精品色哟哟| 亚洲精品中文字幕乱码三区| 亚洲欧美日韩综合aⅴ视频| 一区二区视频免费在线观看| 中文字幕在线不卡一区| 综合久久久久久久| 五月激情六月综合| 九九精品视频在线看| www.av精品| 欧美一区二区人人喊爽| 欧美videossexotv100| 中日韩av电影| 日韩**一区毛片| 高清不卡在线观看av| 欧美日韩一区二区在线视频| 2024国产精品视频| 亚洲图片欧美综合| 丁香婷婷综合五月| 日韩一级视频免费观看在线| 久久久99久久|