📄 656.html
字号:
<br>
-a<br>
2039:0100 MOV AX,0201<br>
2039:0103 MOV BX,1000<br>
2039:0106 MOV CX,0209<br>
2039:0109 MOV DX,0080<br>
2039:010C INT 13<br>
2039:010E INT 20<br>
2039:0110 <br>
-g<br>
Program terminated normally<br>
-d 1000<br>
2039:1000 C9 81 01 00 02 00 02 00-36 9F 00 00 04 07 00 05 ........6.......<br>
2039:1010 07 00 06 07 00 07 07 00-08 07 00 09 07 00 0A 07 ................<br>
2039:1020 00 0B 07 00 0C 07 00 0D-07 00 0E 07 00 00 00 00 ................<br>
2039:1030 00 00 00 00 DA 83 C5 35-7C 22 A5 2B 37 4B 32 33 .......5|".+7K23<br>
2039:1040 FD 41 16 00 02 00 15 00-00 12 00 00 2D 07 00 B8 .A..........-...<br>
2039:1050 17 00 78 1A 00 68 83 00-28 9E 00 00 00 00 00 00 ..x..h..(.......<br>
2039:1060 00 00 00 00 00 00 00 00-00 00 00 00 00 00 00 00 ................<br>
2039:1070 00 00 00 00 2A 31 C1 35-C7 83 C5 35 C7 83 C5 35 ....*1.5...5...5<br>
<br>
<br>
<br>
偏移1040H至107FH正是 /etc 目录的 i-node 。我们把它的数据块也读出来。先读第一个数据块。将2D0700H代入公式,算出 /etc第一个数据块物理地址是3柱面50头27扇。<br>
<br>
-a<br>
2039:0100 MOV AX,0201<br>
2039:0103 MOV BX,1000<br>
2039:0106 MOV CX,031B<br>
2039:0109 MOV DX,3280<br>
2039:010C INT 13<br>
2039:010E INT 20<br>
2039:0110 <br>
-g<br>
Program terminated normally<br>
-d 1000<br>
2039:1000 22 00 2E 00 00 00 00 00-00 00 00 00 00 00 00 00 "...............<br>
2039:1010 02 00 2E 2E 00 00 00 00-00 00 00 00 00 00 00 00 ................<br>
2039:1020 23 00 54 49 4D 45 5A 4F-4E 45 00 00 00 00 00 00 #.TIMEZONE......<br>
2039:1030 24 00 62 61 64 74 72 6B-00 00 00 00 00 00 00 00 $.badtrk........<br>
2039:1040 25 00 62 63 68 65 63 6B-72 63 00 00 00 00 00 00 %.bcheckrc......<br>
2039:1050 26 00 64 65 66 61 75 6C-74 00 00 00 00 00 00 00 &.default.......<br>
2039:1060 2B 00 64 69 76 76 79 00-00 00 00 00 00 00 00 00 +.divvy.........<br>
2039:1070 2C 00 64 6B 69 6E 69 74-00 00 00 00 00 00 00 00 ,.dkinit........<br>
-d<br>
2039:1080 2D 00 65 6D 75 6C 61 74-6F 72 00 00 00 00 00 00 -.emulator......<br>
2039:1090 2D 00 65 6D 75 6C 61 74-6F 72 2E 6D 73 00 00 00 -.emulator.ms...<br>
2039:10A0 2E 00 66 64 69 73 6B 00-00 00 00 00 00 00 00 00 ..fdisk.........<br>
2039:10B0 2F 00 66 73 63 6B 00 00-00 00 00 00 00 00 00 00 /.fsck..........<br>
2039:10C0 30 00 66 73 63 6D 64 2E-64 00 00 00 00 00 00 00 0.fscmd.d.......<br>
2039:10D0 37 00 66 73 73 74 61 74-00 00 00 00 00 00 00 00 7.fsstat........<br>
2039:10E0 38 00 67 72 6F 75 70 00-00 00 00 00 00 00 00 00 8.group.........<br>
2039:10F0 39 00 68 61 6C 74 73 79-73 00 00 00 00 00 00 00 9.haltsys.......<br>
-d<br>
2039:1100 39 00 72 65 62 6F 6F 74-00 00 00 00 00 00 00 00 9.reboot........<br>
2039:1110 3A 00 68 64 62 6F 6F 74-30 00 00 00 00 00 00 00 :.hdboot0.......<br>
2039:1120 3B 00 68 64 62 6F 6F 74-31 00 00 00 00 00 00 00 ;.hdboot1.......<br>
2039:1130 3C 00 69 6E 69 74 00 00-00 00 00 00 00 00 00 00 <.init..........<br>
2039:1140 AD 13 69 6E 69 74 74 61-62 00 00 00 00 00 00 00 ..inittab.......<br>
2039:1150 3E 00 69 6F 63 74 6C 2E-73 79 73 63 6F 6E 00 00 >.ioctl.syscon..<br>
2039:1160 3F 00 6D 61 73 74 65 72-62 6F 6F 74 00 00 00 00 ?.masterboot....<br>
2039:1170 40 00 6D 6B 66 73 00 00-00 00 00 00 00 00 00 00 @.mkfs..........<br>
-d<br>
2039:1180 41 00 6D 6B 6E 6F 64 00-00 00 00 00 00 00 00 00 A.mknod.........<br>
2039:1190 42 00 6D 6F 75 6E 74 61-6C 6C 00 00 00 00 00 00 B.mountall......<br>
2039:11A0 0C 02 70 61 73 73 77 64-00 00 00 00 00 00 00 00 ..passwd........<br>
2039:11B0 44 00 70 69 70 65 00 00-00 00 00 00 00 00 00 00 D.pipe..........<br>
2039:11C0 45 00 73 63 73 69 62 61-64 62 6C 6B 00 00 00 00 E.scsibadblk....<br>
2039:11D0 46 00 73 65 74 6D 6E 74-00 00 00 00 00 00 00 00 F.setmnt........<br>
2039:11E0 47 00 73 77 61 70 00 00-00 00 00 00 00 00 00 00 G.swap..........<br>
2039:11F0 48 00 74 74 79 74 79 70-65 00 00 00 00 00 00 00 H.ttytype.......<br>
<br>
<br>
<br>
偏移11A0H至11AFH是 /etc 目录下的passwd文件名。我们把它改成zls。<br>
<br>
-e 11a2<br>
2039:11A2 70.7a 61.6c 73.73 73.00 77.00 64.00<br>
-a 100<br>
2039:0100 MOV AX,0301<br>
2039:0103<br>
-g<br>
Program terminated normally<br>
<br>
<br>
<br>
现在退出DEBUG命令。<br>
<br>
取出软盘,重启机器,引导UNIX操作系统。<br>
<br>
按照引导顺序,UNIX显示出硬件配置信息后就该提问超级用户口令了,但就在此时它却突然发现 /etc/passwd 文件失踪了!(其实只是被改名为zls,但UNIX对此一无所知。)<br>
<br>
没有了这个文件,UNIX无法提问超级用户口令,于是它只好在屏幕上显示如下信息并允许用户以系统管理员身份直接进入系统维护态:<br>
<br>
su: Unknown id: root<br>
/etc/tcbck: file /etc/passwd is missing or zero length<br>
/etc/tcbck: either slash (/) is missing <br>
from /etc/auth/system/files or there<br>
are malformed entries in /etc/passwd or /etc/group<br>
/etc/smmck: restore missing files from backup or distribution.<br>
INIT: SINGLE USER MODE<br>
**** PASSWORD FILE MISSING! ****<br>
Entering System Maintenance Mode<br>
#<br>
<br>
<br>
<br>
现在既然已经进入维护态,当然就可以“为所欲为”了。但最好先设置一个新的超级用户口令。<br>
<br>
首先,我们必须恢复passwd文件名。<br>
<br>
#mv/etc/zls /etc/passwd<br>
<br>
<br>
<br>
然后,就可以用passwd命令设置新的超级用户口令了。<br>
<br>
# passwd<br>
Setting password for user: root<br>
Choose password<br>
You can choose whether you pick a password,<br>
or have the system create one for you.<br>
1. Pick a password<br>
2. Pronounceable password will be generated for you<br>
<br>
Enter choice (default is 1): 1<br>
Please enter new password:<br>
New password:<br>
Re-enter password:<br>
# reboot<br>
<br>
<br>
<br>
以后就可以用新口令登录系统了。<br>
<br>
结束语<br>
<br>
在本文行将结束时,我们再来作一个小小的总结。<br>
<br>
传统方案有操作平台、操作工具和操作对象局限性。新方案则突破了这三大局限性。<br>
<br>
一、新方案突破了操作平台局限性。传统方案的操作平台必须是UNIX,而新方案则是DOS。DOS比UNIX普及得多,中国的绝大部分计算机用户对UNIX陌生,但对DOS却相当熟悉,使用起来也有亲切感。<br>
<br>
二、新方案突破了操作工具局限性。传统方案的操作工具必须是两张紧急启动软盘,而新方案仅使用一张DOS系统盘,其上只需拷贝一个DEBUG.EXE文件。紧急启动软盘只能专盘专用,DOS系统盘却不存在这个问题 —— 用任何一台机器上的DOS制作出的系统盘,可以用来解决任何一台机器上的UNIX超级用户口令被忘记的问题。至于用来访问物理硬盘的软件,当然更不是非 DEBUG不可,任何软件——只要支持访问物理盘——均<br>
<br>
可。作者推荐使用Norton 8.0 软件包里的diskedit程序,对不懂汇编语言编程的人来说该程序无疑是一个最好的选择。<br>
<br>
三、新方案突破了操作对象局限性。传统方案的操作对象是文件系统管理下的文件,而新方案撇开了文件系统,直接在底层修改数据。<br>
<br>
最后需要强调的是,本文的要旨所在绝非仅仅体现在解决超级用户口令被遗忘的问题上。事实上,利用这种直接读取硬盘物理扇区的方法,还可以恢复那些在UNIX上被误删除的文件。<br>
<br>
关于这一点,如果有机会,作者会加以适当的补充。<br>
<br>
【作者简介】<br>
<br>
张雷生,1973年生,1995年毕业分配至电子部15所,2000年加盟北京东方龙马信息产业有限公司,2001年任东方龙马防火墙研发中心技术部经理。长期从事UNIX操作系统的深层技术支援和网络安全技术研究工作,擅长网络安全整体解决方案的设计和产品实施过程中的troubleshooting。<br>
[返回列表]
</FONT><br>
</TD>
</TR>
<TR>
<TD colSpan=2><FONT
class=middlefont></FONT><BR>
<FONT
class=normalfont>全文结束</FONT> </TD>
</TR>
<TR>
<TD background="images/dot.gif" tppabs="http://www.linuxhero.com/docs/images/dot.gif" colSpan=2
height=10></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></DIV></TD>
<TD vAlign=top width="20%"
background="images/line.gif" tppabs="http://www.linuxhero.com/docs/images/line.gif" rowSpan=2>
<DIV align=center>
<table class=tableoutline cellspacing=1 cellpadding=4
width="100%" align=center border=0>
<tr class=firstalt>
<td noWrap background="images/bgline.gif" tppabs="http://www.linuxhero.com/docs/images/bgline.gif" colspan=2 height=21>
<font class=normalfont><b>所有分类</b></font></td>
</tr>
<tr class=secondalt> <td noWrap width=27%> <font class=normalfont>1:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type1.html" tppabs="http://www.linuxhero.com/docs/type1.html">非技术类</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>2:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type2.html" tppabs="http://www.linuxhero.com/docs/type2.html">基础知识</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>3:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type3.html" tppabs="http://www.linuxhero.com/docs/type3.html">指令大全</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>4:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type4.html" tppabs="http://www.linuxhero.com/docs/type4.html">shell</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>5:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type5.html" tppabs="http://www.linuxhero.com/docs/type5.html">安装启动</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>6:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type6.html" tppabs="http://www.linuxhero.com/docs/type6.html">xwindow</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>7:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type7.html" tppabs="http://www.linuxhero.com/docs/type7.html">kde</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>8:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type8.html" tppabs="http://www.linuxhero.com/docs/type8.html">gnome</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>9:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type9.html" tppabs="http://www.linuxhero.com/docs/type9.html">输入法类</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>10:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type10.html" tppabs="http://www.linuxhero.com/docs/type10.html">美化汉化</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>11:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type11.html" tppabs="http://www.linuxhero.com/docs/type11.html">网络配置</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>12:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type12.html" tppabs="http://www.linuxhero.com/docs/type12.html">存储备份</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>13:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type13.html" tppabs="http://www.linuxhero.com/docs/type13.html">杂项工具</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>14:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type14.html" tppabs="http://www.linuxhero.com/docs/type14.html">编程技术</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>15:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type15.html" tppabs="http://www.linuxhero.com/docs/type15.html">网络安全</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>16:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type16.html" tppabs="http://www.linuxhero.com/docs/type16.html">内核技术</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>17:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type17.html" tppabs="http://www.linuxhero.com/docs/type17.html">速度优化</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>18:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type18.html" tppabs="http://www.linuxhero.com/docs/type18.html">apache</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>19:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type19.html" tppabs="http://www.linuxhero.com/docs/type19.html">email</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>20:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type20.html" tppabs="http://www.linuxhero.com/docs/type20.html">ftp服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>21:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type21.html" tppabs="http://www.linuxhero.com/docs/type21.html">cvs服务</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>22:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type22.html" tppabs="http://www.linuxhero.com/docs/type22.html">代理服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>23:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type23.html" tppabs="http://www.linuxhero.com/docs/type23.html">samba</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>24:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type24.html" tppabs="http://www.linuxhero.com/docs/type24.html">域名服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>25:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type25.html" tppabs="http://www.linuxhero.com/docs/type25.html">网络过滤</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>26:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type26.html" tppabs="http://www.linuxhero.com/docs/type26.html">其他服务</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>27:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type27.html" tppabs="http://www.linuxhero.com/docs/type27.html">nfs</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>28:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type28.html" tppabs="http://www.linuxhero.com/docs/type28.html">oracle</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>29:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type29.html" tppabs="http://www.linuxhero.com/docs/type29.html">dhcp</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>30:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type30.html" tppabs="http://www.linuxhero.com/docs/type30.html">mysql</a></font></td> </tr> </table></td></tr><tr class=secondalt> <td noWrap width=27%> <font class=normalfont>31:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type31.html" tppabs="http://www.linuxhero.com/docs/type31.html">php</a></font></td> </tr> </table></td></tr><tr class=firstalt> <td noWrap width=27%> <font class=normalfont>32:</font> </td><td noWrap width=73%> <table width=100% border=0> <tr> <td><font class=normalfont><a href="type32.html" tppabs="http://www.linuxhero.com/docs/type32.html">ldap</a></font></td> </tr> </table></td></tr> </table>
</DIV></TD></TR>
<TR vAlign=top>
<TD width="80%">
<DIV align=center><BR>
</DIV>
</TD></TR></TBODY></TABLE></TD></TR>
</TABLE></TD></TR>
</TABLE>
<TABLE cellSpacing=0 cellPadding=4 width="100%" bgColor=#eeeeee
border=0><TBODY>
<TR>
<TD width="50%">
<P><FONT class=middlefont>版权所有 © 2004 <A
href="mailto:bjchenxu@sina.com">linux知识宝库</A><BR>
违者必究. </FONT></P>
</TD>
<TD width="50%">
<DIV align=right><FONT class=middlefont>Powered by: <A
href="mailto:bjchenxu@sina.com">Linux知识宝库</A> Version 0.9.0 </FONT></DIV>
</TD></TR></TBODY></TABLE>
<CENTER></CENTER></TD></TR>
</TABLE></CENTER></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -