Compare commits

...

15 Commits

Author SHA1 Message Date
Alexandre
ec2ee2f688 Merge pull request #2488 from 9turnbull/master
S
2026-02-22 19:29:38 +01:00
Alexandre
bb9530b836 Merge pull request #2514 from alexbelgium/codex/increment-immich-openvino-version
Bump Immich OpenVINO add-on revision to 2.5.6-3
2026-02-22 18:03:32 +01:00
Alexandre
ad1688b4a2 Bump Immich OpenVINO add-on revision to 2.5.6-3 2026-02-22 18:03:13 +01:00
Alexandre
a1f774cf10 Merge pull request #2513 from alexbelgium/copilot/fix-mountpoint-name-collisions
Fix 4 critical bugs in SMB/NFS mount script
2026-02-22 17:58:49 +01:00
copilot-swe-agent[bot]
89b4cdebef Revert CIFS path validation to IP-only per maintainer request
Co-authored-by: alexbelgium <44178713+alexbelgium@users.noreply.github.com>
2026-02-22 16:58:07 +00:00
copilot-swe-agent[bot]
367410d2b7 Address code review: use mountpoint -q for collision check, tighten NFS regex
Co-authored-by: alexbelgium <44178713+alexbelgium@users.noreply.github.com>
2026-02-22 16:53:18 +00:00
copilot-swe-agent[bot]
c591203a70 Fix 4 critical issues in SMB/NFS mount script
1. Mountpoint name collisions: check if /mnt/$diskname already exists
   before mounting and skip with warning if it does
2. test_mount() readonly false positive: verify mountpoint is actually
   mounted before reporting readonly status
3. Independent retries: save original MOUNTOPTIONS and use as base for
   each noserverino/noperm retry independently
4. Hostname support: accept hostnames (not just IPv4) in CIFS/NFS path
   validation, FSTYPE detection, and server extraction

Co-authored-by: alexbelgium <44178713+alexbelgium@users.noreply.github.com>
2026-02-22 16:52:23 +00:00
copilot-swe-agent[bot]
9dfafc0406 Initial plan 2026-02-22 16:48:19 +00:00
Alexandre
a91ff1f91f Merge pull request #2512 from alexbelgium/copilot/fix-smb-1-0-connection-issue
Fix SMB 1.0 mount failures in CIFS version negotiation ladder
2026-02-22 17:42:22 +01:00
copilot-swe-agent[bot]
367a42230b Fix SMB 1.0 connection failure in CIFS mount script
- Add SMB 1.0 to version ladder in retry_cifs_with_vers_ladder_on_dialect_failure
- Add sec=ntlm to security variants for SMB1 compatibility
- Fix SMBVERS_FORCE override to actually force when SMBv1 detected
- Fix smbclient SMBv1 detection to use credentials instead of anonymous
- Add SMBv1 pattern detection to nmap smb-protocols parsing

Co-authored-by: alexbelgium <44178713+alexbelgium@users.noreply.github.com>
2026-02-22 16:24:38 +00:00
copilot-swe-agent[bot]
1a3dc1e7a9 Initial plan 2026-02-22 16:20:13 +00:00
github-actions[bot]
ab9e5ae198 Update stargazer map & cache 2026-02-22 02:53:59 +00:00
github-actions[bot]
df6175e1ec Update stargazer map & cache 2026-02-15 02:57:28 +00:00
github-actions[bot]
353a5668a3 Update stargazer map & cache 2026-02-08 03:10:31 +00:00
github-actions[bot]
c16e84676d Update stargazer map & cache 2026-02-01 03:08:34 +00:00
3 changed files with 45 additions and 17 deletions

View File

@@ -47,9 +47,11 @@ test_mount() {
return 0
fi
if [[ "$FSTYPE" == "cifs" && "$MOUNTOPTIONS" != *"noserverino"* ]]; then
local orig_mountoptions="$MOUNTOPTIONS"
if [[ "$FSTYPE" == "cifs" && "$orig_mountoptions" != *"noserverino"* ]]; then
echo "... retrying mount with noserverino"
MOUNTOPTIONS="${MOUNTOPTIONS},noserverino"
MOUNTOPTIONS="${orig_mountoptions},noserverino"
umount "$mountpoint" 2>/dev/null || true
if mount_drive "$MOUNTOPTIONS"; then
@@ -60,9 +62,9 @@ test_mount() {
fi
fi
if [[ "$FSTYPE" == "cifs" && "$MOUNTOPTIONS" != *"noperm"* ]]; then
if [[ "$FSTYPE" == "cifs" && "$orig_mountoptions" != *"noperm"* ]]; then
echo "... retrying mount with noperm"
MOUNTOPTIONS="${MOUNTOPTIONS},noperm"
MOUNTOPTIONS="${orig_mountoptions},noperm"
umount "$mountpoint" 2>/dev/null || true
if mount_drive "$MOUNTOPTIONS"; then
@@ -73,7 +75,11 @@ test_mount() {
fi
fi
MOUNTED="readonly"
if mountpoint -q "$mountpoint"; then
MOUNTED="readonly"
else
MOUNTED=false
fi
return 0
}
@@ -111,7 +117,7 @@ retry_cifs_with_vers_ladder_on_dialect_failure() {
fi
CIFS_LADDER_ATTEMPTED=true
bashio::log.warning "...... CIFS negotiation/dialect failure: trying SMB dialect ladder (3.x -> 2.x)."
bashio::log.warning "...... CIFS negotiation/dialect failure: trying SMB dialect ladder (3.x -> 2.x -> 1.0)."
local base_opts try_opts vers vopt sectry
@@ -119,8 +125,8 @@ retry_cifs_with_vers_ladder_on_dialect_failure() {
base_opts="$(echo "$base_opts" | sed -E 's/,vers=[^,]+//g; s/,sec=[^,]+//g')"
local -a opt_variants=("" ",nounix" ",noserverino" ",nounix,noserverino")
local -a sec_variants=("" ",sec=ntlmssp" ",sec=ntlmv2")
local -a vers_variants=("3.1.1" "3.02" "3.0" "2.1" "2.0")
local -a sec_variants=("" ",sec=ntlmssp" ",sec=ntlmv2" ",sec=ntlm")
local -a vers_variants=("3.1.1" "3.02" "3.0" "2.1" "2.0" "1.0")
for vopt in "${opt_variants[@]}"; do
for vers in "${vers_variants[@]}"; do
@@ -143,7 +149,7 @@ retry_cifs_with_vers_ladder_on_dialect_failure() {
base_opts="${base_opts//,nobrl/}"
base_opts="$(echo "$base_opts" | sed -E 's/,iocharset=[^,]+//g')"
local -a vers_variants2=("2.1" "2.0")
local -a vers_variants2=("2.1" "2.0" "1.0")
for vopt in "${opt_variants[@]}"; do
for vers in "${vers_variants2[@]}"; do
for sectry in "${sec_variants[@]}"; do
@@ -226,7 +232,7 @@ if bashio::config.has_value 'networkdisks'; then
if [[ "$disk" =~ ^nfs:// ]]; then
FSTYPE="nfs"
disk="${disk#nfs://}"
elif [[ "$disk" =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+:/.+ ]]; then
elif [[ "$disk" =~ ^[^/:]+:/.+ ]]; then
FSTYPE="nfs"
fi
@@ -240,6 +246,11 @@ if bashio::config.has_value 'networkdisks'; then
diskname="${diskname//\\//}"
diskname="${diskname##*/}"
if mountpoint -q "/mnt/$diskname" 2>/dev/null; then
bashio::log.warning "...... mount point /mnt/$diskname already in use (name collision for $disk). Skipping this share."
continue
fi
ERRORCODE_FILE="/tmp/mount_error_${diskname//[^a-zA-Z0-9._-]/_}.log"
: >"$ERRORCODE_FILE" || true
@@ -259,8 +270,8 @@ if bashio::config.has_value 'networkdisks'; then
continue
fi
else
if [[ ! "$disk" =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+:/.+ ]]; then
bashio::log.fatal "...... invalid NFS path \"$disk\". Use 123.12.12.12:/export/path"
if [[ ! "$disk" =~ ^[^/:]+:/.+ ]]; then
bashio::log.fatal "...... invalid NFS path \"$disk\". Use server:/export/path or 123.12.12.12:/export/path"
echo "Invalid NFS path structure: $disk" >"$ERRORCODE_FILE" || true
continue
fi
@@ -332,14 +343,19 @@ if bashio::config.has_value 'networkdisks'; then
fi
SMBRAW=""
SMB1_DETECTED=false
if command -v nmap >/dev/null 2>&1; then
NMAP_OUTPUT="$(nmap --script smb-protocols -p 445 "$server" 2>/dev/null || true)"
SMBRAW="$(
nmap --script smb-protocols -p 445 "$server" 2>/dev/null \
echo "$NMAP_OUTPUT" \
| awk '/SMB2_DIALECT_/ {print $NF}' \
| sed 's/SMB2_DIALECT_//' \
| tr -d '_' \
| sort -V | tail -n 1 || true
)"
if [[ -z "$SMBRAW" ]] && echo "$NMAP_OUTPUT" | grep -Eiq 'NT LM 0\.12|SMBv1|NT1'; then
SMB1_DETECTED=true
fi
fi
SMBVERS=""
@@ -352,19 +368,28 @@ if bashio::config.has_value 'networkdisks'; then
*) SMBVERS="" ;;
esac
if [[ -z "$SMBVERS" && "$SMB1_DETECTED" == "true" ]]; then
echo "...... SMB version detected via nmap : SMBv1 (NT LM 0.12)"
SMBVERS=",vers=1.0"
SECVERS=",sec=ntlm"
fi
if [[ -n "$SMBVERS" ]]; then
echo "...... SMB version detected : ${SMBVERS#,vers=}"
elif command -v smbclient >/dev/null 2>&1 && smbclient -t 2 -L "$server" -m NT1 -N $DOMAINCLIENT -c "exit" &>/dev/null; then
elif command -v smbclient >/dev/null 2>&1 && smbclient -t 2 -L "$server" -m NT1 -U "$USERNAME%$PASSWORD" $DOMAINCLIENT -c "exit" &>/dev/null; then
echo "...... SMB version : only SMBv1 is supported, this can lead to issues"
SECVERS=",sec=ntlm"
SMBVERS=",vers=1.0"
else
echo "...... SMB version : couldn't detect, falling back to SMB3->SMB2 ladder on negotiation/dialect failure"
echo "...... SMB version : couldn't detect, falling back to SMB3->SMB2->SMB1 ladder on negotiation/dialect failure"
SMBVERS=",vers=3.1.1"
fi
if [[ -n "$SMBVERS_FORCE" ]]; then
[[ -z "$SMBVERS" ]] && SMBVERS="$SMBVERS_FORCE"
if [[ -n "$SMBVERS" && "$SMBVERS" != "$SMBVERS_FORCE" ]]; then
bashio::log.warning "...... overriding detected SMB version ${SMBVERS#,vers=} with forced ${SMBVERS_FORCE#,vers=} (server requires legacy protocol)"
fi
SMBVERS="$SMBVERS_FORCE"
[[ -z "$SECVERS" ]] && SECVERS="$SECVERS_FORCE"
fi

View File

@@ -1,4 +1,7 @@
## 2.5.6-3 (2026-02-22)
- Increment add-on revision.
## 2.5.6-2 (2026-02-14)
- Add `VIPS_NOVECTOR` add-on option to set `VIPS_NOVECTOR=1` for thumbnail generation workaround on aarch64 (issue #2460)

View File

@@ -142,6 +142,6 @@ slug: immich_openvino
udev: true
url: https://github.com/alexbelgium/hassio-addons
usb: true
version: "2.5.6-2"
version: "2.5.6-3"
video: true
webui: http://[HOST]:[PORT:8080]