1 /** 2 * This file has no copyright assigned and is placed in the Public Domain. 3 * This file is part of the mingw-w64 runtime package. 4 * No warranty is given; refer to the file DISCLAIMER.PD within this package. 5 */ 6 #ifndef _INC_SLPUBLIC 7 #define _INC_SLPUBLIC 8 #if (_WIN32_WINNT >= 0x0600) 9 10 #ifdef __cplusplus 11 extern "C" { 12 #endif 13 14 typedef GUID SLID; 15 16 typedef enum _SL_GENUINE_STATE { 17 SL_GEN_STATE_IS_GENUINE = 0, 18 SL_GEN_STATE_INVALID_LICENSE = 1, 19 SL_GEN_STATE_TAMPERED = 2, 20 SL_GEN_STATE_LAST = 3 21 } SL_GENUINE_STATE; 22 23 typedef enum _tagSLDATATYPE { 24 SL_DATA_NONE = REG_NONE, 25 SL_DATA_SZ = REG_SZ, 26 SL_DATA_DWORD = REG_DWORD, 27 SL_DATA_BINARY = REG_BINARY, 28 SL_DATA_MULTI_SZ = REG_MULTI_SZ, 29 SL_DATA_SUM = 100 30 } SLDATATYPE; 31 32 typedef struct _tagSL_NONGENUINE_UI_OPTIONS { 33 DWORD cbSize; 34 const SLID *pComponentId; 35 HRESULT hResultUI; 36 } SL_NONGENUINE_UI_OPTIONS; 37 38 HRESULT WINAPI SLAcquireGenuineTicket( 39 void **ppTicketBlob, 40 UINT *pcbTicketBlob, 41 PCWSTR pwszTemplateId, 42 PCWSTR pwszServerUrl, 43 PCWSTR pwszClientToken 44 ); 45 46 HRESULT WINAPI SLGetGenuineInformation( 47 const SLID *pAppId, 48 PCWSTR pwszValueName, 49 SLDATATYPE *peDataType, 50 UINT *pcbValue, 51 BYTE **ppbValue 52 ); 53 54 HRESULT WINAPI SLGetInstalledSAMLicenseApplications( 55 UINT *pnReturnedAppIds, 56 SLID **ppReturnedAppIds 57 ); 58 59 HRESULT WINAPI SLGetSAMLicense( 60 const SLID *pApplicationId, 61 UINT *pcbXmlLicenseData, 62 PBYTE *ppbXmlLicenseData 63 ); 64 65 HRESULT WINAPI SLGetWindowsInformation( 66 PCWSTR pwszValueName, 67 SLDATATYPE *peDataType, 68 UINT *pcbValue, 69 PBYTE *ppbValue 70 ); 71 72 HRESULT WINAPI SLGetWindowsInformationDWORD( 73 PCWSTR pwszValueName, 74 DWORD *pdwValue 75 ); 76 77 HRESULT WINAPI SLInstallSAMLicense( 78 const SLID *pApplicationId, 79 UINT cbXmlLicenseData, 80 const BYTE *pbXmlLicenseData 81 ); 82 83 HRESULT WINAPI SLIsGenuineLocal( 84 const SLID *pAppId, 85 SL_GENUINE_STATE *pGenuineState, 86 SL_NONGENUINE_UI_OPTIONS *pUIOptions 87 ); 88 89 HRESULT WINAPI SLSetGenuineInformation( 90 const SLID *pAppId, 91 PCWSTR pwszValueName, 92 SLDATATYPE eDataType, 93 UINT cbValue, 94 const BYTE *pbValue 95 ); 96 97 HRESULT WINAPI SLUninstallSAMLicense( 98 const SLID *pApplicationId 99 ); 100 101 #if (_WIN32_WINNT >= 0x0601) 102 HRESULT WINAPI SLIsGenuineLocalEx( 103 const SLID *pAppId, 104 const SLID pSkuId, 105 SL_GENUINE_STATE *pGenuineState 106 ); 107 #endif /*(_WIN32_WINNT >= 0x0601)*/ 108 109 #ifdef __cplusplus 110 } 111 #endif 112 #endif /*(_WIN32_WINNT >= 0x0600)*/ 113 #endif /*_INC_SLPUBLIC*/ 114