- typedefs changed

This commit is contained in:
Martin Willi
2005-11-24 11:30:19 +00:00
parent 95c61cb956
commit 5796aa164d
61 changed files with 303 additions and 242 deletions
+6 -6
View File
@@ -41,13 +41,13 @@
*/
#define NONCE_SIZE 16
typedef struct ike_sa_t ike_sa_t;
/**
* @brief This class is used to represent an IKE_SA
*
*/
typedef struct ike_sa_s ike_sa_t;
struct ike_sa_s {
struct ike_sa_t {
/**
* @brief Processes a incoming IKEv2-Message of type message_t
@@ -84,12 +84,12 @@ struct ike_sa_s {
status_t (*destroy) (ike_sa_t *this);
};
typedef struct protected_ike_sa_t protected_ike_sa_t;
/**
* Protected data of an ike_sa_t object
*/
typedef struct protected_ike_sa_s protected_ike_sa_t;
struct protected_ike_sa_s {
struct protected_ike_sa_t {
/**
* Public part of a ike_sa_t object
+3 -3
View File
@@ -28,12 +28,12 @@
#include <types.h>
#include <utils/allocator.h>
typedef struct private_ike_sa_id_t private_ike_sa_id_t;
/**
* Private data of an ike_sa_id object
*/
typedef struct private_ike_sa_id_s private_ike_sa_id_t;
struct private_ike_sa_id_s {
struct private_ike_sa_id_t {
/**
* Public part of a ike_sa_id object
*/
+3 -3
View File
@@ -26,6 +26,8 @@
#include "types.h"
typedef struct ike_sa_id_t ike_sa_id_t;
/**
* @brief This class is used to identify an IKE_SA.
*
@@ -33,9 +35,7 @@
* Additionaly it contains the role of the actual running IKEv2-Daemon
* for the specific IKE_SA.
*/
typedef struct ike_sa_id_s ike_sa_id_t;
struct ike_sa_id_s {
struct ike_sa_id_t {
/**
* @brief Sets the SPI of the responder.
+6 -4
View File
@@ -32,11 +32,12 @@
#include <utils/logger_manager.h>
#include <utils/linked_list.h>
typedef struct ike_sa_entry_t ike_sa_entry_t;
/**
* @brief An entry in the linked list, contains IKE_SA, locking and lookup data.
*/
typedef struct ike_sa_entry_s ike_sa_entry_t;
struct ike_sa_entry_s {
struct ike_sa_entry_t {
/**
* destructor, also destroys ike_sa
*/
@@ -131,11 +132,12 @@ static ike_sa_entry_t *ike_sa_entry_create(ike_sa_id_t *ike_sa_id)
return this;
}
typedef struct private_ike_sa_manager_t private_ike_sa_manager_t;
/**
* Additional private members to ike_sa_manager_t
*/
typedef struct private_ike_sa_manager_s private_ike_sa_manager_t;
struct private_ike_sa_manager_s {
struct private_ike_sa_manager_t {
/**
* Public members
*/
+7 -6
View File
@@ -27,19 +27,20 @@
#include <sa/ike_sa.h>
typedef struct ike_sa_manager_t ike_sa_manager_t;
/**
* @brief The IKE_SA-Manager manages the IKE_SAs ;-).
*
* @brief The IKE_SA-Manager manages the IKE_SAs ;-).
*
* To avoid access from multiple threads, IKE_SAs must be checked out from
* the manager, and checked back in after usage.
* The manager also handles deletion of SAs.
*
*
* @todo checking of double-checkouts from the same threads would be nice.
* This could be by comparing thread-ids via pthread_self()...
*
*
*/
typedef struct ike_sa_manager_s ike_sa_manager_t;
struct ike_sa_manager_s {
struct ike_sa_manager_t {
/**
* @brief Checkout an IKE_SA, create it when necesarry
*
+4 -2
View File
@@ -24,12 +24,14 @@
#include <utils/allocator.h>
typedef struct private_ike_auth_requested_t private_ike_auth_requested_t;
/**
* Private data of a ike_auth_requested_t object.
*
*/
typedef struct private_ike_auth_requested_s private_ike_auth_requested_t;
struct private_ike_auth_requested_s {
struct private_ike_auth_requested_t {
/**
* methods of the state_t interface
*/
+4 -3
View File
@@ -26,13 +26,14 @@
#include <sa/states/state.h>
#include <sa/ike_sa.h>
typedef struct ike_auth_requested_t ike_auth_requested_t;
/**
* @brief This class represents an IKE_SA, which has requested an IKE_AUTH.
*
*/
typedef struct ike_auth_requested_s ike_auth_requested_t;
struct ike_auth_requested_s {
struct ike_auth_requested_t {
/**
* methods of the state_t interface
*/
+4 -2
View File
@@ -24,12 +24,14 @@
#include <utils/allocator.h>
typedef struct private_ike_sa_established_t private_ike_sa_established_t;
/**
* Private data of a ike_sa_established_t object.
*
*/
typedef struct private_ike_sa_established_s private_ike_sa_established_t;
struct private_ike_sa_established_s {
struct private_ike_sa_established_t {
/**
* methods of the state_t interface
*/
+4 -4
View File
@@ -26,14 +26,14 @@
#include <sa/states/state.h>
#include <sa/ike_sa.h>
typedef struct ike_sa_established_t ike_sa_established_t;
/**
* @brief This class represents an the state of an established
* @brief This class represents an the state of an established.
* IKE_SA.
*
*/
typedef struct ike_sa_established_s ike_sa_established_t;
struct ike_sa_established_s {
struct ike_sa_established_t {
/**
* methods of the state_t interface
*/
@@ -29,12 +29,14 @@
#include <encoding/payloads/nonce_payload.h>
#include <transforms/diffie_hellman.h>
typedef struct private_ike_sa_init_requested_t private_ike_sa_init_requested_t;
/**
* Private data of a ike_sa_init_requested_t object.
*
*/
typedef struct private_ike_sa_init_requested_s private_ike_sa_init_requested_t;
struct private_ike_sa_init_requested_s {
struct private_ike_sa_init_requested_t {
/**
* methods of the state_t interface
*/
@@ -29,13 +29,13 @@
#include <sa/states/state.h>
#include <transforms/diffie_hellman.h>
typedef struct ike_sa_init_requested_t ike_sa_init_requested_t;
/**
* @brief This class represents an IKE_SA state when requested an IKE_SA_INIT
* @brief This class represents an IKE_SA state when requested an IKE_SA_INIT.
*
*/
typedef struct ike_sa_init_requested_s ike_sa_init_requested_t;
struct ike_sa_init_requested_s {
struct ike_sa_init_requested_t {
/**
* methods of the state_t interface
*/
@@ -24,12 +24,14 @@
#include <utils/allocator.h>
typedef struct private_ike_sa_init_responded_t private_ike_sa_init_responded_t;
/**
* Private data of a ike_sa_init_responded_t object.
*
*/
typedef struct private_ike_sa_init_responded_s private_ike_sa_init_responded_t;
struct private_ike_sa_init_responded_s {
struct private_ike_sa_init_responded_t {
/**
* methods of the state_t interface
*/
@@ -26,13 +26,13 @@
#include <sa/ike_sa.h>
#include <sa/states/state.h>
typedef struct ike_sa_init_responded_t ike_sa_init_responded_t;
/**
* @brief This class represents an IKE_SA state when responded to an IKE_SA_INIT request
* @brief This class represents an IKE_SA state when responded to an IKE_SA_INIT request.
*
*/
typedef struct ike_sa_init_responded_s ike_sa_init_responded_t;
struct ike_sa_init_responded_s {
struct ike_sa_init_responded_t {
/**
* methods of the state_t interface
*/
+3 -2
View File
@@ -33,12 +33,13 @@
#include <encoding/payloads/nonce_payload.h>
typedef struct private_initiator_init_t private_initiator_init_t;
/**
* Private data of a initiator_init_t object.
*
*/
typedef struct private_initiator_init_s private_initiator_init_t;
struct private_initiator_init_s {
struct private_initiator_init_t {
/**
* Methods of the state_t interface.
*/
+5 -5
View File
@@ -28,14 +28,14 @@
#include <sa/states/state.h>
typedef struct initiator_init_t initiator_init_t;
/**
* @brief This class represents an IKE_SA state when initializing
* a connection as initiator
* @brief This class represents an IKE_SA state when initializing.
* a connection as initiator
*
*/
typedef struct initiator_init_s initiator_init_t;
struct initiator_init_s {
struct initiator_init_t {
/**
* methods of the state_t interface
*/
+4 -2
View File
@@ -31,12 +31,14 @@
#include <encoding/payloads/nonce_payload.h>
#include <transforms/diffie_hellman.h>
typedef struct private_responder_init_t private_responder_init_t;
/**
* Private data of a responder_init_t object.
*
*/
typedef struct private_responder_init_s private_responder_init_t;
struct private_responder_init_s {
struct private_responder_init_t {
/**
* Methods of the state_t interface.
*/
+6 -5
View File
@@ -26,14 +26,15 @@
#include <sa/ike_sa.h>
#include <sa/states/state.h>
typedef struct responder_init_t responder_init_t;
/**
* @brief This class represents an IKE_SA state when initializing
* a connection as responder
* @brief This class represents an IKE_SA state when initializing.
* a connection as responder
*
*/
typedef struct responder_init_s responder_init_t;
struct responder_init_s {
struct responder_init_t {
/**
* methods of the state_t interface
*/
+6 -7
View File
@@ -29,12 +29,12 @@
extern mapping_t ike_sa_state_m[];
typedef enum ike_sa_state_t ike_sa_state_t;
/**
* States in which a IKE_SA can actually be
*/
typedef enum ike_sa_state_e ike_sa_state_t;
enum ike_sa_state_e {
enum ike_sa_state_t {
/**
* IKE_SA is is not in a state as initiator
@@ -75,13 +75,12 @@ enum ike_sa_state_e {
*/
extern mapping_t ike_sa_state_m[];
typedef struct state_t state_t;
/**
* @brief This interface represents an IKE_SA state
*
*/
typedef struct state_s state_t;
struct state_s {
struct state_t {
/**
* @brief Processes a incoming IKEv2-Message of type message_t