1
0

libkms.h 883 B

123456789101112131415161718192021222324252627282930313233
  1. /*
  2. * libkms.h
  3. */
  4. #ifndef LIBKMS_H_
  5. #define LIBKMS_H_
  6. #include "types.h"
  7. #include "kms.h"
  8. #include "rpc.h"
  9. #ifdef __cplusplus
  10. #define EXTERNC extern "C"
  11. #else
  12. #define EXTERNC
  13. #endif
  14. #if !defined(_WIN32) && !__CYGWIN__
  15. #define __declspec(x) __attribute__((__visibility__("default")))
  16. #endif
  17. #if !defined(EXTERNAL)
  18. #define EXTERNAL dllimport
  19. #endif
  20. EXTERNC __declspec(EXTERNAL) DWORD __cdecl SendActivationRequest(const char* const hostname, const int port, RESPONSE* baseResponse, const REQUEST* const baseRequest, RESPONSE_RESULT* result, BYTE *hwid);
  21. EXTERNC __declspec(EXTERNAL) DWORD __cdecl StartKmsServer(const int port, RequestCallback_t requestCallback);
  22. EXTERNC __declspec(EXTERNAL) DWORD __cdecl StopKmsServer();
  23. EXTERNC __declspec(EXTERNAL) int __cdecl GetLibKmsVersion();
  24. //EXTERN_C __declspec(EXTERNAL) unsigned int __cdecl GetRandom32();
  25. #endif /* LIBKMS_H_ */