Update nCipher header with more liberal licence.

This commit is contained in:
Ben Laurie 2001-07-04 12:26:39 +00:00
parent 43f9391bcc
commit 5be022712a

View File

@ -8,13 +8,19 @@
* synchronous-within-each-thread, facility.
*
*
* This file is Copyright 1998-1999 nCipher Corporation Limited.
* This file is Copyright 1998-2000 nCipher Corporation Limited.
*
* This file is provided for your information and assistance. You are
* permitted to copy it verbatim, to use it to create compatible
* software, and for review and comment. However, you may not
* distribute changed versions or other derivative works. All other
* rights are reserved.
* Redistribution and use in source and binary forms, with opr without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the copyright notice,
* this list of conditions, and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions, and the following
* disclaimer, in the documentation and/or other materials provided
* with the distribution
*
* IN NO EVENT SHALL NCIPHER CORPORATION LIMITED (`NCIPHER') AND/OR
* ANY OTHER AUTHORS OR DISTRIBUTORS OF THIS FILE BE LIABLE for any
@ -52,14 +58,14 @@
*
*
* The actual dynamically loadable plugin, and the library files for
* static linking, which are also provided in this distribution, are
* static linking, which are also provided in some distributions, are
* not covered by the licence described above. You should have
* received a separate licence with terms and conditions for these
* library files; if you received the library files without a licence,
* please contact nCipher.
*
*
* $Id: hwcryptohook.h,v 1.2 2000/10/26 21:06:30 levitte Exp $
* $Id: hwcryptohook.h,v 1.3 2001/07/04 12:26:39 ben Exp $
*/
#ifndef HWCRYPTOHOOK_H
@ -111,12 +117,11 @@ typedef struct {
* integer-valued ones). It will, if an ErrMsgBuf is passed, also put
* an error message there.
*
* size is the size of the buffer. When the buffer is filled, it will
* always be null-terminated. If you pass 0 buf buf you must pass 0
* for size, and nothing will be recorded (just as if you passed 0 for
* the struct pointer). Size will not be modified when an error is
* recorded. The buffer is always null-terminated even if there is an
* overrun.
* size is the size of the buffer, and will not be modified. If you
* pass 0 for size you must pass 0 for buf, and nothing will be
* recorded (just as if you passed 0 for the struct pointer).
* Messages written to the buffer will always be null-terminated, even
* when truncated to fit within size bytes.
*
* The contents of the buffer are not defined if there is no error.
*/
@ -126,10 +131,14 @@ typedef struct HWCryptoHook_MPIStruct {
size_t size;
} HWCryptoHook_MPI;
/* When one of these is returned, a pointer is passed to the function.
* At call, size is the space available. Afterwards it is updated.
* buf (the pointer) is not updated. size is in bytes and may be
* zero, but must be a multiple of the limb size. Zero limbs at the
* MS end are not permitted.
* At call, size is the space available. Afterwards it is updated to
* be set to the actual length (which may be more than the space available,
* if there was not enough room and the result was truncated).
* buf (the pointer) is not updated.
*
* size is in bytes and may be zero at call or return, but must be a
* multiple of the limb size. Zero limbs at the MS end are not
* permitted.
*/
#define HWCryptoHook_InitFlags_FallbackModExp 0x0002UL
@ -312,7 +321,7 @@ typedef struct {
typedef
HWCryptoHook_ContextHandle HWCryptoHook_Init_t(const HWCryptoHook_InitInfo *initinfo,
size_t initinfosize,
HWCryptoHook_ErrMsgBuf *errors,
const HWCryptoHook_ErrMsgBuf *errors,
HWCryptoHook_CallerContext *cactx);
extern HWCryptoHook_Init_t HWCryptoHook_Init;
@ -339,7 +348,7 @@ extern HWCryptoHook_Init_t HWCryptoHook_Init;
/* The RSAImmed* functions (and key managed RSA) only work with
* modules which have an RSA patent licence - currently that means KM
* units; the ModExp* ones work with all modules, so you need a patent
* licence in the software in the US.
* licence in the software in the US. They are otherwise identical.
*/
typedef
@ -430,7 +439,7 @@ extern HWCryptoHook_RSALoadKey_t HWCryptoHook_RSALoadKey;
* and the provider must cope (returning an error if the string is not
* valid).
*
* If the key does not exist, it is _not_ an error - in that case,
* If the key does not exist, no error is recorded and 0 is returned;
* keyhandle_r will be set to 0 instead of to a key handle.
*/
@ -472,5 +481,6 @@ int HWCryptoHook_RSA_t(HWCryptoHook_MPI m,
HWCryptoHook_MPI *r,
const HWCryptoHook_ErrMsgBuf *errors);
extern HWCryptoHook_RSA_t HWCryptoHook_RSA;
/* RSA private key operation (sign or decrypt) - raw, unpadded. */
#endif /*HWCRYPTOHOOK_H*/