The Assimilation Project
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
cryptframe.h File Reference

Describes interfaces to CryptFrame (encryption) C-Class It represents the abstract base class for FrameSet encryption. More...

#include <frame.h>
#include <netaddr.h>
Include dependency graph for cryptframe.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  CryptFramePublicKey
 
struct  CryptFramePrivateKey
 
struct  _CryptFrame
 This is our CryptFrame class object - representing an encryption method. More...
 
#define MAXCRYPTKEYNAMELENGTH   64
 Maximum length of a crypt key name. More...
 
typedef struct _CryptFrame CryptFrame
 
CryptFramecryptframe_new (guint16 frame_type, const char *sender_key_id, const char *receiver_key_id, gsize framesize)
 Construct a new CryptFrame This can only be used directly for creating subclassed CryptFrame frames because CryptFrame is an abstract class... More...
 
WINEXPORT Framecryptframe_tlvconstructor (gpointer tlvstart, gconstpointer pktend, gpointer *, gpointer *)
 Given marshalled packet data corresponding to an CryptFrame - which we can't do because we're an abstract class... More...
 
WINEXPORT CryptFramePublicKeycryptframe_public_key_by_id (const char *key_id)
 Return the non-const public key with the given id. More...
 
WINEXPORT CryptFramePrivateKeycryptframe_private_key_by_id (const char *key_id)
 Return the non-const private key with the given id. More...
 
WINEXPORT CryptFramePublicKeycryptframe_publickey_new (const char *key_id, gpointer public_key)
 Create a new public key - or return the existing public key with this id. More...
 
WINEXPORT CryptFramePrivateKeycryptframe_privatekey_new (const char *key_id, gpointer private_key)
 Create a new private key - or return the existing private key with this id. More...
 
WINEXPORT gboolean cryptframe_associate_identity (const char *identity, const char *key_id)
 Associate the given key id with the given identity Note that it is OK to associate multiple key ids with a given identity but it is NOT OK to associate multiple identities with a given key id Return TRUE if we could make the association (it's OK to make the same valid association multiple times) More...
 
WINEXPORT gboolean cryptframe_dissociate_identity (const char *identity, const char *key_id)
 Dissociate the given key from the given identity (analogous to revoking the key) More...
 
WINEXPORT void cryptframe_purge_key_id (const char *key_id)
 
WINEXPORT const char * cryptframe_whois_public_key (const CryptFramePublicKey *public_key)
 Return the identity associated with the given public key object. More...
 
WINEXPORT const char * cryptframe_whois_key_id (const char *key_id)
 Return the identity associated with the given key id. More...
 
WINEXPORT GHashTable * cryptframe_key_ids_for (const char *identity)
 Return a GHashTable of strings of all the key ids associated with the given identity. More...
 
WINEXPORT GList * cryptframe_get_identities (void)
 Return a GList of strings of all known identities. More...
 
WINEXPORT GList * cryptframe_get_key_ids (void)
 Return a GList of strings of all known key ids. More...
 
WINEXPORT void cryptframe_shutdown (void)
 Shut down our key caches and so on... (destroy our maps) More...
 
WINEXPORT void cryptframe_set_signing_key_id (const char *key_id)
 Set the default signing key. More...
 
WINEXPORT const char * cryptframe_get_signing_key_id (void)
 Return the key_id of the default signing key. More...
 
WINEXPORT CryptFramePrivateKeycryptframe_get_signing_key (void)
 Return the default signing key. More...
 
WINEXPORT void cryptframe_set_dest_public_key (NetAddr *, CryptFramePublicKey *)
 Set the encryption key to use when sending to destaddr Set destkey to NULL to stop encrypting to that destination. More...
 
WINEXPORT void cryptframe_set_dest_public_key_id (NetAddr *, const char *key_id)
 Set the encryption key to use when sending to destaddr Set destkey to NULL to stop encrypting to that destination. More...
 
WINEXPORT CryptFramecryptframe_new_by_destaddr (const NetAddr *destination_address)
 Construct a CryptFrame class appropriate for encrypting messages to destaddr More...
 
WINEXPORT void cryptframe_set_encryption_method (CryptFrame *(*)(const char *sender_key_id, const char *receiver_key_id))
 

Detailed Description

Describes interfaces to CryptFrame (encryption) C-Class It represents the abstract base class for FrameSet encryption.

This file is part of the Assimilation Project.

Author
Copyright © 2011, 2012 - Alan Robertson alanr.nosp@m.@uni.nosp@m.x.sh
The Assimilation software is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

The Assimilation software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with the Assimilation Project software. If not, see http://www.gnu.org/licenses/

Definition in file cryptframe.h.