Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
426 views
in Technique[技术] by (71.8m points)

64 bit - How to sign my driver so it will install on Windows 7 64-bit?

I have a kernel mode driver and I have to install t on 64 bit Windows 7. It needs to be digitally signed. I digitally signed it using the dseo13b.exe. But when I load the driver I get an error in the system event log saying:

The driver failed to start due to the following error:
Windows cannot verify the digital signature for this file. A recent hardware or software change might have installed a file that is signed incorrectly or damaged, or that might be malicious software from an unknown source.

I don't want to use the testsigning mode. How do I resolve this? Do I need to get a certificate from Microsoft?

I have developed the driver and am now making it work on the 64 bit machine...

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Only for 64 bit builds: setting up self signing

Part 1: creating and installing the test certificate

  1. Launch an elevated command line shell (Vista and later).
  2. makecert.exe -r -pe -ss my -n "CN=MyTestCertificate" mytestcert.cer
  3. certmgr.exe -add mytestcert.cer -s -r localMachine root
  4. Start certmgr.exe and check that "MyTestCertificate" is listed both under "Personal" and "Trusted Root Certification Authorities".
  5. Keep the mytestcert.cer file in a safe place.

Part 2: configuring the system to run test signed code (Vista and later)

  1. Launch an elevated command line shell (Vista and later).
  2. Run Bcdedit.exe -set TESTSIGNING ON on an elevated cmd.exe prompt.
  3. certmgr.exe -add mytestcert.cer -s -r localMachine root
  4. certmgr.exe -add mytestcert.cer -s -r localMachine trustedpublisher
  5. Reboot.
  6. Vista: "Test Mode" will appear in all four corners of the desktop and "Microsoft (R) Windows (R) (Build 6000)" will appear on the top. Windows 7: "Test ModeWindows 7Build 7600" will appear in the lower right corner.

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...