aboutsummaryrefslogtreecommitdiff
path: root/src/core/gnunet-service-core_kx.h
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2011-10-05 13:26:24 +0000
committerChristian Grothoff <christian@grothoff.org>2011-10-05 13:26:24 +0000
commit0f29195adbd56ae10dea70c2951333c13e765f88 (patch)
tree83247d0f38a2cba50209af2325bad3d74890eb71 /src/core/gnunet-service-core_kx.h
parentf39c4e7141b1fbb4830cb24ff630a879337f98d4 (diff)
downloadgnunet-0f29195adbd56ae10dea70c2951333c13e765f88.tar.gz
gnunet-0f29195adbd56ae10dea70c2951333c13e765f88.zip
towards new core service implementation -- breaking core up into smaller modules
Diffstat (limited to 'src/core/gnunet-service-core_kx.h')
-rw-r--r--src/core/gnunet-service-core_kx.h77
1 files changed, 77 insertions, 0 deletions
diff --git a/src/core/gnunet-service-core_kx.h b/src/core/gnunet-service-core_kx.h
new file mode 100644
index 000000000..f4f1daaeb
--- /dev/null
+++ b/src/core/gnunet-service-core_kx.h
@@ -0,0 +1,77 @@
1struct GSC_KeyExchangeInfo
2{
3
4 /**
5 * SetKeyMessage to transmit, NULL if we are not currently trying
6 * to send one.
7 */
8 struct SetKeyMessage *skm;
9
10 /**
11 * Non-NULL if we are currently looking up HELLOs for this peer.
12 * for this peer.
13 */
14 struct GNUNET_PEERINFO_IteratorContext *pitr;
15
16 /**
17 * Public key of the neighbour, NULL if we don't have it yet.
18 */
19 struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded *public_key;
20
21 /**
22 * We received a PING message before we got the "public_key"
23 * (or the SET_KEY). We keep it here until we have a key
24 * to decrypt it. NULL if no PING is pending.
25 */
26 struct PingMessage *pending_ping;
27
28 /**
29 * We received a PONG message before we got the "public_key"
30 * (or the SET_KEY). We keep it here until we have a key
31 * to decrypt it. NULL if no PONG is pending.
32 */
33 struct PongMessage *pending_pong;
34
35 /**
36 * Key we use to encrypt our messages for the other peer
37 * (initialized by us when we do the handshake).
38 */
39 struct GNUNET_CRYPTO_AesSessionKey encrypt_key;
40
41 /**
42 * Key we use to decrypt messages from the other peer
43 * (given to us by the other peer during the handshake).
44 */
45 struct GNUNET_CRYPTO_AesSessionKey decrypt_key;
46
47 /**
48 * At what time did we generate our encryption key?
49 */
50 struct GNUNET_TIME_Absolute encrypt_key_created;
51
52 /**
53 * At what time did the other peer generate the decryption key?
54 */
55 struct GNUNET_TIME_Absolute decrypt_key_created;
56
57 /**
58 * At what frequency are we currently re-trying SET_KEY messages?
59 */
60 struct GNUNET_TIME_Relative set_key_retry_frequency;
61
62 /**
63 * ID of task used for re-trying SET_KEY and PING message.
64 */
65 GNUNET_SCHEDULER_TaskIdentifier retry_set_key_task;
66
67 /**
68 * What was our PING challenge number (for this peer)?
69 */
70 uint32_t ping_challenge;
71
72 /**
73 * What is our connection status?
74 */
75 enum PeerStateMachine status;
76
77};