diff options
author | irungentoo <irungentoo@gmail.com> | 2014-03-28 22:37:42 -0400 |
---|---|---|
committer | irungentoo <irungentoo@gmail.com> | 2014-03-28 22:37:42 -0400 |
commit | 8aaa5fe996e44a0c68c069b8e70649264f5e8a56 (patch) | |
tree | 09a7a2c680425d772bdf2d2b6a0499a1ead3a00d /docs | |
parent | a11667355491b6a0b18111e0c6ef16f816521214 (diff) |
TCP server almost ready.
Diffstat (limited to 'docs')
-rw-r--r-- | docs/TCP_Network.txt | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/docs/TCP_Network.txt b/docs/TCP_Network.txt index 80cdfbdb..ee1bcbde 100644 --- a/docs/TCP_Network.txt +++ b/docs/TCP_Network.txt | |||
@@ -100,6 +100,10 @@ special ids and packets: | |||
100 | [uint8_t id (2)][uint8_t (packet id of connection that got connected)] | 100 | [uint8_t id (2)][uint8_t (packet id of connection that got connected)] |
101 | 3 - Disconnect notification: | 101 | 3 - Disconnect notification: |
102 | [uint8_t id (3)][uint8_t (packet id of connection that got disconnected)] | 102 | [uint8_t id (3)][uint8_t (packet id of connection that got disconnected)] |
103 | 4 - ping packet | ||
104 | [uint8_t id (4)][uint64_t ping_id] | ||
105 | 5 - ping response (pong) | ||
106 | [uint8_t id (5)][uint64_t ping_id] | ||
103 | 8 - onion packet (same format as initial onion packet (See: Prevent | 107 | 8 - onion packet (same format as initial onion packet (See: Prevent |
104 | tracking.txt) but packet id is 8 instead of 128) | 108 | tracking.txt) but packet id is 8 instead of 128) |
105 | 9 - onion packet response (same format as onion packet with id 142 but id is 9 | 109 | 9 - onion packet response (same format as onion packet with id 142 but id is 9 |
@@ -129,6 +133,13 @@ If the server receives an onion packet he handles it the same as he would if it | |||
129 | was one received normally via UDP, he must also assure himself that any | 133 | was one received normally via UDP, he must also assure himself that any |
130 | responses must be sent to the proper client. | 134 | responses must be sent to the proper client. |
131 | 135 | ||
136 | Ping responses must have the same ping_id as the request. | ||
137 | |||
138 | If the server recieves a ping packet he must respond with a ping response. | ||
139 | |||
140 | The server will send a ping packet to clients every 30 seconds, they have 30 | ||
141 | seconds to respond, if they don't the connection is deleted. | ||
142 | |||
132 | Client: | 143 | Client: |
133 | 144 | ||
134 | Implementation details coming soon. | 145 | Implementation details coming soon. |