mirror of
https://github.com/meshcore-dev/meshcore_py.git
synced 2026-06-11 03:56:16 +00:00
verify if channels has hashes ...
This commit is contained in:
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
||||
|
||||
[project]
|
||||
name = "meshcore"
|
||||
version = "2.2.16"
|
||||
version = "2.2.17"
|
||||
authors = [
|
||||
{ name="Florent de Lamotte", email="florent@frizoncorrea.fr" },
|
||||
{ name="Alex Wolden", email="awolden@gmail.com" },
|
||||
|
||||
@@ -627,7 +627,7 @@ class MessageReader:
|
||||
|
||||
channel = None
|
||||
for c in self.channels:
|
||||
if c["channel_hash"] == chan_hash : # validate against MAC
|
||||
if "channel_hash" in c and c["channel_hash"] == chan_hash : # validate against MAC
|
||||
h = HMAC.new(c["channel_secret"], digestmod=SHA256)
|
||||
h.update(msg)
|
||||
if h.digest()[0:2] == cipher_mac:
|
||||
|
||||
Reference in New Issue
Block a user