Main Page | Modules | Namespace List | Class Hierarchy | Data Structures | Directories | File List | Namespace Members | Data Fields | Globals

SecurityUtilities.h

Go to the documentation of this file.
00001 /********************************************************************
00002 
00003 Copyright 2006, ACCESS Systems Americas, Inc. All rights reserved.
00004 
00005 The contents of this file are subject to the Mozilla Public License Version
00006 1.1 (the "License"); you may not use this file except in compliance with
00007 the License. You may obtain a copy of the License at
00008 http://www.mozilla.org/MPL/
00009 
00010 Software distributed under the License is distributed on an "AS IS" basis,
00011 WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
00012 for the specific language governing rights and limitations under the
00013 License.
00014 
00015 The Original Code is the entire contents of this file.
00016 
00017 The Initial Developer of the Original Code is ACCESS Systems Americas, Inc.
00018 
00019 Portions created by ACCESS Systems Americas, Inc. are Copyright © 2006. All
00020 Rights Reserved.
00021 
00022 Contributor(s): none.
00023 
00024 ********************************************************************/
00025 /* SecurityUtilities.h
00026 **
00027 **
00028 ** Utility Functions for the SPF Security Service
00029 **
00030 ** This file contains the interface to a number of utility functions for use
00031 ** by the  SPF. Many of these functions  are here to mask  the complexity of
00032 ** using the OpenSSL C API.
00033 **
00034 ** $Id:$
00035 */
00036 
00037 /* Macro Definitions */
00038 #ifndef _H_ALP_PRV_SECURITYUTILITY_
00039 #define _H_ALP_PRV_SECURITYUTILITY_
00040 
00041 /* File Includes */
00042 #include <stdio.h>
00043 
00044 /* Typedefs, Structs, Unions, Enums, etc. */
00045 
00046 typedef struct {
00047   char *salt;
00048   unsigned int salt_length;
00049   unsigned int iteration;
00050   unsigned int active;
00051   char *id;
00052   char *phrase;
00053 } AlpPrvSpfSuPKCS5;
00054 
00055 /* Function Prototypes */
00056 
00057 void alp_prv_spf_su_rfc1113_encode( char *input, unsigned int input_length, char *output, unsigned int output_max_length, unsigned int *output_bytes_written );
00058 void alp_prv_spf_su_rfc1113_decode( char *input, unsigned int input_length, char *output, unsigned int output_max_length, unsigned int *output_bytes_written );
00059 void alp_prv_spf_su_sha1( char *input, unsigned int input_length, char *output );
00060 void alp_prv_spf_su_pkcs5_init_default( AlpPrvSpfSuPKCS5 **context, char *id );
00061 void alp_prv_spf_su_pkcs5_init( AlpPrvSpfSuPKCS5 **context, char *salt, unsigned int iteration, char *id );
00062 void alp_prv_spf_su_pkcs5_fput( AlpPrvSpfSuPKCS5 *context, FILE *fp );
00063 void alp_prv_spf_su_pkcs5_phrase_set( AlpPrvSpfSuPKCS5 *context, char *phrase );
00064 void alp_prv_spf_su_pkcs5_phrase_test( AlpPrvSpfSuPKCS5 *context, char *phrase, unsigned int *success );
00065 
00066 /* External Variable Declarations */
00067 
00068 #endif /* _H_ALP_PRV_SECURITYUTILITY_ */

Generated on Sat Dec 16 20:29:47 2006 for hiker-0.9 by  doxygen 1.4.4