Sample Install Program

/* OS-specific includes */

#include <stdio.h> #include <stdlib.h> #include <string.h> #include <unistd.h> #include <sys/stat.h>

#define PATH_LEN 256

#define DL_LIB “libdummydl.1” #define DEST_PATH “/usr/lib/cdsa”

#define TARGET_NAME “/usr/lib/cdsa/libdummydl.1” #define DUMMY_DL_MAJOR_VER 1

#define DUMMY_DL_MINOR_VER 2

static CSSM_GUID my_addin_guid =

{ /* 714ed4ea-15d8-11d2-9be7-0060b0b6e655 */

0x714ed4ea, 0x15d8, 0x11d2, {0x9b, 0xe7, 0x00, 0x60, 0xb0, 0xb6, 0xe6, 0x55}

};

/* Memory Funcs */

#if defined(__STDC__ ) defined(__cplusplus) void* ex_malloc(uint32 size,void *ref) { return malloc(size);

}

void ex_free(void *block,void *ref) { free(block);

}

74

Appendix A

Page 74
Image 74
HP UX Security Products and Features Software manual Appendix a