GNUnet  0.11.x
gnunet-service-core_sessions.h
Go to the documentation of this file.
1 /*
2  This file is part of GNUnet.
3  Copyright (C) 2009-2014 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 
26 #ifndef GNUNET_SERVICE_CORE_SESSIONS_H
27 #define GNUNET_SERVICE_CORE_SESSIONS_H
28 
29 #include "gnunet-service-core.h"
30 #include "gnunet-service-core_kx.h"
31 
32 
39 void
41  struct GSC_KeyExchangeInfo *kx);
42 
43 
51 void
53 
54 
62 void
64  const struct GNUNET_MessageHeader *msg);
65 
66 
73 void
75 
76 
84 void
86 
87 
97 void
99 
100 
107 void
109 
110 
119 void
121  const struct GNUNET_MessageHeader *msg,
122  enum GNUNET_MQ_PriorityPreferences priority);
123 
124 
131 void
133 
134 
140 void
142 
143 
151 void
153  const struct GNUNET_MessageHeader *msg);
154 
155 
164 void
166  uint16_t type);
167 
168 
172 void
173 GSC_SESSIONS_init (void);
174 
175 
179 void
180 GSC_SESSIONS_done (void);
181 
182 
183 #endif
struct GNUNET_MessageHeader * msg
Definition: 005.c:2
Globals for gnunet-service-core.
code for managing the key exchange (SET_KEY, PING, PONG) with other peers
void GSC_SESSIONS_dequeue_request(struct GSC_ClientActiveRequest *car)
Dequeue a request from a client from transmission to a particular peer.
void GSC_SESSIONS_reinit(const struct GNUNET_PeerIdentity *peer)
The other peer has indicated that it 'lost' the session (KX down), reinitialize the session on our en...
void GSC_SESSIONS_transmit(struct GSC_ClientActiveRequest *car, const struct GNUNET_MessageHeader *msg, enum GNUNET_MQ_PriorityPreferences priority)
Transmit a message to a particular peer.
void GSC_SESSIONS_add_to_typemap(const struct GNUNET_PeerIdentity *peer, uint16_t type)
The given peer send a message of the specified type.
void GSC_SESSIONS_done(void)
Shutdown sessions subsystem.
void GSC_SESSIONS_end(const struct GNUNET_PeerIdentity *pid)
End the session with the given peer (we are no longer connected).
void GSC_SESSIONS_confirm_typemap(const struct GNUNET_PeerIdentity *peer, const struct GNUNET_MessageHeader *msg)
The other peer has confirmed receiving our type map, check if it is current and if so,...
void GSC_SESSIONS_solicit(const struct GNUNET_PeerIdentity *pid)
Traffic is being solicited for the given peer.
void GSC_SESSIONS_notify_client_about_sessions(struct GSC_Client *client)
We have a new client, notify it about all current sessions.
void GSC_SESSIONS_broadcast_typemap(const struct GNUNET_MessageHeader *msg)
Broadcast an updated typemap message to all neighbours.
void GSC_SESSIONS_create(const struct GNUNET_PeerIdentity *peer, struct GSC_KeyExchangeInfo *kx)
Create a session, a key exchange was just completed.
void GSC_SESSIONS_set_typemap(const struct GNUNET_PeerIdentity *peer, const struct GNUNET_MessageHeader *msg)
We've received a typemap message from a peer, update ours.
void GSC_SESSIONS_init(void)
Initialize sessions subsystem.
void GSC_SESSIONS_queue_request(struct GSC_ClientActiveRequest *car)
Queue a request from a client for transmission to a particular peer.
static struct GNUNET_PeerIdentity pid
Identity of the peer we transmit to / connect to.
GNUNET_MQ_PriorityPreferences
Per envelope preferences and priorities.
Header for all communications.
The identity of the host (wraps the signing key of the peer).
Record kept for each request for transmission issued by a client that is still pending.
Data structure for each client connected to the CORE service.
Information about the status of a key exchange with another peer.
enum GNUNET_TESTBED_UnderlayLinkModelType type
the type of this model
struct GNUNET_TESTBED_Peer * peer
The peer associated with this model.