87 lines
2.0 KiB
C
87 lines
2.0 KiB
C
|
#ifndef _MICASA_KEYS_H_
|
||
|
#define _MICASA_KEYS_H_
|
||
|
|
||
|
#include <windows.h>
|
||
|
#include "IMiCASAKeys.h"
|
||
|
#include <micasa.h>
|
||
|
|
||
|
#define MICASA_KEYS_CONTRACTID "@novell.com/CASA/MiCASAKeys;1"
|
||
|
#define MICASA_KEYS_CLASSNAME "Common Authentication Services Adapter"
|
||
|
// {287249D7-A851-4aa4-9AEE-5BCDA3B53566}
|
||
|
#define MICASA_KEYS_CID { 0x287249d7, 0xa851, 0x4aa4, { 0x9a, 0xee, 0x5b, 0xcd, 0xa3, 0xb5, 0x35, 0x66 } }
|
||
|
|
||
|
// External prototypes not yet in micasa.h
|
||
|
typedef
|
||
|
void *
|
||
|
(STDAPICALLTYPE *PCASAOPEN)(
|
||
|
SSCS_SECRETSTORE_T * ssid,
|
||
|
unsigned long ssFlags,
|
||
|
SSCS_EXT_T * ext
|
||
|
);
|
||
|
|
||
|
typedef
|
||
|
int
|
||
|
(STDAPICALLTYPE *PCASACLOSE)(
|
||
|
void * context,
|
||
|
unsigned long ssFlags,
|
||
|
SSCS_EXT_T * ext
|
||
|
);
|
||
|
|
||
|
|
||
|
typedef
|
||
|
int
|
||
|
(STDAPICALLTYPE *PCASAWRITEKEY)(
|
||
|
void * context,
|
||
|
uint32_t ssFlags,
|
||
|
SSCS_KEYCHAIN_ID_T * keyChainID,
|
||
|
SSCS_SECRET_ID_T * sharedSecretID,
|
||
|
SS_UTF8_T * key,
|
||
|
uint32_t keyLen,
|
||
|
uint8_t * val,
|
||
|
uint32_t valLen,
|
||
|
SSCS_PASSWORD_T * epPassword,
|
||
|
SSCS_EXT_T * ext
|
||
|
);
|
||
|
|
||
|
typedef
|
||
|
int
|
||
|
(STDAPICALLTYPE *PCASAREADKEY)(
|
||
|
void * context,
|
||
|
uint32_t ssFlags,
|
||
|
SSCS_KEYCHAIN_ID_T * keyChainID,
|
||
|
SSCS_SECRET_ID_T * sharedSecretID,
|
||
|
SS_UTF8_T * key,
|
||
|
uint32_t keyLen,
|
||
|
uint8_t * val,
|
||
|
uint32_t * valLen,
|
||
|
SSCS_PASSWORD_T * epPassword,
|
||
|
uint32_t * bytesRequired,
|
||
|
SSCS_EXT_T * ext
|
||
|
);
|
||
|
|
||
|
|
||
|
/* Header file */
|
||
|
class MiCASAKeys : public IMiCASAKeys
|
||
|
{
|
||
|
public:
|
||
|
NS_DECL_ISUPPORTS
|
||
|
NS_DECL_IMICASAKEYS
|
||
|
|
||
|
MiCASAKeys();
|
||
|
|
||
|
private:
|
||
|
~MiCASAKeys();
|
||
|
HINSTANCE m_hCASALibrary;
|
||
|
BOOLEAN m_bLibraryLoaded;
|
||
|
|
||
|
PCASAOPEN m_pCASAOpen;
|
||
|
PCASACLOSE m_pCASAClose;
|
||
|
PCASAWRITEKEY m_pCASAWriteKey;
|
||
|
PCASAREADKEY m_pCASAReadKey;
|
||
|
|
||
|
protected:
|
||
|
/* additional members */
|
||
|
};
|
||
|
|
||
|
#endif //_MICASA_KEYS_H_
|