Home | History | Annotate | Download | only in inc
      1 /** \file unicastKeySM.h
      2  *  \brief station unicast key SM API
      3  *
      4  *  \see unicastKeySM.c
      5  */
      6 /****************************************************************************
      7 **+-----------------------------------------------------------------------+**
      8 **|                                                                       |**
      9 **| Copyright(c) 1998 - 2008 Texas Instruments. All rights reserved.      |**
     10 **| All rights reserved.                                                  |**
     11 **|                                                                       |**
     12 **| Redistribution and use in source and binary forms, with or without    |**
     13 **| modification, are permitted provided that the following conditions    |**
     14 **| are met:                                                              |**
     15 **|                                                                       |**
     16 **|  * Redistributions of source code must retain the above copyright     |**
     17 **|    notice, this list of conditions and the following disclaimer.      |**
     18 **|  * Redistributions in binary form must reproduce the above copyright  |**
     19 **|    notice, this list of conditions and the following disclaimer in    |**
     20 **|    the documentation and/or other materials provided with the         |**
     21 **|    distribution.                                                      |**
     22 **|  * Neither the name Texas Instruments nor the names of its            |**
     23 **|    contributors may be used to endorse or promote products derived    |**
     24 **|    from this software without specific prior written permission.      |**
     25 **|                                                                       |**
     26 **| THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS   |**
     27 **| "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT     |**
     28 **| LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |**
     29 **| A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT  |**
     30 **| OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |**
     31 **| SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT      |**
     32 **| LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |**
     33 **| DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |**
     34 **| THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT   |**
     35 **| (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |**
     36 **| OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.  |**
     37 **|                                                                       |**
     38 **+-----------------------------------------------------------------------+**
     39 ****************************************************************************/
     40 
     41 /****************************************************************************
     42  *                                                                          *
     43  *   MODULE:  station unicast key SM	                                	*
     44  *   PURPOSE: station unicast key SM API		                            *
     45  *                                                                          *
     46  ****************************************************************************/
     47 
     48 #ifndef _KEY_DERIVE_H
     49 #define _KEY_DERIVE_H
     50 
     51 #include "paramOut.h"
     52 #include "rsnApi.h"
     53 #include "keyTypes.h"
     54 
     55 /* Constants */
     56 
     57 /* Enumerations */
     58 
     59 /* Typedefs */
     60 
     61 typedef struct _keyDerive_t    keyDerive_t;
     62 
     63 /* Main Sec SM functions */
     64 typedef TI_STATUS (*keyDeriveDerive_t)(struct _keyDerive_t *pKeyDerive, encodedKeyMaterial_t *pEncodedKeyMaterial);
     65 typedef TI_STATUS (*keyDeriveRemove_t)(struct _keyDerive_t *pKeyDerive, encodedKeyMaterial_t *pEncodedKeyMaterial);
     66 
     67 /* Structures */
     68 
     69 /* State machine associated data structures. */
     70 struct _keyDerive_t
     71 {
     72 	encodedKeyMaterial_t	key;
     73 
     74 	struct _mainKeys_t     	*pMainKeys;
     75 
     76 	TI_HANDLE				hReport;
     77 	TI_HANDLE			    hOs;
     78 
     79 	keyDeriveDerive_t		derive;
     80 	keyDeriveRemove_t		remove;
     81 };
     82 
     83 /* External data definitions */
     84 
     85 /* External functions definitions */
     86 
     87 /* Function prototypes */
     88 
     89 keyDerive_t* keyDerive_create(TI_HANDLE hOs);
     90 
     91 TI_STATUS keyDerive_unload(keyDerive_t *pKeyDerive);
     92 
     93 TI_STATUS keyDerive_config(keyDerive_t *pKeyDerive,
     94 						cipherSuite_e cipher,
     95 						struct _mainKeys_t *pParent,
     96 						TI_HANDLE hReport,
     97 						TI_HANDLE hOs);
     98 
     99 
    100 #endif /*  _KEY_DERIVE_H*/
    101