1*1b191cb5SApple OSS Distributions // 2*1b191cb5SApple OSS Distributions // KernelUtils.hpp 3*1b191cb5SApple OSS Distributions // CoreEntitlements_kernel 4*1b191cb5SApple OSS Distributions // 5*1b191cb5SApple OSS Distributions // 6*1b191cb5SApple OSS Distributions 7*1b191cb5SApple OSS Distributions #ifndef CORE_ENTITLEMENTS_KERNEL_H 8*1b191cb5SApple OSS Distributions #define CORE_ENTITLEMENTS_KERNEL_H 9*1b191cb5SApple OSS Distributions 10*1b191cb5SApple OSS Distributions #include <CoreEntitlements/CoreEntitlements.h> 11*1b191cb5SApple OSS Distributions #include <libkern/c++/OSPtr.h> 12*1b191cb5SApple OSS Distributions #include <libkern/c++/OSDictionary.h> 13*1b191cb5SApple OSS Distributions 14*1b191cb5SApple OSS Distributions #ifndef CORE_ENTITLEMENTS_I_KNOW_WHAT_IM_DOING 15*1b191cb5SApple OSS Distributions #error This is a private API, please consult with the Trusted Execution team before using this. Misusing these functions will lead to security issues. 16*1b191cb5SApple OSS Distributions #endif 17*1b191cb5SApple OSS Distributions 18*1b191cb5SApple OSS Distributions /*! 19*1b191cb5SApple OSS Distributions * @function CEQueryContextToOSDictionary 20*1b191cb5SApple OSS Distributions * Private API, converts a query context into an OSDictionary that can be handed out to legacy users 21*1b191cb5SApple OSS Distributions */ 22*1b191cb5SApple OSS Distributions OSPtr<OSDictionary> CEQueryContextToOSDictionary(CEQueryContext_t entitlements); 23*1b191cb5SApple OSS Distributions 24*1b191cb5SApple OSS Distributions /*! 25*1b191cb5SApple OSS Distributions * @function CEQueryContextToOSObject 26*1b191cb5SApple OSS Distributions * Private API, converts a query context into an OSObject that may be returned dynamically 27*1b191cb5SApple OSS Distributions */ 28*1b191cb5SApple OSS Distributions OSPtr<OSObject> CEQueryContextToOSObject(CEQueryContext_t context); 29*1b191cb5SApple OSS Distributions 30*1b191cb5SApple OSS Distributions #endif 31