diff options
author | TheJackiMonster <thejackimonster@gmail.com> | 2020-11-12 17:32:32 +0100 |
---|---|---|
committer | TheJackiMonster <thejackimonster@gmail.com> | 2020-11-12 17:32:32 +0100 |
commit | e11d1e59e4ae5f7d89c33df3ae9ca8f1ece990cf (patch) | |
tree | 80c08d417bb0c862adcbcde7f55aa7e3a4646d27 /src/messenger/gnunet-service-messenger_message_recv.h | |
parent | fec34163a1f17729c190022a2bf747f48e34f07a (diff) | |
download | gnunet-e11d1e59e4ae5f7d89c33df3ae9ca8f1ece990cf.tar.gz gnunet-e11d1e59e4ae5f7d89c33df3ae9ca8f1ece990cf.zip |
-revert "-merge branch 'jacki/messenger'"
This reverts commit fec34163a1f17729c190022a2bf747f48e34f07a, reversing
changes made to 63fe195e40e55f13ab29e3ba578e97017fc4cc48.
Diffstat (limited to 'src/messenger/gnunet-service-messenger_message_recv.h')
-rw-r--r-- | src/messenger/gnunet-service-messenger_message_recv.h | 159 |
1 files changed, 0 insertions, 159 deletions
diff --git a/src/messenger/gnunet-service-messenger_message_recv.h b/src/messenger/gnunet-service-messenger_message_recv.h deleted file mode 100644 index 245612cb0..000000000 --- a/src/messenger/gnunet-service-messenger_message_recv.h +++ /dev/null | |||
@@ -1,159 +0,0 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | /** | ||
21 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_recv.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_MESSAGE_RECV_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_MESSAGE_RECV_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | |||
32 | #include "gnunet-service-messenger_tunnel.h" | ||
33 | #include "messenger_api_message.h" | ||
34 | |||
35 | /** | ||
36 | * Handles a received info message to change the current member id to the one generated by | ||
37 | * the host connected to. (all current tunnels will be informed about the id change) | ||
38 | * | ||
39 | * @param room Room of the message | ||
40 | * @param tunnel Receiving connection | ||
41 | * @param message INFO-Message | ||
42 | * @param hash Hash of the message | ||
43 | */ | ||
44 | void | ||
45 | recv_message_info (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
46 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
47 | |||
48 | /** | ||
49 | * Handles a received join message to forward all member information to the new member if the message was | ||
50 | * the direct reaction to a previous info message from this peer. | ||
51 | * | ||
52 | * @param room Room of the message | ||
53 | * @param tunnel Receiving connection | ||
54 | * @param message JOIN-Message | ||
55 | * @param hash Hash of the message | ||
56 | */ | ||
57 | void | ||
58 | recv_message_join (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
59 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
60 | |||
61 | /** | ||
62 | * Handles a received leave message. | ||
63 | * @see handle_message_leave() | ||
64 | * | ||
65 | * @param room Room of the message | ||
66 | * @param tunnel Receiving connection | ||
67 | * @param message LEAVE-Message | ||
68 | * @param hash Hash of the message | ||
69 | */ | ||
70 | void | ||
71 | recv_message_leave (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
72 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
73 | |||
74 | /** | ||
75 | * Handles a received name message. | ||
76 | * @see handle_message_name() | ||
77 | * | ||
78 | * @param room Room of the message | ||
79 | * @param tunnel Receiving connection | ||
80 | * @param message NAME-Message | ||
81 | * @param hash Hash of the message | ||
82 | */ | ||
83 | void | ||
84 | recv_message_name (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
85 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
86 | |||
87 | /** | ||
88 | * Handles a received key message. | ||
89 | * @see handle_message_key() | ||
90 | * | ||
91 | * @param room Room of the message | ||
92 | * @param tunnel Receiving connection | ||
93 | * @param message KEY-Message | ||
94 | * @param hash Hash of the message | ||
95 | */ | ||
96 | void | ||
97 | recv_message_key (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
98 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
99 | |||
100 | /** | ||
101 | * Handles a received peer message to link it to its origin tunnel if the peer identity matches. | ||
102 | * (the peer message and the member id can potentially be linked to the tunnel) | ||
103 | * | ||
104 | * TODO: This handling will only check the one given tunnel! | ||
105 | * | ||
106 | * @param room Room of the message | ||
107 | * @param tunnel Receiving connection | ||
108 | * @param message PEER-Message | ||
109 | * @param hash Hash of the message | ||
110 | */ | ||
111 | void | ||
112 | recv_message_peer (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
113 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
114 | |||
115 | /** | ||
116 | * Handles a received id message to change the tunnels linked member id if necessary. | ||
117 | * (the tunnels linked member id will be changed if the sender id is matching) | ||
118 | * | ||
119 | * TODO: This handling will only check the one given tunnel! | ||
120 | * | ||
121 | * @param room Room of the message | ||
122 | * @param tunnel Receiving connection | ||
123 | * @param message ID-Message | ||
124 | * @param hash Hash of the message | ||
125 | */ | ||
126 | void | ||
127 | recv_message_id (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
128 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
129 | |||
130 | /** | ||
131 | * Handles a received miss message. | ||
132 | * @see handle_message_miss() | ||
133 | * | ||
134 | * @param room Room of the message | ||
135 | * @param tunnel Receiving connection | ||
136 | * @param message MISS-Message | ||
137 | * @param hash Hash of the message | ||
138 | */ | ||
139 | void | ||
140 | recv_message_miss (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
141 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
142 | |||
143 | /** | ||
144 | * Handles a received request message by checking for the requested message and forwarding it back | ||
145 | * if the message was found. | ||
146 | * (this can also cause this peer to send a new request instead of only forwarding the received one) | ||
147 | * | ||
148 | * TODO: Requests can cause exponentially more requests! | ||
149 | * | ||
150 | * @param room Room of the message | ||
151 | * @param tunnel Receiving connection | ||
152 | * @param message REQUEST-Message | ||
153 | * @param hash Hash of the message | ||
154 | */ | ||
155 | void | ||
156 | recv_message_request (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
157 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
158 | |||
159 | #endif //GNUNET_SERVICE_MESSENGER_MESSAGE_RECV_H | ||