From 92ede16bcac6c52b0565a670172266847133b059 Mon Sep 17 00:00:00 2001
From: Jezza34000 <57314417+Jezza34000@users.noreply.github.com>
Date: Wed, 27 Jul 2022 14:34:18 +0200
Subject: [PATCH 01/28] Update install_apt.sh
add wheel for Atlas
---
resources/install_apt.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/install_apt.sh b/resources/install_apt.sh
index 90f5225..b5092c7 100755
--- a/resources/install_apt.sh
+++ b/resources/install_apt.sh
@@ -23,7 +23,7 @@ echo 65 > ${PROGRESS_FILE}
echo "*************************************"
echo "Install the required python libraries"
echo "*************************************"
-python3 -m pip install "h11" "setuptools" "charset-normalizer" "requests" "aiohttp" "aiosignal" "asyncio" "fastapi" "uvicorn" "urllib3"
+python3 -m pip install "wheel" "h11" "setuptools" "charset-normalizer" "requests" "aiohttp" "aiosignal" "asyncio" "fastapi" "uvicorn" "urllib3"
echo 100 > ${PROGRESS_FILE}
echo $(date)
From 6a5e776dc2140f05d6942146944066eb5e3e758a Mon Sep 17 00:00:00 2001
From: Jezza34000 <57314417+Jezza34000@users.noreply.github.com>
Date: Tue, 11 Oct 2022 21:21:17 +0200
Subject: [PATCH 02/28] Update reolinkapi.class.php
is_loggedin bug fix
---
3rdparty/reolinkapi.class.php | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/3rdparty/reolinkapi.class.php b/3rdparty/reolinkapi.class.php
index 5a86195..ef0ee1a 100755
--- a/3rdparty/reolinkapi.class.php
+++ b/3rdparty/reolinkapi.class.php
@@ -151,7 +151,7 @@ class reolinkAPI {
public function __construct(array $cnxinfo) {
log::add('reolink', 'debug', str_repeat("~", 60));
- $this->$is_loggedin = false;
+ $this->is_loggedin = false;
$this->ip = trim($cnxinfo['adresseIP']);
if (strtolower($cnxinfo['cnxtype'] == "")) {
@@ -182,7 +182,7 @@ public function __construct(array $cnxinfo) {
// TOKEN NOK (get new one)
$this->login();
} else {
- $this->$is_loggedin = true;
+ $this->is_loggedin = true;
}
}
@@ -244,7 +244,7 @@ private function reolinkTokenValidity() {
if ($tsnow > ($this->tokenexp) -15)
{
log::add('reolink', 'debug', 'API Token expiré > renouvellement requis.');
- $this->$is_loggedin = false;
+ $this->is_loggedin = false;
unset($this->$token);
unset($this->$tokenexp);
try {
@@ -263,7 +263,7 @@ private function reolinkTokenValidity() {
private function login() {
log::add('reolink', 'debug', 'Camera login...');
- $this->$is_loggedin = false;
+ $this->is_loggedin = false;
unset($this->$token);
unset($this->$tokenexp);
$loginParameters = '[{"cmd":"Login","param":{"User":{"userName":"'.$this->user.'","password":"'.$this->password.'"}}}]';
@@ -278,7 +278,7 @@ private function login() {
if (!empty($this->token) && !empty($this->tokenexp))
{
// Login OK
- $this->$is_loggedin = true;
+ $this->is_loggedin = true;
log::add('reolink', 'debug', 'Token : '.$this->token.' Validité : '.$this->tokenexp);
try {
config::save("token".$this->tagtoken, $this->token, 'reolink');
@@ -290,7 +290,7 @@ private function login() {
}
} else {
// Login FAILED
- $this->$is_loggedin = false;
+ $this->is_loggedin = false;
log::add('reolink', 'error', 'Echec > Impossible de se logguer sur la caméra');
return false;
}
@@ -299,7 +299,7 @@ private function login() {
public function SendCMD($POSTparameters, $URLrequest = NULL) {
- if (!$this->$is_loggedin && !strpos($POSTparameters, 'cmd":"Login')) {
+ if (!$this->is_loggedin && !strpos($POSTparameters, 'cmd":"Login')) {
log::add('reolink', 'error', 'Envoi de la commande impossible non loggué sur la caméra');
return false;
}
From 974dd44fa6b8f5ab04014ceb8e742236fd744329 Mon Sep 17 00:00:00 2001
From: Jezza34000 <57314417+Jezza34000@users.noreply.github.com>
Date: Fri, 28 Oct 2022 07:08:00 +0200
Subject: [PATCH 03/28] bug fix refresh
bug fix refresh
---
changelog.md | 6 ++++++
core/class/reolink.class.php | 4 ++--
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/changelog.md b/changelog.md
index 4d1b8e2..cd1fb08 100755
--- a/changelog.md
+++ b/changelog.md
@@ -1,5 +1,11 @@
# Change log
+28/10/2022
+- Bug fix RefreshInfo
+
+18/10/2022
+- Bug fix API (is_loggedin)
+
27/07/2022
- Bug fix for Atlas Jeedom (py wheel)
diff --git a/core/class/reolink.class.php b/core/class/reolink.class.php
index 0efd49d..6b91b20 100755
--- a/core/class/reolink.class.php
+++ b/core/class/reolink.class.php
@@ -45,7 +45,7 @@ public static function getReolinkConnection($id) {
public static function TryConnect($id) {
$reolinkConn = reolink::getReolinkConnection($id);
- if ($reolinkConn->$is_loggedin == true) {
+ if ($reolinkConn->is_loggedin == true) {
log::add('reolink', 'info', 'Connection à la caméra réussie');
return true;
} else {
@@ -217,7 +217,7 @@ public static function refreshNFO($id) {
$camcnx = reolink::getReolinkConnection($id);
$cmdget = NULL;
- if ($camcnx->$is_loggedin == false) {
+ if ($camcnx->is_loggedin == false) {
exit();
}
From 2b5a1af460d13b2e1a9ed5a5360eb5384407621c Mon Sep 17 00:00:00 2001
From: Jezza <57314417+Jezza34000@users.noreply.github.com>
Date: Mon, 7 Nov 2022 17:21:53 +0100
Subject: [PATCH 04/28] Update README.md
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
avertissement remontée détection
---
README.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/README.md b/README.md
index 05e9be9..db9d7b7 100755
--- a/README.md
+++ b/README.md
@@ -47,6 +47,8 @@ Vous pouvez tester si les paramètres sont correctes et si le plugin arrive à a
Lors de mise(s) à jour du plugin Reolink, de nouvelles commandes peuvent être ajouter (cf. Changelog du plugin) pour faciliter une meilleure gestion de la caméra.
**Pour bénéficier des nouvelles commandes, relancer le processus de création de commandes pour chacun de la (des) caméra(s)**
+
+ > Warning : La remontée de détection de mouvement depuis la caméra vers le plugin n'est pas fiable, et ne dois aucunement être utilisé en tant que système de sécurité.
From 6f98f42c718e6faf76c3ca92d0cc2d35981f9a63 Mon Sep 17 00:00:00 2001
From: Jezza <57314417+Jezza34000@users.noreply.github.com>
Date: Mon, 7 Nov 2022 17:23:03 +0100
Subject: [PATCH 05/28] Update README.md
---
README.md | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/README.md b/README.md
index db9d7b7..af3df4f 100755
--- a/README.md
+++ b/README.md
@@ -43,12 +43,9 @@ Vous pouvez tester si les paramètres sont correctes et si le plugin arrive à a
* Générez les commandes de la caméra : bouton ![image](https://user-images.githubusercontent.com/54839700/174434177-5f433dc2-91b5-4cdb-9bcc-8a42d6a48f0d.png)
-**!! NB TRES IMPORTANT !! :**
-
- Lors de mise(s) à jour du plugin Reolink, de nouvelles commandes peuvent être ajouter (cf. Changelog du plugin) pour faciliter une meilleure gestion de la caméra.
- **Pour bénéficier des nouvelles commandes, relancer le processus de création de commandes pour chacun de la (des) caméra(s)**
+> IMPORTANT : Lors de mise(s) à jour du plugin Reolink, de nouvelles commandes peuvent être ajouter (cf. Changelog du plugin) pour faciliter une meilleure gestion de la caméra. **Pour bénéficier des nouvelles commandes, relancer le processus de création de commandes pour chacun de la (des) caméra(s)**
- > Warning : La remontée de détection de mouvement depuis la caméra vers le plugin n'est pas fiable, et ne dois aucunement être utilisé en tant que système de sécurité.
+ > ATTENTION : La remontée de détection de mouvement depuis la caméra vers le plugin n'est pas fiable, et ne dois aucunement être utilisé en tant que système de sécurité.
From b998c301bb5d44cd8f6f80412466a80a02dae111 Mon Sep 17 00:00:00 2001
From: Jezza <57314417+Jezza34000@users.noreply.github.com>
Date: Thu, 21 Dec 2023 13:48:06 +0100
Subject: [PATCH 06/28] Update requirements.txt
Update vulnerable packages
-aiohttp's ClientSession is vulnerable to CRLF injection via version High
-Removal of e-Tugra root certificate High
-Starlette allows an unauthenticated and remote attacker to specify any number of form fields or files High
-pypa/setuptools vulnerable to Regular Expression Denial of Service (ReDoS) High
---
resources/requirements.txt | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 1d9e475..414b3bd 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -1,10 +1,10 @@
-aiohttp~=3.8.1
+aiohttp>=3.9.1
aiosignal~=1.2.0
anyio~=3.6.1
asgiref~=3.5.2
async-timeout~=4.0.2
attrs~=21.4.0
-certifi~=2022.5.18
+certifi>=2023.7.22
charset-normalizer~=2.0.12
click~=8.1.3
fastapi~=0.78.0
@@ -15,9 +15,9 @@ multidict~=6.0.2
pip~=22.1
pydantic~=1.9.1
requests~=2.27.1
-setuptools~=62.3.2
+setuptools>=65.5.1
sniffio~=1.2.0
-starlette~=0.20.0
+starlette>=0.25.0
typing-extensions~=4.2.0
urllib3~=1.26.9
uvicorn~=0.17.6
From 2b214e42ce18f9d678a8d49b2313c14b85dbb2de Mon Sep 17 00:00:00 2001
From: Jezza <57314417+Jezza34000@users.noreply.github.com>
Date: Thu, 21 Dec 2023 13:49:48 +0100
Subject: [PATCH 07/28] Update changelog.md
---
changelog.md | 3 +++
1 file changed, 3 insertions(+)
diff --git a/changelog.md b/changelog.md
index cd1fb08..400951b 100755
--- a/changelog.md
+++ b/changelog.md
@@ -1,5 +1,8 @@
# Change log
+21/12/2023
+- Update vunerable package in requirements.txt
+
28/10/2022
- Bug fix RefreshInfo
From 405c96b24dce07fdb3244c3e0f5a81b469217ce5 Mon Sep 17 00:00:00 2001
From: Jezza <57314417+Jezza34000@users.noreply.github.com>
Date: Thu, 21 Dec 2023 13:50:03 +0100
Subject: [PATCH 08/28] Update changelog.md
---
changelog.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/changelog.md b/changelog.md
index 400951b..3be533b 100755
--- a/changelog.md
+++ b/changelog.md
@@ -1,7 +1,7 @@
# Change log
21/12/2023
-- Update vunerable package in requirements.txt
+- Update vulnerable package in requirements.txt
28/10/2022
- Bug fix RefreshInfo
From a18723a1d8137e24ee25d44a250f6d7fae958e0b Mon Sep 17 00:00:00 2001
From: t0urista
Date: Thu, 7 Mar 2024 20:56:15 +0100
Subject: [PATCH 09/28] Update reolinkapicmd.json with additionnal onvif event
commands
---
core/config/reolinkapicmd.json | 96 ++++++++++++++++++++++++++++++++++
1 file changed, 96 insertions(+)
diff --git a/core/config/reolinkapicmd.json b/core/config/reolinkapicmd.json
index c98bc5a..04de06b 100755
--- a/core/config/reolinkapicmd.json
+++ b/core/config/reolinkapicmd.json
@@ -30,6 +30,102 @@
"isVisible": 1,
"logicalId": "MdState"
},
+
+
+ {
+ "abilityneed":"alarmMd",
+ "name": "event Motion (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvMotion"
+ },
+ {
+ "abilityneed":"alarmMd",
+ "name": "event FaceDetect (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvFaceDetect"
+ },
+ {
+ "abilityneed":"alarmMd",
+ "name": "event PeopleDetect (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvPeopleDetect"
+ },
+ {
+ "abilityneed":"alarmMd",
+ "name": "event VehicleDetect (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvVehicleDetect"
+ },
+ {
+ "abilityneed":"alarmMd",
+ "name": "event DogCatDetect (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvDogCatDetect"
+ },
+ {
+ "abilityneed":"alarmMd",
+ "name": "event MotionAlarm (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvMotionAlarm"
+ },
+ {
+ "abilityneed":"alarmMd",
+ "name": "event Visitor (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvVisitor"
+ },
+
+ {
+ "abilityneed":"alarmMd",
+ "name": "last Onvif Event (full) ",
+ "type": "info",
+ "subtype": "string",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvLastOnvifFull"
+ },
+
+ {
+ "abilityneed":"alarmMd",
+ "name": "last Onvif Event (name) ",
+ "type": "info",
+ "subtype": "string",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvLastOnvifName"
+ },
+
+ {
+ "abilityneed":"alarmMd",
+ "name": "last Onvif Event (etat)",
+ "type": "info",
+ "subtype": "binary",
+ "IsHistorized": 0,
+ "isVisible": 1,
+ "logicalId": "EvLastOnvifState"
+ },
+
{
"abilityneed":"performance",
"name": "Débit codec (Kbps)",
From 3d85554305a9c0580e91bd3d0a71a0f86541b978 Mon Sep 17 00:00:00 2001
From: t0urista
Date: Thu, 7 Mar 2024 20:57:16 +0100
Subject: [PATCH 10/28] Update jeeReolink.php with additionnal onvif event
---
core/php/jeeReolink.php | 27 ++++++++++++++++++++++++---
1 file changed, 24 insertions(+), 3 deletions(-)
diff --git a/core/php/jeeReolink.php b/core/php/jeeReolink.php
index 3f10355..a7c889d 100755
--- a/core/php/jeeReolink.php
+++ b/core/php/jeeReolink.php
@@ -16,7 +16,10 @@
die();
}
- if (isset($result['message']) && $result['message'] == "motion") {
+# BEGIN modified by t0urista to handle ONVIF events
+ if (isset($result['message']) && (($result['message']=="motion") || (strpos($result['message'], 'Ev') !== false) )) {
+# END modified by t0urista to handle ONVIF events
+
$plugin = plugin::byId('reolink');
$eqLogics = eqLogic::byType($plugin->getId());
@@ -31,8 +34,26 @@
}
if ($camera_ip == $result['ip']) {
- log::add('reolink', 'debug', 'Evènement MotionState reçu depuis le daemon. Cam IP='.$result['ip'].' état='.$result['motionstate']);
- $eqLogic->checkAndUpdateCmd('MdState', $result['motionstate']);
+ if ($result['message'] == "motion") {
+ log::add('reolink', 'debug', 'Cam IP='.$result['ip']. ' Onvif event reçu depuis le daemon. name= MDstate, état='.$result['motionstate']);
+ $eqLogic->checkAndUpdateCmd('MdState', $result['motionstate']);
+ }
+
+# BEGIN added by t0urista to handle ONVIF events
+
+# catch any ONVIF events in the 3 genreic ONVIF commands, can cover unknown ONVIF events
+ $eqLogic->checkAndUpdateCmd('EvLastOnvifName', $result['message']);
+ $eqLogic->checkAndUpdateCmd('EvLastOnvifState', $result['motionstate']);
+ $eqLogic->checkAndUpdateCmd('EvLastOnvifFull', $result['message'] . '-' . $result['motionstate']);
+
+# catch all pre-defined ONVIF events with their dedicated commands, does only cover knwon ONVIF events
+
+ if (strpos($result['message'], 'Ev') !== false) {
+ log::add('reolink', 'debug', 'Cam IP='.$result['ip']. ' Onvif event reçu depuis le daemon. name= ' . $result['message'] . ', etat='.$result['motionstate']);
+ $eqLogic->checkAndUpdateCmd($result['message'], $result['motionstate']);
+ }
+# END added by t0urista to handle ONVIF events
+
#log::add('reolink', 'debug', 'IP : ' . $camera_contact_point . ' / IsCamAI : ' . $camera_AI . ' / EqId : ' . $EqId . ' / Channel : ' . $channel);
if ($camera_AI == "Oui") {
$camcnx = reolink::getReolinkConnection($eqLogic->getId());
From cec6c2a6a82ecc99afaedf313b682a35fed04dd9 Mon Sep 17 00:00:00 2001
From: t0urista
Date: Thu, 7 Mar 2024 20:59:33 +0100
Subject: [PATCH 11/28] Update camhook.py
---
resources/demond/camhook.py | 117 ++++++++++++++++++++++++++----------
1 file changed, 86 insertions(+), 31 deletions(-)
diff --git a/resources/demond/camhook.py b/resources/demond/camhook.py
index 044dddb..a50f42b 100644
--- a/resources/demond/camhook.py
+++ b/resources/demond/camhook.py
@@ -4,49 +4,104 @@
import re
try:
- from jeedom.jeedom import *
+ from jeedom.jeedom import *
except ImportError:
- print("Error: importing module jeedom.jeedom")
- sys.exit(1)
+ print("Error: importing module jeedom.jeedom")
+ sys.exit(1)
try:
- f = open('jeedomcreds', 'r')
- _callback = f.readline().rstrip("\n")
- _apikey = f.readline().rstrip("\n")
- f.close()
+ f = open('jeedomcreds', 'r')
+ _callback = f.readline().rstrip("\n")
+ _apikey = f.readline().rstrip("\n")
+ f.close()
except:
- logging.error(f"Unable to read credentials jeedom file, retry...")
- sys.exit(1)
+ logging.error(f"Unable to read credentials jeedom file, retry...")
+ sys.exit(1)
try:
- os.remove("jeedomcreds")
+ os.remove("jeedomcreds")
except:
- pass
+ pass
jeedom_cnx = jeedom_com(_apikey, _callback)
detect_state = 0
+# BEGIN added by t0urista to handle ONVIF events
+eventTable = {}
+# END added by t0urista to handle ONVIF events
app = FastAPI()
@app.post("/inbound_events", status_code=200)
async def get_body(request: Request):
- global detect_state
- ip = request.client.host
- logging.debug(f"Incoming XML camera event on webhook from IP={ip}")
- xml_answer = await request.body()
-
- new_detect_state = 0
- if re.search('IsMotion" Value="true"', xml_answer.decode('utf-8')):
- new_detect_state = 1
-
- if detect_state != new_detect_state:
- detect_state = new_detect_state
- send_frame = {
- "message": "motion",
- "ip": ip,
- "motionstate": detect_state
- }
- # convert into JSON:
- message = json.dumps(send_frame)
- jeedom_cnx.send_change_immediate(json.loads(message))
- return
+
+ global detect_state
+
+# BEGIN added by t0urista to handle ONVIF events
+ global eventTable
+# END added by t0urista to handle ONVIF events
+
+
+ ip = request.client.host
+ logging.debug(f"Incoming XML camera event on webhook from IP={ip}")
+ xml_answer = await request.body()
+
+ new_detect_state = 0
+ if re.search('IsMotion" Value="true"', xml_answer.decode('utf-8')):
+ new_detect_state = 1
+ if detect_state != new_detect_state:
+ detect_state = new_detect_state
+ send_frame = {
+ "message": "motion",
+ "ip": ip,
+ "motionstate": detect_state
+ }
+# convert into JSON:
+ message = json.dumps(send_frame)
+ jeedom_cnx.send_change_immediate(json.loads(message))
+
+
+# BEGIN added by t0urista to handle ONVIF events
+ pattern=r'(.*?).*?.*?Value="(.*?)" />'
+ event_status_all=re.findall(pattern,xml_answer.decode('utf-8'))
+
+# logging.debug(event_status_all)
+ for event_status in event_status_all:
+# logging.debug(event_status)
+ event=re.findall(r'tns1:.*/(.*)', event_status[0])
+ event="Ev" + event[0]
+# logging.debug(event[0])
+# logging.debug(tuple[0])
+ status=0
+ if(event_status[1]!="false"):
+ status=1
+ logging.debug(f"received event {event} {status}")
+ eventFound=0
+ for eventName in eventTable:
+# print(eventName)
+ if (eventName==event):
+ eventFound=1
+ if (eventTable[eventName]!=status):
+ logging.debug(f"{event} --> {status}")
+ eventTable[eventName]=status
+ send_frame = {
+ "message": event,
+ "ip": ip,
+ "motionstate": status
+ }
+ # convert into JSON:
+ message = json.dumps(send_frame)
+ jeedom_cnx.send_change_immediate(json.loads(message))
+ if (eventFound==0):
+ eventTable[event] = status
+ logging.debug(f"{event} --> {status}")
+ send_frame = {
+ "message": event,
+ "ip": ip,
+ "motionstate": status
+ }
+ # convert into JSON:
+ message = json.dumps(send_frame)
+ jeedom_cnx.send_change_immediate(json.loads(message))
+# END added by t0urista to handle ONVIF events
+
+ return
From 302132d3106a58c16b81d8e17fa80185283a7c0f Mon Sep 17 00:00:00 2001
From: t0urista
Date: Fri, 8 Mar 2024 07:33:53 +0100
Subject: [PATCH 12/28] Update camhook.py treat ONVIF notifications received by
the ONVIF subscripton daemon
---
resources/demond/camhook.py | 1 -
1 file changed, 1 deletion(-)
diff --git a/resources/demond/camhook.py b/resources/demond/camhook.py
index a50f42b..251dd4a 100644
--- a/resources/demond/camhook.py
+++ b/resources/demond/camhook.py
@@ -70,7 +70,6 @@ async def get_body(request: Request):
event=re.findall(r'tns1:.*/(.*)', event_status[0])
event="Ev" + event[0]
# logging.debug(event[0])
-# logging.debug(tuple[0])
status=0
if(event_status[1]!="false"):
status=1
From 554ab730616e1ab0219f93ab682886b83632d51f Mon Sep 17 00:00:00 2001
From: Jezza <57314417+Jezza34000@users.noreply.github.com>
Date: Sun, 10 Mar 2024 15:55:09 +0100
Subject: [PATCH 13/28] Update changelog.md
---
changelog.md | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/changelog.md b/changelog.md
index 3be533b..e08ed29 100755
--- a/changelog.md
+++ b/changelog.md
@@ -1,5 +1,10 @@
# Change log
+10/03/2021
+- Ajout de nouvelles détection depuis la souscrption ONVIF
+- Amélioration communication entre daemon et plugin
+Merci @t0urista
+
21/12/2023
- Update vulnerable package in requirements.txt
From a5618e6cecbf963e91361f6b7888caebb8588274 Mon Sep 17 00:00:00 2001
From: t0urista
Date: Sun, 24 Mar 2024 17:12:06 +0100
Subject: [PATCH 14/28] Update jeeReolink.php
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
fixes update of binary commands for People and Vehicle objects détection for AI capable cameras
---
core/php/jeeReolink.php | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/core/php/jeeReolink.php b/core/php/jeeReolink.php
index a7c889d..1946877 100755
--- a/core/php/jeeReolink.php
+++ b/core/php/jeeReolink.php
@@ -60,8 +60,8 @@
$channel = $eqLogic->getConfiguration('channelNum') - 1;
$res = $camcnx->SendCMD('[{"cmd":"GetAiState","action":0,"param":{"channel":'.$channel.'}}]');
if (isset($res[0]['value'])) {
- $eqLogic->checkAndUpdateCmd('MdPersonState', $res[0]['value']['people']['alarm_state']);
- $eqLogic->checkAndUpdateCmd('MdVehicleState', $res[0]['value']['vehicle']['alarm_state']);
+ $eqLogic->checkAndUpdateCmd('EvPeopleDetect', $res[0]['value']['people']['alarm_state']);
+ $eqLogic->checkAndUpdateCmd('EvVehicleDetect', $res[0]['value']['vehicle']['alarm_state']);
}
log::add('reolink', 'debug', 'Cam AI : Evènements Motion | Personne : ' . $res[0]['value']['people']['alarm_state'] . ' / Vehicule : ' . $res[0]['value']['vehicle']['alarm_state']);
}
From cb1975b4637fd6b9e33c9d2083cf5e72c8da297b Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 10:52:46 +0000
Subject: [PATCH 15/28] Add renovate.json
---
renovate.json | 6 ++++++
1 file changed, 6 insertions(+)
create mode 100644 renovate.json
diff --git a/renovate.json b/renovate.json
new file mode 100644
index 0000000..5db72dd
--- /dev/null
+++ b/renovate.json
@@ -0,0 +1,6 @@
+{
+ "$schema": "https://docs.renovatebot.com/renovate-schema.json",
+ "extends": [
+ "config:recommended"
+ ]
+}
From fe1bbba99778241a5f910997a9889023b4c0c219 Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 10:54:36 +0000
Subject: [PATCH 16/28] Update dependency aiosignal to ~=1.3.1
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 414b3bd..33ad56c 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -1,5 +1,5 @@
aiohttp>=3.9.1
-aiosignal~=1.2.0
+aiosignal~=1.3.1
anyio~=3.6.1
asgiref~=3.5.2
async-timeout~=4.0.2
From 9b0c713efa8223db35a2cc100acedcc782fb7529 Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 13:56:26 +0000
Subject: [PATCH 17/28] Update dependency anyio to ~=3.7.1
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 33ad56c..3a34a7d 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -1,6 +1,6 @@
aiohttp>=3.9.1
aiosignal~=1.3.1
-anyio~=3.6.1
+anyio~=3.7.1
asgiref~=3.5.2
async-timeout~=4.0.2
attrs~=21.4.0
From cc932fda19fef2c6529a270d03f02cb085c43281 Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 13:56:34 +0000
Subject: [PATCH 18/28] Update dependency charset-normalizer to ~=2.1.1
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 33ad56c..41c4b4e 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -5,7 +5,7 @@ asgiref~=3.5.2
async-timeout~=4.0.2
attrs~=21.4.0
certifi>=2023.7.22
-charset-normalizer~=2.0.12
+charset-normalizer~=2.1.1
click~=8.1.3
fastapi~=0.78.0
frozenlist~=1.3.0
From 858a4f954fc470bf76ba31b8e2b2843c7cf06ee0 Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 13:57:03 +0000
Subject: [PATCH 19/28] Update dependency asgiref to ~=3.8.1
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 3a34a7d..ab9183f 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -1,7 +1,7 @@
aiohttp>=3.9.1
aiosignal~=1.3.1
anyio~=3.7.1
-asgiref~=3.5.2
+asgiref~=3.8.1
async-timeout~=4.0.2
attrs~=21.4.0
certifi>=2023.7.22
From 68dd1a1b47e34de8a4073a13b024d444be0644cc Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 15:03:07 +0000
Subject: [PATCH 20/28] Update dependency frozenlist to ~=1.4.1
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 305119a..994b515 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -8,7 +8,7 @@ certifi>=2023.7.22
charset-normalizer~=2.1.1
click~=8.1.3
fastapi~=0.78.0
-frozenlist~=1.3.0
+frozenlist~=1.4.1
h11~=0.13.0
idna~=3.3
multidict~=6.0.2
From 6e5c249457bf8dd0a09d147323dac3930eb064ff Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 18:54:48 +0000
Subject: [PATCH 21/28] Update dependency h11 to ~=0.14.0
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 994b515..58dfb8e 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -9,7 +9,7 @@ charset-normalizer~=2.1.1
click~=8.1.3
fastapi~=0.78.0
frozenlist~=1.4.1
-h11~=0.13.0
+h11~=0.14.0
idna~=3.3
multidict~=6.0.2
pip~=22.1
From 0ed1e1c7ed6f87bf6e2b10292d61a2823379abf0 Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 21:30:31 +0000
Subject: [PATCH 22/28] Update dependency requests to ~=2.31.0
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 994b515..c855b4c 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -14,7 +14,7 @@ idna~=3.3
multidict~=6.0.2
pip~=22.1
pydantic~=1.9.1
-requests~=2.27.1
+requests~=2.31.0
setuptools>=65.5.1
sniffio~=1.2.0
starlette>=0.25.0
From caec09176e5925cbd0f88113d61b9e82b1079e4a Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Tue, 2 Apr 2024 21:30:35 +0000
Subject: [PATCH 23/28] Update dependency sniffio to ~=1.3.1
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 994b515..3c24c3f 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -16,7 +16,7 @@ pip~=22.1
pydantic~=1.9.1
requests~=2.27.1
setuptools>=65.5.1
-sniffio~=1.2.0
+sniffio~=1.3.1
starlette>=0.25.0
typing-extensions~=4.2.0
urllib3~=1.26.9
From e9cec3d2bb01d2ef0fbeba9c7bac54635d4575de Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Wed, 3 Apr 2024 04:19:59 +0000
Subject: [PATCH 24/28] Update dependency yarl to ~=1.9.4
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 994b515..5810669 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -22,4 +22,4 @@ typing-extensions~=4.2.0
urllib3~=1.26.9
uvicorn~=0.17.6
wheel~=0.37.1
-yarl~=1.7.2
+yarl~=1.9.4
From 732b352ee2832c1912a1fbdef2c3dc3e33b22160 Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Wed, 3 Apr 2024 08:02:49 +0000
Subject: [PATCH 25/28] Update dependency wheel to ~=0.43.0
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 5810669..e641d74 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -21,5 +21,5 @@ starlette>=0.25.0
typing-extensions~=4.2.0
urllib3~=1.26.9
uvicorn~=0.17.6
-wheel~=0.37.1
+wheel~=0.43.0
yarl~=1.9.4
From 0e5ff4d6032a0388c3a37407e5de3b0e5cfc559c Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Wed, 3 Apr 2024 08:02:54 +0000
Subject: [PATCH 26/28] Update dependency attrs to v23
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index 5810669..ad790a7 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -3,7 +3,7 @@ aiosignal~=1.3.1
anyio~=3.7.1
asgiref~=3.8.1
async-timeout~=4.0.2
-attrs~=21.4.0
+attrs~=23.2.0
certifi>=2023.7.22
charset-normalizer~=2.1.1
click~=8.1.3
From b11d1e4f2f59ae36adacd90d10a317d1cba226cb Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Wed, 3 Apr 2024 08:03:30 +0000
Subject: [PATCH 27/28] Update dependency uvicorn to ~=0.29.0
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index e641d74..2740225 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -20,6 +20,6 @@ sniffio~=1.2.0
starlette>=0.25.0
typing-extensions~=4.2.0
urllib3~=1.26.9
-uvicorn~=0.17.6
+uvicorn~=0.29.0
wheel~=0.43.0
yarl~=1.9.4
From 2115cb4efcd180c906514a0197e7557edcc68173 Mon Sep 17 00:00:00 2001
From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com>
Date: Fri, 5 Apr 2024 13:42:38 +0000
Subject: [PATCH 28/28] Update dependency typing-extensions to ~=4.11.0
---
resources/requirements.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/resources/requirements.txt b/resources/requirements.txt
index e641d74..b2db4a0 100644
--- a/resources/requirements.txt
+++ b/resources/requirements.txt
@@ -18,7 +18,7 @@ requests~=2.27.1
setuptools>=65.5.1
sniffio~=1.2.0
starlette>=0.25.0
-typing-extensions~=4.2.0
+typing-extensions~=4.11.0
urllib3~=1.26.9
uvicorn~=0.17.6
wheel~=0.43.0