From ddd8f5eee19c04da97b5631c9bda449f90885423 Mon Sep 17 00:00:00 2001 From: LordGrey Date: Thu, 12 Jun 2025 22:36:06 +0200 Subject: [PATCH 1/7] Fixes - WebUI unreachable via IPv6 (#1871) --- CHANGELOG.md | 11 +++++++++++ libsrc/utils/NetOrigin.cpp | 25 ++++++++++++++----------- 2 files changed, 25 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4d583eb2c..74bc242cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased](https://github.com/hyperion-project/hyperion.ng/compare/2.1.0...HEAD) +### ⚠️ Breaking Changes + +### ✨ Added + +### 🔧 Changed + +- **Fixes:** + - WebUI unreachable via IPv6 (#1871) + +### 🗑️ Removed + ## [2.1.0](https://github.com/hyperion-project/hyperion.ng/releases/tag/2.1.0) - 2025-06-12 ### ⚠️ Breaking Changes diff --git a/libsrc/utils/NetOrigin.cpp b/libsrc/utils/NetOrigin.cpp index 42693491b..f85589bd3 100644 --- a/libsrc/utils/NetOrigin.cpp +++ b/libsrc/utils/NetOrigin.cpp @@ -58,31 +58,34 @@ bool NetOrigin::isLocalAddress(const QHostAddress& ipAddress, const QHostAddress return true; } - //Convert to IPv4 to check, if an IPv6 address is an IPv4 mapped address - QHostAddress ipv4Address(address.toIPv4Address()); - if (ipv4Address != QHostAddress::AnyIPv4) // ipv4Address is not "0.0.0.0" + // Convert IPv4-mapped IPv6 to pure IPv4 + QHostAddress const ipv4Address(address.toIPv4Address()); + if (ipv4Address != QHostAddress::AnyIPv4) { address = ipv4Address; } - QList allInterfaces = QNetworkInterface::allInterfaces(); - for (const QNetworkInterface &networkInterface : allInterfaces) { - QList addressEntries = networkInterface.addressEntries(); - for (const QNetworkAddressEntry &localNetworkAddressEntry : addressEntries) { - QHostAddress localIP = localNetworkAddressEntry.ip(); + QList const allInterfaces = QNetworkInterface::allInterfaces(); + for (const QNetworkInterface &networkInterface : allInterfaces) + { + QList const addressEntries = networkInterface.addressEntries(); + for (const QNetworkAddressEntry &localNetworkAddressEntry : addressEntries) + { + QHostAddress const localIP = localNetworkAddressEntry.ip(); - if(localIP.protocol() != QAbstractSocket::NetworkLayerProtocol::IPv4Protocol) + // Skip protocol mismatch + if (localIP.protocol() != address.protocol()) { continue; } - bool isInSubnet = address.isInSubnet(localIP, localNetworkAddressEntry.prefixLength()); - if (isInSubnet) + if (address.isInSubnet(localIP, localNetworkAddressEntry.prefixLength())) { return true; } } } + return false; } From 0e319041e82dc227f3c62968f9043ca7f2cc2621 Mon Sep 17 00:00:00 2001 From: LordGrey Date: Thu, 12 Jun 2025 22:39:03 +0200 Subject: [PATCH 2/7] Rollover version --- .version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.version b/.version index 7ec1d6db4..8249aefcc 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -2.1.0 +2.1.1-beta.1 From c5eaf985f8677da894962211a4e7721c2ef21b90 Mon Sep 17 00:00:00 2001 From: LordGrey Date: Fri, 13 Jun 2025 10:29:53 +0200 Subject: [PATCH 3/7] Align install_pr script working with default Qt6 builds & show authentication failures (#1871) --- CHANGELOG.md | 7 +++++ bin/scripts/install_pr.sh | 61 +++++++++++++++++++++++++++------------ 2 files changed, 49 insertions(+), 19 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 74bc242cd..e2b4ee005 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,12 +8,19 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### ⚠️ Breaking Changes +--- + ### ✨ Added +--- + ### 🔧 Changed - **Fixes:** - WebUI unreachable via IPv6 (#1871) + - Align install_pr script working with default Qt6 builds & show authentication failures (#1871) + +--- ### 🗑️ Removed diff --git a/bin/scripts/install_pr.sh b/bin/scripts/install_pr.sh index 947130469..07cc8cf3e 100755 --- a/bin/scripts/install_pr.sh +++ b/bin/scripts/install_pr.sh @@ -15,7 +15,6 @@ hasPython2=$? DISTRIBUTION="debian" CODENAME="bullseye" ARCHITECTURE="" -WITH_QT5=false BASE_PATH='.' @@ -35,21 +34,57 @@ else exit 1 fi -function request_call() { +request_call() { + local url="$1" + local response body status_code + if [ $hasWget -eq 0 ]; then - echo $(wget --quiet --header="Authorization: token ${PR_TOKEN}" -O - $1) + # Use a temp file to store headers + local headers_file=$(mktemp) + body=$(wget --quiet --server-response --header="Authorization: token ${PR_TOKEN}" -O - "$url" 2> "$headers_file") + status_code=$(awk '/^ HTTP/{code=$2} END{print code}' "$headers_file") + rm -f "$headers_file" + elif [ $hasCurl -eq 0 ]; then - echo $(curl -skH "Authorization: token ${PR_TOKEN}" $1) + # Append status code at the end of the response + response=$(curl -sk -w "\n%{http_code}" -H "Authorization: token ${PR_TOKEN}" "$url") + body=$(echo "$response" | sed '$d') # All but last line + status_code=$(echo "$response" | tail -n1) # Last line = status code + else + echo "---> Neither wget nor curl is available." >&2 + exit 1 fi + + # Handle common HTTP errors + case "$status_code" in + 401) + echo "---> Error: 401 Unauthorized. Check your token." >&2 + exit 1 + ;; + 403) + echo "---> Error: 403 Forbidden. You might be rate-limited or lack permissions." >&2 + exit 1 + ;; + 404) + echo "---> Error: 404 Not Found. URL is incorrect or resource doesn't exist." >&2 + exit 1 + ;; + 5*) + echo "---> Error: Server error ($status_code). Try again later." >&2 + exit 1 + ;; + esac + + # Success: print response body + echo "$body" } -while getopts ":a:c:r:t:5" opt; do +while getopts ":a:c:r:t:" opt; do case "$opt" in a) ARCHITECTURE=$OPTARG ;; c) CONFIGDIR=$OPTARG ;; r) run_id=$OPTARG ;; t) PR_TOKEN=$OPTARG ;; - 5) WITH_QT5=true ;; esac done shift $((OPTIND - 1)) @@ -103,19 +138,7 @@ if [ $? -ne 0 ]; then exit 1 else PACKAGE="${ARCHITECTURE}" - - # armv6 has no Qt6 support yet - if [[ "${PACKAGE}" == "armv6" ]]; then - WITH_QT5=true - fi - - QTVERSION="5" - if [ ${WITH_QT5} == false ]; then - QTVERSION="6" - PACKAGE="${PACKAGE}_qt6" - fi - - echo "---> Download package for identified runtime architecture: $ARCHITECTURE and Qt$QTVERSION" + echo "---> Download package for identified runtime architecture: $ARCHITECTURE" fi # Determine if PR number exists From 542a75b9e7cc65d827f31a1ed444a2d80a5d4fd2 Mon Sep 17 00:00:00 2001 From: Paulchen-Panther <16664240+Paulchen-Panther@users.noreply.github.com> Date: Fri, 13 Jun 2025 20:40:51 +0200 Subject: [PATCH 4/7] add debian trixie (armv6 excluded) correct effectengine and python condition --- .github/workflows/debian.yml | 5 +++++ .github/workflows/push_pull.yml | 3 ++- src/hyperiond/CMakeLists.txt | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/debian.yml b/.github/workflows/debian.yml index a6b6c1e19..324c325c7 100644 --- a/.github/workflows/debian.yml +++ b/.github/workflows/debian.yml @@ -47,6 +47,11 @@ jobs: target_lookup: [ { 'arm64': 'arm64', 'armv6': 'armv6l', 'armv7': 'armv7l' } ] + isTrixie: + - ${{ inputs.codename == 'trixie' }} + exclude: + - isTrixie: true + os: { architecture: [ armv6, linux/arm/v6 ] } steps: - name: ⬇ Checkout diff --git a/.github/workflows/push_pull.yml b/.github/workflows/push_pull.yml index f29dcac0d..b2cf815cb 100644 --- a/.github/workflows/push_pull.yml +++ b/.github/workflows/push_pull.yml @@ -23,7 +23,8 @@ jobs: matrix: debian: [ { codename: [ 'bullseye', 'Bullseye' ] }, - { codename: [ 'bookworm', 'Bookworm (Testing)' ] } + { codename: [ 'bookworm', 'Bookworm (Testing)' ] }, + { codename: [ 'trixie', 'Trixie (Testing)' ] } ] uses: ./.github/workflows/debian.yml secrets: inherit diff --git a/src/hyperiond/CMakeLists.txt b/src/hyperiond/CMakeLists.txt index b1c7ef19a..d1be3d9d4 100644 --- a/src/hyperiond/CMakeLists.txt +++ b/src/hyperiond/CMakeLists.txt @@ -91,7 +91,7 @@ target_link_libraries(${PROJECT_NAME} $<$:protoserver> $<$:cechandler> # Services - $<$:effectengine python> + $<$,$>:effectengine python> $<$:mdns> ) From b5979d20cb15bd1aef6bafdd9397a8c0658ef78c Mon Sep 17 00:00:00 2001 From: Paulchen-Panther <16664240+Paulchen-Panther@users.noreply.github.com> Date: Sat, 14 Jun 2025 15:18:27 +0200 Subject: [PATCH 5/7] added debian trixie armv6 --- .../download-pre-built-deps/buildspec.json | 76 +++++++++++++------ .github/workflows/debian.yml | 5 -- 2 files changed, 51 insertions(+), 30 deletions(-) diff --git a/.github/actions/download-pre-built-deps/buildspec.json b/.github/actions/download-pre-built-deps/buildspec.json index 2b6571375..fd1c1a2e0 100644 --- a/.github/actions/download-pre-built-deps/buildspec.json +++ b/.github/actions/download-pre-built-deps/buildspec.json @@ -1,84 +1,110 @@ { - "version": "2025-06-08", + "version": "2025-06-14", "baseUrl": "https://github.com/hyperion-project/hyperion-deps/releases/download", "hashes": { "debian_bookworm": { "amd64": { "qt6": { - "debug": "0e942549ea239c0b82125475511cc6f471e5ae6106eccd447b2657a77784aed0", - "release": "a815cf7ef9695b5cfbbf07bd1a4c65bd11fe7f1507a06ad36585c151b590fdf1" + "debug": "e4b23dae967ba4f1f97f3b14be85ba64ba22749e568e16992edcb26c98253785", + "release": "3d41b66502e4a306f15f22123920d2180346ad56e160e26825d1c906d24d1a3e" } }, "arm64": { "qt6": { - "debug": "f78dd1fedbb93232473eca6cac9c33465b0245ef36fa4ddd4beba3cddaa0b525", - "release": "616d10f849e1f2335690ee3349a656a0c610c42f47f8c4c2f2534f944c7005f5" + "debug": "a598f94c59138841384220137dae968ea04a306e54d42aded0983746324d0199", + "release": "e76a951f98a584e0bef5abd18e367a0ca9625e5d323851b8c56bd0ea913dd7a3" } }, "armv6": { "qt6": { - "debug": "c5b8d6f2b8347b6f7a53e80530feec87d45196171709f257783fefb8d99b6470", - "release": "afc221f57eda8cca6929b67c5931358566886e1466741403ea622d60e2d7391b" + "debug": "d76d863a6027eebb3cdb55b794154da1a4627074481f54f45bb0c8132294f3eb", + "release": "0d1ff354e8d75cf7113c0f99f9ceb9852a68a520fb8fb6b24db815b68cc6a962" } }, "armv7": { "qt6": { - "debug": "64a59a230d4450dbc34707c23178ed0da2f0dad8a5b6f1aa580e750c2bdedf0e", - "release": "965e26b678dd3222f2d8d9615bee7625253d4d7acd881b4c233f1b623179e4e1" + "debug": "dbeb12e1819a65dd15cf0e26ebf2b3b5ba98c1a97b313187d4a2a4c283d1786f", + "release": "19f4b26f0b5e53a7b1fb1e909bdb5483f5fb152d95df6b49f02ea1bb362caa4a" } } }, "debian_bullseye": { "amd64": { "qt6": { - "debug": "d9e87d8321ec62db6eeee61177e4ca83d3e5485a9475da2633460d3dfb6d2001", - "release": "5207ae10c3351ba7b59c1d7a0ea33377996c3f8c035ad3861a6d7aa409c23476" + "debug": "8e69724c2ec35b471765b6bd153c00fb3edfe7e136dfdfa023b9232f0bf02545", + "release": "532ebf28a3469be87a88a32fd4871dc475b585857b9f85398386160439689647" } }, "arm64": { "qt6": { - "debug": "2e056a31fbc03221496d075c9c851779547730a6e2cc47cf7569b4790dfaef1c", - "release": "f715d0376a96f05d072b4e2d4c4e2cd4aa04790bbe9c06fe02ae83261f3bd233" + "debug": "4dc745b91eea3b7dc057a1f781cfdff600d51f4b4bc6751c2795578e2a70c0db", + "release": "ca681d04c7cbd720b336e52972918d9fb0c4cf0e85fda078005b1030fa353444" } }, "armv6": { "qt5": { - "debug": "88ac40a89707ef146453162c683f0deced478d768c50d4cba95bf2ba246d9ec2", - "release": "58d9a3fa11564347fe46d4b2c308efc63c788cad1d9f0ccaeb6ab86997b6e29f" + "debug": "76f39f5f771e33978d3ed1f3de3b995020f0ba8be952b16e7613e831a2a3b0b5", + "release": "a388f7941bdd0cf3fe8807eb98ba5a815af666e65c47c3c3821ccd099778403e" } }, "armv7": { "qt6": { - "debug": "df56203dca02c2dd8724f9ad111e105af4f46efabac6aba3f8583d48cbd6c8a3", - "release": "70ea455ad0a5ddbe74296b35a2ff4e0fe7c2acb5af9f527a9548b72b56eaaeae" + "debug": "43743e0956529d3420380bdf2648a2cf6d0e16d9ae8b000faebc5afc4781a942", + "release": "754573abfe866695545614e3775d9554102a2249ef42bb2b262c94026e9af7ce" + } + } + }, + "debian_trixie": { + "amd64": { + "qt6": { + "debug": "13b548b24d78628854431e313dbeb792be22df124e0f3366285ab1f858bbf759", + "release": "265032c7173d16c1acc8901dd8ec5c65effd4db05069f4dfefea3c901d4afc51" + } + }, + "arm64": { + "qt6": { + "debug": "ad02bd31029a5b30b27d4333e00c30ffbf242da555683394d8ccf2ac6ab42f21", + "release": "b0f8644c5c2bf61fe3b8d3623324bc7cc85b3f8e481b180e797d0719d0ad6e9f" + } + }, + "armv6": { + "qt6": { + "debug": "0ecda00729db18d52a1353a594caa61122541a7380b45f54c389e8317106f208", + "release": "2066020c282c49b52d504147be76f0932e3d69c8f281a21500ccda86cf2940bb" + } + }, + "armv7": { + "qt6": { + "debug": "a2e06583be33963bcd2ec5b0921b90f2849d9a1c0b3f9c77d916a20f83600cb6", + "release": "7424d63e6f5986b8891635fddab46dfce51de2de5155ab9dbde62d5614a08c50" } } }, "macos": { "arm64": { "qt6": { - "debug": "b850180c333e07400d9e8d525b4322c38596d2d112f70e589f0023e756e65752", - "release": "4ba3d8da0802b7d2f658fe45dfc470143987cbfd107cf75bd267f1926352041f" + "debug": "11d3eb5658ecad15c4f2f4ef8e00b6fe870260df90b6c6cbb495adf4e33ba6d8", + "release": "9c4921b3a8497b36572091a5907d35e04009d554daf835d4ec8c5950b9c5fc60" } }, "x64": { "qt6": { - "debug": "6c759d2b63fe26bdd013375f323ffe086d7e241b22067c88c8642cfb3beec8a9", - "release": "dcd7e8ffb7c32bfc78844afc1ac7eb1f35cb1eaf3b5392f1453f9ba5eefbcf51" + "debug": "d4e123952710e61db3be7ff2c23c44f99a902539892a090758463a576edaff8b", + "release": "69a93c21bf36f7f84ea8f3e627df3599c139df299e639b7e803e0e95e60032bb" } } }, "windows": { "arm64": { "qt6": { - "release": "74fe89d5513f7f98ad6d75518ad87415a970d0777d2c07b6e91e351a7ca28679", - "relwithdebinfo": "ae32edcd574a390e5ececc724e02850a036d2240a517ce61c18d7e3aed9f0881" + "release": "b8b38aa1077003d2eb20fad49e046796a59297e408fd039d0300d70d6b54bc19", + "relwithdebinfo": "1ad231fd78a5fc490793b077f8a1da989e89c76b9b32c820cf64dd10880e8c5c" } }, "x64": { "qt6": { - "release": "17ca40e4e38c7cf753a330f11912c3aef892413474bbe6523c4592e355cd95ea", - "relwithdebinfo": "f968de5a05eacb6cb24374879be81d01f67bc22ab00c4ee9c55ce5b9640918ca" + "release": "70af4ea825e52c933e565cffd8bd8d8c7da554daca989e6288eba1928d2296bd", + "relwithdebinfo": "d267667572a1898b208e687d81554f51705fc6f895a02b83ddfc46fbb52a34e6" } } } diff --git a/.github/workflows/debian.yml b/.github/workflows/debian.yml index 324c325c7..a6b6c1e19 100644 --- a/.github/workflows/debian.yml +++ b/.github/workflows/debian.yml @@ -47,11 +47,6 @@ jobs: target_lookup: [ { 'arm64': 'arm64', 'armv6': 'armv6l', 'armv7': 'armv7l' } ] - isTrixie: - - ${{ inputs.codename == 'trixie' }} - exclude: - - isTrixie: true - os: { architecture: [ armv6, linux/arm/v6 ] } steps: - name: ⬇ Checkout From 041d12dc593207a7442f049bd0ab7196da1553d7 Mon Sep 17 00:00:00 2001 From: Paulchen-Panther <16664240+Paulchen-Panther@users.noreply.github.com> Date: Sat, 14 Jun 2025 15:40:12 +0200 Subject: [PATCH 6/7] mbedtls debug build fix --- dependencies/CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dependencies/CMakeLists.txt b/dependencies/CMakeLists.txt index fb6b34df3..5da6d4773 100644 --- a/dependencies/CMakeLists.txt +++ b/dependencies/CMakeLists.txt @@ -617,6 +617,11 @@ if(ENABLE_DEV_NETWORK) # Add MbedTLS directory to the build add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/external/mbedtls") + + # Can be removed when the issue is resolved: https://github.com/Mbed-TLS/mbedtls/issues/9875 + if(CMAKE_C_COMPILER_ID MATCHES "GNU" AND TARGET mbedcrypto) + target_compile_options(mbedcrypto PRIVATE -fomit-frame-pointer) + endif() endif() if(TARGET MbedTLS::mbedtls) From 1bdf185fad04d5cbe8c29f42e58cf37757ab0e77 Mon Sep 17 00:00:00 2001 From: LordGrey Date: Sat, 14 Jun 2025 17:42:24 +0200 Subject: [PATCH 7/7] Add Debian Trixie to PR-builds for early testing --- .github/workflows/push_pull.yml | 2 +- CHANGELOG.md | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/push_pull.yml b/.github/workflows/push_pull.yml index b2cf815cb..ad65a4d90 100644 --- a/.github/workflows/push_pull.yml +++ b/.github/workflows/push_pull.yml @@ -23,7 +23,7 @@ jobs: matrix: debian: [ { codename: [ 'bullseye', 'Bullseye' ] }, - { codename: [ 'bookworm', 'Bookworm (Testing)' ] }, + { codename: [ 'bookworm', 'Bookworm' ] }, { codename: [ 'trixie', 'Trixie (Testing)' ] } ] uses: ./.github/workflows/debian.yml diff --git a/CHANGELOG.md b/CHANGELOG.md index e2b4ee005..840c14837 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -19,6 +19,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - **Fixes:** - WebUI unreachable via IPv6 (#1871) - Align install_pr script working with default Qt6 builds & show authentication failures (#1871) + +- **Build:** + - Added Debian Trixie to PR-builds for early testing ---