Package: barrier
Version: 2.1.2+dfsg-1~bpo9+1
Severity: normal
Dear Maintainer,
I have Barrier server version 2.1.2+dfsg-1~bpo9+1 on a Debian box
and Barrier client version 2.3.3 on a Mac (from Homebrew).
After restarting the Mac, Barrier failed to start. Its log says
repeatedly:
ERROR: ssl error occurred (system call failure)
ERROR: failed to connect to secure socket
On the Debian system, syslog shows:
ERROR: ssl certificate doesn't exist:
/home/phil/.local/share/barrier/SSL/Barrier.pem
But that file does exist:
-rw--- 1 phil phil 2798 Feb 20 2020
/home/phil/.local/share/barrier/SSL/Barrier.pem
Investigating with strace:
[pid 15729] openat(AT_FDCWD, "/home/phil/.local/share/barrier/SSL/Barrier.pem",
O_RDONLY) = -1 EMFILE (Too many open files)
So there appears to be an issue with misleading error reporting.
Looking at the source:
https://github.com/debauchee/barrier/blob/master/src/lib/net/SecureSocket.cpp
Line 344
It just checks std::ifstream::good().
At the very minimum, the error message "ssl certificate doesn't exist"
should be replaced with "ssl certificate file could not be opened".
Much better, it should use errno and e.g. strerror to give a useful
message.
(Note I'm using an older version of Barrier but I'm looking at the
current source code.)
I'm continuing to look at what the underlying issue might be.
-- System Information:
Debian Release: 9.9
APT prefers stable
APT policy: (990, 'stable'), (500, 'oldstable-updates'), (500, 'oldstable')
Architecture: arm64 (aarch64)
Foreign Architectures: armhf
Kernel: Linux 3.14.29+ (SMP w/2 CPU cores; PREEMPT)
Locale: LANG=en_GB.utf8, LC_CTYPE=en_GB.utf8 (charmap=UTF-8),
LANGUAGE=en_GB.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages barrier depends on:
ii libavahi-compat-libdnssd1 0.7-4+b1
ii libc6 2.28-10
ii libcurl3 7.52.1-5+deb9u9
ii libgcc11:6.3.0-18+deb9u1
ii libice62:1.0.9-2
ii libqt5core5a 5.7.1+dfsg-3+deb9u1
ii libqt5gui5 5.7.1+dfsg-3+deb9u1
ii libqt5network5 5.7.1+dfsg-3+deb9u1
ii libqt5widgets5 5.7.1+dfsg-3+deb9u1
ii libsm6 2:1.2.2-1+b3
ii libssl1.1 1.1.0k-1~deb9u1
ii libstdc++6 6.3.0-18+deb9u1
ii libx11-6 2:1.6.4-3+deb9u1
ii libxext6 2:1.3.3-1+b2
ii libxi6 2:1.7.9-1
ii libxinerama1 2:1.1.3-1+b3
ii libxrandr2 2:1.5.1-1
ii libxtst6 2:1.2.3-1
ii openssl1.1.0k-1~deb9u1
barrier recommends no packages.
barrier suggests no packages.
-- no debconf information