Compare commits

...

51 Commits

Author SHA1 Message Date
Mark Qvist 0a29f0cfa1 Updated changelog 2023-08-15 10:38:29 +02:00
Mark Qvist 97153ad59d Updated explanation text 2023-08-15 10:30:49 +02:00
Mark Qvist bc8378fb60 Merge branch 'master' of github.com:markqvist/Reticulum 2023-08-15 10:27:15 +02:00
markqvist 3320cf8da8 Merge pull request #363 from blackjack75/master
Added suggestion to use lower baudrate if flashing fails on ESP32
2023-08-15 10:26:57 +02:00
markqvist bb53bd3f27 Merge pull request #362 from Erethon/eeprom-dump-dir
rnodeconf: Dump eeprom under specific directory
2023-08-15 10:25:17 +02:00
Mark Qvist 73eed59fab Updated docs 2023-08-15 10:23:51 +02:00
Santiago Lema 91ede52634 Added suggestion to use lower baudrate if flashing fails on ESP32 2023-08-14 20:47:40 +02:00
Dionysis Grigoropoulos 93f13a98b2 rnodeconf: Dump eeprom under specific directory 2023-08-14 20:08:40 +03:00
Mark Qvist c87c5c9709 Updated docs 2023-08-14 16:46:00 +02:00
markqvist b0c6c53430 Merge pull request #360 from Erethon/set-baud-rate-when-flashing
rnodeconf: Add option to set baud when flashing
2023-08-14 16:42:26 +02:00
Mark Qvist 94a5222390 Updated version 2023-08-13 20:38:41 +02:00
Dionysis Grigoropoulos 98bb304060 rnodeconf: Add option to set baud when flashing 2023-08-12 02:37:05 +03:00
Mark Qvist 08bfd923ea Fixed possible invalid comparison in link watchdog job 2023-08-05 15:10:00 +02:00
Mark Qvist ae28f04ce4 Added bytes input to destination hash convenience functions 2023-07-10 00:54:02 +02:00
Mark Qvist 024a742f2a Updated changelog 2023-07-09 16:51:54 +02:00
Mark Qvist df184f3e54 Updated docs 2023-07-09 16:48:45 +02:00
Mark Qvist 5542410afa Updated version 2023-07-09 16:45:52 +02:00
Mark Qvist 99205cdc0f Fixed typo in rnid 2023-07-09 16:29:40 +02:00
Mark Qvist 8c936af963 Merge branch 'master' of github.com:markqvist/Reticulum 2023-06-29 22:12:30 +02:00
Mark Qvist 7fe751e74f Updated documentation 2023-06-29 16:52:06 +02:00
markqvist 6d551578c3 Merge pull request #325 from npetrangelo/patch-3
Update __init__.py
2023-06-22 20:05:37 +02:00
markqvist 40c85fb607 Merge pull request #330 from Erethon/rnodeconf-device-selection
Fix bug in device selection of rnodeconf
2023-06-22 20:00:42 +02:00
Dionysis Grigoropoulos 743736b376 Fix bug in device selection of rnodeconf 2023-06-21 00:02:11 +03:00
Mark Qvist 7fdb431d70 Updated changelog 2023-06-13 19:27:53 +02:00
Mark Qvist ebcc3d8912 Updated manual 2023-06-13 19:27:07 +02:00
Mark Qvist 32e29a54c3 Updated manual 2023-06-13 19:21:03 +02:00
Mark Qvist 049733c4b6 Fixed race condition for link initiators on timed out link establishment 2023-06-13 19:20:54 +02:00
Mark Qvist 420d58527d Merge branch 'master' of github.com:markqvist/Reticulum 2023-06-13 16:11:28 +02:00
Mark Qvist bab779a34c Fixed race condition for link initiators on timed out link establishment 2023-06-13 16:10:47 +02:00
markqvist 45aa71b2b7 Merge pull request #326 from SebastianObi/master
RNodeInterface - Fixed missing init of 'r_stat_snr'.
2023-06-07 18:40:50 +02:00
SebastianObi 6dcfe2cad6 Fixed missing init of 'r_stat_snr'.
This this will otherwise lead to the error:
AttributeError: 'RNodeInterface' object has no attribute 'r_stat_snr'
2023-06-07 17:43:14 +02:00
SebastianObi f206047908 Fixed missing init of 'r_stat_snr'.
This this will otherwise lead to the error:
AttributeError: 'RNodeInterface' object has no attribute 'r_stat_snr'
2023-06-07 17:42:44 +02:00
Nathan Petrangelo 6ce979a7de Update __init__.py
Auto convert log messages to strings on the way in
2023-06-05 17:31:52 -04:00
Mark Qvist 97f97eb063 Updated changelog 2023-06-03 16:04:18 +02:00
Mark Qvist f3db762e9f Updated documentation 2023-06-03 16:03:13 +02:00
Mark Qvist f9f623dfa5 Updated version and changelog 2023-06-03 15:52:44 +02:00
Mark Qvist ffa6bec3b4 Updated parser 2023-06-02 21:24:57 +02:00
Mark Qvist 4f78973751 Fixed race condition when timed-out link receives a late establishment proof a few milliseconds after it has timed out 2023-06-02 21:24:49 +02:00
Mark Qvist a8a7af4b74 Handle missing identity file in rncp. Fixes #317. 2023-05-31 15:39:55 +02:00
Mark Qvist 45295c779c Updated changelog 2023-05-19 11:38:46 +02:00
Mark Qvist a82376d1f5 Updated manuals 2023-05-19 11:35:45 +02:00
Mark Qvist 75c6248264 Updated documentation 2023-05-19 11:31:43 +02:00
Mark Qvist 9294ab4f97 Updated version 2023-05-19 11:31:36 +02:00
Mark Qvist f01193e854 Updated documentation 2023-05-19 03:06:24 +02:00
Mark Qvist d7375bc4c3 Fixed callback invocation on channel receive 2023-05-19 01:58:28 +02:00
Mark Qvist 1a860c6ffd Add EOF signal on buffer close 2023-05-19 01:57:20 +02:00
Mark Qvist 800ed3af7a Fixed ready callback invocation 2023-05-18 23:35:28 +02:00
Mark Qvist 9c8e79546c Fixed missing check in receipt culling 2023-05-18 23:33:26 +02:00
Mark Qvist 4c272aa536 Updated buffer tests for windowed channel 2023-05-18 23:32:29 +02:00
Mark Qvist e184861822 Enabled channel tests 2023-05-18 23:31:29 +02:00
Mark Qvist d40e19f08d Updated gitignore 2023-05-18 23:29:31 +02:00
57 changed files with 835 additions and 13738 deletions
+1 -1
View File
@@ -10,6 +10,6 @@ docs/build
rns*.egg-info rns*.egg-info
profile.data profile.data
tests/rnsconfig/storage tests/rnsconfig/storage
tests/rnsconfig/logfile tests/rnsconfig/logfile*
*.data *.data
*.result *.result
+70
View File
@@ -1,3 +1,73 @@
### 2023-08-14: RNS β 0.5.7
This maintenance release contains a number of bugfixes and quality improvements to Reticulum and related tools.
**Changes**
- Added bytes input to destination hash convenience functions
- Fixed possible invalid comparison in link watchdog job
- Add option to `rnodeconf` to set baud rate when flashing
- Added better explanation in `rnodeconf` when flashing fails
- Fixed EEPROM dump directory in `rnodeconf`
**Release Hashes**
```
867fbb5c73c2a49a75e1f8f3e9f376b507b683328e26c64d4387acd0cc1dbbc7 rns-0.5.7-py3-none-any.whl
7bab2865264b32208e023b5c4bbe88c37f51e3176ca4a8cf332d95f59a6d7f2c rnspure-0.5.7-py3-none-any.whl
```
### 2023-07-09: RNS β 0.5.6
This maintenance release contains a few bugfixes.
**Changes**
- Fixed an issue in `rnodeconf` that prevented Heltec LoRa32 v2 boards from being flashed.
- Fixed a typo in the `rnid` utility.
**Release Hashes**
```
255a5b4bac28326c6b2cc85f43b26dcb0606404a4abd2dfa8244937155838973 rns-0.5.6-py3-none-any.whl
1510b6da4641ceaa4c599a142e498c7e2c1ae12035868f9db1c111e5600161e9 rnspure-0.5.6-py3-none-any.whl
```
### 2023-06-13: RNS β 0.5.5
This maintenance release brings a single bugfix.
**Changes**
- Fixed a race condition for link initiators on timed out link establishments.
**Release Hashes**
```
4ae61d28bf981a7cb853c179e9de3b56b350d2dc984fb671a21d38c4ce5b449e rns-0.5.5-py3-none-any.whl
ed417cbd3c90e9f1b68565a3411ca5c9bc936b495300fd1ace3c4a6414aabd5a rnspure-0.5.5-py3-none-any.whl
```
### 2023-05-19: RNS β 0.5.4
This maintenance release brings a single bugfix.
**Changes**
- Fixed a potential race condition when timed-out link receives a late establishment proof a few milliseconds after it has timed out.
**Release Hashes**
```
71b42fe737da97a4b63bb227c29bb67854a7f003c9585f085b0ff68c8f460815 rns-0.5.4-py3-none-any.whl
af6949d581445444f57cfca75756200e7c509a6fc66483d859716ce6a06064db rnspure-0.5.4-py3-none-any.whl
```
### 2023-05-19: RNS β 0.5.3
This maintenance release brings a single, but important bugfix.
**Changes**
- Fixed a bug that could cause data corruption to occur over when using `Buffer` instances.
**Release Hashes**
```
f23c8d655c9e80a12a6728495aec56f19f27184d3d8e6b6ed6184b0e89d4be35 rns-0.5.3-py3-none-any.whl
2c692a2153bb766a9dc2391340a06f429c13a75b86b746b69c6fcd5a4fe5ee33 rnspure-0.5.3-py3-none-any.whl
```
### 2023-05-12: RNS β 0.5.2 ### 2023-05-12: RNS β 0.5.2
This maintenance release brings a number of bugfixes and improvements. This maintenance release brings a number of bugfixes and improvements.
+12 -1
View File
@@ -1,6 +1,7 @@
from __future__ import annotations from __future__ import annotations
import bz2 import bz2
import sys import sys
import time
import threading import threading
from threading import RLock from threading import RLock
import struct import struct
@@ -65,6 +66,7 @@ class StreamDataMessage(MessageBase):
self.compressed = (0x4000 & self.stream_id) > 0 self.compressed = (0x4000 & self.stream_id) > 0
self.stream_id = self.stream_id & 0x3fff self.stream_id = self.stream_id & 0x3fff
self.data = raw[2:] self.data = raw[2:]
if self.compressed: if self.compressed:
self.data = bz2.decompress(self.data) self.data = bz2.decompress(self.data)
@@ -129,7 +131,7 @@ class RawChannelReader(RawIOBase, AbstractContextManager):
self._eof = True self._eof = True
for listener in self._listeners: for listener in self._listeners:
try: try:
listener(len(self._buffer)) threading.Thread(target=listener, name="Message Callback", args=[len(self._buffer)], daemon=True).start()
except Exception as ex: except Exception as ex:
RNS.log("Error calling RawChannelReader(" + str(self._stream_id) + ") callback: " + str(ex)) RNS.log("Error calling RawChannelReader(" + str(self._stream_id) + ") callback: " + str(ex))
return True return True
@@ -207,6 +209,15 @@ class RawChannelWriter(RawIOBase, AbstractContextManager):
return 0 return 0
def close(self): def close(self):
try:
link_rtt = self._channel._outlet.link.rtt
timeout = time.time() + (link_rtt * len(self._channel._tx_ring) * 1)
except Exception as e:
timeout = time.time() + 15
while time.time() < timeout and not self._channel.is_ready_to_send():
time.sleep(0.05)
self._eof = True self._eof = True
self.write(bytes()) self.write(bytes())
+37 -22
View File
@@ -176,6 +176,9 @@ class Envelope:
raise ChannelException(CEType.ME_NOT_REGISTERED, f"Unable to find constructor for Channel MSGTYPE {hex(msgtype)}") raise ChannelException(CEType.ME_NOT_REGISTERED, f"Unable to find constructor for Channel MSGTYPE {hex(msgtype)}")
message = ctor() message = ctor()
message.unpack(raw) message.unpack(raw)
self.unpacked = True
self.message = message
return message return message
def pack(self) -> bytes: def pack(self) -> bytes:
@@ -183,6 +186,7 @@ class Envelope:
raise ChannelException(CEType.ME_NO_MSG_TYPE, f"{self.message.__class__} lacks MSGTYPE") raise ChannelException(CEType.ME_NO_MSG_TYPE, f"{self.message.__class__} lacks MSGTYPE")
data = self.message.pack() data = self.message.pack()
self.raw = struct.pack(">HHH", self.message.MSGTYPE, self.sequence, len(data)) + data self.raw = struct.pack(">HHH", self.message.MSGTYPE, self.sequence, len(data)) + data
self.packed = True
return self.raw return self.raw
def __init__(self, outlet: ChannelOutletBase, message: MessageBase = None, raw: bytes = None, sequence: int = None): def __init__(self, outlet: ChannelOutletBase, message: MessageBase = None, raw: bytes = None, sequence: int = None):
@@ -194,6 +198,8 @@ class Envelope:
self.sequence = sequence self.sequence = sequence
self.outlet = outlet self.outlet = outlet
self.tries = 0 self.tries = 0
self.unpacked = False
self.packed = False
self.tracked = False self.tracked = False
@@ -371,22 +377,29 @@ class Channel(contextlib.AbstractContextManager):
def _emplace_envelope(self, envelope: Envelope, ring: collections.deque[Envelope]) -> bool: def _emplace_envelope(self, envelope: Envelope, ring: collections.deque[Envelope]) -> bool:
with self._lock: with self._lock:
i = 0 i = 0
window_overflow = (self._next_rx_sequence+Channel.WINDOW_MAX) % Channel.SEQ_MODULUS
for existing in ring: for existing in ring:
if existing.sequence > envelope.sequence \
and not existing.sequence // 2 > envelope.sequence: # account for overflow if envelope.sequence == existing.sequence:
ring.insert(i, envelope)
return True
if existing.sequence == envelope.sequence:
RNS.log(f"Envelope: Emplacement of duplicate envelope with sequence "+str(envelope.sequence), RNS.LOG_EXTREME) RNS.log(f"Envelope: Emplacement of duplicate envelope with sequence "+str(envelope.sequence), RNS.LOG_EXTREME)
return False return False
if envelope.sequence < existing.sequence and not envelope.sequence < window_overflow:
ring.insert(i, envelope)
RNS.log("Inserted seq "+str(envelope.sequence)+" at "+str(i), RNS.LOG_DEBUG)
envelope.tracked = True
return True
i += 1 i += 1
envelope.tracked = True envelope.tracked = True
ring.append(envelope) ring.append(envelope)
return True return True
def _run_callbacks(self, message: MessageBase): def _run_callbacks(self, message: MessageBase):
with self._lock: cbs = self._message_callbacks.copy()
cbs = self._message_callbacks.copy()
for cb in cbs: for cb in cbs:
try: try:
@@ -405,12 +418,11 @@ class Channel(contextlib.AbstractContextManager):
window_overflow = (self._next_rx_sequence+Channel.WINDOW_MAX) % Channel.SEQ_MODULUS window_overflow = (self._next_rx_sequence+Channel.WINDOW_MAX) % Channel.SEQ_MODULUS
if window_overflow < self._next_rx_sequence: if window_overflow < self._next_rx_sequence:
if envelope.sequence > window_overflow: if envelope.sequence > window_overflow:
RNS.log("Invalid packet sequence ("+str(envelope.sequence)+") received on channel "+str(self), RNS.LOG_DEBUG) RNS.log("Invalid packet sequence ("+str(envelope.sequence)+") received on channel "+str(self), RNS.LOG_EXTREME)
return return
else: else:
if envelope.sequence < self._next_rx_sequence: RNS.log("Invalid packet sequence ("+str(envelope.sequence)+") received on channel "+str(self), RNS.LOG_EXTREME)
RNS.log("Invalid packet sequence ("+str(envelope.sequence)+") received on channel "+str(self), RNS.LOG_DEBUG) return
return
is_new = self._emplace_envelope(envelope, self._rx_ring) is_new = self._emplace_envelope(envelope, self._rx_ring)
@@ -426,9 +438,13 @@ class Channel(contextlib.AbstractContextManager):
self._next_rx_sequence = (self._next_rx_sequence + 1) % Channel.SEQ_MODULUS self._next_rx_sequence = (self._next_rx_sequence + 1) % Channel.SEQ_MODULUS
for e in contigous: for e in contigous:
m = e.unpack(self._message_factories) if not e.unpacked:
m = e.unpack(self._message_factories)
else:
m = e.message
self._rx_ring.remove(e) self._rx_ring.remove(e)
threading.Thread(target=self._run_callbacks, name="Message Callback", args=[m], daemon=True).start() self._run_callbacks(m)
except Exception as e: except Exception as e:
RNS.log("An error ocurred while receiving data on "+str(self)+". The contained exception was: "+str(e), RNS.LOG_ERROR) RNS.log("An error ocurred while receiving data on "+str(self)+". The contained exception was: "+str(e), RNS.LOG_ERROR)
@@ -469,7 +485,7 @@ class Channel(contextlib.AbstractContextManager):
self.window_min += 1 self.window_min += 1
# TODO: Remove at some point # TODO: Remove at some point
RNS.log("Increased "+str(self)+" window to "+str(self.window), RNS.LOG_DEBUG) # RNS.log("Increased "+str(self)+" window to "+str(self.window), RNS.LOG_EXTREME)
if self._outlet.rtt != 0: if self._outlet.rtt != 0:
if self._outlet.rtt > Channel.RTT_FAST: if self._outlet.rtt > Channel.RTT_FAST:
@@ -483,19 +499,17 @@ class Channel(contextlib.AbstractContextManager):
if self.window_max < Channel.WINDOW_MAX_MEDIUM and self.medium_rate_rounds == Channel.FAST_RATE_THRESHOLD: if self.window_max < Channel.WINDOW_MAX_MEDIUM and self.medium_rate_rounds == Channel.FAST_RATE_THRESHOLD:
self.window_max = Channel.WINDOW_MAX_MEDIUM self.window_max = Channel.WINDOW_MAX_MEDIUM
# TODO: Remove at some point # TODO: Remove at some point
RNS.log("Increased "+str(self)+" max window to "+str(self.window_max), RNS.LOG_EXTREME) # RNS.log("Increased "+str(self)+" max window to "+str(self.window_max), RNS.LOG_EXTREME)
else: else:
self.fast_rate_rounds += 1 self.fast_rate_rounds += 1
if self.window_max < Channel.WINDOW_MAX_FAST and self.fast_rate_rounds == Channel.FAST_RATE_THRESHOLD: if self.window_max < Channel.WINDOW_MAX_FAST and self.fast_rate_rounds == Channel.FAST_RATE_THRESHOLD:
self.window_max = Channel.WINDOW_MAX_FAST self.window_max = Channel.WINDOW_MAX_FAST
# TODO: Remove at some point # TODO: Remove at some point
RNS.log("Increased "+str(self)+" max window to "+str(self.window_max), RNS.LOG_EXTREME) # RNS.log("Increased "+str(self)+" max window to "+str(self.window_max), RNS.LOG_EXTREME)
else: else:
RNS.log("Envelope not found in TX ring for "+str(self), RNS.LOG_DEBUG) RNS.log("Envelope not found in TX ring for "+str(self), RNS.LOG_EXTREME)
if not envelope: if not envelope:
RNS.log("Spurious message received on "+str(self), RNS.LOG_EXTREME) RNS.log("Spurious message received on "+str(self), RNS.LOG_EXTREME)
@@ -525,7 +539,7 @@ class Channel(contextlib.AbstractContextManager):
self.window_max -= 1 self.window_max -= 1
# TODO: Remove at some point # TODO: Remove at some point
RNS.log("Decreased "+str(self)+" window to "+str(self.window), RNS.LOG_EXTREME) # RNS.log("Decreased "+str(self)+" window to "+str(self.window), RNS.LOG_EXTREME)
return False return False
@@ -543,16 +557,18 @@ class Channel(contextlib.AbstractContextManager):
with self._lock: with self._lock:
if not self.is_ready_to_send(): if not self.is_ready_to_send():
raise ChannelException(CEType.ME_LINK_NOT_READY, f"Link is not ready") raise ChannelException(CEType.ME_LINK_NOT_READY, f"Link is not ready")
envelope = Envelope(self._outlet, message=message, sequence=self._next_sequence) envelope = Envelope(self._outlet, message=message, sequence=self._next_sequence)
self._next_sequence = (self._next_sequence + 1) % Channel.SEQ_MODULUS self._next_sequence = (self._next_sequence + 1) % Channel.SEQ_MODULUS
self._emplace_envelope(envelope, self._tx_ring) self._emplace_envelope(envelope, self._tx_ring)
if envelope is None: if envelope is None:
raise BlockingIOError() raise BlockingIOError()
envelope.pack() envelope.pack()
if len(envelope.raw) > self._outlet.mdu: if len(envelope.raw) > self._outlet.mdu:
raise ChannelException(CEType.ME_TOO_BIG, f"Packed message too big for packet: {len(envelope.raw)} > {self._outlet.mdu}") raise ChannelException(CEType.ME_TOO_BIG, f"Packed message too big for packet: {len(envelope.raw)} > {self._outlet.mdu}")
envelope.packet = self._outlet.send(envelope.raw) envelope.packet = self._outlet.send(envelope.raw)
envelope.tries += 1 envelope.tries += 1
self._outlet.set_packet_delivered_callback(envelope.packet, self._packet_delivered) self._outlet.set_packet_delivered_callback(envelope.packet, self._packet_delivered)
@@ -591,7 +607,6 @@ class LinkChannelOutlet(ChannelOutletBase):
return packet return packet
def resend(self, packet: RNS.Packet) -> RNS.Packet: def resend(self, packet: RNS.Packet) -> RNS.Packet:
RNS.log("Resending packet " + RNS.prettyhexrep(packet.packet_hash), RNS.LOG_DEBUG)
receipt = packet.resend() receipt = packet.resend()
if not receipt: if not receipt:
RNS.log("Failed to resend packet", RNS.LOG_ERROR) RNS.log("Failed to resend packet", RNS.LOG_ERROR)
+6 -1
View File
@@ -99,7 +99,12 @@ class Destination:
name_hash = RNS.Identity.full_hash(Destination.expand_name(None, app_name, *aspects).encode("utf-8"))[:(RNS.Identity.NAME_HASH_LENGTH//8)] name_hash = RNS.Identity.full_hash(Destination.expand_name(None, app_name, *aspects).encode("utf-8"))[:(RNS.Identity.NAME_HASH_LENGTH//8)]
addr_hash_material = name_hash addr_hash_material = name_hash
if identity != None: if identity != None:
addr_hash_material += identity.hash if isinstance(identity, RNS.Identity):
addr_hash_material += identity.hash
elif isinstance(identity, bytes) and len(identity) == RNS.Reticulum.TRUNCATED_HASHLENGTH//8:
addr_hash_material += identity
else:
raise TypeError("Invalid material supplied for destination hash calculation")
return RNS.Identity.full_hash(addr_hash_material)[:RNS.Reticulum.TRUNCATED_HASHLENGTH//8] return RNS.Identity.full_hash(addr_hash_material)[:RNS.Reticulum.TRUNCATED_HASHLENGTH//8]
+1 -1
View File
@@ -452,7 +452,7 @@ class Identity:
return False return False
except Exception as e: except Exception as e:
RNS.log("Error while loading identity from "+str(path), RNS.LOG_ERROR) RNS.log("Error while loading identity from "+str(path), RNS.LOG_ERROR)
RNS.log("The contained exception was: "+str(e)) RNS.log("The contained exception was: "+str(e), RNS.LOG_ERROR)
def get_salt(self): def get_salt(self):
return self.hash return self.hash
+1
View File
@@ -395,6 +395,7 @@ class RNodeInterface(Interface):
self.r_stat_rx = None self.r_stat_rx = None
self.r_stat_tx = None self.r_stat_tx = None
self.r_stat_rssi = None self.r_stat_rssi = None
self.r_stat_snr = None
self.r_random = None self.r_random = None
self.packet_queue = [] self.packet_queue = []
+1
View File
@@ -157,6 +157,7 @@ class RNodeInterface(Interface):
self.r_stat_rx = None self.r_stat_rx = None
self.r_stat_tx = None self.r_stat_tx = None
self.r_stat_rssi = None self.r_stat_rssi = None
self.r_stat_snr = None
self.r_random = None self.r_random = None
self.packet_queue = [] self.packet_queue = []
+61 -45
View File
@@ -225,15 +225,18 @@ class Link:
self.hash = self.link_id self.hash = self.link_id
def handshake(self): def handshake(self):
self.status = Link.HANDSHAKE if self.status == Link.PENDING and self.prv != None:
self.shared_key = self.prv.exchange(self.peer_pub) self.status = Link.HANDSHAKE
self.shared_key = self.prv.exchange(self.peer_pub)
self.derived_key = RNS.Cryptography.hkdf( self.derived_key = RNS.Cryptography.hkdf(
length=32, length=32,
derive_from=self.shared_key, derive_from=self.shared_key,
salt=self.get_salt(), salt=self.get_salt(),
context=self.get_context(), context=self.get_context(),
) )
else:
RNS.log("Handshake attempt on "+str(self)+" with invalid state "+str(self.status), RNS.LOG_ERROR)
def prove(self): def prove(self):
@@ -261,41 +264,50 @@ class Link:
self.had_outbound() self.had_outbound()
def validate_proof(self, packet): def validate_proof(self, packet):
if self.status == Link.PENDING: try:
if self.initiator and len(packet.data) == RNS.Identity.SIGLENGTH//8+Link.ECPUBSIZE//2: if self.status == Link.PENDING:
peer_pub_bytes = packet.data[RNS.Identity.SIGLENGTH//8:RNS.Identity.SIGLENGTH//8+Link.ECPUBSIZE//2] if self.initiator and len(packet.data) == RNS.Identity.SIGLENGTH//8+Link.ECPUBSIZE//2:
peer_sig_pub_bytes = self.destination.identity.get_public_key()[Link.ECPUBSIZE//2:Link.ECPUBSIZE] peer_pub_bytes = packet.data[RNS.Identity.SIGLENGTH//8:RNS.Identity.SIGLENGTH//8+Link.ECPUBSIZE//2]
self.load_peer(peer_pub_bytes, peer_sig_pub_bytes) peer_sig_pub_bytes = self.destination.identity.get_public_key()[Link.ECPUBSIZE//2:Link.ECPUBSIZE]
self.handshake() self.load_peer(peer_pub_bytes, peer_sig_pub_bytes)
self.handshake()
self.establishment_cost += len(packet.raw) self.establishment_cost += len(packet.raw)
signed_data = self.link_id+self.peer_pub_bytes+self.peer_sig_pub_bytes signed_data = self.link_id+self.peer_pub_bytes+self.peer_sig_pub_bytes
signature = packet.data[:RNS.Identity.SIGLENGTH//8] signature = packet.data[:RNS.Identity.SIGLENGTH//8]
if self.destination.identity.validate(signature, signed_data): if self.destination.identity.validate(signature, signed_data):
self.rtt = time.time() - self.request_time if self.status != Link.HANDSHAKE:
self.attached_interface = packet.receiving_interface raise IOError("Invalid link state for proof validation: "+str(self.status))
self.__remote_identity = self.destination.identity
self.status = Link.ACTIVE
self.activated_at = time.time()
self.last_proof = self.activated_at
RNS.Transport.activate_link(self)
RNS.log("Link "+str(self)+" established with "+str(self.destination)+", RTT is "+str(round(self.rtt, 3))+"s", RNS.LOG_VERBOSE)
if self.rtt != None and self.establishment_cost != None and self.rtt > 0 and self.establishment_cost > 0: self.rtt = time.time() - self.request_time
self.establishment_rate = self.establishment_cost/self.rtt self.attached_interface = packet.receiving_interface
self.__remote_identity = self.destination.identity
self.status = Link.ACTIVE
self.activated_at = time.time()
self.last_proof = self.activated_at
RNS.Transport.activate_link(self)
RNS.log("Link "+str(self)+" established with "+str(self.destination)+", RTT is "+str(round(self.rtt, 3))+"s", RNS.LOG_VERBOSE)
rtt_data = umsgpack.packb(self.rtt) if self.rtt != None and self.establishment_cost != None and self.rtt > 0 and self.establishment_cost > 0:
rtt_packet = RNS.Packet(self, rtt_data, context=RNS.Packet.LRRTT) self.establishment_rate = self.establishment_cost/self.rtt
rtt_packet.send()
self.had_outbound()
if self.callbacks.link_established != None: rtt_data = umsgpack.packb(self.rtt)
thread = threading.Thread(target=self.callbacks.link_established, args=(self,)) rtt_packet = RNS.Packet(self, rtt_data, context=RNS.Packet.LRRTT)
thread.daemon = True rtt_packet.send()
thread.start() self.had_outbound()
else:
RNS.log("Invalid link proof signature received by "+str(self)+". Ignoring.", RNS.LOG_DEBUG) if self.callbacks.link_established != None:
thread = threading.Thread(target=self.callbacks.link_established, args=(self,))
thread.daemon = True
thread.start()
else:
RNS.log("Invalid link proof signature received by "+str(self)+". Ignoring.", RNS.LOG_DEBUG)
except Exception as e:
self.status = Link.CLOSED
RNS.log("An error ocurred while validating link request proof on "+str(self)+".", RNS.LOG_ERROR)
RNS.log("The contained exception was: "+str(e), RNS.LOG_ERROR)
def identify(self, identity): def identify(self, identity):
@@ -498,7 +510,11 @@ class Link:
def __watchdog_job(self): def __watchdog_job(self):
while not self.status == Link.CLOSED: while not self.status == Link.CLOSED:
while (self.watchdog_lock): while (self.watchdog_lock):
sleep(max(self.rtt, 0.025)) rtt_wait = 0.025
if hasattr(self, "rtt") and self.rtt:
rtt_wait = self.rtt
sleep(max(rtt_wait, 0.025))
if not self.status == Link.CLOSED: if not self.status == Link.CLOSED:
# Link was initiated, but no response # Link was initiated, but no response
@@ -517,16 +533,16 @@ class Link:
next_check = self.request_time + self.establishment_timeout next_check = self.request_time + self.establishment_timeout
sleep_time = next_check - time.time() sleep_time = next_check - time.time()
if time.time() >= self.request_time + self.establishment_timeout: if time.time() >= self.request_time + self.establishment_timeout:
if self.initiator:
RNS.log("Timeout waiting for link request proof", RNS.LOG_DEBUG)
else:
RNS.log("Timeout waiting for RTT packet from link initiator", RNS.LOG_DEBUG)
self.status = Link.CLOSED self.status = Link.CLOSED
self.teardown_reason = Link.TIMEOUT self.teardown_reason = Link.TIMEOUT
self.link_closed() self.link_closed()
sleep_time = 0.001 sleep_time = 0.001
if self.initiator:
RNS.log("Timeout waiting for link request proof", RNS.LOG_DEBUG)
else:
RNS.log("Timeout waiting for RTT packet from link initiator", RNS.LOG_DEBUG)
elif self.status == Link.ACTIVE: elif self.status == Link.ACTIVE:
activated_at = self.activated_at if self.activated_at != None else 0 activated_at = self.activated_at if self.activated_at != None else 0
last_inbound = max(max(self.last_inbound, self.last_proof), activated_at) last_inbound = max(max(self.last_inbound, self.last_proof), activated_at)
@@ -844,7 +860,7 @@ class Link:
try: try:
self.fernet = Fernet(self.derived_key) self.fernet = Fernet(self.derived_key)
except Exception as e: except Exception as e:
RNS.log("Could not "+str(self)+" instantiate Fernet while performin encryption on link. The contained exception was: "+str(e), RNS.LOG_ERROR) RNS.log("Could not instantiate Fernet while performin encryption on link "+str(self)+". The contained exception was: "+str(e), RNS.LOG_ERROR)
raise e raise e
return self.fernet.encrypt(plaintext) return self.fernet.encrypt(plaintext)
+4 -1
View File
@@ -334,7 +334,8 @@ class Transport:
for receipt in Transport.receipts: for receipt in Transport.receipts:
receipt.check_timeout() receipt.check_timeout()
if receipt.status != RNS.PacketReceipt.SENT: if receipt.status != RNS.PacketReceipt.SENT:
Transport.receipts.remove(receipt) if receipt in Transport.receipts:
Transport.receipts.remove(receipt)
Transport.receipts_last_checked = time.time() Transport.receipts_last_checked = time.time()
@@ -1740,6 +1741,8 @@ class Transport:
def activate_link(link): def activate_link(link):
RNS.log("Activating link "+str(link), RNS.LOG_EXTREME) RNS.log("Activating link "+str(link), RNS.LOG_EXTREME)
if link in Transport.pending_links: if link in Transport.pending_links:
if link.status != RNS.Link.ACTIVE:
raise IOError("Invalid link state for link activation: "+str(link.status))
Transport.pending_links.remove(link) Transport.pending_links.remove(link)
Transport.active_links.append(link) Transport.active_links.append(link)
link.status = RNS.Link.ACTIVE link.status = RNS.Link.ACTIVE
+5
View File
@@ -227,6 +227,11 @@ def send(configdir, verbosity = 0, quietness = 0, destination = None, file = Non
identity_path = RNS.Reticulum.identitypath+"/"+APP_NAME identity_path = RNS.Reticulum.identitypath+"/"+APP_NAME
if os.path.isfile(identity_path): if os.path.isfile(identity_path):
identity = RNS.Identity.from_file(identity_path) identity = RNS.Identity.from_file(identity_path)
if identity == None:
RNS.log("Could not load identity for rncp. The identity file at \""+str(identity_path)+"\" may be corrupt or unreadable.", RNS.LOG_ERROR)
exit(2)
else:
identity = None
if identity == None: if identity == None:
RNS.log("No valid saved identity found, creating new...", RNS.LOG_INFO) RNS.log("No valid saved identity found, creating new...", RNS.LOG_INFO)
+1 -1
View File
@@ -69,7 +69,7 @@ def main():
parser.add_argument("-q", "--quiet", action="count", default=0, help="decrease verbosity") parser.add_argument("-q", "--quiet", action="count", default=0, help="decrease verbosity")
parser.add_argument("-a", "--announce", metavar="aspects", action="store", default=None, help="announce a destination based on this Identity") parser.add_argument("-a", "--announce", metavar="aspects", action="store", default=None, help="announce a destination based on this Identity")
parser.add_argument("-H", "--hash", metavar="aspects", action="store", default=None, help="show destination hash5s for other aspects for this Identity") parser.add_argument("-H", "--hash", metavar="aspects", action="store", default=None, help="show destination hashes for other aspects for this Identity")
parser.add_argument("-e", "--encrypt", metavar="path", action="store", default=None, help="encrypt file") parser.add_argument("-e", "--encrypt", metavar="path", action="store", default=None, help="encrypt file")
parser.add_argument("-d", "--decrypt", metavar="path", action="store", default=None, help="decrypt file") parser.add_argument("-d", "--decrypt", metavar="path", action="store", default=None, help="decrypt file")
parser.add_argument("-s", "--sign", metavar="path", action="store", default=None, help="sign file") parser.add_argument("-s", "--sign", metavar="path", action="store", default=None, help="sign file")
Regular → Executable
+35 -27
View File
@@ -1,4 +1,4 @@
#!python3 #!/usr/bin/env python3
# MIT License # MIT License
# #
@@ -237,6 +237,7 @@ try:
EXT_DIR = CNF_DIR+"/extracted" EXT_DIR = CNF_DIR+"/extracted"
RT_PATH = CNF_DIR+"/recovery_esptool.py" RT_PATH = CNF_DIR+"/recovery_esptool.py"
TK_DIR = CNF_DIR+"/trusted_keys" TK_DIR = CNF_DIR+"/trusted_keys"
ROM_DIR = CNF_DIR+"/eeprom"
if not os.path.isdir(CNF_DIR): if not os.path.isdir(CNF_DIR):
os.makedirs(CNF_DIR) os.makedirs(CNF_DIR)
@@ -248,6 +249,8 @@ try:
os.makedirs(EXT_DIR) os.makedirs(EXT_DIR)
if not os.path.isdir(TK_DIR): if not os.path.isdir(TK_DIR):
os.makedirs(TK_DIR) os.makedirs(TK_DIR)
if not os.path.isdir(ROM_DIR):
os.makedirs(ROM_DIR)
except Exception as e: except Exception as e:
print("No access to directory "+str(CNF_DIR)+". This utility needs file system access to store firmware and data files. Cannot continue.") print("No access to directory "+str(CNF_DIR)+". This utility needs file system access to store firmware and data files. Cannot continue.")
@@ -1131,6 +1134,7 @@ def main():
parser.add_argument("-e", "--extract", action="store_true", help="Extract firmware from connected RNode for later use") parser.add_argument("-e", "--extract", action="store_true", help="Extract firmware from connected RNode for later use")
parser.add_argument("-E", "--use-extracted", action="store_true", help="Use the extracted firmware for autoinstallation or update") parser.add_argument("-E", "--use-extracted", action="store_true", help="Use the extracted firmware for autoinstallation or update")
parser.add_argument("-C", "--clear-cache", action="store_true", help="Clear locally cached firmware files") parser.add_argument("-C", "--clear-cache", action="store_true", help="Clear locally cached firmware files")
parser.add_argument("--baud-flash", action="store", metavar="baud_flash", type=str, default="921600", help="Set specific baud rate when flashing device. Default is 921600")
parser.add_argument("-N", "--normal", action="store_true", help="Switch device to normal mode") parser.add_argument("-N", "--normal", action="store_true", help="Switch device to normal mode")
parser.add_argument("-T", "--tnc", action="store_true", help="Switch device to TNC mode") parser.add_argument("-T", "--tnc", action="store_true", help="Switch device to TNC mode")
@@ -1348,11 +1352,11 @@ def main():
hash_f.close() hash_f.close()
extraction_parts = [ extraction_parts = [
("bootloader", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud 921600 --before default_reset --after hard_reset read_flash 0x1000 0x4650 \""+EXT_DIR+"/extracted_rnode_firmware.bootloader\""), ("bootloader", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud "+args.baud_flash+" --before default_reset --after hard_reset read_flash 0x1000 0x4650 \""+EXT_DIR+"/extracted_rnode_firmware.bootloader\""),
("partition table", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud 921600 --before default_reset --after hard_reset read_flash 0x8000 0xC00 \""+EXT_DIR+"/extracted_rnode_firmware.partitions\""), ("partition table", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud "+args.baud_flash+" --before default_reset --after hard_reset read_flash 0x8000 0xC00 \""+EXT_DIR+"/extracted_rnode_firmware.partitions\""),
("app boot", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud 921600 --before default_reset --after hard_reset read_flash 0xe000 0x2000 \""+EXT_DIR+"/extracted_rnode_firmware.boot_app0\""), ("app boot", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud "+args.baud_flash+" --before default_reset --after hard_reset read_flash 0xe000 0x2000 \""+EXT_DIR+"/extracted_rnode_firmware.boot_app0\""),
("application image", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud 921600 --before default_reset --after hard_reset read_flash 0x10000 0x200000 \""+EXT_DIR+"/extracted_rnode_firmware.bin\""), ("application image", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud "+args.baud_flash+" --before default_reset --after hard_reset read_flash 0x10000 0x200000 \""+EXT_DIR+"/extracted_rnode_firmware.bin\""),
("console image", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud 921600 --before default_reset --after hard_reset read_flash 0x210000 0x1F0000 \""+EXT_DIR+"/extracted_console_image.bin\""), ("console image", "python \""+CNF_DIR+"/recovery_esptool.py\" --chip esp32 --port "+port_path+" --baud "+args.baud_flash+" --before default_reset --after hard_reset read_flash 0x210000 0x1F0000 \""+EXT_DIR+"/extracted_console_image.bin\""),
] ]
import subprocess, shlex import subprocess, shlex
for part, command in extraction_parts: for part, command in extraction_parts:
@@ -1494,7 +1498,7 @@ def main():
selected_product = None selected_product = None
try: try:
c_dev = int(input()) c_dev = int(input())
if c_dev < 1 or c_dev > 6: if c_dev < 1 or c_dev > 7:
raise ValueError() raise ValueError()
elif c_dev == 1: elif c_dev == 1:
selected_product = ROM.PRODUCT_RNODE selected_product = ROM.PRODUCT_RNODE
@@ -2055,7 +2059,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2073,7 +2077,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2091,7 +2095,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2109,7 +2113,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2127,7 +2131,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2145,7 +2149,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2163,7 +2167,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2181,7 +2185,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2199,7 +2203,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2217,7 +2221,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2235,7 +2239,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2253,7 +2257,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2271,7 +2275,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2289,7 +2293,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2307,7 +2311,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2325,7 +2329,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2343,7 +2347,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2361,7 +2365,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2378,7 +2382,7 @@ def main():
sys.executable, flasher, sys.executable, flasher,
"--chip", "esp32", "--chip", "esp32",
"--port", args.port, "--port", args.port,
"--baud", "921600", "--baud", args.baud_flash,
"--before", "default_reset", "--before", "default_reset",
"--after", "hard_reset", "--after", "hard_reset",
"write_flash", "-z", "write_flash", "-z",
@@ -2466,6 +2470,10 @@ def main():
RNS.log("Waiting for ESP32 reset...") RNS.log("Waiting for ESP32 reset...")
time.sleep(7) time.sleep(7)
else: else:
RNS.log("Error from flasher ("+str(flash_status)+") while writing.")
RNS.log("Some boards have trouble flashing at high speeds, and you can")
RNS.log("try flashing with a lower baud rate, as in this example:")
RNS.log("rnodeconf --autoinstall --baud-flash 115200")
exit() exit()
except Exception as e: except Exception as e:
@@ -2673,7 +2681,7 @@ def main():
try: try:
timestamp = time.time() timestamp = time.time()
filename = str(time.strftime("%Y-%m-%d_%H-%M-%S")) filename = str(time.strftime("%Y-%m-%d_%H-%M-%S"))
path = "./eeprom/"+filename+".eeprom" path = ROM_DIR + filename + ".eeprom"
file = open(path, "wb") file = open(path, "wb")
file.write(rnode.eeprom) file.write(rnode.eeprom)
file.close() file.close()
+1 -1
View File
@@ -105,7 +105,7 @@ def timestamp_str(time_s):
def log(msg, level=3, _override_destination = False): def log(msg, level=3, _override_destination = False):
global _always_override_destination, compact_log_fmt global _always_override_destination, compact_log_fmt
msg = str(msg)
if loglevel >= level: if loglevel >= level:
if not compact_log_fmt: if not compact_log_fmt:
logstring = "["+timestamp_str(time.time())+"] ["+loglevelname(level)+"] "+msg logstring = "["+timestamp_str(time.time())+"] ["+loglevelname(level)+"] "+msg
+1 -1
View File
@@ -1 +1 @@
__version__ = "0.5.2" __version__ = "0.5.7"
+2 -1
View File
@@ -15,11 +15,12 @@ This document outlines the currently established development roadmap for Reticul
For each release cycle of Reticulum, improvements and additions from the five [Primary Efforts](#primary-efforts) are selected as active work areas, and can be expected to be included in the upcoming releases within that cycle. While not entirely set in stone for each release cycle, they serve as a pointer of what to expect in the near future. For each release cycle of Reticulum, improvements and additions from the five [Primary Efforts](#primary-efforts) are selected as active work areas, and can be expected to be included in the upcoming releases within that cycle. While not entirely set in stone for each release cycle, they serve as a pointer of what to expect in the near future.
- The current `0.5.x` release cycle aims at completing - The current `0.5.x` release cycle aims at completing
- [x] Reach feature-completion of the Reticulum API
- [x] Improve performance and efficiency of the `Buffer` and `Channel` API
- [ ] Overhauling and updating the documentation - [ ] Overhauling and updating the documentation
- [ ] Performance and memory optimisations of the Python reference implementation - [ ] Performance and memory optimisations of the Python reference implementation
- [ ] Fixing potential bugs - [ ] Fixing potential bugs
- [ ] Add automatic retries to all use cases of the `Request` API - [ ] Add automatic retries to all use cases of the `Request` API
- [ ] Improve performance and efficiency of the `Buffer` and `Channel` API
## Primary Efforts ## Primary Efforts
The development path for Reticulum is currently laid out in five distinct areas: *Comprehensibility*, *Universality*, *Functionality*, *Usability & Utility* and *Interfaceability*. Conceptualising the development of Reticulum into these areas serves to advance the implementation and work towards the Foundational Goals & Values of Reticulum. The development path for Reticulum is currently laid out in five distinct areas: *Comprehensibility*, *Universality*, *Functionality*, *Usability & Utility* and *Interfaceability*. Conceptualising the development of Reticulum into these areas serves to advance the implementation and work towards the Foundational Goals & Values of Reticulum.
Binary file not shown.
Binary file not shown.
+1 -1
View File
@@ -1,4 +1,4 @@
# Sphinx build info version 1 # Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: c5670e7931d15fbef274e2eee17c3561 config: ccc7aed64e52195ae55e727c672c5a8d
tags: 645f666f9bcd5a90fca523b33c5a78b7 tags: 645f666f9bcd5a90fca523b33c5a78b7
+1 -1
View File
@@ -858,7 +858,7 @@ both on general-purpose CPUs and on microcontrollers. The necessary primitives a
* Ed25519 for signatures * Ed25519 for signatures
* X22519 for ECDH key exchanges * X25519 for ECDH key exchanges
* HKDF for key derivation * HKDF for key derivation
@@ -1,134 +0,0 @@
/*
* _sphinx_javascript_frameworks_compat.js
* ~~~~~~~~~~
*
* Compatability shim for jQuery and underscores.js.
*
* WILL BE REMOVED IN Sphinx 6.0
* xref RemovedInSphinx60Warning
*
*/
/**
* select a different prefix for underscore
*/
$u = _.noConflict();
/**
* small helper function to urldecode strings
*
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/decodeURIComponent#Decoding_query_parameters_from_a_URL
*/
jQuery.urldecode = function(x) {
if (!x) {
return x
}
return decodeURIComponent(x.replace(/\+/g, ' '));
};
/**
* small helper function to urlencode strings
*/
jQuery.urlencode = encodeURIComponent;
/**
* This function returns the parsed url parameters of the
* current request. Multiple values per key are supported,
* it will always return arrays of strings for the value parts.
*/
jQuery.getQueryParameters = function(s) {
if (typeof s === 'undefined')
s = document.location.search;
var parts = s.substr(s.indexOf('?') + 1).split('&');
var result = {};
for (var i = 0; i < parts.length; i++) {
var tmp = parts[i].split('=', 2);
var key = jQuery.urldecode(tmp[0]);
var value = jQuery.urldecode(tmp[1]);
if (key in result)
result[key].push(value);
else
result[key] = [value];
}
return result;
};
/**
* highlight a given string on a jquery object by wrapping it in
* span elements with the given class name.
*/
jQuery.fn.highlightText = function(text, className) {
function highlight(node, addItems) {
if (node.nodeType === 3) {
var val = node.nodeValue;
var pos = val.toLowerCase().indexOf(text);
if (pos >= 0 &&
!jQuery(node.parentNode).hasClass(className) &&
!jQuery(node.parentNode).hasClass("nohighlight")) {
var span;
var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg");
if (isInSVG) {
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
} else {
span = document.createElement("span");
span.className = className;
}
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
node.parentNode.insertBefore(span, node.parentNode.insertBefore(
document.createTextNode(val.substr(pos + text.length)),
node.nextSibling));
node.nodeValue = val.substr(0, pos);
if (isInSVG) {
var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect");
var bbox = node.parentElement.getBBox();
rect.x.baseVal.value = bbox.x;
rect.y.baseVal.value = bbox.y;
rect.width.baseVal.value = bbox.width;
rect.height.baseVal.value = bbox.height;
rect.setAttribute('class', className);
addItems.push({
"parent": node.parentNode,
"target": rect});
}
}
}
else if (!jQuery(node).is("button, select, textarea")) {
jQuery.each(node.childNodes, function() {
highlight(this, addItems);
});
}
}
var addItems = [];
var result = this.each(function() {
highlight(this, addItems);
});
for (var i = 0; i < addItems.length; ++i) {
jQuery(addItems[i].parent).before(addItems[i].target);
}
return result;
};
/*
* backward compatibility for jQuery.browser
* This will be supported until firefox bug is fixed.
*/
if (!jQuery.browser) {
jQuery.uaMatch = function(ua) {
ua = ua.toLowerCase();
var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
/(msie) ([\w.]+)/.exec(ua) ||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
[];
return {
browser: match[ 1 ] || "",
version: match[ 2 ] || "0"
};
};
jQuery.browser = {};
jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
}
+47 -25
View File
@@ -4,7 +4,7 @@
* *
* Sphinx stylesheet -- basic theme. * Sphinx stylesheet -- basic theme.
* *
* :copyright: Copyright 2007-2022 by the Sphinx team, see AUTHORS. * :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details. * :license: BSD, see LICENSE for details.
* *
*/ */
@@ -236,16 +236,6 @@ div.body p, div.body dd, div.body li, div.body blockquote {
a.headerlink { a.headerlink {
visibility: hidden; visibility: hidden;
} }
a.brackets:before,
span.brackets > a:before{
content: "[";
}
a.brackets:after,
span.brackets > a:after {
content: "]";
}
h1:hover > a.headerlink, h1:hover > a.headerlink,
h2:hover > a.headerlink, h2:hover > a.headerlink,
@@ -334,11 +324,17 @@ aside.sidebar {
p.sidebar-title { p.sidebar-title {
font-weight: bold; font-weight: bold;
} }
nav.contents,
aside.topic,
div.admonition, div.topic, blockquote { div.admonition, div.topic, blockquote {
clear: left; clear: left;
} }
/* -- topics ---------------------------------------------------------------- */ /* -- topics ---------------------------------------------------------------- */
nav.contents,
aside.topic,
div.topic { div.topic {
border: 1px solid #ccc; border: 1px solid #ccc;
padding: 7px; padding: 7px;
@@ -377,6 +373,8 @@ div.body p.centered {
div.sidebar > :last-child, div.sidebar > :last-child,
aside.sidebar > :last-child, aside.sidebar > :last-child,
nav.contents > :last-child,
aside.topic > :last-child,
div.topic > :last-child, div.topic > :last-child,
div.admonition > :last-child { div.admonition > :last-child {
margin-bottom: 0; margin-bottom: 0;
@@ -384,6 +382,8 @@ div.admonition > :last-child {
div.sidebar::after, div.sidebar::after,
aside.sidebar::after, aside.sidebar::after,
nav.contents::after,
aside.topic::after,
div.topic::after, div.topic::after,
div.admonition::after, div.admonition::after,
blockquote::after { blockquote::after {
@@ -608,19 +608,27 @@ ol.simple p,
ul.simple p { ul.simple p {
margin-bottom: 0; margin-bottom: 0;
} }
dl.footnote > dt,
dl.citation > dt {
float: left;
margin-right: 0.5em;
}
dl.footnote > dd, aside.footnote > span,
dl.citation > dd { div.citation > span {
float: left;
}
aside.footnote > span:last-of-type,
div.citation > span:last-of-type {
padding-right: 0.5em;
}
aside.footnote > p {
margin-left: 2em;
}
div.citation > p {
margin-left: 4em;
}
aside.footnote > p:last-of-type,
div.citation > p:last-of-type {
margin-bottom: 0em; margin-bottom: 0em;
} }
aside.footnote > p:last-of-type:after,
dl.footnote > dd:after, div.citation > p:last-of-type:after {
dl.citation > dd:after {
content: ""; content: "";
clear: both; clear: both;
} }
@@ -636,10 +644,6 @@ dl.field-list > dt {
padding-left: 0.5em; padding-left: 0.5em;
padding-right: 5px; padding-right: 5px;
} }
dl.field-list > dt:after {
content: ":";
}
dl.field-list > dd { dl.field-list > dd {
padding-left: 0.5em; padding-left: 0.5em;
@@ -666,6 +670,16 @@ dd {
margin-left: 30px; margin-left: 30px;
} }
.sig dd {
margin-top: 0px;
margin-bottom: 0px;
}
.sig dl {
margin-top: 0px;
margin-bottom: 0px;
}
dl > dd:last-child, dl > dd:last-child,
dl > dd:last-child > :last-child { dl > dd:last-child > :last-child {
margin-bottom: 0; margin-bottom: 0;
@@ -734,6 +748,14 @@ abbr, acronym {
cursor: help; cursor: help;
} }
.translated {
background-color: rgba(207, 255, 207, 0.2)
}
.untranslated {
background-color: rgba(255, 207, 207, 0.2)
}
/* -- code displays --------------------------------------------------------- */ /* -- code displays --------------------------------------------------------- */
pre { pre {
+2 -1
View File
@@ -35,7 +35,8 @@ div.highlight {
position: relative; position: relative;
} }
.highlight:hover button.copybtn { /* Show the copybutton */
.highlight:hover button.copybtn, button.copybtn.success {
opacity: 1; opacity: 1;
} }
+36 -8
View File
@@ -20,7 +20,7 @@ const messages = {
}, },
'fr' : { 'fr' : {
'copy': 'Copier', 'copy': 'Copier',
'copy_to_clipboard': 'Copié dans le presse-papier', 'copy_to_clipboard': 'Copier dans le presse-papier',
'copy_success': 'Copié !', 'copy_success': 'Copié !',
'copy_failure': 'Échec de la copie', 'copy_failure': 'Échec de la copie',
}, },
@@ -102,18 +102,25 @@ const clearSelection = () => {
} }
} }
// Changes tooltip text for two seconds, then changes it back // Changes tooltip text for a moment, then changes it back
// We want the timeout of our `success` class to be a bit shorter than the
// tooltip and icon change, so that we can hide the icon before changing back.
var timeoutIcon = 2000;
var timeoutSuccessClass = 1500;
const temporarilyChangeTooltip = (el, oldText, newText) => { const temporarilyChangeTooltip = (el, oldText, newText) => {
el.setAttribute('data-tooltip', newText) el.setAttribute('data-tooltip', newText)
el.classList.add('success') el.classList.add('success')
setTimeout(() => el.setAttribute('data-tooltip', oldText), 2000) // Remove success a little bit sooner than we change the tooltip
setTimeout(() => el.classList.remove('success'), 2000) // So that we can use CSS to hide the copybutton first
setTimeout(() => el.classList.remove('success'), timeoutSuccessClass)
setTimeout(() => el.setAttribute('data-tooltip', oldText), timeoutIcon)
} }
// Changes the copy button icon for two seconds, then changes it back // Changes the copy button icon for two seconds, then changes it back
const temporarilyChangeIcon = (el) => { const temporarilyChangeIcon = (el) => {
el.innerHTML = iconCheck; el.innerHTML = iconCheck;
setTimeout(() => {el.innerHTML = iconCopy}, 2000) setTimeout(() => {el.innerHTML = iconCopy}, timeoutIcon)
} }
const addCopyButtonToCodeCells = () => { const addCopyButtonToCodeCells = () => {
@@ -125,7 +132,8 @@ const addCopyButtonToCodeCells = () => {
} }
// Add copybuttons to all of our code cells // Add copybuttons to all of our code cells
const codeCells = document.querySelectorAll('div.highlight pre') const COPYBUTTON_SELECTOR = 'div.highlight pre';
const codeCells = document.querySelectorAll(COPYBUTTON_SELECTOR)
codeCells.forEach((codeCell, index) => { codeCells.forEach((codeCell, index) => {
const id = codeCellId(index) const id = codeCellId(index)
codeCell.setAttribute('id', id) codeCell.setAttribute('id', id)
@@ -141,10 +149,25 @@ function escapeRegExp(string) {
return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&'); // $& means the whole matched string return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&'); // $& means the whole matched string
} }
/**
* Removes excluded text from a Node.
*
* @param {Node} target Node to filter.
* @param {string} exclude CSS selector of nodes to exclude.
* @returns {DOMString} Text from `target` with text removed.
*/
function filterText(target, exclude) {
const clone = target.cloneNode(true); // clone as to not modify the live DOM
if (exclude) {
// remove excluded nodes
clone.querySelectorAll(exclude).forEach(node => node.remove());
}
return clone.innerText;
}
// Callback when a copy button is clicked. Will be passed the node that was clicked // Callback when a copy button is clicked. Will be passed the node that was clicked
// should then grab the text and replace pieces of text that shouldn't be used in output // should then grab the text and replace pieces of text that shouldn't be used in output
function formatCopyText(textContent, copybuttonPromptText, isRegexp = false, onlyCopyPromptLines = true, removePrompts = true, copyEmptyLines = true, lineContinuationChar = "", hereDocDelim = "") { function formatCopyText(textContent, copybuttonPromptText, isRegexp = false, onlyCopyPromptLines = true, removePrompts = true, copyEmptyLines = true, lineContinuationChar = "", hereDocDelim = "") {
var regexp; var regexp;
var match; var match;
@@ -199,7 +222,12 @@ function formatCopyText(textContent, copybuttonPromptText, isRegexp = false, onl
var copyTargetText = (trigger) => { var copyTargetText = (trigger) => {
var target = document.querySelector(trigger.attributes['data-clipboard-target'].value); var target = document.querySelector(trigger.attributes['data-clipboard-target'].value);
return formatCopyText(target.innerText, '', false, true, true, true, '', '')
// get filtered text
let exclude = '.linenos';
let text = filterText(target, exclude);
return formatCopyText(text, '', false, true, true, true, '', '')
} }
// Initialize with a callback so we can modify the text before copy // Initialize with a callback so we can modify the text before copy
+16 -1
View File
@@ -2,10 +2,25 @@ function escapeRegExp(string) {
return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&'); // $& means the whole matched string return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&'); // $& means the whole matched string
} }
/**
* Removes excluded text from a Node.
*
* @param {Node} target Node to filter.
* @param {string} exclude CSS selector of nodes to exclude.
* @returns {DOMString} Text from `target` with text removed.
*/
export function filterText(target, exclude) {
const clone = target.cloneNode(true); // clone as to not modify the live DOM
if (exclude) {
// remove excluded nodes
clone.querySelectorAll(exclude).forEach(node => node.remove());
}
return clone.innerText;
}
// Callback when a copy button is clicked. Will be passed the node that was clicked // Callback when a copy button is clicked. Will be passed the node that was clicked
// should then grab the text and replace pieces of text that shouldn't be used in output // should then grab the text and replace pieces of text that shouldn't be used in output
export function formatCopyText(textContent, copybuttonPromptText, isRegexp = false, onlyCopyPromptLines = true, removePrompts = true, copyEmptyLines = true, lineContinuationChar = "", hereDocDelim = "") { export function formatCopyText(textContent, copybuttonPromptText, isRegexp = false, onlyCopyPromptLines = true, removePrompts = true, copyEmptyLines = true, lineContinuationChar = "", hereDocDelim = "") {
var regexp; var regexp;
var match; var match;
+1 -1
View File
@@ -4,7 +4,7 @@
* *
* Base JavaScript utilities for all Sphinx HTML documentation. * Base JavaScript utilities for all Sphinx HTML documentation.
* *
* :copyright: Copyright 2007-2022 by the Sphinx team, see AUTHORS. * :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details. * :license: BSD, see LICENSE for details.
* *
*/ */
+1 -1
View File
@@ -1,6 +1,6 @@
var DOCUMENTATION_OPTIONS = { var DOCUMENTATION_OPTIONS = {
URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'), URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'),
VERSION: '0.5.2 beta', VERSION: '0.5.7 beta',
LANGUAGE: 'en', LANGUAGE: 'en',
COLLAPSE_INDEX: false, COLLAPSE_INDEX: false,
BUILDER: 'html', BUILDER: 'html',
-10881
View File
File diff suppressed because it is too large Load Diff
-2
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -5,7 +5,7 @@
* This script contains the language-specific data used by searchtools.js, * This script contains the language-specific data used by searchtools.js,
* namely the list of stopwords, stemmer, scorer and splitter. * namely the list of stopwords, stemmer, scorer and splitter.
* *
* :copyright: Copyright 2007-2022 by the Sphinx team, see AUTHORS. * :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details. * :license: BSD, see LICENSE for details.
* *
*/ */
+2 -2
View File
@@ -101,7 +101,7 @@ body[data-theme="dark"] .highlight .x { color: #d0d0d0 } /* Other */
body[data-theme="dark"] .highlight .p { color: #d0d0d0 } /* Punctuation */ body[data-theme="dark"] .highlight .p { color: #d0d0d0 } /* Punctuation */
body[data-theme="dark"] .highlight .ch { color: #ababab; font-style: italic } /* Comment.Hashbang */ body[data-theme="dark"] .highlight .ch { color: #ababab; font-style: italic } /* Comment.Hashbang */
body[data-theme="dark"] .highlight .cm { color: #ababab; font-style: italic } /* Comment.Multiline */ body[data-theme="dark"] .highlight .cm { color: #ababab; font-style: italic } /* Comment.Multiline */
body[data-theme="dark"] .highlight .cp { color: #cd2828; font-weight: bold } /* Comment.Preproc */ body[data-theme="dark"] .highlight .cp { color: #ff3a3a; font-weight: bold } /* Comment.Preproc */
body[data-theme="dark"] .highlight .cpf { color: #ababab; font-style: italic } /* Comment.PreprocFile */ body[data-theme="dark"] .highlight .cpf { color: #ababab; font-style: italic } /* Comment.PreprocFile */
body[data-theme="dark"] .highlight .c1 { color: #ababab; font-style: italic } /* Comment.Single */ body[data-theme="dark"] .highlight .c1 { color: #ababab; font-style: italic } /* Comment.Single */
body[data-theme="dark"] .highlight .cs { color: #e50808; font-weight: bold; background-color: #520000 } /* Comment.Special */ body[data-theme="dark"] .highlight .cs { color: #e50808; font-weight: bold; background-color: #520000 } /* Comment.Special */
@@ -186,7 +186,7 @@ body:not([data-theme="light"]) .highlight .x { color: #d0d0d0 } /* Other */
body:not([data-theme="light"]) .highlight .p { color: #d0d0d0 } /* Punctuation */ body:not([data-theme="light"]) .highlight .p { color: #d0d0d0 } /* Punctuation */
body:not([data-theme="light"]) .highlight .ch { color: #ababab; font-style: italic } /* Comment.Hashbang */ body:not([data-theme="light"]) .highlight .ch { color: #ababab; font-style: italic } /* Comment.Hashbang */
body:not([data-theme="light"]) .highlight .cm { color: #ababab; font-style: italic } /* Comment.Multiline */ body:not([data-theme="light"]) .highlight .cm { color: #ababab; font-style: italic } /* Comment.Multiline */
body:not([data-theme="light"]) .highlight .cp { color: #cd2828; font-weight: bold } /* Comment.Preproc */ body:not([data-theme="light"]) .highlight .cp { color: #ff3a3a; font-weight: bold } /* Comment.Preproc */
body:not([data-theme="light"]) .highlight .cpf { color: #ababab; font-style: italic } /* Comment.PreprocFile */ body:not([data-theme="light"]) .highlight .cpf { color: #ababab; font-style: italic } /* Comment.PreprocFile */
body:not([data-theme="light"]) .highlight .c1 { color: #ababab; font-style: italic } /* Comment.Single */ body:not([data-theme="light"]) .highlight .c1 { color: #ababab; font-style: italic } /* Comment.Single */
body:not([data-theme="light"]) .highlight .cs { color: #e50808; font-weight: bold; background-color: #520000 } /* Comment.Special */ body:not([data-theme="light"]) .highlight .cs { color: #e50808; font-weight: bold; background-color: #520000 } /* Comment.Special */
@@ -1,7 +0,0 @@
/*!
* gumshoejs v5.1.2 (patched by @pradyunsg)
* A simple, framework-agnostic scrollspy script.
* (c) 2019 Chris Ferdinandi
* MIT License
* http://github.com/cferdinandi/gumshoe
*/
+1 -1
View File
@@ -4,7 +4,7 @@
* *
* Sphinx JavaScript utilities for the full-text search. * Sphinx JavaScript utilities for the full-text search.
* *
* :copyright: Copyright 2007-2022 by the Sphinx team, see AUTHORS. * :copyright: Copyright 2007-2023 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details. * :license: BSD, see LICENSE for details.
* *
*/ */
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
+19 -22
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Support Reticulum" href="support.html" /><link rel="prev" title="Building Networks" href="networks.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Support Reticulum" href="support.html" /><link rel="prev" title="Building Networks" href="networks.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Code Examples - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Code Examples - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -2064,7 +2064,7 @@ data between peers of a <code class="docutils literal notranslate"><span class="
<span class="n">RNS</span><span class="o">.</span><span class="n">log</span><span class="p">(</span><span class="s2">&quot;Client disconnected&quot;</span><span class="p">)</span> <span class="n">RNS</span><span class="o">.</span><span class="n">log</span><span class="p">(</span><span class="s2">&quot;Client disconnected&quot;</span><span class="p">)</span>
<span class="k">def</span> <span class="nf">server_message_received</span><span class="p">(</span><span class="n">message</span><span class="p">):</span> <span class="k">def</span> <span class="nf">server_message_received</span><span class="p">(</span><span class="n">message</span><span class="p">):</span>
<span class="sd">&quot;&quot;&quot;</span> <span class="w"> </span><span class="sd">&quot;&quot;&quot;</span>
<span class="sd"> A message handler</span> <span class="sd"> A message handler</span>
<span class="sd"> @param message: An instance of a subclass of MessageBase</span> <span class="sd"> @param message: An instance of a subclass of MessageBase</span>
<span class="sd"> @return: True if message was handled</span> <span class="sd"> @return: True if message was handled</span>
@@ -2413,7 +2413,7 @@ binary data between peers of a <code class="docutils literal notranslate"><span
<span class="n">RNS</span><span class="o">.</span><span class="n">log</span><span class="p">(</span><span class="s2">&quot;Client disconnected&quot;</span><span class="p">)</span> <span class="n">RNS</span><span class="o">.</span><span class="n">log</span><span class="p">(</span><span class="s2">&quot;Client disconnected&quot;</span><span class="p">)</span>
<span class="k">def</span> <span class="nf">server_buffer_ready</span><span class="p">(</span><span class="n">ready_bytes</span><span class="p">:</span> <span class="nb">int</span><span class="p">):</span> <span class="k">def</span> <span class="nf">server_buffer_ready</span><span class="p">(</span><span class="n">ready_bytes</span><span class="p">:</span> <span class="nb">int</span><span class="p">):</span>
<span class="sd">&quot;&quot;&quot;</span> <span class="w"> </span><span class="sd">&quot;&quot;&quot;</span>
<span class="sd"> Callback from buffer when buffer has data available</span> <span class="sd"> Callback from buffer when buffer has data available</span>
<span class="sd"> :param ready_bytes: The number of bytes ready to read</span> <span class="sd"> :param ready_bytes: The number of bytes ready to read</span>
@@ -3322,14 +3322,11 @@ interface to efficiently pass files of any size over a Reticulum <a class="refer
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>An Explanation of Reticulum for Human Beings - Reticulum Network Stack 0.5.2 beta documentation</title> <title>An Explanation of Reticulum for Human Beings - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -257,14 +257,11 @@
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+15 -18
View File
@@ -4,12 +4,12 @@
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><link rel="index" title="Index" href="#" /><link rel="search" title="Search" href="search.html" /> <meta name="color-scheme" content="light dark"><link rel="index" title="Index" href="#" /><link rel="search" title="Search" href="search.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/><title>Index - Reticulum Network Stack 0.5.2 beta documentation</title> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/><title>Index - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -139,7 +139,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -159,16 +159,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -723,14 +723,11 @@
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Using Reticulum on Your System" href="using.html" /><link rel="prev" title="What is Reticulum?" href="whatis.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Using Reticulum on Your System" href="using.html" /><link rel="prev" title="What is Reticulum?" href="whatis.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Getting Started Fast - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Getting Started Fast - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -737,14 +737,11 @@ section of this manual.</p>
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Supported Interfaces" href="interfaces.html" /><link rel="prev" title="Understanding Reticulum" href="understanding.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Supported Interfaces" href="interfaces.html" /><link rel="prev" title="Understanding Reticulum" href="understanding.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Communications Hardware - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Communications Hardware - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -499,14 +499,11 @@ connectivity for client devices.</p>
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="What is Reticulum?" href="whatis.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="What is Reticulum?" href="whatis.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Reticulum Network Stack 0.5.2 beta documentation</title> <title>Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="#"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="#"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="#"> <div class="sidebar-sticky"><a class="sidebar-brand" href="#">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -464,14 +464,11 @@ to participate in the development of Reticulum itself.</p>
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Building Networks" href="networks.html" /><link rel="prev" title="Communications Hardware" href="hardware.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Building Networks" href="networks.html" /><link rel="prev" title="Communications Hardware" href="hardware.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Supported Interfaces - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Supported Interfaces - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -1006,14 +1006,11 @@ that a large span of network types can seamlessly <em>co-exist</em> and intercon
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Code Examples" href="examples.html" /><link rel="prev" title="Supported Interfaces" href="interfaces.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Code Examples" href="examples.html" /><link rel="prev" title="Supported Interfaces" href="interfaces.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Building Networks - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Building Networks - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -467,14 +467,11 @@ connected outliers are now an integral part of the network.</p>
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
Binary file not shown.
+151 -154
View File
File diff suppressed because it is too large Load Diff
+14 -17
View File
@@ -4,11 +4,11 @@
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="#" /> <meta name="color-scheme" content="light dark"><link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="#" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/><title>Search - Reticulum Network Stack 0.5.2 beta documentation</title><link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/><title>Search - Reticulum Network Stack 0.5.7 beta documentation</title><link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -138,7 +138,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -158,16 +158,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="#" role="search"> </a><form class="sidebar-search-container" method="get" action="#" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -262,15 +262,12 @@
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
<script src="_static/searchtools.js"></script> <script src="_static/searchtools.js"></script>
<script src="_static/language_data.js"></script> <script src="_static/language_data.js"></script>
File diff suppressed because one or more lines are too long
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="API Reference" href="reference.html" /><link rel="prev" title="Code Examples" href="examples.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="API Reference" href="reference.html" /><link rel="prev" title="Code Examples" href="examples.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Support Reticulum - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Support Reticulum - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -330,14 +330,11 @@ report issues, suggest functionality and contribute code to Reticulum.</p>
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+18 -21
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Communications Hardware" href="hardware.html" /><link rel="prev" title="Using Reticulum on Your System" href="using.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Communications Hardware" href="hardware.html" /><link rel="prev" title="Using Reticulum on Your System" href="using.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Understanding Reticulum - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Understanding Reticulum - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -1061,7 +1061,7 @@ cryptographic primitives, with widely available implementations that can be used
both on general-purpose CPUs and on microcontrollers. The necessary primitives are:</p> both on general-purpose CPUs and on microcontrollers. The necessary primitives are:</p>
<ul class="simple"> <ul class="simple">
<li><p>Ed25519 for signatures</p></li> <li><p>Ed25519 for signatures</p></li>
<li><p>X22519 for ECDH key exchanges</p></li> <li><p>X25519 for ECDH key exchanges</p></li>
<li><p>HKDF for key derivation</p></li> <li><p>HKDF for key derivation</p></li>
<li><p>Fernet for encrypted tokens</p> <li><p>Fernet for encrypted tokens</p>
<ul> <ul>
@@ -1196,14 +1196,11 @@ those risks are acceptable to you.</p>
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Understanding Reticulum" href="understanding.html" /><link rel="prev" title="Getting Started Fast" href="gettingstartedfast.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Understanding Reticulum" href="understanding.html" /><link rel="prev" title="Getting Started Fast" href="gettingstartedfast.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>Using Reticulum on Your System - Reticulum Network Stack 0.5.2 beta documentation</title> <title>Using Reticulum on Your System - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -812,14 +812,11 @@ WantedBy=multi-user.target
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+17 -20
View File
@@ -2,16 +2,16 @@
<html class="no-js" lang="en"> <html class="no-js" lang="en">
<head><meta charset="utf-8"/> <head><meta charset="utf-8"/>
<meta name="viewport" content="width=device-width,initial-scale=1"/> <meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="color-scheme" content="light dark"><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Getting Started Fast" href="gettingstartedfast.html" /><link rel="prev" title="Reticulum Network Stack Manual" href="index.html" /> <link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Getting Started Fast" href="gettingstartedfast.html" /><link rel="prev" title="Reticulum Network Stack Manual" href="index.html" />
<meta name="generator" content="sphinx-5.2.2, furo 2022.09.29"/> <meta name="generator" content="sphinx-7.1.2, furo 2022.09.29.dev1"/>
<title>What is Reticulum? - Reticulum Network Stack 0.5.2 beta documentation</title> <title>What is Reticulum? - Reticulum Network Stack 0.5.7 beta documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="_static/pygments.css?v=362ab14a" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=d81277517bee4d6b0349d71bb2661d4890b5617c" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo.css?digest=189ec851f9bb375a2509b67be1f64f0cf212b702" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css" /> <link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" /> <link rel="stylesheet" type="text/css" href="_static/styles/furo-extensions.css?digest=30d1aed668e5c3a91c3e3bf6a60b675221979f0e" />
<link rel="stylesheet" type="text/css" href="_static/custom.css" /> <link rel="stylesheet" type="text/css" href="_static/custom.css?v=bb3cebc5" />
@@ -141,7 +141,7 @@
</label> </label>
</div> </div>
<div class="header-center"> <div class="header-center">
<a href="index.html"><div class="brand">Reticulum Network Stack 0.5.2 beta documentation</div></a> <a href="index.html"><div class="brand">Reticulum Network Stack 0.5.7 beta documentation</div></a>
</div> </div>
<div class="header-right"> <div class="header-right">
<div class="theme-toggle-container theme-toggle-header"> <div class="theme-toggle-container theme-toggle-header">
@@ -161,16 +161,16 @@
<aside class="sidebar-drawer"> <aside class="sidebar-drawer">
<div class="sidebar-container"> <div class="sidebar-container">
<div class="sidebar-sticky"><a class="sidebar-brand centered" href="index.html"> <div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">
<div class="sidebar-logo-container"> <div class="sidebar-logo-container">
<img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/> <img class="sidebar-logo" src="_static/rns_logo_512.png" alt="Logo"/>
</div> </div>
<span class="sidebar-brand-text">Reticulum Network Stack 0.5.2 beta documentation</span> <span class="sidebar-brand-text">Reticulum Network Stack 0.5.7 beta documentation</span>
</a><form class="sidebar-search-container" method="get" action="search.html" role="search"> </a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder=Search name="q" aria-label="Search"> <input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
<input type="hidden" name="check_keywords" value="yes"> <input type="hidden" name="check_keywords" value="yes">
<input type="hidden" name="area" value="default"> <input type="hidden" name="area" value="default">
</form> </form>
@@ -434,14 +434,11 @@ want to help out with this, or can help sponsor an audit, please do get in touch
</aside> </aside>
</div> </div>
</div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script> </div><script data-url_root="./" id="documentation_options" src="_static/documentation_options.js?v=261083eb"></script>
<script src="_static/jquery.js"></script> <script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/underscore.js"></script> <script src="_static/sphinx_highlight.js?v=4825356b"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js"></script> <script src="_static/scripts/furo.js?v=2c7c1115"></script>
<script src="_static/doctools.js"></script> <script src="_static/clipboard.min.js?v=a7894cd8"></script>
<script src="_static/sphinx_highlight.js"></script> <script src="_static/copybutton.js?v=f281be69"></script>
<script src="_static/scripts/furo.js"></script>
<script src="_static/clipboard.min.js"></script>
<script src="_static/copybutton.js"></script>
</body> </body>
</html> </html>
+1 -1
View File
@@ -858,7 +858,7 @@ both on general-purpose CPUs and on microcontrollers. The necessary primitives a
* Ed25519 for signatures * Ed25519 for signatures
* X22519 for ECDH key exchanges * X25519 for ECDH key exchanges
* HKDF for key derivation * HKDF for key derivation
+72 -72
View File
@@ -404,104 +404,104 @@ class TestChannel(unittest.TestCase):
self.assertEqual(data, decoded) self.assertEqual(data, decoded)
# def test_buffer_big(self): def test_buffer_big(self):
# writer = RNS.Buffer.create_writer(15, self.h.channel) writer = RNS.Buffer.create_writer(15, self.h.channel)
# reader = RNS.Buffer.create_reader(15, self.h.channel) reader = RNS.Buffer.create_reader(15, self.h.channel)
# data = "01234556789"*1024 # 10 KB data = "01234556789"*1024 # 10 KB
# count = 0 count = 0
# write_finished = False write_finished = False
# def write_thread(): def write_thread():
# nonlocal count, write_finished nonlocal count, write_finished
# count = writer.write(data.encode("utf-8")) count = writer.write(data.encode("utf-8"))
# writer.flush() writer.flush()
# writer.close() writer.close()
# write_finished = True write_finished = True
# threading.Thread(target=write_thread, name="Write Thread", daemon=True).start() threading.Thread(target=write_thread, name="Write Thread", daemon=True).start()
# while not write_finished or next(filter(lambda x: x.state != MessageState.MSGSTATE_DELIVERED, while not write_finished or next(filter(lambda x: x.state != MessageState.MSGSTATE_DELIVERED,
# self.h.outlet.packets), None) is not None: self.h.outlet.packets), None) is not None:
# with self.h.outlet.lock: with self.h.outlet.lock:
# for packet in self.h.outlet.packets: for packet in self.h.outlet.packets:
# if packet.state != MessageState.MSGSTATE_DELIVERED: if packet.state != MessageState.MSGSTATE_DELIVERED:
# self.h.channel._receive(packet.raw) self.h.channel._receive(packet.raw)
# packet.delivered() packet.delivered()
# time.sleep(0.0001) time.sleep(0.0001)
# self.assertEqual(len(data), count) self.assertEqual(len(data), count)
# read_finished = False read_finished = False
# result = bytes() result = bytes()
# def read_thread(): def read_thread():
# nonlocal read_finished, result nonlocal read_finished, result
# result = reader.read() result = reader.read()
# read_finished = True read_finished = True
# threading.Thread(target=read_thread, name="Read Thread", daemon=True).start() threading.Thread(target=read_thread, name="Read Thread", daemon=True).start()
# timeout_at = time.time() + 7 timeout_at = time.time() + 7
# while not read_finished and time.time() < timeout_at: while not read_finished and time.time() < timeout_at:
# time.sleep(0.001) time.sleep(0.001)
# self.assertTrue(read_finished) self.assertTrue(read_finished)
# self.assertEqual(len(data), len(result)) self.assertEqual(len(data), len(result))
# decoded = result.decode("utf-8") decoded = result.decode("utf-8")
# self.assertSequenceEqual(data, decoded) self.assertSequenceEqual(data, decoded)
# def test_buffer_small_with_callback(self): def test_buffer_small_with_callback(self):
# callbacks = 0 callbacks = 0
# last_cb_value = None last_cb_value = None
# def callback(ready: int): def callback(ready: int):
# nonlocal callbacks, last_cb_value nonlocal callbacks, last_cb_value
# callbacks += 1 callbacks += 1
# last_cb_value = ready last_cb_value = ready
# data = "Hello\n" data = "Hello\n"
# with RNS.RawChannelWriter(0, self.h.channel) as writer, RNS.RawChannelReader(0, self.h.channel) as reader: with RNS.RawChannelWriter(0, self.h.channel) as writer, RNS.RawChannelReader(0, self.h.channel) as reader:
# reader.add_ready_callback(callback) reader.add_ready_callback(callback)
# count = writer.write(data.encode("utf-8")) count = writer.write(data.encode("utf-8"))
# writer.flush() writer.flush()
# self.assertEqual(len(data), count) self.assertEqual(len(data), count)
# self.assertEqual(1, len(self.h.outlet.packets)) self.assertEqual(1, len(self.h.outlet.packets))
# packet = self.h.outlet.packets[0] packet = self.h.outlet.packets[0]
# self.h.channel._receive(packet.raw) self.h.channel._receive(packet.raw)
# packet.delivered() packet.delivered()
# self.assertEqual(1, callbacks) self.assertEqual(1, callbacks)
# self.assertEqual(len(data), last_cb_value) self.assertEqual(len(data), last_cb_value)
# result = reader.readline() result = reader.readline()
# self.assertIsNotNone(result) self.assertIsNotNone(result)
# self.assertEqual(len(result), len(data)) self.assertEqual(len(result), len(data))
# decoded = result.decode("utf-8") decoded = result.decode("utf-8")
# self.assertEqual(data, decoded) self.assertEqual(data, decoded)
# self.assertEqual(1, len(self.h.outlet.packets)) self.assertEqual(1, len(self.h.outlet.packets))
# result = reader.read(1) result = reader.read(1)
# self.assertIsNone(result) self.assertIsNone(result)
# self.assertTrue(self.h.channel.is_ready_to_send()) self.assertTrue(self.h.channel.is_ready_to_send())
# writer.close() writer.close()
# self.assertEqual(2, len(self.h.outlet.packets)) self.assertEqual(2, len(self.h.outlet.packets))
# packet = self.h.outlet.packets[1] packet = self.h.outlet.packets[1]
# self.h.channel._receive(packet.raw) self.h.channel._receive(packet.raw)
# packet.delivered() packet.delivered()
# result = reader.read(1) result = reader.read(1)
# self.assertIsNotNone(result) self.assertIsNotNone(result)
# self.assertTrue(len(result) == 0) self.assertTrue(len(result) == 0)
if __name__ == '__main__': if __name__ == '__main__':
+37 -28
View File
@@ -4,6 +4,7 @@ import subprocess
import shlex import shlex
import threading import threading
import time import time
import random
from unittest import skipIf from unittest import skipIf
import RNS import RNS
import os import os
@@ -23,6 +24,8 @@ fixed_keys = [
("08bb35f92b06a0832991165a0d9b4fd91af7b7765ce4572aa6222070b11b767092b61b0fd18b3a59cae6deb9db6d4bfb1c7fcfe076cfd66eea7ddd5f877543b9", "d13712efc45ef87674fb5ac26c37c912"), ("08bb35f92b06a0832991165a0d9b4fd91af7b7765ce4572aa6222070b11b767092b61b0fd18b3a59cae6deb9db6d4bfb1c7fcfe076cfd66eea7ddd5f877543b9", "d13712efc45ef87674fb5ac26c37c912"),
] ]
BUFFER_TEST_TARGET = 32000
def targets_job(caller): def targets_job(caller):
cmd = "python -c \"from tests.link import targets; targets()\"" cmd = "python -c \"from tests.link import targets; targets()\""
print("Opening subprocess for "+str(cmd)+"...", RNS.LOG_VERBOSE) print("Opening subprocess for "+str(cmd)+"...", RNS.LOG_VERBOSE)
@@ -455,7 +458,7 @@ class TestLink(unittest.TestCase):
# @skipIf(os.getenv('SKIP_NORMAL_TESTS') != None and os.getenv('RUN_SLOW_TESTS') == None, "Skipping") # @skipIf(os.getenv('SKIP_NORMAL_TESTS') != None and os.getenv('RUN_SLOW_TESTS') == None, "Skipping")
def test_12_buffer_round_trip_big(self, local_bitrate = None): def test_12_buffer_round_trip_big(self, local_bitrate = None):
global c_rns global c_rns, buffer_read_target
init_rns(self) init_rns(self)
print("") print("")
print("Buffer round trip test") print("Buffer round trip test")
@@ -490,9 +493,9 @@ class TestLink(unittest.TestCase):
buffer = None buffer = None
received = [] received = []
def handle_data(ready_bytes: int): def handle_data(ready_bytes: int):
# TODO: Remove global received_bytes
RNS.log("Handling data")
data = buffer.read(ready_bytes) data = buffer.read(ready_bytes)
received.append(data) received.append(data)
@@ -509,10 +512,11 @@ class TestLink(unittest.TestCase):
if local_interface.bitrate < 1000: if local_interface.bitrate < 1000:
target_bytes = 3000 target_bytes = 3000
else: else:
target_bytes = 16000 target_bytes = BUFFER_TEST_TARGET
random.seed(154889)
message = os.urandom(target_bytes) message = random.randbytes(target_bytes)
buffer_read_target = len(message)
# the return message will have an appendage string " back at you" # the return message will have an appendage string " back at you"
# for every StreamDataMessage that arrives. To verify, we need # for every StreamDataMessage that arrives. To verify, we need
@@ -527,35 +531,24 @@ class TestLink(unittest.TestCase):
# since the segments will be received at max length for a # since the segments will be received at max length for a
# StreamDataMessage, the appended text will end up in a # StreamDataMessage, the appended text will end up in a
# separate packet. # separate packet.
expected_chunk_count = ceil(len(message)/StreamDataMessage.MAX_DATA_LEN * 2)-1 print("Sending " + str(len(message)) + " bytes, receiving " + str(len(expected_rx_message)) + " bytes, ")
print("Sending " + str(len(message)) + " bytes, receiving " + str(len(expected_rx_message)) + " bytes, " +
"expecting " + str(expected_chunk_count) + " chunks of " + str(StreamDataMessage.MAX_DATA_LEN) + " bytes")
buffer.write(message) buffer.write(message)
buffer.flush() buffer.flush()
# delay a reasonable time for the send and receive timeout = time.time() + 4
# a chunk each way plus a little more for a proof each way while not time.time() > timeout:
# while time.time() < expected_ready_time and len(received) < expected_chunk_count: time.sleep(1)
# time.sleep(0.1) print(f"Received {len(received)} chunks so far")
# # sleep for at least one more chunk round trip in case there time.sleep(1)
# # are more chunks than expected
# if time.time() < expected_ready_time:
# time.sleep(max(c_rns.MTU * 2 / local_interface.bitrate * 8, 1))
timeout = time.time() + 10
while len(received) < expected_chunk_count and not time.time() > timeout:
time.sleep(2)
print(f"Received {len(received)} out of {expected_chunk_count} chunks so far")
time.sleep(2)
print(f"Received {len(received)} out of {expected_chunk_count} chunks")
data = bytearray() data = bytearray()
for rx in received: for rx in received:
data.extend(rx) data.extend(rx)
rx_message = data rx_message = data
print(f"Received {len(received)} chunks, totalling {len(rx_message)} bytes")
self.assertEqual(len(expected_rx_message), len(rx_message)) self.assertEqual(len(expected_rx_message), len(rx_message))
for i in range(0, len(expected_rx_message)): for i in range(0, len(expected_rx_message)):
self.assertEqual(expected_rx_message[i], rx_message[i]) self.assertEqual(expected_rx_message[i], rx_message[i])
@@ -598,7 +591,7 @@ class TestLink(unittest.TestCase):
if __name__ == '__main__': if __name__ == '__main__':
unittest.main(verbosity=1) unittest.main(verbosity=1)
buffer_read_len = 0
def targets(yp=False): def targets(yp=False):
if yp: if yp:
import yappi import yappi
@@ -645,10 +638,26 @@ def targets(yp=False):
buffer = None buffer = None
response_data = []
def handle_buffer(ready_bytes: int): def handle_buffer(ready_bytes: int):
global buffer_read_len, BUFFER_TEST_TARGET
data = buffer.read(ready_bytes) data = buffer.read(ready_bytes)
buffer.write(data + " back at you".encode("utf-8")) buffer_read_len += len(data)
buffer.flush() response_data.append(data)
if data == "Hi there".encode("utf-8"):
RNS.log("Sending response")
for data in response_data:
buffer.write(data + " back at you".encode("utf-8"))
buffer.flush()
buffer_read_len = 0
if buffer_read_len == BUFFER_TEST_TARGET:
RNS.log("Sending response")
for data in response_data:
buffer.write(data + " back at you".encode("utf-8"))
buffer.flush()
buffer_read_len = 0
buffer = RNS.Buffer.create_bidirectional_buffer(0, 0, channel, handle_buffer) buffer = RNS.Buffer.create_bidirectional_buffer(0, 0, channel, handle_buffer)