Commit deaec092 authored by Vladimir Bashkirtsev's avatar Vladimir Bashkirtsev

ACS should not fail if connection request URL is empty

parent 33891af8
...@@ -6,6 +6,7 @@ all: acs-cwmp-service acs-fs-service acs-nbi-service acs-ui-service genieacs-con ...@@ -6,6 +6,7 @@ all: acs-cwmp-service acs-fs-service acs-nbi-service acs-ui-service genieacs-con
tar xf genieacs-1.2.5.tar.gz tar xf genieacs-1.2.5.tar.gz
patch -Np1 -d genieacs-1.2.5 < genieacs-1.2.5-ping_fix.patch patch -Np1 -d genieacs-1.2.5 < genieacs-1.2.5-ping_fix.patch
patch -Np1 -d genieacs-1.2.5 < genieacs-1.2.5-handle_empty_connection_URL.patch
cd genieacs-1.2.5 && npm install cd genieacs-1.2.5 && npm install
cd genieacs-1.2.5 && NODE_OPTIONS="--max-old-space-size=3072" npm run build cd genieacs-1.2.5 && NODE_OPTIONS="--max-old-space-size=3072" npm run build
......
diff -uNr genieacs-1.2.5/lib/connection-request.ts genieacs-1.2.5-handle_empty_connection_URL/lib/connection-request.ts
--- genieacs-1.2.5/lib/connection-request.ts 2021-03-13 10:06:19.000000000 +1030
+++ genieacs-1.2.5-handle_empty_connection_URL/lib/connection-request.ts 2025-04-11 10:43:01.511284274 +0930
@@ -94,6 +94,8 @@
_debug: boolean,
deviceId: string
): Promise<string> {
+ if (address === "") return "";
+
const options: http.RequestOptions = parse(address);
if (options.protocol !== "http:")
return "Invalid connection request URL or protocol";
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment