在内核调试模式下连接到目标机器时无法中断

2024-02-01

我正在启动一个包含 Windows 微过滤器的原型。 我已经设置好了我的环境:

  • 目标虚拟机(实际上是 3 个:Windows 7、8 和 8.1)
  • 主机开发计算机(托管 Visual Studio 2013 和 HyperV VM)

我终于设法将测试微过滤器部署到目标机器,但我的问题是:

我无法破坏目标机器中的内核。

当我进行构建并从 Visual Studio 调试器启动时,结果如下:

    -----------------------------------------------------------------------
-----------------------------------------------------------------------
                  Starting New Debugger Session         
-----------------------------------------------------------------------
-----------------------------------------------------------------------

Microsoft (R) Windows Debugger Version 6.3.9600.16384 AMD64
Copyright (c) Microsoft Corporation. All rights reserved.

MONTLUC\pascal (npipe WinIDE_01CED6303D19BD92) connected at Thu Oct 31 12:56:31 2013

Microsoft (R) Windows Debugger Version 6.3.9600.16384 AMD64
Copyright (c) Microsoft Corporation. All rights reserved.

Waiting for pipe \\montlucw81x64\pipe\dbg
Waiting to reconnect...
[12:56:32:860]: Removing any existing files from the remote driver folder
[12:56:33:121]: Removing any existing files from test execution folder

te.exe "%SystemDrive%\DriverTest\Run\DriverTestTasks.dll" /select:"@Name='DriverTestTasks::_DriverRemoval'" /p:"InfFile=passThrough.inf" /p:"Debug=1" /p:"ImportDriver=1" /p:"RemoveDriver=1" /p:"CertificateFile=package.cer" /p:"PackageGuid={A23BA0FC-7265-4E3C-B99F-1E7A04AD970D}" /rebootStateFile:%SystemDrive%\DriverTest\Logs\DriverTestReboot.xml /enableWttLogging /wttDeviceString:$LogFile:file="%SystemDrive%\DriverTest\Logs\Driver_Removal_(x64)_(possible_reboot)_00060.wtl",writemode=append,encoding=unicode,nofscache=true,EnableLvl="WexStartTest|WexEndTest|WexXml|WexProperty|WexCreateContext|WexCloseContext|*" /runas:Elevated
[12:56:56:926]: Result Summary: Total=1, Passed=1, Failed=0, Blocked=0, Warned=0, Skipped=0
[12:56:57:457]: Removing any existing files from test execution folder

te.exe "%SystemDrive%\DriverTest\Run\DriverTestTasks.dll" /select:"@Name='DriverTestTasks::_DriverPreparation'" /p:"InfFile=passThrough.inf" /p:"Debug=1" /p:"ImportDriver=1" /p:"RemoveDriver=1" /p:"CertificateFile=package.cer" /p:"PackageGuid={A23BA0FC-7265-4E3C-B99F-1E7A04AD970D}" /rebootStateFile:%SystemDrive%\DriverTest\Logs\DriverTestReboot.xml /enableWttLogging /wttDeviceString:$LogFile:file="%SystemDrive%\DriverTest\Logs\Driver_Preparation_(x64)_(possible_reboot)_00060.wtl",writemode=append,encoding=unicode,nofscache=true,EnableLvl="WexStartTest|WexEndTest|WexXml|WexProperty|WexCreateContext|WexCloseContext|*" /runas:Elevated
[12:57:00:437]: Result Summary: Total=1, Passed=1, Failed=0, Blocked=0, Warned=0, Skipped=0
[12:57:00:893]: Removing any existing files from test execution folder

te.exe "%SystemDrive%\DriverTest\Run\DriverTestTasks.dll" /select:"@Name='DriverTestTasks::_RunProcess'" /p:"BinaryPath=rundll32" /p:"Arguments=setupapi,InstallHinfSection DefaultInstall 132 C:\DriverTest\Drivers\passthrough.inf" /p:"ExitCodes=0" /p:"WorkingFolder=%SystemDrive%\DriverTest\Drivers" /p:"LogOutput=1" /rebootStateFile:%SystemDrive%\DriverTest\Logs\DriverTestReboot.xml /enableWttLogging /wttDeviceString:$LogFile:file="%SystemDrive%\DriverTest\Logs\Driver_Install_(x64)_(possible_reboot)_00025.wtl",writemode=append,encoding=unicode,nofscache=true,EnableLvl="WexStartTest|WexEndTest|WexXml|WexProperty|WexCreateContext|WexCloseContext|*" /runas:Elevated
[12:57:03:916]: Result Summary: Total=1, Passed=1, Failed=0, Blocked=0, Warned=0, Skipped=0
[12:57:04:418]: Removing any existing files from test execution folder

te.exe "%SystemDrive%\DriverTest\Run\DriverTestTasks.dll" /select:"@Name='DriverTestTasks::_DriverPostInstall'" /rebootStateFile:%SystemDrive%\DriverTest\Logs\DriverTestReboot.xml /enableWttLogging /wttDeviceString:$LogFile:file="%SystemDrive%\DriverTest\Logs\Driver_Post_Install_Actions_(x64)_(possible_reboot)_00060.wtl",writemode=append,encoding=unicode,nofscache=true,EnableLvl="WexStartTest|WexEndTest|WexXml|WexProperty|WexCreateContext|WexCloseContext|*" /runas:Elevated
[12:57:06:139]: Result Summary: Total=1, Passed=1, Failed=0, Blocked=0, Warned=0, Skipped=0
[12:57:06:564]: Driver Installation summary:
[12:57:06:566]:   Driver Removal (x64) (possible reboot): Pass
[12:57:06:571]:   Driver Preparation (x64) (possible reboot): Pass
[12:57:06:578]:   Driver Install (x64) (possible reboot): Pass
[12:57:06:586]:   Driver Post Install Actions (x64) (possible reboot): Pass

当我尝试打破时,什么也没有发生。

当我直接附加到内核时(使用 VS 菜单“调试”->“附加到进程”->“内核调试”->“附加”,我得到以下信息:

-----------------------------------------------------------------------
-----------------------------------------------------------------------
                  Starting New Debugger Session         
-----------------------------------------------------------------------
-----------------------------------------------------------------------

Microsoft (R) Windows Debugger Version 6.3.9600.16384 AMD64
Copyright (c) Microsoft Corporation. All rights reserved.

MONTLUC\pascal (npipe WinIDE_01CED630A522D2F5) connected at Thu Oct 31 12:59:26 2013

Microsoft (R) Windows Debugger Version 6.3.9600.16384 AMD64
Copyright (c) Microsoft Corporation. All rights reserved.

Waiting for pipe \\montlucw81x64\pipe\dbg
Waiting to reconnect...

但同样,不可能打破。

我试过 :

  • 所有目标主机(Windows 7、8 和 8.1)并得到相同的结果(是的,所有这些都已正确配置为内核调试)
  • 使用网络而不是命名管道
  • 使用 WinDBG 代替 Visual Studio

但我总是得到相同的结果:不可能破坏这个!@#内核!

谷歌不是我的朋友,我找不到任何类似的问题。

所以现在我想知道:

  • 不管调试器怎么说(但部署有效),我实际上是否可以连接到目标计算机?
  • HyperV 和内核调试是否有问题?

任何想法欢迎!


Edit:我用真实的目标机器而不是虚拟的机器进行了测试,我也遇到了同样的问题,所以这与Hyper-V无关。


我解决了我的问题(我很糟糕,所以我是)

简而言之,以下是两台机器必须如何配置以进行内核调试。

A. 目标机器(Hyper-V VM)

  • 在串行 COM1 上配置内核调试(使用 msconfig 是最简单的方法)
  • 配置 Hyper-V 计算机以通过管道将 COM1 连接到命名管道(例如 \.\pipe\debug)

B. 源计算机(托管目标的 Hyper-V 主机)

  • 在管理模式下运行 WinDBG 或 VS(这是我的第一个错误)
  • 连接到具有完全相同名称的命名管道(\.\pipe\debug)(这是我的第二个错误,我认为机器名称必须是实际的目标名称)

它工作得很好,在 Visual Studio 2013 下有很好的集成。 感谢所有回答的人(没有人)......以及所有其他阅读的人:)

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

在内核调试模式下连接到目标机器时无法中断 的相关文章

随机推荐

  • 使用 PhantomJS 运行 RequireJS/WireJS 应用程序

    我正在尝试执行一个使用 RequireJS 2 1 8 WireJS 0 10 2 和 PhantomJS 1 9 2 的基本应用程序 当使用 PhantomJS 运行应用程序时 这是我的目标 WireJS 无法加载 请参见下面的错误 使用
  • 中心导航栏链接没有品牌将其推到 Bootstrap 4 的右侧?

    我试图将我的导航栏链接居中 但是当我这样做时 我的品牌徽标将其推到右侧 因此它不居中 这是我的 html
  • AngularJS - 将 $resource.query 与 params 对象一起使用

    我正在尝试接起angular js http angularjs org并致力于找出一些记录较少的事情 考虑一下 我在服务器上有一个搜索方法 它接受查询参数并返回搜索结果的集合 并响应GET search json路线 Rails FWIW
  • Ag-grid:使用 AggFunc 时如何更改定义列标题名称?

    对于给定的列定义 当使用 aggFunc 时 headerName 以 func string 格式显示 我只希望标题显示我定义的字符串 当 AggFunc 为 null 时 此行为不存在 const columnDef any heade
  • 使 Appen 功能在 Google 谷歌表格/[重复]中运行得更快

    这个问题在这里已经有答案了 我有一个代码工作正常但没有优化 我是 Google App 脚本的新手 该代码执行以下操作 从外部URL获取数据 过滤数据 解析文件夹中包含的工作表中的数据 更改列标题 在特定列中附加内容 function my
  • PostgreSQL - 按 UUID 版本 1 时间戳排序

    我在用UUID版本1 https en wikipedia org wiki Universally unique identifier Version 1 date time and MAC address 作为主键 我想按 UUID v
  • 如何在 SwiftUI AttributedString 中渲染 Markdown 标题?

    我一直在尝试使用新的属性字符串 https developer apple com documentation foundation attributedstring随 iOS 15 一起发布 用于渲染存储在变量中的 Markdown 但是
  • 在 MVC 中使用 dotnet core 时如何删除 ErrorViewModel

    如果 ErrorViewModel 从我的项目中删除 它将无法运行 失败于app UseMvc 出现错误 System TypeLoadException 无法加载类型 程序集 DocumentGenerationService 版本 1
  • SED 更改标签之间的值

    我在 UNIX 上有这样的日志文件 start host1 java serv host1 def java es dev L2 1 dev w fr host1 def java es dev L3 0 dev w fr host1 de
  • 扫描线算法 - 一维平面的实现

    问题很简单 平面上有一些给定的一维线 我们需要找到至少有一行的空间的总大小 让我用一个示例图像来讨论这个问题 这可能是一个案例 Or 这可能是一个案例或类似的东西 我知道这是一个基本问题扫线算法 https en wikipedia org
  • 全屏显示时 Flex 中的文本输入字段不起作用

    大家好 我有一个问题 如果我的应用程序是全屏的 我无法单击任何文本输入组件 也无法在字段中输入任何文本 我尝试过在运行时创建文本输入字段 并且尝试在 Flex 构建器的 GUI 设计窗口上时在画布上创建它们 然而 它们都给出相同的结果 并且
  • 将 IO Int 转换为 Int

    我通过转换创建了一个组合框xmlWidget to a comboBox与功能castTocomboBox现在我想获取活动项目的文本或索引 问题是如果我使用comboBoxGetActive它返回一个函数IO Int结果 我需要知道如何获得
  • ASP.NET MVC 将 null 转换为零长度字符串

    我正在使用 MVC 3 并尝试将留空的字段作为零长度字符串而不是空值发送到数据库 这可能与数据注释属性有关吗 如果不是 从空值转换的最合适的位置是什么 是在模型验证期间吗 虽然不理想 但这是我所知道的最好的方法 DisplayFormat
  • 找出超速时间段?

    我脑海中浮现出一些有趣的事情 假设我们有一个表 在 SQL Server 中 如下所示 Location Velocity Time 例如 Location Velocity Time 1 40 1 20 2 35 2 00 3 45 2
  • 获取特定键的所有值

    我在 mongoDB 中有一个数据 我想检索一个键的所有值 category 使用Python代码 我尝试了几种方法 但在每种情况下我都必须给出要检索的 值 任何建议 将不胜感激 id my id1 tags tag1 tag2 tag3
  • Keras 构建 9 维特征向量网络

    我有以下简单的数据集 它由 9 个特征组成 是一个二元分类问题 特征向量的示例如下所示 每行都有其对应的 0 1 标签 30 82 1 2 73 172 117 2 2 655 94 30 174 1 5 8 256 189 3 2 587
  • PHP:将数字四舍五入为 16 位小数

    嗨 我正在尝试将数字四舍五入16位小数但它只显示并且不会四舍五入直到14位小数 这是我的尝试 OUTPUT 0 16346153846154 预期输出 0 1634615384615385 我知道float只有 14 位十进制数字 还有其他
  • Windows 7 将 CTRL + j 映射到向下箭头键

    I have been searching for months for a way to map a key combination CTRL something to a directional key like down or up
  • QBOv3 XML 验证错误

    我正在尝试在批量请求中一起发送几个 Quickbooks 查询 我遵循了 Intuit 在这里提供的格式https developer intuit com docs 0025 quickbooksapi 0050 data service
  • 在内核调试模式下连接到目标机器时无法中断

    我正在启动一个包含 Windows 微过滤器的原型 我已经设置好了我的环境 目标虚拟机 实际上是 3 个 Windows 7 8 和 8 1 主机开发计算机 托管 Visual Studio 2013 和 HyperV VM 我终于设法将测