<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
	<channel>
		<title>Boxcounter's blog</title>
		<link>http://www.boxcounter.com/</link>
		<description>人在做, 天在看              boxcounter.com   boxcounter.org    boxcounter[a]boxcounter.org</description>
		<copyright>Copyright (C) 2004 Security Angel Team [S4T] All Rights Reserved.</copyright>
		<generator>SaBlog-X Version 1.6 Build 20080806</generator>
		<lastBuildDate>Thu, 09 Sep 2010 20:23:34 +0000</lastBuildDate>
		<ttl>30</ttl>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=131</guid>
			<title>吐血的ZwEnumerateKey</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>哥本机装的是WDK7600_1，貌似是今年上半年出的，里面关于ZwEnumerateKey的第三个参数是这么说的~</p>
<dl><dt><em>KeyInformationClass</em>  </dt><dd>Specifies a KEY_INFORMATION_CLASS  value that determines the type of information to be received by the  <em>KeyInformation</em> buffer. </dd><dt></dt><dt></dt></dl><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=131" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=131</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2010-08-27 19:04</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=123</guid>
			<title>EventLog</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp;&nbsp; EventLog功能的使用就不多废话了，有不少资料，wdk里提供的源码也有范例。这里主要记一下我编写过程中遇到的一个小、但是很恼人的一个小问题。日志成功写入系统日志数据库了，但是显示不正常，提示：<br />
&nbsp;&nbsp;&nbsp; &ldquo;自 I/O 子系统收到的驱动程序数据包无效。数据在 数据包内。&rdquo;</p>
<p>&nbsp;&nbsp;&nbsp; &hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=123" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=123</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2010-04-07 17:10</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=121</guid>
			<title>卷的文件系统识别、卷的挂载以及路径解析</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp;&nbsp;&nbsp; 前段时间琢磨文件过滤驱动的时候碰到一个棘手的问题，当时挂上wrk内核分析，发现了问题的关键点。分析的过程中明显感觉自己对IoMgr、ObjMgr、Fsd、Volume这些组件的结构关系掌握得很烂，于是最近这几天专门又挂上wrk内核，一点一点的追踪。有了一点收获，记录在这里，备忘。顺便也许会给一些朋友一点点帮助。</p>
<p>&nbsp;&nbsp;&nbsp; &hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=121" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=121</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2010-03-09 20:30</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=112</guid>
			<title>有关 STATUS_INVALID_DEVICE_OBJECT_PARAMETER</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp;&nbsp; 这两天遇到一个问题，记录在这里。<br />
&nbsp;&nbsp;&nbsp; 我有两个FS过滤驱动，这里称它们为 A 和 B，A 在 B 之上，其中 B 是个重定向驱动。下面是问题描述：<br />
&nbsp;&nbsp;&nbsp; A 调用 FltCreateFile 打开 C: 中的某个文件，B收到这个请求后，指定这个请求重定向到 D:，结果 A收到了错误码 STATUS_INVALID_DEVICE_OBJECT_PARAMETER。 挂上 WRK 调试，发现整个调用栈是这样：<br />
<br />
&nbsp;&nbsp;&nbsp; &hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=112" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=112</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-11-15 16:08</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=111</guid>
			<title>堆破坏 和 Special pool</title>
			<author>boxcounter</author>
			<description><![CDATA[<p><br />
&nbsp;&nbsp;&nbsp; 前阵子遇到个堆破坏的BUG，花了一个早上才找到根源，一个低级错误：<br />
&nbsp;&nbsp;&nbsp; 首先我定义了一个变量用于存储进程完整路径：<br />
<br />
&nbsp;&nbsp;&nbsp; UNICODE_STRING usProcessPath = {0, MAX_PATH * sizeof(WCHAR), NULL};<br />
<br />
&nbsp;&nbsp;&nbsp; &hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=111" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=111</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-11-13 09:52</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=110</guid>
			<title>[ZZ] Filter Manager Concepts: Part 1 – FLTP_FRAME</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>Filter Manager's only purpose is to simplify writing file system filters and sometimes it does this by abstracting some of the things that a filter needs to deal with&hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=110" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=110</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-10-19 12:56</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=107</guid>
			<title>关于 sizeof</title>
			<author>boxcounter</author>
			<description><![CDATA[<p><img alt="" src="file:///C:/Users/BOXCOU~1/AppData/Local/Temp/moz-screenshot.png" /><img alt="" src="file:///C:/Users/BOXCOU~1/AppData/Local/Temp/moz-screenshot-1.png" /><a href="http://www.boxcounter.com/attachment.php?id=55" target="_blank"><img src="http://www.boxcounter.com/attachments//date_200909/362b3b00b72e835c5b1870952e027475.jpg" border="0" alt="大小: 7.2 K&#13;尺寸: 231 x 55&#13;浏览: 14 次&#13;点击打开新窗口浏览全图" width="231" height="55" /></a></p>
<p>谁能帮忙解释下，今天调试的时候，windbg同学给的结果。</p>
<p>难道被当成指针了？</p>
<p>补：刚跟robin讨论了下，猜测是MS WDK编译器的解释问题，目前这是唯一靠谱的解释了。</p>
<p>又补：根据robin的提示，用VC试了下，CPP中值就是1，C就是4。应该就是MS C编译器的解释方式了。</p>]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=107</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-09-17 11:52</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=103</guid>
			<title>[ZZ]Tutorial suggestion for newbie</title>
			<author>boxcounter</author>
			<description><![CDATA[<h1 class="ha"><span id=":z2" class="hP">[ntfsd] Tutorial suggestion for newbie</span><span id=":z3">
<table width="531" height="93" cellpadding="0" class="cf hX">
    <tbody>
        <tr class="hY hM">
            <td class="hT hM">&nbsp;</td>
            <td class="hU hM" style="background-color: rgb(32, 108, 255); color: rgb(224, 236, 255);">&nbsp;</td>
            <td class="hS hM" style="background-color: rgb(32, 108, 255);">&nbsp;</td>
            <td class="hV hM" style="background-color: rgb(32, 108, 255);">&nbsp;</td>
            <td class="hW hM">&nbsp;</td>
        </tr>
        <tr class="hR">
            <td class="hT hU hM" style="background-color: rgb(32, 108, 255); color: rgb(224, 236, 255);">&nbsp;</td>
            <td class="hU hM" style="background-color: rgb(32, 108, 255); color: rgb(224, 236, 255);">&nbsp;</td>
            <td class="hS hM" style="background-color: rgb(224, 236, 255);">&nbsp;</td>
            <td class="hV hM" style="background-color: rgb(32, 108, 255); color: rgb(224, 236, 255);">&nbsp;</td>
            <td class="hW hV hM" style="background-color: rgb(32, 108, 255);">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 回家路上看邮件，发现一个很有意思的讨论帖，里面讨论的主要是文件系统相关的驱动开发的东西，包括辛酸苦辣什么的。自己也在这块做了一段时间了，看着这个帖子挺有感触的，于是全贴转载，后续如果有更新，也会补在后头。<br />
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 里面提到了楚狂人的那篇文件过滤驱动的资料，确实挺感谢楚狂人的，能够分享自己的心得，这个文档也给了我不少帮助，真诚的感谢。<br />
            <br />
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 另：别问我为什么要把这段话的背景色弄成这样，哥们也不想的，粘贴过来的时候一不小心复制了一个不知道什么的鸟元素，删不掉，减不走，只好废物利用~</td>
        </tr>
        <tr class="hY hM">
            <td class="hT hM">&nbsp;</td>
            <td class="hU hM" style="background-color: rgb(32, 108, 255); color: rgb(224, 236, 255);">&nbsp;</td>
            <td class="hS hM" style="background-color: rgb(32, 108, 255);">&nbsp;</td>
            <td class="hV hM" style="background-color: rgb(32, 108, 255);">&nbsp;</td>
            <td class="hW hM">&nbsp;</td>
        </tr>
    </tbody>
</table>
</span></h1><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=103" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=103</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-08-21 23:44</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=96</guid>
			<title>驱动中获取进程完整路径名</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>在OSR上无意中看到一篇文章，关于获取进程完整路径的。贴过来，最后有一点小调整。</p>
<p>原文地址：<a href="http://www.osronline.com/article.cfm?id=472">http://www.osronline.com/article.cfm?id=472</a></p>
<p>&hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=96" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=96</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-07-23 18:55</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=89</guid>
			<title>[ZZ] Hooking has its disadvantages!</title>
			<author>boxcounter</author>
			<description><![CDATA[<p><span style="font-size: 12pt; color: rgb(31, 73, 125);">I actually wanted to write on how to hook the SSDT. But then I realized why not give a warning of why you should not do a thing and then go on to actually tell you how to do that wrong thing.<br />
&hellip;&hellip;</span></p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=89" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=89</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-04-08 17:48</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=87</guid>
			<title>[ZT] Do you really need to hook it?</title>
			<author>boxcounter</author>
			<description><![CDATA[<p><span xmlns=""><span style="font-size: 12pt; color: rgb(31, 73, 125);">An evergreen question 'How should I hook...? I want to monitor/ block...' How many of us really look up before asking this question?<br />
&hellip;&hellip;</span></span></p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=87" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=87</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-04-08 17:43</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=85</guid>
			<title>[ZZ] FltLockUserBuffer locks the buffer in CORRECT process context- HOW?</title>
			<author>boxcounter</author>
			<description><![CDATA[<p><span xmlns=""><span style="color: rgb(31, 73, 125); font-size: 12pt;">The WDK documentation says &quot;The caller can be running in any process context. FltLockUserBuffer automatically locks the buffer in the correct process context.&quot; Remember that in our legacy filters we used to call MmProbeAndLockPages in the correct process context to lock the pages?</span></span></p>
<p>&hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=85" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=85</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-04-08 16:54</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=84</guid>
			<title>通过inf安装驱动</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp;&nbsp;&nbsp; 今天遇到个问题，耗了不短的时间，记下来，备份，顺便给遇到同样的问题的朋友一些帮助。<br />
&nbsp;&nbsp;&nbsp;&nbsp; <br />
&nbsp;&nbsp;&nbsp;&nbsp; 用rundll32 通过 inf 文件安装我的驱动的时候，老是会失败。最开始是因为inf有些问题，最后用WDK自带的checkinf检查、修改后，解决。之后又有个问题，rundll32提示&ldquo;安装失败&rdquo;，当时的命令如下：<br />
&hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=84" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=84</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-04-01 13:20</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=83</guid>
			<title>InstallHinfSection</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MS提供的一个函数，MSDN上有详细的，今天琢磨inf文件，网上找了一些，不够详细，于是干脆贴在这里，作为备份，大家请无视。</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=83" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=83</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-03-31 14:03</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=82</guid>
			<title>[ZZ] Creating an INF File for a Minifilter Driver</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>An INF file for a file system minifilter driver generally contains the following sections:</p>
<p>&hellip;&hellip;</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=82" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=82</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-03-31 13:59</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=78</guid>
			<title>[ZZ] Filtering File Systems - Then Things You Should Know</title>
			<author>boxcounter</author>
			<description><![CDATA[<p><font class="tsBody"><span style="font-size: 9pt;">
<p align="justify"><span style="font-family: arial;">Regardless of whether you are  still supporting legacy file system filter drivers, or maintaining or building  new mini-filter drivers, there are some common techniques (ok, there are only  nine?) you can use to improve the robustness of your filter. Many of these are  pragmatic&nbsp;- they are not things you will read in the documentation, they come  from experience working with filters for many, many years.</span></p>
</span><strong><span style="font-size: 12pt;"><span style="font-family: arial;">Never Trust Buffers<br />
</span></span></strong><span style="font-size: 12pt;"><span style="font-family: arial;">&hellip;&hellip;</span></span></font></p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=78" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=78</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2009-03-18 19:30</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=67</guid>
			<title>奇怪的现象</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp;&nbsp;&nbsp; 2个不同文件，2个不同的FO，相同的&ldquo;FCB&rdquo;，相同的SectionObjectPointer，实在是让人费解~</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=67" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=67</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2008-12-01 19:07</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=65</guid>
			<title>有关卡巴对BUG态度的感想</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp; 今年一直在做文件过滤驱动的学习和开发，OSR这个驱动圣地自然是少不了要去学习的，OSR有个功能很赞，如果你同意，它会自动将你加入的版块的每一个帖子及后续回复都以邮件的方式通知给你。这个功能相当方便......</p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=65" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=65</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2008-10-15 18:35</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=50</guid>
			<title>有关符号表</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>WinDbg帮助文档上的一小段：&nbsp;&nbsp;&nbsp;</p>
<p><font color="#3366ff">&nbsp;&nbsp;&nbsp;</font><font color="#0000ff"> <font face="Courier New">All types created by typedefs within your own code will be present......</font></font></p><br /><br /><a href="http://www.boxcounter.com/?action=show&amp;id=50" target="_blank">阅读全文</a><br /><br />]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=50</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2008-08-20 18:52</pubDate>
		</item>
		<item>
			<guid>http://www.boxcounter.com/?action=show&amp;id=44</guid>
			<title>NOBUFFER vs WRITE_THROUGH</title>
			<author>boxcounter</author>
			<description><![CDATA[<p>&nbsp;&nbsp;&nbsp;&nbsp; 根据sinister的提示，用ProcMon追查了不同标志的写、读操作。正好弄清楚了之前自己迷糊的一个地方，看来我还是太懒了，读的资料倒是挺多，经常对着资料冥思苦想，却忘了自己动手试验。一小部分是填鸭式教育养成的习惯，更多的是自己的学习习惯有问题，写在这里，提醒自己。</p>
<p>图1. WRITE_THROUGH方式打开文件，然后写文件</p>
<p><a href="http://www.boxcounter.com/attachment.php?id=20" target="_blank"><img src="http://www.boxcounter.com/attachments/date_200806/thumb_506552f533b9d8bd81d43cca683796c3.jpg" border="0" alt="大小: 6.62 K&#13;尺寸: 500 x 43&#13;浏览: 33 次&#13;点击打开新窗口浏览全图" width="500" height="43" /></a></p>
<p>&nbsp;</p>
<p>图2. NO_BUFFER方式打开文件，然后写文件</p>
<p><a href="http://www.boxcounter.com/attachment.php?id=19" target="_blank"><img src="http://www.boxcounter.com/attachments//date_200806/ccdc6749acf06a973c1420cd2ef75163.jpg" border="0" alt="大小: 3.9 K&#13;尺寸: 307 x 25&#13;浏览: 23 次&#13;点击打开新窗口浏览全图" width="307" height="25" /></a></p>]]></description>
			<link>http://www.boxcounter.com/?action=show&amp;id=44</link>
			<category domain="http://www.boxcounter.com/?cid=5">windows编程(R0)</category>
			<pubDate>2008-06-10 22:19</pubDate>
		</item>
	</channel>
</rss>
