问题描述
我在优胜美地的kext上有一个代码签名.但是kextload失败.
那是version2 codesign. codesign --verify
是真的.
但是kextload失败.为什么不载入优胜美地?
I had a code signing on kext in Yosemite. But kextload is failed.
It was version2 codesign. codesign --verify
is true.
But kextload is failed. Why not load in Yosemite?
这是我的日志.
我已经与codesign -dvvv ./myKext.kext
核对过了.
codesign -dvvv ./myKext.kext
返回以下内容:
Executable=/Path/to/myKext
Identifier=com.myKext.kext.Firewall
Format=bundle with Mach-O thin (x86_64)
CodeDirectory v=20100 size=317 flags=0x0(none) hashes=9+3 location=embedded
Hash type=sha1 size=20
CDHash=d0ff68bd8b49c650f45349c2d1570d45a8c1f148
Signature size=8544
Authority=Developer ID Application: My Kext Co., Ltd. (R2PBZJ465V)
Authority=Developer ID Certification Authority
Authority=Apple Root CA
Timestamp=2014. 10. 31. 오전 11:09:35
Info.plist entries=18
TeamIdentifier=not set
Sealed Resources version=2 rules=12 files=1
Internal requirements count=1 size=188
它显示版本2.
但是sudo kextload ./myKext.kext
返回以下内容:
It shows that the version 2.
But sudo kextload ./myKext.kext
is returning the following:
cat /var/log/system.log
返回:
sudo kextutil -l ./myKext.kext
返回:
Diagnostics for ./myKext.kext:
Code Signing Failure: code signature is invalid
ERROR: invalid signature for com.myKext.kext.Firewall, will not load
为什么签名无效?!
我已经在优胜美地使用version2 codesign进行了签名.
我做错了什么标志?有人请教我.
Why are invalid signature?!
I have signed with version2 codesign in Yosemite.
What I did wrong sign? Somebody teach me please.
推荐答案
我也遇到了同样的问题.然后我与您分享了解决方案.
I had the same problem too. And I got the solution sharing with you.
Apple更改了Mac Developer Program,并从中删除了kext的认证.因此,即使您是Mac Developer Program的成员,也不会获得kext开发的认证,除非您在开发人员ID和Gatekeeper .
Apple changed the Mac Developer Program, and removed certification for kext from it.So even you are member of Mac Developer Program, you will not get certification for kext development unless you request it at Developer ID and Gatekeeper.
顺便说一句,苹果说,
因此,我们可以做的是通过添加"kext-dev-mode = 1" boot-arg在KEXT开发模式下运行Kext.喜欢,
So what we can do is run our Kext on the KEXT Development Mode by adding the "kext-dev- mode=1" boot-arg. Like,
sudo nvram boot-args="debug=0x146 kext-dev-mode=1"
然后重新启动.
我希望这对您有帮助.
这篇关于codesigned kext但为什么不加载在优胜美地(10.10)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!