2014-10-31 10 views
9

मेरे पास योसामेट में केक्स्ट पर कोड कोड था। लेकिन kextload विफल रहा है।
यह संस्करण 2 कोडिन था। codesign --verify सच है।
लेकिन kextload विफल रहा है। योसामेट में क्यों लोड नहीं हो रहा है?कोड किए गए kext लेकिन योसैमेट में लोड क्यों नहीं (10.10)

यहां मेरा लॉग है।

मैंने 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 निम्नलिखित लौटा रहा है:

/Path/to/myKext.kext failed to load - (libkern/kext) not loadable (reason unspecified); check the system/kernel logs for errors or try kextutil(8).

cat /var/log/system.log रिटर्न:

com.apple.kextd[19]: ERROR: invalid signature for com.myKext.kext.Firewall, will not load

codesign -dvvv ./myKext.kext निम्नलिखित लौटे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 

अमान्य हस्ताक्षर क्यों कर रहे हैं ?!
मैंने योसामेट में संस्करण 2 कोडइन के साथ हस्ताक्षर किए हैं।
मैंने गलत संकेत क्या किया? कोई मुझे कृपया सिखाओ।

+0

मैं बस अनुमान लगा रहा हूं, लेकिन इसे वैध बनाने के लिए ऐप्पल को कोड हस्ताक्षर में शामिल होने की आवश्यकता नहीं होगी? – trojanfoe

+0

क्या आपने ऐप्पल से अनुरोध किया है कि आपके डेवलपर आईडी में इसमें kext codeign विशेषता शामिल है? – TheDarkKnight

+0

यह वही समस्या जैसा दिखता है: http://stackoverflow.com/questions/26283158/codesigning-kext-with-kext-enabled-certificate-fails-during-kextload-code-sign – pmdj

उत्तर

8

मुझे भी यही समस्या थी। और मुझे आपके साथ समाधान साझा करना मिला।

ऐप्पल ने मैक डेवलपर प्रोग्राम को बदल दिया, और इसके सेक्स्ट के लिए प्रमाणन हटा दिया। तो आप मैक डेवलपर प्रोग्राम के सदस्य भी हैं, आपको Kext विकास के लिए प्रमाणीकरण नहीं मिलेगा जबतक कि आप इसे Developer ID and Gatekeeper पर अनुरोध न करें।

Btw, सेब कहते हैं,

"KEXT signing is intended for signing commercially shipping kexts or projects broadly distributed in a large organization."

तो क्या हम कर सकते हैं "kext-dev- मोड = 1" बूट-आर्ग जोड़कर KEXT विकास मोड पर हमारे Kext चलाया जाता है। पसंद है,

sudo nvram boot-args="debug=0x146 kext-dev-mode=1" 

और रीबूट करें।

मेरी इच्छा है कि यह आपके लिए सहायक होगा।

+0

यह उत्तर पुराना है एल कैपिटन (10.11)। विवरण के लिए अन्य उत्तरों देखें। –

0

मैं पैराडाविल उत्तर से सहमत हूं।
OS X Yosemite के लिए आप निम्न कर सकते हैं:

  1. डाउनलोड "कर्नेल डिबग किट";
  2. इंस्टॉलर पैकेज चलाएं;
  3. "मुझे पढ़ें" चरण जारी रखें;
  4. "पढ़ें मी" का कहना है:

In order to load unsigned kexts, the system must have "KEXT Developer Mode" enabled by adding the "kext-dev-mode=1" boot-arg. The following command (followed by a reboot) would be suitable to prepare a system for testing non-production kexts:     

sudo nvram boot-args="debug=0x146 kext-dev-mode=1" 

Once this is done, the machine will be able to load any valid kext; signatures will still be checked, but a failed verification will just result in a log message. Note: This applies to kexts that contain a binary, as well as codeless (plist-only) kexts. The system will remain in developer mode until you manually remove the boot-arg or clear nvram and reboot. You can exit developer mode by redefining the boot-arg to your previous settings, or clear your boot-args as follows:

sudo nvram -d boot-args 

Apple recommends that you make use of KEXT Developer Mode rather than use your Developer ID certificate to sign drivers while they are under development. Ideally you should sign a driver using a Developer ID certificate only when it reaches its final stages of testing and is being evaluated for release to customers.


ओएस एक्स एल कप्तान 10.11 आदेश के लिए:

sudo nvram boot-args="debug=0x146 kext-dev-mode=1" 

का कोई प्रभाव नहीं है। अधिक जानकारी के लिए

System Integrity Protection Guide/Kernel Extensions पढ़ें।

0

दिसंबर 2016 के रूप में:

यह System Integrity Protection विशेषता यह है कि एल कैप्टन (10.11) में पेश किया गया था के कारण है। एल कैपिटन के रूप में, kext-dev-mode बूट विकल्प का कोई प्रभाव नहीं पड़ता है, इसलिए पैराडाइविल का जवाब काम नहीं करता है। वसूली ओएस के लिए अपने मशीन को पुन: प्रारंभ और स्टार्टअप पर कमान और आर कुंजियों को दबाए रखकर

  1. बूट: इसके बजाय, आप एसआईपी this page से निर्देशों का पालन करके अक्षम करना होगा।

  2. उपयोगिता मेनू से टर्मिनल लॉन्च करें।

    csrutil disable 
    

जब आप पुनः आरंभ, सिस्टम वफ़ादारी संरक्षण अक्षम है या नहीं:

  • निम्न आदेश चलाएं।

  • संबंधित मुद्दे