38
38
* secport.h - portability interfaces for security libraries
40
* $Id: secport.h,v 1.19 2009/02/27 00:15:03 nelson%bolyard.com Exp $
40
* $Id: secport.h,v 1.23 2009/10/30 09:44:47 nelson%bolyard.com Exp $
43
43
#ifndef _SECPORT_H_
44
44
#define _SECPORT_H_
46
46
#include "utilrename.h"
49
50
* define XP_WIN, XP_BEOS, or XP_UNIX, in case they are not defined
245
242
extern int NSS_PutEnv(const char * envVarName, const char * envValue);
244
extern int NSS_SecureMemcmp(const void *a, const void *b, size_t n);
247
* Load a shared library called "newShLibName" in the same directory as
248
* a shared library that is already loaded, called existingShLibName.
249
* A pointer to a static function in that shared library,
250
* staticShLibFunc, is required.
253
* The file name of the shared library that shall be used as the
254
* "reference library". The loader will attempt to load the requested
255
* library from the same directory as the reference library.
258
* Pointer to a static function in the "reference library".
261
* The simple file name of the new shared library to be loaded.
263
* We use PR_GetLibraryFilePathname to get the pathname of the loaded
264
* shared lib that contains this function, and then do a
265
* PR_LoadLibraryWithFlags with an absolute pathname for the shared
266
* library to be loaded.
268
* On Windows, the "alternate search path" strategy is employed, if available.
269
* On Unix, if existingShLibName is a symbolic link, and no link exists for the
270
* new library, the original link will be resolved, and the new library loaded
271
* from the resolved location.
273
* If the new shared library is not found in the same location as the reference
274
* library, it will then be loaded from the normal system library path.
277
PORT_LoadLibraryFromOrigin(const char* existingShLibName,
278
PRFuncPtr staticShLibFunc,
279
const char *newShLibName);
249
283
#endif /* _SECPORT_H_ */