Skip Navigation Links | |
Exit Print View | |
![]() |
man pages section 3: Extended Library Functions Oracle Solaris 10 8/11 Information Library |
Extended Library Functions - Part 1
Extended Library Functions - Part 2
Extended Library Functions - Part 3
gl_customize_completion(3TECLA)
HBA_GetAdapterAttributes(3HBAAPI)
HBA_GetAdapterPortAttributes(3HBAAPI)
HBA_GetBindingCapability(3HBAAPI)
HBA_GetBindingSupport(3HBAAPI)
HBA_GetDiscoveredPortAttributes(3HBAAPI)
HBA_GetFcpPersistentBinding(3HBAAPI)
HBA_GetFcpTargetMapping(3HBAAPI)
HBA_GetFcpTargetMappingV2(3HBAAPI)
HBA_GetNumberOfAdapters(3HBAAPI)
HBA_GetPersistentBindingV2(3HBAAPI)
HBA_GetPortAttributesByWWN(3HBAAPI)
HBA_GetPortStatistics(3HBAAPI)
HBA_GetVendorLibraryAttributes(3HBAAPI)
HBA_GetWrapperLibraryAttributes(3HBAAPI)
HBA_RefreshAdapterConfiguration(3HBAAPI)
HBA_RefreshInformation(3HBAAPI)
HBA_RegisterForAdapterAddEvents(3HBAAPI)
HBA_RegisterForAdapterEvents(3HBAAPI)
HBA_RegisterForAdapterPortEvents(3HBAAPI)
HBA_RegisterForAdapterPortStatEvents(3HBAAPI)
HBA_RegisterForLinkEvents(3HBAAPI)
HBA_RegisterForTargetEvents(3HBAAPI)
HBA_RemoveAllPersistentBindings(3HBAAPI)
HBA_RemovePersistentBinding(3HBAAPI)
HBA_ScsiReadCapacityV2(3HBAAPI)
HBA_SetBindingSupport(3HBAAPI)
HBA_SetPersistentBindingV2(3HBAAPI)
IFDHCreateChannelByName(3SMARTCARD)
IFDHGetCapabilities(3SMARTCARD)
IFDHSetCapabilities(3SMARTCARD)
IFDHSetProtocolParameters(3SMARTCARD)
MP_AssignLogicalUnitToTPG(3MPAPI)
MP_DeregisterForObjectPropertyChanges(3MPAPI)
MP_DeregisterForObjectVisibilityChanges(3MPAPI)
MP_DisableAutoFailback(3MPAPI)
Extended Library Functions - Part 4
- MD4 digest functions
cc [ flag ... ] file ... -lmd [ library ... ] #include <md4.h> void MD4Init(MD4_CTX *context);
void MD4Update(MD4_CTX *context, unsigned char *input, unsigned int inlen);
void MD4Final(unsigned char *output, MD4_CTX *context);
The MD4 functions implement the MD4 message-digest algorithm. The algorithm takes as input a message of arbitrary length and produces a “fingerprint” or “message digest” as output. The MD4 message-digest algorithm is intended for digital signature applications in which large files are “compressed” in a secure manner before being encrypted with a private (secret) key under a public-key cryptosystem such as RSA.
The MD4Init(), MD4Update(), and MD4Final() functions allow an MD4 digest to be computed over multiple message blocks. Between blocks, the state of the MD4 computation is held in an MD4 context structure allocated by the caller. A complete digest computation consists of calls to MD4 functions in the following order: one call to MD4Init(), one or more calls to MD4Update(), and one call to MD4Final().
The MD4Init() function initializes the MD4 context structure pointed to by context.
The MD4Update() function computes a partial MD4 digest on the inlen-byte message block pointed to by input, and updates the MD4 context structure pointed to by context accordingly.
The MD4Final() function generates the final MD4 digest, using the MD4 context structure pointed to by context. The MD4 digest is written to output. After a call to MD4Final(), the state of the context structure is undefined. It must be reinitialized with MD4Init() before it can be used again.
These functions do not return a value.
The MD4 digest algorithm is not currently considered cryptographically secure. It is included in libmd(3LIB) for use by legacy protocols and systems only. It should not be used by new systems or protocols.
Example 1 Authenticate a message found in multiple buffers
The following is a sample function that must authenticate a message that is found in multiple buffers. The calling function provides an authentication buffer that will contain the result of the MD4 digest.
#include <sys/types.h> #include <sys/uio.h> #include <md4.h> int AuthenticateMsg(unsigned char *auth_buffer, struct iovec *messageIov, unsigned int num_buffers) { MD4_CTX ctx; unsigned int i; MD4Init(&ctx); for(i=0; i<num_buffers; i++) { MD4Update(&ctx, messageIov->iov_base, messageIov->iov_len); messageIov += sizeof(struct iovec); } MD4Final(auth_buffer, &ctx); return 0; }
See attributes(5) for descriptions of the following attributes:
|
RFC 1320