Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/cplusplus/124.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
使用智能卡签名时为RtlFreeHeap指定的地址无效(C+;+;) 我使用C++和Visual Studio 2010。_C++_Exception_Cryptography_Heap Corruption - Fatal编程技术网

使用智能卡签名时为RtlFreeHeap指定的地址无效(C+;+;) 我使用C++和Visual Studio 2010。

使用智能卡签名时为RtlFreeHeap指定的地址无效(C+;+;) 我使用C++和Visual Studio 2010。,c++,exception,cryptography,heap-corruption,C++,Exception,Cryptography,Heap Corruption,当我使用智能卡执行签名时出现:“程序完成时” 论产出 HEAP[MyProgram.exe]: Invalid Address specified to RtlFreeHeap( 003C0000, 01BBFEA0 ) Windows has triggered a breakpoint in MyProgram.exe. This may be due to a corruption of the heap, which indicates a bug in MyProgram.exe o

当我使用智能卡执行签名时出现:“程序完成时”

论产出

HEAP[MyProgram.exe]: Invalid Address specified to RtlFreeHeap( 003C0000, 01BBFEA0 )
Windows has triggered a breakpoint in MyProgram.exe.

This may be due to a corruption of the heap, which indicates a bug in MyProgram.exe or any of the DLLs it has loaded.

This may also be due to the user pressing F12 while MyProgram.exe has focus.

The output window may have more diagnostic information.
MyProgram.exe程序使用dll“signer.dll”

我试着用“没有智能卡”来签名。仅使用Windows证书。正常终止。
当我尝试使用智能卡签名时,出现一个窗口询问PIN。当节目结束时。错误-为RtlFreeHeap指定的地址无效。
我使用智能卡,当它要求输入PIN码时,我会标记为“不”。当程序结束时。错误-为RtlFreeHeap指定的地址无效

我注意到只有当窗口出现询问PIN时才会发生错误

因此,我尝试使用WinDbg,如下所述:

我把断点放在“CryptSignMessage”出现:“当使用智能卡时”

如果不使用智能卡,则不会发生这种情况

我认为他试图获得钥匙的上下文,但却不能,并且“腐蚀记忆”。“第一次机会”后提示PIN的窗口

这就是问题所在吗? 在使用CryptSignMessage之前,如何获取具有密钥上下文的证书

我该怎么修理

没有智能卡,我可以正常签名。 使用智能卡,我可以正常签名,但当程序完成时,会出现错误

应该注意智能卡上的标志吗


提前感谢

正如消息所说,这似乎是堆损坏。他们不太容易找到。您最好使用内存分析工具来帮助查找原因。

正如消息所说,这似乎是堆损坏。他们不太容易找到。您最好使用内存分析工具来帮助查找原因。

谢谢您的回复。我把阅读器的软件换成了旧的,它可以工作了。我讨厌虫子。对不起,我的回答没有帮助。谢谢你的回复。我把阅读器的软件换成了旧的,它可以工作了。我讨厌虫子。对不起,我的回答没有帮助。
HEAP[MyProgram.exe]: Invalid Address specified to RtlFreeHeap( 003C0000, 01BBFEA0 )
Windows has triggered a breakpoint in MyProgram.exe.

This may be due to a corruption of the heap, which indicates a bug in MyProgram.exe or any of the DLLs it has loaded.

This may also be due to the user pressing F12 while MyProgram.exe has focus.

The output window may have more diagnostic information.
(150c.17fc): C++ EH exception - code e06d7363 (first chance)
(150c.17fc): C++ EH exception - code e06d7363 (first chance)