Add support Mageia 10, OpenMandriva Lx 6 Rock and openSuse Leap 16.
This commit is contained in:
parent
e7c2f284d9
commit
9f08b71900
11 changed files with 9752 additions and 25 deletions
468
mageia/bastionguard-mageia10.spec
Normal file
468
mageia/bastionguard-mageia10.spec
Normal file
|
|
@ -0,0 +1,468 @@
|
|||
#
|
||||
# BastionGuard™
|
||||
# Copyright (C) 2025–2026 Calogero Scarnà
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, version 3.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
#
|
||||
# BastionGuard™ is a trademark of Calogero Scarnà.
|
||||
# The BastionGuard™ name and branding are not licensed under the GPL.
|
||||
#
|
||||
|
||||
Name: bastionguard
|
||||
Version: 2.0
|
||||
Release: %mkrel 2
|
||||
%global yara_version 4.5.5
|
||||
%global yara_stage %{_builddir}/%{name}-%{version}/.yara-stage
|
||||
|
||||
Summary: BastionGuard Security Platform
|
||||
Group: System/Monitoring
|
||||
|
||||
Provides: bastionguard = %{version}-%{release}
|
||||
Provides: bundled(yara) = %{yara_version}
|
||||
Obsoletes: bastionguard < %{version}-%{release}
|
||||
|
||||
License: GPLv3+ and BSD
|
||||
URL: https://git.bastionguard.eu/specialworld83/BastionGuard
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
Source1: https://github.com/VirusTotal/yara/archive/refs/tags/v%{yara_version}.tar.gz#/yara-%{yara_version}.tar.gz
|
||||
|
||||
%global debug_package %{nil}
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Mageia 10 build tools
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: cmake
|
||||
BuildRequires: make
|
||||
BuildRequires: pkgconf-pkg-config
|
||||
BuildRequires: gettext
|
||||
BuildRequires: python3
|
||||
BuildRequires: rsync
|
||||
BuildRequires: git
|
||||
BuildRequires: systemd
|
||||
BuildRequires: bash
|
||||
BuildRequires: curl
|
||||
BuildRequires: file
|
||||
BuildRequires: binutils
|
||||
|
||||
# Mageia 10 does not provide yara-devel in the enabled repositories.
|
||||
# Build the pinned upstream YARA source and stage it for BastionGuard.
|
||||
BuildRequires: autoconf
|
||||
BuildRequires: automake
|
||||
BuildRequires: libtool
|
||||
BuildRequires: flex
|
||||
BuildRequires: bison
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Main BastionGuard libraries
|
||||
# Use Mageia RPM virtual provides so the correct lib64*-devel provider is
|
||||
# selected automatically on x86_64 and the corresponding provider on i686.
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: pkgconfig(gtkmm-4.0)
|
||||
BuildRequires: pkgconfig(giomm-2.68)
|
||||
BuildRequires: pkgconfig(pangomm-2.48)
|
||||
BuildRequires: pkgconfig(sigc++-3.0)
|
||||
BuildRequires: pkgconfig(libsoup-3.0)
|
||||
BuildRequires: pkgconfig(libsecret-1)
|
||||
BuildRequires: pkgconfig(libsystemd)
|
||||
BuildRequires: pkgconfig(libudev)
|
||||
BuildRequires: pkgconfig(libidn2)
|
||||
BuildRequires: pkgconfig(sqlite3)
|
||||
BuildRequires: pkgconfig(libcurl)
|
||||
BuildRequires: pkgconfig(openssl)
|
||||
BuildRequires: boost-devel
|
||||
BuildRequires: pkgconfig(re2)
|
||||
BuildRequires: pkgconfig(libhs)
|
||||
BuildRequires: json-devel
|
||||
BuildRequires: pkgconfig(polkit-gobject-1)
|
||||
BuildRequires: pkgconfig(libffi)
|
||||
BuildRequires: pkgconfig(zlib)
|
||||
BuildRequires: pkgconfig(libpcre2-8)
|
||||
BuildRequires: pkgconfig(libpng)
|
||||
BuildRequires: pkgconfig(libjpeg)
|
||||
BuildRequires: pkgconfig(libtiff-4)
|
||||
BuildRequires: pkgconfig(libwebp)
|
||||
BuildRequires: pkgconfig(nss)
|
||||
BuildRequires: pkgconfig(nspr)
|
||||
BuildRequires: pkgconfig(fribidi)
|
||||
BuildRequires: pkgconfig(x11)
|
||||
BuildRequires: pkgconfig(xcursor)
|
||||
BuildRequires: pkgconfig(xrandr)
|
||||
BuildRequires: pkgconfig(xi)
|
||||
BuildRequires: pkgconfig(xinerama)
|
||||
BuildRequires: pkgconfig(xdamage)
|
||||
BuildRequires: pkgconfig(xcomposite)
|
||||
BuildRequires: pkgconfig(xkbcommon)
|
||||
BuildRequires: pkgconfig(wayland-client)
|
||||
BuildRequires: pkgconfig(alsa)
|
||||
BuildRequires: pkgconfig(libpipewire-0.3)
|
||||
BuildRequires: pkgconfig(smbclient)
|
||||
BuildRequires: pkgconfig(libzstd)
|
||||
BuildRequires: pkgconfig(lzo2)
|
||||
|
||||
# CMake checks these executables during configuration.
|
||||
BuildRequires: nginx
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# bastionguard-backup (Meson + Vala)
|
||||
# The current source checks GTK 3/VTE 2.91 directly from pkg-config.
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: meson
|
||||
BuildRequires: ninja
|
||||
BuildRequires: vala
|
||||
BuildRequires: pkgconfig(gtk+-3.0)
|
||||
BuildRequires: pkgconfig(gio-2.0)
|
||||
BuildRequires: pkgconfig(vte-2.91-gtk4)
|
||||
BuildRequires: pkgconfig(gtk4)
|
||||
BuildRequires: pkgconfig(gio-unix-2.0)
|
||||
BuildRequires: pkgconfig(json-glib-1.0)
|
||||
BuildRequires: pkgconfig(vte-2.91)
|
||||
BuildRequires: pkgconfig(gee-0.8)
|
||||
BuildRequires: help2man
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# bastionguard-secure-connection (Meson + Go + protobuf/gRPC + eBPF)
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: golang
|
||||
BuildRequires: protobuf-compiler
|
||||
BuildRequires: pkgconfig(protobuf)
|
||||
BuildRequires: grpc-plugins
|
||||
BuildRequires: pkgconfig(grpc)
|
||||
BuildRequires: pkgconfig(grpc++)
|
||||
BuildRequires: pkgconfig(shumate-1.0)
|
||||
BuildRequires: pkgconfig(libnetfilter_queue)
|
||||
BuildRequires: pkgconfig(libnfnetlink)
|
||||
BuildRequires: pkgconfig(libmnl)
|
||||
BuildRequires: pkgconfig(libelf)
|
||||
BuildRequires: lib64bpf-devel
|
||||
BuildRequires: bpftool
|
||||
BuildRequires: clang
|
||||
BuildRequires: llvm
|
||||
BuildRequires: patchelf
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Runtime requirements for Mageia 10
|
||||
# -----------------------------------------------------------------------------
|
||||
Requires: systemd
|
||||
Requires: nginx
|
||||
Requires: php-fpm
|
||||
Requires: dnsmasq
|
||||
Requires: polkit
|
||||
Requires: rsync
|
||||
Requires: bubblewrap
|
||||
Requires: clamav
|
||||
Requires: clamav-db
|
||||
Requires: clamd
|
||||
Requires: curl
|
||||
Requires: nss
|
||||
Requires: nss-tools
|
||||
Requires: sudo
|
||||
|
||||
%description
|
||||
Transparent security control plane for Linux desktops.
|
||||
BastionGuard is not a "trust us" security product.
|
||||
It is a security control plane for Linux desktops where every protection
|
||||
mechanism is explicit, deterministic, and observable.
|
||||
|
||||
%prep
|
||||
%autosetup -n %{name}-%{version} -a 1
|
||||
cp -p yara-%{yara_version}/COPYING YARA-COPYING
|
||||
|
||||
# Consume the staged YARA installation through an imported pkg-config target.
|
||||
# This propagates its include directory, private -L path and -lyara to every
|
||||
# BastionGuard target, including packaging builds that suppress link_directories.
|
||||
if grep -Fq 'pkg_check_modules(YARA REQUIRED yara)' CMakeLists.txt; then
|
||||
sed -i \
|
||||
's/pkg_check_modules(YARA REQUIRED yara)/pkg_check_modules(YARA REQUIRED IMPORTED_TARGET GLOBAL yara)/' \
|
||||
CMakeLists.txt
|
||||
fi
|
||||
|
||||
grep -Fq 'pkg_check_modules(YARA REQUIRED IMPORTED_TARGET GLOBAL yara)' \
|
||||
CMakeLists.txt
|
||||
|
||||
sed -i 's/${YARA_LIBRARIES}/PkgConfig::YARA/g' CMakeLists.txt
|
||||
|
||||
if grep -Fq '${YARA_LIBRARIES}' CMakeLists.txt; then
|
||||
echo "ERROR: legacy YARA link references remain in CMakeLists.txt"
|
||||
grep -n -F '${YARA_LIBRARIES}' CMakeLists.txt || :
|
||||
exit 1
|
||||
fi
|
||||
|
||||
%build
|
||||
# Do not inherit paths from the machine that generated the SRPM.
|
||||
unset LD_LIBRARY_PATH LIBRARY_PATH CMAKE_PREFIX_PATH PKG_CONFIG_PATH PKG_CONFIG_SYSROOT_DIR
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# Build YARA first and install it into a private staging root. The same build
|
||||
# is installed into %{buildroot} later, so BastionGuard links against exactly
|
||||
# the YARA runtime shipped by the resulting RPM.
|
||||
# ---------------------------------------------------------------------------
|
||||
rm -rf %{yara_stage}
|
||||
mkdir -p %{yara_stage}
|
||||
|
||||
pushd yara-%{yara_version}
|
||||
./bootstrap.sh
|
||||
|
||||
YARA_CFLAGS="${CFLAGS:-%{optflags}}"
|
||||
YARA_LDFLAGS="${LDFLAGS:-}"
|
||||
|
||||
CFLAGS="$YARA_CFLAGS" \
|
||||
LDFLAGS="$YARA_LDFLAGS" \
|
||||
./configure \
|
||||
--prefix=%{_prefix} \
|
||||
--bindir=%{_bindir} \
|
||||
--libdir=%{_libdir} \
|
||||
--includedir=%{_includedir} \
|
||||
--mandir=%{_mandir} \
|
||||
--disable-static \
|
||||
--enable-shared \
|
||||
--with-crypto
|
||||
|
||||
%make_build
|
||||
make DESTDIR=%{yara_stage} install
|
||||
popd
|
||||
|
||||
# Rewrite only the staged yara.pc paths. Do not set PKG_CONFIG_SYSROOT_DIR:
|
||||
# that would also redirect unrelated system dependencies such as libsoup.
|
||||
YARA_PC="%{yara_stage}%{_libdir}/pkgconfig/yara.pc"
|
||||
test -f "$YARA_PC"
|
||||
|
||||
sed -i \
|
||||
-e 's|^prefix=.*|prefix=%{yara_stage}%{_prefix}|' \
|
||||
-e 's|^exec_prefix=.*|exec_prefix=%{yara_stage}%{_prefix}|' \
|
||||
-e 's|^libdir=.*|libdir=%{yara_stage}%{_libdir}|' \
|
||||
-e 's|^includedir=.*|includedir=%{yara_stage}%{_includedir}|' \
|
||||
"$YARA_PC"
|
||||
|
||||
export PKG_CONFIG_PATH="%{yara_stage}%{_libdir}/pkgconfig"
|
||||
unset PKG_CONFIG_SYSROOT_DIR
|
||||
export PATH="%{yara_stage}%{_bindir}:$PATH"
|
||||
|
||||
test -x "%{yara_stage}%{_bindir}/yara"
|
||||
test "$(pkg-config --modversion yara)" = "%{yara_version}"
|
||||
|
||||
YARA_LIBDIR="$(pkg-config --variable=libdir yara)"
|
||||
YARA_INCLUDEDIR="$(pkg-config --variable=includedir yara)"
|
||||
|
||||
test -d "$YARA_LIBDIR"
|
||||
test -d "$YARA_INCLUDEDIR"
|
||||
test -e "$YARA_LIBDIR/libyara.so"
|
||||
|
||||
echo "YARA version: $(pkg-config --modversion yara)"
|
||||
echo "YARA libdir: $YARA_LIBDIR"
|
||||
echo "YARA includedir: $YARA_INCLUDEDIR"
|
||||
pkg-config --cflags --libs yara
|
||||
ls -la "$YARA_LIBDIR"/libyara.so*
|
||||
|
||||
# Extra fallback for any legacy target that still emits a plain -lyara.
|
||||
export LDFLAGS="${LDFLAGS:-} -L$YARA_LIBDIR"
|
||||
|
||||
# Mageia build:
|
||||
# - the legacy standalone CEF switch is disabled;
|
||||
# - the embedded runtime required by Secure Browser/Bank GUI remains enabled;
|
||||
# - the standalone proxy daemon and system CA installer are disabled.
|
||||
%cmake \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_SYSCONFDIR=%{_sysconfdir} \
|
||||
-DCMAKE_INSTALL_LOCALSTATEDIR=%{_localstatedir} \
|
||||
-DCMAKE_INSTALL_DATAROOTDIR=%{_datadir} \
|
||||
-DENABLE_SYSTEMD_SERVICES=OFF \
|
||||
-DENABLE_USER_AGENT_AUTO=OFF \
|
||||
-DINSTALL_NGINX_DEFAULTS=OFF \
|
||||
-DBG_PACKAGING=ON \
|
||||
-DBG_DEBIAN_NO_INSTALL_CODE=ON \
|
||||
-DENABLE_CEF=OFF \
|
||||
-DENABLE_EMBEDDED_CEF=ON \
|
||||
-DENABLE_CEF_DAEMON=OFF \
|
||||
-DENABLE_SYSTEM_CA_INSTALL=OFF \
|
||||
-DCMAKE_BUILD_WITH_INSTALL_RPATH=ON \
|
||||
-DCMAKE_INSTALL_RPATH='$ORIGIN/../share/BastionGuard/lib;$ORIGIN/../share/BastionGuard/cef' \
|
||||
-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=OFF
|
||||
|
||||
%cmake_build
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
|
||||
# Install the same pinned YARA build used by BastionGuard.
|
||||
pushd yara-%{yara_version}
|
||||
make DESTDIR=%{buildroot} install
|
||||
popd
|
||||
|
||||
# The bundled YARA command-line tools must not retain libtool's temporary
|
||||
# build-tree RUNPATH. libyara is installed in the standard %{_libdir}, so no
|
||||
# private runtime search path is required.
|
||||
for _tool in yara yarac; do
|
||||
_elf="%{buildroot}%{_bindir}/${_tool}"
|
||||
test -x "$_elf"
|
||||
patchelf --remove-rpath "$_elf"
|
||||
|
||||
if readelf -d "$_elf" | grep -Eq '\((RPATH|RUNPATH)\)'; then
|
||||
echo "ERROR: $_elf still contains RPATH/RUNPATH"
|
||||
readelf -d "$_elf" | grep -E '\((RPATH|RUNPATH)\)' || :
|
||||
exit 1
|
||||
fi
|
||||
done
|
||||
|
||||
# Keep only runtime files. Development headers, metadata and the unversioned
|
||||
# linker symlink are used during the build but are not shipped.
|
||||
rm -rf %{buildroot}%{_includedir}/yara
|
||||
rm -f %{buildroot}%{_includedir}/yara.h
|
||||
rm -f %{buildroot}%{_libdir}/pkgconfig/yara.pc
|
||||
rm -f %{buildroot}%{_libdir}/libyara.la
|
||||
rm -f %{buildroot}%{_libdir}/libyara.a
|
||||
rm -f %{buildroot}%{_libdir}/libyara.so
|
||||
|
||||
%cmake_install
|
||||
|
||||
# Mageia desktop-file validation: Exec does not perform shell expansion, and
|
||||
# unquoted '$' characters are forbidden. The launched processes already inherit
|
||||
# the desktop session locale, so remove the redundant env assignments.
|
||||
sed -i \
|
||||
-e 's|^Exec=env .* BastionGuard-bankgui$|Exec=BastionGuard-bankgui|' \
|
||||
-e 's|^Categories=Network;Security;$|Categories=Network;Security;System;|' \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-bankgui.desktop"
|
||||
|
||||
sed -i \
|
||||
-e 's|^Exec=env .* BastionGuard-secure-gui$|Exec=BastionGuard-secure-gui|' \
|
||||
-e 's|^Categories=Network;Security;WebBrowser;$|Categories=Network;Security;System;WebBrowser;|' \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-secure.desktop"
|
||||
|
||||
# Fail here with a clear message if upstream changes the desktop entries and the
|
||||
# substitutions no longer match.
|
||||
grep -qx 'Exec=BastionGuard-bankgui' \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-bankgui.desktop"
|
||||
grep -qx 'Exec=BastionGuard-secure-gui' \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-secure.desktop"
|
||||
! grep -E '^Exec=.*\$' \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-bankgui.desktop" \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-secure.desktop"
|
||||
|
||||
# Mageia 10: embedded CEF and the Secure Browser GUIs must be present.
|
||||
# The standalone CEF proxy, its service, activation helper and system CA
|
||||
# integration must not be installed.
|
||||
for _forbidden in \
|
||||
"%{buildroot}%{_bindir}/bastionguard-cef" \
|
||||
"%{buildroot}%{_bindir}/bastionguard-activation-helper" \
|
||||
"%{buildroot}%{_datadir}/polkit-1/actions/eu.bastionguard.install-ca.policy" \
|
||||
"%{buildroot}%{_datadir}/polkit-1/actions/org.bastionguard.activation.policy" \
|
||||
"%{buildroot}%{_datadir}/BastionGuard/data/scripts/install-ca-system.sh" \
|
||||
"%{buildroot}%{_userunitdir}/BastionGuard-cef.service" \
|
||||
"%{buildroot}%{_datadir}/BastionGuard/data/service/BastionGuard-cef.service" \
|
||||
"%{buildroot}%{_unitdir}/bastionguard-cef.service"; do
|
||||
test ! -e "$_forbidden"
|
||||
done
|
||||
|
||||
for _required in \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-bankopener" \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-bankgui" \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-secure" \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-secure-gui" \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-bankgui.desktop" \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-secure.desktop" \
|
||||
"%{buildroot}%{_datadir}/applications/bastionguard-bankopener.desktop"; do
|
||||
test -e "$_required"
|
||||
done
|
||||
|
||||
# Runtime CEF embedded required by BankOpener and Secure Browser.
|
||||
test -d "%{buildroot}%{_datadir}/BastionGuard/cef"
|
||||
|
||||
install -dm750 %{buildroot}%{_sharedstatedir}/bastionguard-webui/{cache,quarantine,sessions,tmp}
|
||||
install -dm755 %{buildroot}%{_localstatedir}/log/bastionguard-webui
|
||||
|
||||
test -x %{buildroot}%{_bindir}/BastionGuard
|
||||
test -x %{buildroot}%{_bindir}/yara
|
||||
test -x %{buildroot}%{_bindir}/yarac
|
||||
file %{buildroot}%{_bindir}/BastionGuard | grep -q "ELF 64-bit"
|
||||
readelf -d %{buildroot}%{_bindir}/BastionGuard | grep -q NEEDED
|
||||
readelf -d %{buildroot}%{_bindir}/BastionGuard | grep -q 'libyara\.so'
|
||||
find %{buildroot}%{_libdir} -maxdepth 1 -type f \
|
||||
-name 'libyara.so.*' -print -quit | grep -q .
|
||||
|
||||
%postun
|
||||
if command -v systemctl >/dev/null 2>&1; then
|
||||
systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
:
|
||||
|
||||
%files
|
||||
%license YARA-COPYING
|
||||
%{_bindir}/*
|
||||
%{_libdir}/libyara.so.*
|
||||
|
||||
%{_datadir}/BastionGuard
|
||||
%{_datadir}/bastionguard-backup
|
||||
%{_datadir}/bastionguard-sc
|
||||
%{_datadir}/applications/BastionGuard.desktop
|
||||
%{_datadir}/applications/bastionguard-sc.desktop
|
||||
%{_datadir}/applications/bastionguard-backup-gtk.desktop
|
||||
%{_datadir}/applications/BastionGuard-bankgui.desktop
|
||||
%{_datadir}/applications/BastionGuard-secure.desktop
|
||||
%{_datadir}/applications/bastionguard-bankopener.desktop
|
||||
|
||||
%config(noreplace) %{_sysconfdir}/xdg/autostart/BastionGuard-autostart.desktop
|
||||
%config(noreplace) %{_sysconfdir}/xdg/autostart/bastionguard-sc-autostart.desktop
|
||||
|
||||
%{_datadir}/dbus-1/services/org.BastionGuard.RansomwareAlert.service
|
||||
%{_datadir}/dbus-1/system-services/org.BastionGuard.USBD.service
|
||||
%{_datadir}/dbus-1/system.d/org.BastionGuard.USBD.conf
|
||||
|
||||
%{_datadir}/polkit-1/actions/it.BastionGuard.camera.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.ransomware.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.USBD.policy
|
||||
%{_datadir}/polkit-1/actions/eu.bastionguard.sc.policy
|
||||
%{_datadir}/polkit-1/actions/org.bastionguard.pkexec.backup.policy
|
||||
|
||||
%{_unitdir}/*
|
||||
%{_userunitdir}/*
|
||||
|
||||
%{_datadir}/locale/*
|
||||
%{_datadir}/icons/*
|
||||
%{_datadir}/plymouth/*
|
||||
%config(noreplace) %{_sysconfdir}/bastionguard-backup/*
|
||||
/usr/lib/bastionguard-sc/*
|
||||
%{_datadir}/metainfo/*
|
||||
%{_mandir}/*
|
||||
|
||||
%dir %{_libexecdir}/bastionguard
|
||||
%{_libexecdir}/bastionguard/archive_worker
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-helper
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-phishing
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-bank
|
||||
|
||||
%dir %attr(750,apache,apache) %{_sharedstatedir}/bastionguard-webui
|
||||
%dir %attr(750,apache,apache) %{_sharedstatedir}/bastionguard-webui/cache
|
||||
%dir %attr(750,apache,apache) %{_sharedstatedir}/bastionguard-webui/quarantine
|
||||
%dir %attr(750,apache,apache) %{_sharedstatedir}/bastionguard-webui/sessions
|
||||
%dir %attr(750,apache,apache) %{_sharedstatedir}/bastionguard-webui/tmp
|
||||
%dir %attr(755,root,root) %{_localstatedir}/log/bastionguard-webui
|
||||
|
||||
# BastionGuard Recovery Data
|
||||
%{_datadir}/bastionguard-recovery-data
|
||||
%{_datadir}/applications/com.bastionguard.RecoveryData.desktop
|
||||
%{_datadir}/polkit-1/actions/com.bastionguard.RecoveryData.policy
|
||||
|
||||
# Plymouth assets
|
||||
%{_datadir}/pixmaps/*
|
||||
|
||||
# BastionGuard Secure Connection daemon configuration
|
||||
%dir %{_sysconfdir}/bastionguard-secure-connectiond
|
||||
%config(noreplace) %{_sysconfdir}/bastionguard-secure-connectiond/*
|
||||
|
||||
%changelog
|
||||
* Thu Jul 16 2026 Calogero Scarnà <info@bastionguard.eu> 2.0-2
|
||||
- Build and bundle YARA 4.5.5 because Mageia 10 does not provide yara-devel.
|
||||
- Stage YARA for BastionGuard through the imported PkgConfig::YARA target.
|
||||
- Ship the YARA and yarac tools together with the versioned libyara runtime.
|
||||
- Remove external yara and yara-devel package requirements.
|
||||
2739
mageia/change_cmake_mageia/CMakeLists.txt
Normal file
2739
mageia/change_cmake_mageia/CMakeLists.txt
Normal file
File diff suppressed because it is too large
Load diff
551
openmandriva/bastionguard-openmandriva6-rock.spec
Normal file
551
openmandriva/bastionguard-openmandriva6-rock.spec
Normal file
|
|
@ -0,0 +1,551 @@
|
|||
#
|
||||
# BastionGuard™
|
||||
# Copyright (C) 2025–2026 Calogero Scarnà
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, version 3.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
#
|
||||
# BastionGuard™ is a trademark of Calogero Scarnà.
|
||||
# The BastionGuard™ name and branding are not licensed under the GPL.
|
||||
#
|
||||
|
||||
|
||||
Name: bastionguard
|
||||
Version: 2.0
|
||||
Release: 3
|
||||
|
||||
%global yara_version 4.5.5
|
||||
%global yara_stage %{_builddir}/%{name}-%{version}/.yara-stage
|
||||
Summary: BastionGuard Security Platform
|
||||
Group: System/Monitoring
|
||||
|
||||
Provides: bastionguard = %{version}-%{release}
|
||||
Provides: bundled(yara) = %{yara_version}
|
||||
Obsoletes: bastionguard < %{version}-%{release}
|
||||
|
||||
License: GPLv3+ AND BSD-3-Clause
|
||||
URL: https://git.bastionguard.eu/specialworld83/BastionGuard
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
Source1: https://github.com/VirusTotal/yara/archive/refs/tags/v%{yara_version}.tar.gz#/yara-%{yara_version}.tar.gz
|
||||
|
||||
# CEF binary bundle and the current packaging layout are 64-bit only.
|
||||
ExclusiveArch: x86_64 znver1
|
||||
|
||||
%global debug_package %{nil}
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# OpenMandriva Lx 6.0 Rock build tools
|
||||
# OpenMandriva uses RPM/DNF, pkgconf and the LLVM toolchain by default.
|
||||
# gcc-c++ is retained because a few bundled/third-party projects still invoke
|
||||
# g++ explicitly, while clang/llvm are required by the eBPF component.
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: clang
|
||||
BuildRequires: llvm
|
||||
BuildRequires: lld
|
||||
BuildRequires: cmake
|
||||
BuildRequires: ninja
|
||||
BuildRequires: make
|
||||
BuildRequires: pkgconf
|
||||
BuildRequires: gettext-devel
|
||||
BuildRequires: python
|
||||
BuildRequires: rsync
|
||||
BuildRequires: git-core
|
||||
BuildRequires: systemd
|
||||
BuildRequires: bash
|
||||
BuildRequires: curl
|
||||
BuildRequires: file
|
||||
BuildRequires: binutils
|
||||
|
||||
# YARA is not available in OpenMandriva Rock 6.0. Build the pinned upstream
|
||||
# source first, stage it, and use that staged installation to build BastionGuard.
|
||||
BuildRequires: autoconf
|
||||
BuildRequires: automake
|
||||
BuildRequires: libtool
|
||||
BuildRequires: flex
|
||||
BuildRequires: bison
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Main BastionGuard libraries
|
||||
# Use RPM virtual provides so OpenMandriva selects the matching
|
||||
# lib64*-devel provider on x86_64/znver1.
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: pkgconfig(gtkmm-4.0)
|
||||
BuildRequires: pkgconfig(giomm-2.68)
|
||||
BuildRequires: pkgconfig(pangomm-2.48)
|
||||
BuildRequires: pkgconfig(sigc++-3.0)
|
||||
BuildRequires: pkgconfig(libsoup-3.0)
|
||||
BuildRequires: pkgconfig(libsecret-1)
|
||||
BuildRequires: pkgconfig(libsystemd)
|
||||
BuildRequires: pkgconfig(libudev)
|
||||
BuildRequires: pkgconfig(libidn2)
|
||||
BuildRequires: pkgconfig(sqlite3)
|
||||
BuildRequires: pkgconfig(libcurl)
|
||||
BuildRequires: pkgconfig(openssl)
|
||||
BuildRequires: boost-devel
|
||||
# Optional acceleration libraries. The project has std::regex fallbacks,
|
||||
# therefore Rock builds must not fail when these are absent from the fixed repo.
|
||||
%bcond_with re2
|
||||
%bcond_with hyperscan
|
||||
%if %{with re2}
|
||||
BuildRequires: pkgconfig(re2)
|
||||
%endif
|
||||
%if %{with hyperscan}
|
||||
BuildRequires: pkgconfig(libhs)
|
||||
%endif
|
||||
BuildRequires: nlohmann_json-devel
|
||||
BuildRequires: pkgconfig(polkit-gobject-1)
|
||||
BuildRequires: pkgconfig(libffi)
|
||||
BuildRequires: pkgconfig(zlib)
|
||||
BuildRequires: pkgconfig(libpcre2-8)
|
||||
BuildRequires: pkgconfig(libpng)
|
||||
BuildRequires: pkgconfig(libjpeg)
|
||||
BuildRequires: pkgconfig(libtiff-4)
|
||||
BuildRequires: pkgconfig(libwebp)
|
||||
BuildRequires: pkgconfig(nss)
|
||||
BuildRequires: pkgconfig(nspr)
|
||||
BuildRequires: pkgconfig(fribidi)
|
||||
BuildRequires: pkgconfig(x11)
|
||||
BuildRequires: pkgconfig(xcursor)
|
||||
BuildRequires: pkgconfig(xrandr)
|
||||
BuildRequires: pkgconfig(xi)
|
||||
BuildRequires: pkgconfig(xinerama)
|
||||
BuildRequires: pkgconfig(xdamage)
|
||||
BuildRequires: pkgconfig(xcomposite)
|
||||
BuildRequires: pkgconfig(xkbcommon)
|
||||
BuildRequires: pkgconfig(wayland-client)
|
||||
BuildRequires: pkgconfig(alsa)
|
||||
BuildRequires: pkgconfig(libpipewire-0.3)
|
||||
BuildRequires: pkgconfig(smbclient)
|
||||
BuildRequires: pkgconfig(libzstd)
|
||||
BuildRequires: pkgconfig(lzo2)
|
||||
# CMake checks these executables during configuration.
|
||||
BuildRequires: nginx
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# bastionguard-backup (Meson + Vala)
|
||||
# The current source checks GTK 3/VTE 2.91 directly from pkg-config.
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: meson
|
||||
BuildRequires: ninja
|
||||
BuildRequires: vala
|
||||
BuildRequires: pkgconfig(gtk+-3.0)
|
||||
BuildRequires: pkgconfig(vte-2.91)
|
||||
BuildRequires: pkgconfig(glib-2.0)
|
||||
BuildRequires: pkgconfig(gobject-2.0)
|
||||
BuildRequires: pkgconfig(gtk4)
|
||||
BuildRequires: pkgconfig(gio-2.0)
|
||||
BuildRequires: pkgconfig(gio-unix-2.0)
|
||||
BuildRequires: pkgconfig(json-glib-1.0)
|
||||
BuildRequires: pkgconfig(vte-2.91-gtk4)
|
||||
BuildRequires: pkgconfig(gee-0.8)
|
||||
BuildRequires: help2man
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# bastionguard-secure-connection (Meson + Go + protobuf/gRPC + eBPF)
|
||||
# -----------------------------------------------------------------------------
|
||||
BuildRequires: golang
|
||||
BuildRequires: protobuf-compiler
|
||||
BuildRequires: pkgconfig(protobuf)
|
||||
BuildRequires: grpc-plugins
|
||||
BuildRequires: pkgconfig(grpc)
|
||||
BuildRequires: pkgconfig(grpc++)
|
||||
BuildRequires: pkgconfig(shumate-1.0)
|
||||
BuildRequires: pkgconfig(libnetfilter_queue)
|
||||
BuildRequires: pkgconfig(libnfnetlink)
|
||||
BuildRequires: pkgconfig(libmnl)
|
||||
BuildRequires: pkgconfig(libelf)
|
||||
BuildRequires: pkgconfig(libbpf)
|
||||
BuildRequires: bpftool
|
||||
BuildRequires: patchelf
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Runtime requirements for OpenMandriva Lx 6.0 Rock
|
||||
# -----------------------------------------------------------------------------
|
||||
Requires: systemd
|
||||
Requires: nginx
|
||||
Requires: php-fpm
|
||||
Requires: dnsmasq
|
||||
Requires: polkit
|
||||
Requires: rsync
|
||||
Requires: bubblewrap
|
||||
Requires: clamav
|
||||
Requires: clamav-db
|
||||
Requires: clamd
|
||||
Requires: curl
|
||||
Requires: nss
|
||||
Requires: nss-tools
|
||||
Requires: sudo
|
||||
|
||||
%description
|
||||
Transparent security control plane for Linux desktops.
|
||||
BastionGuard is not a "trust us" security product.
|
||||
It is a security control plane for Linux desktops where every protection
|
||||
mechanism is explicit, deterministic, and observable.
|
||||
|
||||
%prep
|
||||
%autosetup -n %{name}-%{version} -a 1
|
||||
cp -p yara-%{yara_version}/COPYING YARA-COPYING
|
||||
|
||||
# Clang rejects capturing a static local variable. Accept whitespace variants
|
||||
# and verify that the source really changed.
|
||||
sed -E -i \
|
||||
's/\[this,[[:space:]]*&[[:space:]]*kPageOrder[[:space:]]*\]/[this]/g' \
|
||||
src/MainWindow.cpp
|
||||
|
||||
if grep -Eq '\[this,[[:space:]]*&[[:space:]]*kPageOrder[[:space:]]*\]' \
|
||||
src/MainWindow.cpp; then
|
||||
echo "ERROR: kPageOrder capture patch was not applied."
|
||||
grep -n -C 3 'kPageOrder\|navigate_to' src/MainWindow.cpp || :
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# The project previously consumed only ${YARA_LIBRARIES}, which expands to
|
||||
# "-lyara". In BG_PACKAGING mode bg_link_directories() is deliberately a no-op,
|
||||
# so the private staged libdir was lost. Consume the complete pkg-config target
|
||||
# instead; it propagates include flags, -L and libraries to every target.
|
||||
if grep -Fq 'pkg_check_modules(YARA REQUIRED yara)' CMakeLists.txt; then
|
||||
sed -i \
|
||||
's/pkg_check_modules(YARA REQUIRED yara)/pkg_check_modules(YARA REQUIRED IMPORTED_TARGET GLOBAL yara)/' \
|
||||
CMakeLists.txt
|
||||
fi
|
||||
|
||||
grep -Fq 'pkg_check_modules(YARA REQUIRED IMPORTED_TARGET GLOBAL yara)' \
|
||||
CMakeLists.txt
|
||||
|
||||
sed -i 's/${YARA_LIBRARIES}/PkgConfig::YARA/g' CMakeLists.txt
|
||||
|
||||
if grep -Fq '${YARA_LIBRARIES}' CMakeLists.txt; then
|
||||
echo "ERROR: legacy YARA library references remain in CMakeLists.txt."
|
||||
grep -n -F '${YARA_LIBRARIES}' CMakeLists.txt || :
|
||||
exit 1
|
||||
fi
|
||||
|
||||
grep -n -E 'pkg_check_modules\(YARA|PkgConfig::YARA' CMakeLists.txt
|
||||
|
||||
%build
|
||||
# Do not inherit paths from the machine that generated the SRPM.
|
||||
unset LD_LIBRARY_PATH LIBRARY_PATH CMAKE_PREFIX_PATH PKG_CONFIG_PATH PKG_CONFIG_SYSROOT_DIR
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Build YARA first. It is installed into a staging root only for the
|
||||
# BastionGuard compilation. The final installation is performed in %install.
|
||||
# -----------------------------------------------------------------------------
|
||||
rm -rf %{yara_stage}
|
||||
mkdir -p %{yara_stage}
|
||||
|
||||
pushd yara-%{yara_version}
|
||||
./bootstrap.sh
|
||||
|
||||
YARA_CFLAGS="${CFLAGS:-%{optflags}} -fno-lto"
|
||||
YARA_LDFLAGS="${LDFLAGS:-} -fno-lto"
|
||||
|
||||
CC=clang \
|
||||
CXX=clang++ \
|
||||
CFLAGS="$YARA_CFLAGS" \
|
||||
LDFLAGS="$YARA_LDFLAGS" \
|
||||
./configure \
|
||||
--prefix=%{_prefix} \
|
||||
--bindir=%{_bindir} \
|
||||
--libdir=%{_libdir} \
|
||||
--includedir=%{_includedir} \
|
||||
--mandir=%{_mandir} \
|
||||
--disable-static \
|
||||
--enable-shared \
|
||||
--with-crypto
|
||||
|
||||
%make_build
|
||||
make DESTDIR=%{yara_stage} install
|
||||
popd
|
||||
|
||||
# Make the staged YARA headers, library, pkg-config metadata and CLI visible to
|
||||
# CMake without applying a fake sysroot to every system pkg-config module.
|
||||
#
|
||||
# PKG_CONFIG_SYSROOT_DIR must NOT be exported here: it would also rewrite
|
||||
# libsoup's /usr/include/libsoup-3.0 path into
|
||||
# %{yara_stage}/usr/include/libsoup-3.0, where the header does not exist.
|
||||
YARA_PC="%{yara_stage}%{_libdir}/pkgconfig/yara.pc"
|
||||
test -f "$YARA_PC"
|
||||
|
||||
sed -i \
|
||||
-e 's|^prefix=.*|prefix=%{yara_stage}%{_prefix}|' \
|
||||
-e 's|^exec_prefix=.*|exec_prefix=%{yara_stage}%{_prefix}|' \
|
||||
-e 's|^libdir=.*|libdir=%{yara_stage}%{_libdir}|' \
|
||||
-e 's|^includedir=.*|includedir=%{yara_stage}%{_includedir}|' \
|
||||
"$YARA_PC"
|
||||
|
||||
export PKG_CONFIG_PATH="%{yara_stage}%{_libdir}/pkgconfig"
|
||||
unset PKG_CONFIG_SYSROOT_DIR
|
||||
export PATH="%{yara_stage}%{_bindir}:$PATH"
|
||||
|
||||
# Verify that pkg-config resolves the YARA build staged above.
|
||||
test -f "%{yara_stage}%{_libdir}/pkgconfig/yara.pc"
|
||||
test -x "%{yara_stage}%{_bindir}/yara"
|
||||
|
||||
pkg-config --modversion yara
|
||||
test "$(pkg-config --modversion yara)" = "%{yara_version}"
|
||||
|
||||
echo "YARA pkg-config directory:"
|
||||
pkg-config --variable=pcfiledir yara
|
||||
|
||||
echo "YARA compiler and linker flags:"
|
||||
pkg-config --cflags --libs yara
|
||||
|
||||
find "%{yara_stage}%{_libdir}" \
|
||||
-maxdepth 1 \
|
||||
-type f \
|
||||
-name 'libyara.so.*' \
|
||||
-print -quit | grep -q .
|
||||
|
||||
# Keep the staged YARA pkg-config directory, but never apply a sysroot
|
||||
# to native OpenMandriva dependencies.
|
||||
unset LD_LIBRARY_PATH LIBRARY_PATH CMAKE_PREFIX_PATH PKG_CONFIG_SYSROOT_DIR
|
||||
|
||||
YARA_LIBDIR="$(pkg-config --variable=libdir yara)"
|
||||
YARA_INCLUDEDIR="$(pkg-config --variable=includedir yara)"
|
||||
test -d "$YARA_LIBDIR"
|
||||
test -d "$YARA_INCLUDEDIR"
|
||||
test -e "$YARA_LIBDIR/libyara.so"
|
||||
|
||||
echo "YARA libdir: $YARA_LIBDIR"
|
||||
echo "YARA includedir: $YARA_INCLUDEDIR"
|
||||
ls -la "$YARA_LIBDIR"/libyara.so*
|
||||
|
||||
# PkgConfig::YARA is the primary fix. The explicit -L is an additional
|
||||
# packaging safeguard for any legacy target that still links with -lyara.
|
||||
export LDFLAGS="%{build_ldflags} -L$YARA_LIBDIR"
|
||||
export CFLAGS="%{build_cflags}"
|
||||
export CXXFLAGS="%{build_cxxflags}"
|
||||
|
||||
echo "PKG_CONFIG_PATH=${PKG_CONFIG_PATH}"
|
||||
echo "PKG_CONFIG_SYSROOT_DIR=${PKG_CONFIG_SYSROOT_DIR}"
|
||||
|
||||
# Final verification immediately before CMake configuration.
|
||||
test "$(pkg-config --modversion yara)" = "%{yara_version}"
|
||||
pkg-config --exists yara
|
||||
pkg-config --cflags yara
|
||||
pkg-config --libs yara
|
||||
|
||||
# Verify that libsoup is resolved from the native OpenMandriva installation,
|
||||
# not from the private YARA staging directory.
|
||||
pkg-config --exists libsoup-3.0
|
||||
pkg-config --modversion libsoup-3.0
|
||||
SOUP_CFLAGS="$(pkg-config --cflags libsoup-3.0)"
|
||||
SOUP_LIBS="$(pkg-config --libs libsoup-3.0)"
|
||||
echo "libsoup CFLAGS: $SOUP_CFLAGS"
|
||||
echo "libsoup LIBS: $SOUP_LIBS"
|
||||
test -f "%{_includedir}/libsoup-3.0/libsoup/soup.h"
|
||||
printf '%s\n' "$SOUP_CFLAGS" | grep -q -- "-I%{_includedir}/libsoup-3.0"
|
||||
if printf '%s\n' "$SOUP_CFLAGS" | grep -Fq "%{yara_stage}"; then
|
||||
echo "ERROR: libsoup paths were incorrectly redirected into the YARA staging root"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# OpenMandriva Rock build:
|
||||
# - the legacy standalone CEF switch is disabled;
|
||||
# - the embedded runtime required by Secure Browser/Bank GUI remains enabled;
|
||||
# - the standalone proxy daemon and system CA installer are disabled.
|
||||
rm -rf build
|
||||
|
||||
cmake -S . -B build \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_C_COMPILER=clang \
|
||||
-DCMAKE_CXX_COMPILER=clang++ \
|
||||
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
|
||||
-DCMAKE_INSTALL_SYSCONFDIR=%{_sysconfdir} \
|
||||
-DCMAKE_INSTALL_LOCALSTATEDIR=%{_localstatedir} \
|
||||
-DCMAKE_INSTALL_DATAROOTDIR=%{_datadir} \
|
||||
-DCMAKE_EXE_LINKER_FLAGS="$LDFLAGS" \
|
||||
-DCMAKE_SHARED_LINKER_FLAGS="$LDFLAGS" \
|
||||
-DENABLE_SYSTEMD_SERVICES=OFF \
|
||||
-DENABLE_USER_AGENT_AUTO=OFF \
|
||||
-DINSTALL_NGINX_DEFAULTS=OFF \
|
||||
-DBG_PACKAGING=ON \
|
||||
-DBG_DEBIAN_NO_INSTALL_CODE=ON \
|
||||
-DENABLE_CEF=OFF \
|
||||
-DENABLE_EMBEDDED_CEF=ON \
|
||||
-DENABLE_CEF_DAEMON=OFF \
|
||||
-DENABLE_SYSTEM_CA_INSTALL=OFF \
|
||||
-DCMAKE_BUILD_RPATH="$YARA_LIBDIR" \
|
||||
-DCMAKE_BUILD_WITH_INSTALL_RPATH=ON \
|
||||
-DCMAKE_INSTALL_RPATH='$ORIGIN/../share/BastionGuard/lib;$ORIGIN/../share/BastionGuard/cef' \
|
||||
-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=OFF
|
||||
|
||||
grep '^CMAKE_GENERATOR:' build/CMakeCache.txt || true
|
||||
|
||||
# Confirm that CMake retained the staged YARA location before compiling.
|
||||
grep -R -F "$YARA_LIBDIR" \
|
||||
build/CMakeCache.txt build/CMakeFiles 2>/dev/null | head -n 20 || :
|
||||
|
||||
cmake --build build --parallel 1 --verbose
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
|
||||
# Install the same YARA build used to compile BastionGuard. The runtime CLI and
|
||||
# versioned libyara shared object are shipped by this RPM because Rock 6.0 has
|
||||
# no YARA package. Development-only files are removed afterwards.
|
||||
pushd yara-%{yara_version}
|
||||
make DESTDIR=%{buildroot} install
|
||||
popd
|
||||
|
||||
rm -rf %{buildroot}%{_includedir}/yara
|
||||
rm -f %{buildroot}%{_includedir}/yara.h
|
||||
rm -f %{buildroot}%{_libdir}/pkgconfig/yara.pc
|
||||
rm -f %{buildroot}%{_libdir}/libyara.la
|
||||
rm -f %{buildroot}%{_libdir}/libyara.a
|
||||
rm -f %{buildroot}%{_libdir}/libyara.so
|
||||
|
||||
DESTDIR=%{buildroot} cmake --install build
|
||||
|
||||
# OpenMandriva Rock: embedded CEF and the Secure Browser GUIs must be present.
|
||||
# The standalone CEF proxy, its service, activation helper and system CA
|
||||
# integration must not be installed.
|
||||
for _forbidden in \
|
||||
"%{buildroot}%{_bindir}/bastionguard-cef" \
|
||||
"%{buildroot}%{_bindir}/bastionguard-activation-helper" \
|
||||
"%{buildroot}%{_datadir}/polkit-1/actions/eu.bastionguard.install-ca.policy" \
|
||||
"%{buildroot}%{_datadir}/polkit-1/actions/org.bastionguard.activation.policy" \
|
||||
"%{buildroot}%{_datadir}/BastionGuard/data/scripts/install-ca-system.sh" \
|
||||
"%{buildroot}%{_userunitdir}/BastionGuard-cef.service" \
|
||||
"%{buildroot}%{_datadir}/BastionGuard/data/service/BastionGuard-cef.service" \
|
||||
"%{buildroot}%{_unitdir}/bastionguard-cef.service"; do
|
||||
test ! -e "$_forbidden"
|
||||
done
|
||||
|
||||
for _required in \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-bankopener" \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-bankgui" \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-secure" \
|
||||
"%{buildroot}%{_bindir}/BastionGuard-secure-gui" \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-bankgui.desktop" \
|
||||
"%{buildroot}%{_datadir}/applications/BastionGuard-secure.desktop" \
|
||||
"%{buildroot}%{_datadir}/applications/bastionguard-bankopener.desktop"; do
|
||||
test -e "$_required"
|
||||
done
|
||||
|
||||
# Runtime CEF embedded required by BankOpener and Secure Browser.
|
||||
test -d "%{buildroot}%{_datadir}/BastionGuard/cef"
|
||||
|
||||
install -dm750 %{buildroot}%{_sharedstatedir}/bastionguard-webui/{cache,quarantine,sessions,tmp}
|
||||
install -dm755 %{buildroot}%{_localstatedir}/log/bastionguard-webui
|
||||
|
||||
test -x %{buildroot}%{_bindir}/BastionGuard
|
||||
test -x %{buildroot}%{_bindir}/yara
|
||||
test -x %{buildroot}%{_bindir}/yarac
|
||||
file %{buildroot}%{_bindir}/BastionGuard | grep -q "ELF 64-bit"
|
||||
readelf -d %{buildroot}%{_bindir}/BastionGuard | grep -q NEEDED
|
||||
readelf -d %{buildroot}%{_bindir}/BastionGuard | grep -q 'libyara\.so'
|
||||
find %{buildroot}%{_libdir} -maxdepth 1 -type f -name 'libyara.so.*' -print -quit | grep -q .
|
||||
|
||||
%post
|
||||
# Unit activation is intentionally left to BastionGuard's first-run wizard.
|
||||
if command -v systemctl >/dev/null 2>&1; then
|
||||
systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
# OpenMandriva's PHP-FPM packages normally use the apache account. Keep the
|
||||
# package installable even on minimal systems where that account is not yet
|
||||
# present, and fix ownership once php-fpm has created it.
|
||||
if getent passwd apache >/dev/null 2>&1; then
|
||||
chown -R apache:apache %{_sharedstatedir}/bastionguard-webui 2>/dev/null || :
|
||||
fi
|
||||
:
|
||||
|
||||
%postun
|
||||
if command -v systemctl >/dev/null 2>&1; then
|
||||
systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
:
|
||||
|
||||
%files
|
||||
%license YARA-COPYING
|
||||
%{_bindir}/*
|
||||
%{_libdir}/libyara.so.*
|
||||
|
||||
%{_datadir}/BastionGuard
|
||||
%{_datadir}/bastionguard-backup
|
||||
%{_datadir}/bastionguard-sc
|
||||
%{_datadir}/applications/BastionGuard.desktop
|
||||
%{_datadir}/applications/bastionguard-sc.desktop
|
||||
%{_datadir}/applications/bastionguard-backup-gtk.desktop
|
||||
%{_datadir}/applications/BastionGuard-bankgui.desktop
|
||||
%{_datadir}/applications/BastionGuard-secure.desktop
|
||||
%{_datadir}/applications/bastionguard-bankopener.desktop
|
||||
|
||||
%config(noreplace) %{_sysconfdir}/xdg/autostart/BastionGuard-autostart.desktop
|
||||
%config(noreplace) %{_sysconfdir}/xdg/autostart/bastionguard-sc-autostart.desktop
|
||||
|
||||
%{_datadir}/dbus-1/services/org.BastionGuard.RansomwareAlert.service
|
||||
%{_datadir}/dbus-1/system-services/org.BastionGuard.USBD.service
|
||||
%{_datadir}/dbus-1/system.d/org.BastionGuard.USBD.conf
|
||||
|
||||
%{_datadir}/polkit-1/actions/it.BastionGuard.camera.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.ransomware.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.USBD.policy
|
||||
%{_datadir}/polkit-1/actions/eu.bastionguard.sc.policy
|
||||
%{_datadir}/polkit-1/actions/org.bastionguard.pkexec.backup.policy
|
||||
|
||||
%{_unitdir}/*
|
||||
%{_userunitdir}/*
|
||||
|
||||
%{_datadir}/locale/*
|
||||
%{_datadir}/icons/*
|
||||
%{_datadir}/plymouth/*
|
||||
%config(noreplace) %{_sysconfdir}/bastionguard-backup/*
|
||||
/usr/lib/bastionguard-sc/*
|
||||
%{_datadir}/metainfo/*
|
||||
%{_mandir}/*
|
||||
|
||||
%dir %{_libexecdir}/bastionguard
|
||||
%{_libexecdir}/bastionguard/archive_worker
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-helper
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-phishing
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-bank
|
||||
|
||||
%dir %attr(750,root,root) %{_sharedstatedir}/bastionguard-webui
|
||||
%dir %attr(750,root,root) %{_sharedstatedir}/bastionguard-webui/cache
|
||||
%dir %attr(750,root,root) %{_sharedstatedir}/bastionguard-webui/quarantine
|
||||
%dir %attr(750,root,root) %{_sharedstatedir}/bastionguard-webui/sessions
|
||||
%dir %attr(750,root,root) %{_sharedstatedir}/bastionguard-webui/tmp
|
||||
%dir %attr(755,root,root) %{_localstatedir}/log/bastionguard-webui
|
||||
|
||||
# BastionGuard Recovery Data
|
||||
%{_datadir}/bastionguard-recovery-data
|
||||
%{_datadir}/applications/com.bastionguard.RecoveryData.desktop
|
||||
%{_datadir}/polkit-1/actions/com.bastionguard.RecoveryData.policy
|
||||
|
||||
# Plymouth assets
|
||||
%{_datadir}/pixmaps/*
|
||||
|
||||
# BastionGuard Secure Connection daemon configuration
|
||||
%dir %{_sysconfdir}/bastionguard-secure-connectiond
|
||||
%config(noreplace) %{_sysconfdir}/bastionguard-secure-connectiond/*
|
||||
|
||||
%changelog
|
||||
* Thu Jul 16 2026 Calogero Scarnà <info@bastionguard.eu> 2.0-3
|
||||
- Link the private YARA build through the imported PkgConfig::YARA target.
|
||||
- Preserve the staged YARA library directory in the linker flags.
|
||||
- Verify the unversioned libyara.so linker name before configuring CMake.
|
||||
- Use generator-independent out-of-source CMake build and install commands.
|
||||
- Verify the OpenMandriva Clang kPageOrder source patch.
|
||||
|
||||
* Thu Jul 16 2026 Calogero Scarnà <info@bastionguard.eu> 2.0-2
|
||||
- Resolve libsoup-3.0 through its pkg-config capability.
|
||||
- Stop applying the private YARA sysroot to native system dependencies.
|
||||
- Rewrite the staged yara.pc paths instead.
|
||||
- Verify libsoup headers and compiler flags before CMake configuration.
|
||||
|
||||
* Wed Jul 15 2026 Calogero Scarnà <info@bastionguard.eu> 2.0-2
|
||||
- Build and bundle YARA 4.5.5 before BastionGuard on OpenMandriva Rock 6.0
|
||||
- Remove unavailable external yara/yara-devel dependencies
|
||||
2753
openmandriva/change_cmake_openmandriva/CMakeLists.txt
Normal file
2753
openmandriva/change_cmake_openmandriva/CMakeLists.txt
Normal file
File diff suppressed because it is too large
Load diff
362
opensuse_leap16/bastionguard.spec
Normal file
362
opensuse_leap16/bastionguard.spec
Normal file
|
|
@ -0,0 +1,362 @@
|
|||
#
|
||||
#
|
||||
# BastionGuard™
|
||||
# Copyright (C) 2025–2026 Calogero Scarnà
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, version 3.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
#
|
||||
# BastionGuard™ is a trademark of Calogero Scarnà.
|
||||
# The BastionGuard™ name and branding are not licensed under the GPL.
|
||||
#
|
||||
#
|
||||
# Spec file for BastionGuard (openSUSE Leap 16.0)
|
||||
#
|
||||
|
||||
Name: bastionguard
|
||||
Version: 2.0
|
||||
Release: 1leap
|
||||
Summary: BastionGuard Security Platform
|
||||
License: GPL-3.0-or-later
|
||||
URL: https://git.bastionguard.eu/specialworld83/BastionGuard
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
|
||||
# Disable debuginfo / debugsource packages.
|
||||
%global debug_package %{nil}
|
||||
|
||||
# Hyperscan is disabled by default because it is not part of the standard
|
||||
# Leap 16.0 repositories. Enable it only when a trusted repository providing
|
||||
# pkgconfig(hyperscan) has been configured in the build environment.
|
||||
%bcond_with hyperscan
|
||||
|
||||
# Core build tools
|
||||
BuildRequires: binutils
|
||||
BuildRequires: cmake
|
||||
BuildRequires: file
|
||||
BuildRequires: findutils
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: gettext-tools
|
||||
BuildRequires: git
|
||||
BuildRequires: gzip
|
||||
BuildRequires: make
|
||||
BuildRequires: ninja
|
||||
BuildRequires: patch
|
||||
BuildRequires: pkgconf-pkg-config
|
||||
BuildRequires: rsync
|
||||
BuildRequires: tar
|
||||
BuildRequires: which
|
||||
|
||||
# Leap 16 uses the distribution Python selected by /usr/bin/python3.
|
||||
BuildRequires: python3
|
||||
BuildRequires: python3-devel
|
||||
|
||||
# Main GTK/C++ application
|
||||
BuildRequires: pkgconfig(gtk4)
|
||||
BuildRequires: pkgconfig(gtkmm-4.0)
|
||||
BuildRequires: pkgconfig(glib-2.0)
|
||||
BuildRequires: pkgconfig(glibmm-2.68)
|
||||
BuildRequires: pkgconfig(giomm-2.68)
|
||||
BuildRequires: pkgconfig(pangomm-2.48)
|
||||
BuildRequires: pkgconfig(sigc++-3.0)
|
||||
BuildRequires: pkgconfig(libudev)
|
||||
|
||||
BuildRequires: pkgconfig(libsoup-3.0)
|
||||
BuildRequires: pkgconfig(libsecret-1)
|
||||
BuildRequires: pkgconfig(libsystemd)
|
||||
BuildRequires: pkgconfig(libidn2)
|
||||
BuildRequires: pkgconfig(sqlite3)
|
||||
BuildRequires: pkgconfig(libcurl)
|
||||
BuildRequires: pkgconfig(openssl)
|
||||
BuildRequires: pkgconfig(polkit-gobject-1)
|
||||
BuildRequires: pkgconfig(yara)
|
||||
BuildRequires: pkgconfig(re2)
|
||||
BuildRequires: nlohmann_json-devel
|
||||
BuildRequires: boost-devel
|
||||
BuildRequires: libboost_atomic-devel
|
||||
BuildRequires: libboost_system-devel
|
||||
BuildRequires: libboost_thread-devel
|
||||
|
||||
%if %{with hyperscan}
|
||||
BuildRequires: pkgconfig(hyperscan)
|
||||
%endif
|
||||
|
||||
BuildRequires: pkgconfig(libpng)
|
||||
BuildRequires: pkgconfig(libjpeg)
|
||||
BuildRequires: pkgconfig(libtiff-4)
|
||||
BuildRequires: pkgconfig(libwebp)
|
||||
BuildRequires: pkgconfig(fribidi)
|
||||
|
||||
BuildRequires: pkgconfig(nspr)
|
||||
BuildRequires: pkgconfig(nss)
|
||||
|
||||
BuildRequires: pkgconfig(x11)
|
||||
BuildRequires: pkgconfig(xcursor)
|
||||
BuildRequires: pkgconfig(xrandr)
|
||||
BuildRequires: pkgconfig(xi)
|
||||
BuildRequires: pkgconfig(xinerama)
|
||||
BuildRequires: pkgconfig(xdamage)
|
||||
BuildRequires: pkgconfig(xcomposite)
|
||||
BuildRequires: pkgconfig(xfixes)
|
||||
BuildRequires: pkgconfig(xkbcommon)
|
||||
BuildRequires: pkgconfig(wayland-client)
|
||||
BuildRequires: pkgconfig(wayland-protocols)
|
||||
|
||||
BuildRequires: pkgconfig(alsa)
|
||||
BuildRequires: pkgconfig(libpipewire-0.3)
|
||||
BuildRequires: samba-devel
|
||||
|
||||
# bastionguard-backup (GTK4/Vala, Meson)
|
||||
BuildRequires: meson
|
||||
BuildRequires: vala
|
||||
BuildRequires: pkgconfig(gio-unix-2.0)
|
||||
BuildRequires: pkgconfig(json-glib-1.0)
|
||||
BuildRequires: pkgconfig(vte-2.91-gtk4)
|
||||
BuildRequires: pkgconfig(gee-0.8)
|
||||
BuildRequires: help2man
|
||||
|
||||
# bastionguard-secure-connection (Meson + Go)
|
||||
BuildRequires: go
|
||||
BuildRequires: protobuf-devel
|
||||
BuildRequires: grpc-devel
|
||||
|
||||
# Secure Connection GUI, map and eBPF daemon
|
||||
BuildRequires: pkgconfig(shumate-1.0)
|
||||
BuildRequires: libnetfilter_queue-devel
|
||||
BuildRequires: clang
|
||||
BuildRequires: libbpf-devel
|
||||
BuildRequires: bpftool
|
||||
BuildRequires: pkgconfig(libzstd)
|
||||
BuildRequires: lzo-devel
|
||||
BuildRequires: bubblewrap
|
||||
BuildRequires: clamav
|
||||
BuildRequires: curl
|
||||
BuildRequires: dnsmasq
|
||||
BuildRequires: mozilla-nss
|
||||
BuildRequires: mozilla-nss-tools
|
||||
BuildRequires: nginx
|
||||
BuildRequires: polkit
|
||||
BuildRequires: rsync
|
||||
BuildRequires: sudo
|
||||
BuildRequires: yara
|
||||
BuildRequires: libyara-devel
|
||||
|
||||
# Packaging/build helpers used by the project
|
||||
BuildRequires: bubblewrap
|
||||
BuildRequires: patchelf
|
||||
BuildRequires: system-user-wwwrun
|
||||
|
||||
# vmlinux.h must already be present in Source0.
|
||||
# bpftool and libbpf-tools are deliberately not BuildRequires because they are
|
||||
# not guaranteed by the standard Leap 16.0 repositories. The Leap CI workflow
|
||||
# generates vmlinux.h before creating the source archive.
|
||||
|
||||
# Runtime requirements available in the standard Leap repositories
|
||||
Requires: bubblewrap
|
||||
Requires: clamav
|
||||
Requires: curl
|
||||
Requires: dnsmasq
|
||||
Requires: mozilla-nss
|
||||
Requires: mozilla-nss-tools
|
||||
Requires: nginx
|
||||
Requires: polkit
|
||||
Requires: rsync
|
||||
Requires: sudo
|
||||
Requires: yara
|
||||
|
||||
# Provides the openSUSE web-service account used by the writable Web UI dirs.
|
||||
Requires(pre): system-user-wwwrun
|
||||
|
||||
# Optional integrations. These remain weak dependencies so the RPM can be
|
||||
# installed from the standard Leap repositories even when they are unavailable.
|
||||
Recommends: bpftool
|
||||
Recommends: python3
|
||||
Recommends: php8-fpm
|
||||
|
||||
%description
|
||||
Transparent security control plane for Linux desktops.
|
||||
|
||||
BastionGuard is not a "trust us" security product. It is a security control
|
||||
plane for Linux desktops where every protection mechanism is explicit,
|
||||
deterministic, and observable.
|
||||
|
||||
Unlike most desktop security tools, which hide decisions behind opaque
|
||||
engines, cloud scoring, or silent automation, BastionGuard exposes what is
|
||||
happening, why it is happening, and how protections are applied. Users and
|
||||
administrators can see, control, and reason about every security decision.
|
||||
|
||||
%prep
|
||||
%autosetup -n %{name}-%{version}
|
||||
|
||||
%build
|
||||
unset LD_LIBRARY_PATH LIBRARY_PATH CMAKE_PREFIX_PATH PKG_CONFIG_PATH
|
||||
|
||||
export CFLAGS="%{optflags}"
|
||||
export CXXFLAGS="%{optflags}"
|
||||
unset LDFLAGS
|
||||
|
||||
%if %{with hyperscan}
|
||||
%global hyperscan_flag -DENABLE_HYPERSCAN=ON
|
||||
%else
|
||||
%global hyperscan_flag -DENABLE_HYPERSCAN=OFF
|
||||
%endif
|
||||
|
||||
# Use an explicit, deterministic out-of-source build. This does not depend
|
||||
# on distribution-specific CMake helper macro definitions.
|
||||
rm -rf build
|
||||
|
||||
cmake -S . -B build -G Ninja \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
|
||||
-DCMAKE_INSTALL_SYSCONFDIR=%{_sysconfdir} \
|
||||
-DCMAKE_INSTALL_LOCALSTATEDIR=%{_localstatedir} \
|
||||
-DCMAKE_INSTALL_DATAROOTDIR=%{_datadir} \
|
||||
-DBoost_NO_BOOST_CMAKE=ON \
|
||||
-DCMAKE_POLICY_DEFAULT_CMP0167=OLD \
|
||||
-DENABLE_SYSTEMD_SERVICES=ON \
|
||||
-DENABLE_USER_AGENT_AUTO=OFF \
|
||||
-DINSTALL_NGINX_DEFAULTS=OFF \
|
||||
-DBG_PACKAGING=ON \
|
||||
-DBG_DEBIAN_NO_INSTALL_CODE=ON \
|
||||
-DENABLE_CEF=OFF \
|
||||
-DENABLE_EMBEDDED_CEF=ON \
|
||||
-DENABLE_CEF_DAEMON=OFF \
|
||||
-DENABLE_SYSTEM_CA_INSTALL=OFF \
|
||||
-DCMAKE_BUILD_WITH_INSTALL_RPATH=ON \
|
||||
-DCMAKE_INSTALL_RPATH='$ORIGIN/../share/BastionGuard/lib;$ORIGIN/../share/BastionGuard/cef' \
|
||||
-DCMAKE_INSTALL_RPATH_USE_LINK_PATH=OFF \
|
||||
%{hyperscan_flag}
|
||||
|
||||
test -f build/CMakeCache.txt
|
||||
test -f build/build.ninja
|
||||
grep '^CMAKE_GENERATOR:' build/CMakeCache.txt || true
|
||||
|
||||
cmake --build build --parallel 1 --verbose
|
||||
|
||||
%install
|
||||
rm -rf %{buildroot}
|
||||
test -f build/CMakeCache.txt
|
||||
DESTDIR=%{buildroot} cmake --install build
|
||||
|
||||
# icon-theme.cache is generated metadata and must not be packaged.
|
||||
find "%{buildroot}%{_datadir}/icons" \
|
||||
-type f -name 'icon-theme.cache' -delete
|
||||
|
||||
install -dm750 %{buildroot}%{_sharedstatedir}/bastionguard-webui/{cache,quarantine,sessions,tmp}
|
||||
install -dm755 %{buildroot}%{_localstatedir}/log/bastionguard-webui
|
||||
|
||||
# Sanity checks
|
||||
test -x %{buildroot}%{_bindir}/BastionGuard
|
||||
file %{buildroot}%{_bindir}/BastionGuard | grep -q "ELF"
|
||||
readelf -d %{buildroot}%{_bindir}/BastionGuard | grep -q NEEDED
|
||||
|
||||
%post
|
||||
if [ -d /run/systemd/system ] && command -v systemctl >/dev/null 2>&1; then
|
||||
systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
:
|
||||
|
||||
%postun
|
||||
if [ -d /run/systemd/system ] && command -v systemctl >/dev/null 2>&1; then
|
||||
systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
fi
|
||||
:
|
||||
|
||||
%files
|
||||
%{_bindir}/*
|
||||
|
||||
%{_datadir}/BastionGuard
|
||||
%{_datadir}/bastionguard-backup
|
||||
%{_datadir}/bastionguard-sc
|
||||
|
||||
%{_datadir}/applications/BastionGuard.desktop
|
||||
%{_datadir}/applications/BastionGuard-bankgui.desktop
|
||||
%{_datadir}/applications/BastionGuard-secure.desktop
|
||||
%{_datadir}/applications/bastionguard-bankopener.desktop
|
||||
%{_datadir}/applications/bastionguard-sc.desktop
|
||||
%{_datadir}/applications/bastionguard-backup-gtk.desktop
|
||||
|
||||
%config(noreplace) %{_sysconfdir}/xdg/autostart/BastionGuard-autostart.desktop
|
||||
%config(noreplace) %{_sysconfdir}/xdg/autostart/bastionguard-sc-autostart.desktop
|
||||
|
||||
%{_datadir}/dbus-1/services/org.BastionGuard.RansomwareAlert.service
|
||||
%{_datadir}/dbus-1/system-services/org.BastionGuard.USBD.service
|
||||
%{_datadir}/dbus-1/system.d/org.BastionGuard.USBD.conf
|
||||
|
||||
%{_datadir}/polkit-1/actions/it.BastionGuard.camera.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.ransomware.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.USBD.policy
|
||||
%{_datadir}/polkit-1/actions/eu.bastionguard.sc.policy
|
||||
%{_datadir}/polkit-1/actions/org.bastionguard.pkexec.backup.policy
|
||||
|
||||
%{_unitdir}/*
|
||||
%{_userunitdir}/*
|
||||
%{_datadir}/locale/*/LC_MESSAGES/*.mo
|
||||
%{_datadir}/icons/hicolor/*/*/*
|
||||
%{_datadir}/metainfo/*
|
||||
%{_mandir}/man*/*
|
||||
%{_datadir}/pixmaps/*
|
||||
|
||||
%dir %{_sysconfdir}/bastionguard-backup
|
||||
%config(noreplace) %{_sysconfdir}/bastionguard-backup/*
|
||||
|
||||
%{_prefix}/lib/bastionguard-sc/*
|
||||
|
||||
%dir %{_libexecdir}/bastionguard
|
||||
%{_libexecdir}/bastionguard/archive_worker
|
||||
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-helper
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-bank
|
||||
%config(noreplace) %{_sysconfdir}/sudoers.d/bastionguard-phishing
|
||||
|
||||
%dir %attr(750,wwwrun,www) %{_sharedstatedir}/bastionguard-webui
|
||||
%dir %attr(750,wwwrun,www) %{_sharedstatedir}/bastionguard-webui/cache
|
||||
%dir %attr(750,wwwrun,www) %{_sharedstatedir}/bastionguard-webui/quarantine
|
||||
%dir %attr(750,wwwrun,www) %{_sharedstatedir}/bastionguard-webui/sessions
|
||||
%dir %attr(750,wwwrun,www) %{_sharedstatedir}/bastionguard-webui/tmp
|
||||
%dir %attr(755,root,root) %{_localstatedir}/log/bastionguard-webui
|
||||
|
||||
# BastionGuard Recovery Data
|
||||
%{_datadir}/bastionguard-recovery-data
|
||||
%{_datadir}/applications/com.bastionguard.RecoveryData.desktop
|
||||
%{_datadir}/polkit-1/actions/com.bastionguard.RecoveryData.policy
|
||||
|
||||
# Plymouth theme
|
||||
%{_datadir}/plymouth/themes/bastionguard
|
||||
|
||||
# BastionGuard Secure Connection daemon configuration
|
||||
%dir %{_sysconfdir}/bastionguard-secure-connectiond
|
||||
%config(noreplace) %{_sysconfdir}/bastionguard-secure-connectiond/*
|
||||
|
||||
%changelog
|
||||
* Thu Jul 16 2026 Calogero Scarnà <info@bastionguard.eu> - 2.0-4
|
||||
- Remove literal RPM CMake macro references from comments.
|
||||
- Prevent comment macro expansion from injecting commands into the build.
|
||||
- Keep the explicit Ninja build and install directories.
|
||||
|
||||
* Thu Jul 16 2026 Calogero Scarnà <info@bastionguard.eu> - 2.0-3
|
||||
- Use an explicit CMake source and build directory on Leap 16.
|
||||
- Force the Ninja generator and build from ./build.
|
||||
- Avoid inconsistent Leap container definitions of the CMake build helper.
|
||||
- Install from the same verified CMake build tree.
|
||||
|
||||
* Wed Jul 15 2026 Calogero Scarnà <info@bastionguard.eu> - 2.0-2
|
||||
- Adapt the package specification to openSUSE Leap 16.0.
|
||||
- Use the distribution python3 and python3-devel packages.
|
||||
- Make PHP-FPM and BPF command-line tools weak dependencies.
|
||||
- Require a pre-generated vmlinux.h in the source archive.
|
||||
- Use the native wwwrun:www web-service account.
|
||||
- Remove duplicate and runtime-only BuildRequires entries.
|
||||
- Normalize file macros and avoid duplicate file-list entries.
|
||||
|
||||
* Fri Jun 12 2026 Calogero Scarnà <info@bastionguard.eu> - 2.0-1
|
||||
- Update package
|
||||
2711
opensuse_leap16/cmake_opensuse/CMakeLists.txt
Normal file
2711
opensuse_leap16/cmake_opensuse/CMakeLists.txt
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -24,10 +24,10 @@
|
|||
|
||||
Name: bastionguard
|
||||
Version: 2.0
|
||||
Release: 1
|
||||
Release: 2
|
||||
Summary: BastionGuard Security Platform
|
||||
License: GPL-3.0-or-later
|
||||
URL: https://git.bastionguard.eu/specialworld83/BastionGuard
|
||||
URL: https://git.bastionguard.eu/specialworld83/BastionGuard-ci
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
|
||||
Provides: bastionguard = %{version}-%{release}
|
||||
|
|
@ -207,6 +207,10 @@ unset LDFLAGS
|
|||
-DENABLE_USER_AGENT_AUTO=OFF \
|
||||
-DINSTALL_NGINX_DEFAULTS=OFF \
|
||||
-DBG_PACKAGING=ON \
|
||||
-DENABLE_CEF=OFF \
|
||||
-DENABLE_EMBEDDED_CEF=ON \
|
||||
-DENABLE_CEF_DAEMON=OFF \
|
||||
-DENABLE_SYSTEM_CA_INSTALL=OFF \
|
||||
-DBG_DEBIAN_NO_INSTALL_CODE=ON \
|
||||
-DCMAKE_BUILD_WITH_INSTALL_RPATH=ON \
|
||||
-DCMAKE_INSTALL_RPATH='$ORIGIN/../share/BastionGuard/lib;$ORIGIN/../share/BastionGuard/cef' \
|
||||
|
|
@ -256,7 +260,6 @@ fi
|
|||
%{_datadir}/polkit-1/actions/org.BastionGuard.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.ransomware.policy
|
||||
%{_datadir}/polkit-1/actions/org.BastionGuard.USBD.policy
|
||||
%{_datadir}/polkit-1/actions/eu.bastionguard.install-ca.policy
|
||||
%{_datadir}/polkit-1/actions/eu.bastionguard.sc.policy
|
||||
%{_datadir}/polkit-1/actions/org.bastionguard.pkexec.backup.policy
|
||||
%{_unitdir}/*
|
||||
|
|
|
|||
|
|
@ -1,6 +1,72 @@
|
|||
cmake_minimum_required(VERSION 3.16)
|
||||
project(BastionGuard LANGUAGES CXX)
|
||||
|
||||
# ============================================================
|
||||
# CEF feature split for openSUSE
|
||||
#
|
||||
# ENABLE_CEF is retained as the legacy switch for the standalone CEF
|
||||
# proxy/system-CA integration. It is forced OFF on openSUSE.
|
||||
#
|
||||
# ENABLE_EMBEDDED_CEF controls the bundled runtime used by Secure Browser,
|
||||
# BankPage, BankOpener, BankGUI and Secure Payments. It remains ON so that
|
||||
# disabling the standalone CEF integration does not remove those components.
|
||||
# ============================================================
|
||||
option(ENABLE_CEF
|
||||
"Legacy standalone CEF proxy/system-CA switch"
|
||||
OFF)
|
||||
option(ENABLE_EMBEDDED_CEF
|
||||
"Build and install embedded CEF runtime and Secure Browser components"
|
||||
ON)
|
||||
option(ENABLE_CEF_DAEMON
|
||||
"Build and install the standalone bastionguard-cef proxy and user service"
|
||||
OFF)
|
||||
option(ENABLE_SYSTEM_CA_INSTALL
|
||||
"Install the system CA policy and install-ca-system.sh helper"
|
||||
OFF)
|
||||
|
||||
# Embedded CEF remains mandatory for the Secure Browser and banking/payment GUIs.
|
||||
set(ENABLE_EMBEDDED_CEF ON CACHE BOOL
|
||||
"Embedded CEF required by Secure Browser and banking/payment GUIs" FORCE)
|
||||
|
||||
# Standalone proxy and system CA are deliberately disabled on openSUSE.
|
||||
set(ENABLE_CEF OFF CACHE BOOL
|
||||
"Standalone CEF integration disabled for openSUSE" FORCE)
|
||||
set(ENABLE_CEF_DAEMON OFF CACHE BOOL
|
||||
"Standalone bastionguard-cef proxy disabled for openSUSE" FORCE)
|
||||
set(ENABLE_SYSTEM_CA_INSTALL OFF CACHE BOOL
|
||||
"System CA installation disabled for openSUSE" FORCE)
|
||||
|
||||
# Compatibility: BASTIONGUARD_HAS_CEF describes the embedded runtime.
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
add_compile_definitions(
|
||||
BASTIONGUARD_HAS_CEF=1
|
||||
BASTIONGUARD_HAS_EMBEDDED_CEF=1
|
||||
)
|
||||
else()
|
||||
add_compile_definitions(
|
||||
BASTIONGUARD_HAS_CEF=0
|
||||
BASTIONGUARD_HAS_EMBEDDED_CEF=0
|
||||
)
|
||||
endif()
|
||||
|
||||
if(ENABLE_CEF_DAEMON)
|
||||
add_compile_definitions(BASTIONGUARD_HAS_CEF_DAEMON=1)
|
||||
else()
|
||||
add_compile_definitions(BASTIONGUARD_HAS_CEF_DAEMON=0)
|
||||
endif()
|
||||
|
||||
if(ENABLE_SYSTEM_CA_INSTALL)
|
||||
add_compile_definitions(BASTIONGUARD_ALLOW_SYSTEM_CA_INSTALL=1)
|
||||
else()
|
||||
add_compile_definitions(BASTIONGUARD_ALLOW_SYSTEM_CA_INSTALL=0)
|
||||
endif()
|
||||
|
||||
message(STATUS "[CEF] openSUSE: embedded GUI runtime enabled; standalone CEF daemon and system CA disabled")
|
||||
message(STATUS "ENABLE_CEF = ${ENABLE_CEF} (legacy standalone switch)")
|
||||
message(STATUS "ENABLE_EMBEDDED_CEF = ${ENABLE_EMBEDDED_CEF}")
|
||||
message(STATUS "ENABLE_CEF_DAEMON = ${ENABLE_CEF_DAEMON}")
|
||||
message(STATUS "ENABLE_SYSTEM_CA_INSTALL = ${ENABLE_SYSTEM_CA_INSTALL}")
|
||||
|
||||
set(Boost_NO_BOOST_CMAKE ON)
|
||||
set(Boost_USE_STATIC_LIBS OFF)
|
||||
set(Boost_USE_MULTITHREADED ON)
|
||||
|
|
@ -90,10 +156,17 @@ endfunction()
|
|||
# In RPM: niente path assoluti in RUNPATH/RPATH, usa $ORIGIN
|
||||
if(BG_PACKAGING)
|
||||
# binari in /usr/bin → librerie in /usr/share/BastionGuard/*
|
||||
set(BG_INSTALL_RPATH "$ORIGIN/../share/BastionGuard/lib;$ORIGIN/../share/BastionGuard/cef")
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
set(BG_INSTALL_RPATH "\$ORIGIN/../share/BastionGuard/lib;\$ORIGIN/../share/BastionGuard/cef")
|
||||
else()
|
||||
set(BG_INSTALL_RPATH "\$ORIGIN/../share/BastionGuard/lib")
|
||||
endif()
|
||||
else()
|
||||
set(BG_INSTALL_RPATH "/usr/share/BastionGuard/lib;/usr/share/BastionGuard/cef")
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
set(BG_INSTALL_RPATH "/usr/share/BastionGuard/lib;/usr/share/BastionGuard/cef")
|
||||
else()
|
||||
set(BG_INSTALL_RPATH "/usr/share/BastionGuard/lib")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Evita che CMake “trascini” path di link nell'RPATH
|
||||
|
|
@ -203,7 +276,11 @@ endif()
|
|||
# Option to control whether systemd services are enabled / started at install time.
|
||||
option(ENABLE_SYSTEMD_SERVICES "Enable and start systemd services at install time" OFF)
|
||||
|
||||
install(DIRECTORY data/ DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/BastionGuard/data)
|
||||
install(DIRECTORY data/
|
||||
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/BastionGuard/data
|
||||
PATTERN "scripts/install-ca-system.sh" EXCLUDE
|
||||
PATTERN "service/BastionGuard-cef.service" EXCLUDE
|
||||
)
|
||||
|
||||
set(INSTALL_DATA_DIR "${CMAKE_INSTALL_FULL_DATAROOTDIR}/BastionGuard/data")
|
||||
set(INSTALL_LOCALE_DIR "${CMAKE_INSTALL_FULL_DATAROOTDIR}/BastionGuard/locale")
|
||||
|
|
@ -580,10 +657,8 @@ set(BastionGuard_SOURCES
|
|||
src/StyleProvider.cpp
|
||||
src/AntiRansomEngine.cpp
|
||||
src/AntiPhishingEngine.cpp
|
||||
src/BankPage.cpp
|
||||
src/wizard/wizard_window.cpp
|
||||
src/wizard/wizard_setup.cpp
|
||||
src/SecureBrowser.cpp
|
||||
src/PrivacyPage.cpp
|
||||
src/AurScan.cpp
|
||||
src/SettingsWindow.cpp
|
||||
|
|
@ -605,6 +680,14 @@ set(BastionGuard_SOURCES
|
|||
src/backup/BackupPage.cpp
|
||||
src/Utils.cpp
|
||||
)
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
list(APPEND BastionGuard_SOURCES
|
||||
src/BankPage.cpp
|
||||
src/SecureBrowser.cpp
|
||||
)
|
||||
endif()
|
||||
|
||||
add_executable(BastionGuard ${BastionGuard_SOURCES})
|
||||
target_include_directories(BastionGuard
|
||||
PRIVATE
|
||||
|
|
@ -639,6 +722,7 @@ target_link_libraries(BastionGuard
|
|||
target_link_options(BastionGuard PRIVATE -lsystemd)
|
||||
bg_set_rpath(BastionGuard)
|
||||
bg_link_systemd(BastionGuard)
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
# ============================================================
|
||||
# Blink / CEF Integration (SecureBrowser)
|
||||
# ============================================================
|
||||
|
|
@ -745,10 +829,8 @@ endif()
|
|||
message(STATUS "✔ Wrapper statico CEF trovato: ${CEF_WRAPPER}")
|
||||
|
||||
# ------------------------------------------------------------
|
||||
# Aggiungi SecureBrowser
|
||||
# SecureBrowser sources are added before add_executable(BastionGuard).
|
||||
# ------------------------------------------------------------
|
||||
list(APPEND BastionGuard_SOURCES src/SecureBrowser.cpp)
|
||||
|
||||
include_directories(${CEF_ROOT} ${CEF_ROOT}/include)
|
||||
|
||||
target_link_libraries(BastionGuard
|
||||
|
|
@ -813,6 +895,8 @@ bg_install_code( "
|
|||
execute_process(COMMAND chmod 4755 ${CMAKE_INSTALL_FULL_DATAROOTDIR}/BastionGuard/cef/chrome-sandbox)
|
||||
")
|
||||
|
||||
endif()
|
||||
|
||||
# ============================================================
|
||||
# Optional Polkit integration
|
||||
# ============================================================
|
||||
|
|
@ -1277,6 +1361,7 @@ install(TARGETS BastionGuard-usbd RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
|||
|
||||
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
# ======================
|
||||
# BankOpener (wrapper sandbox sicuro)
|
||||
# ======================
|
||||
|
|
@ -1337,6 +1422,8 @@ target_link_libraries(BastionGuard-bankgui
|
|||
bg_set_rpath(BastionGuard-bankgui)
|
||||
install(TARGETS BastionGuard-bankgui RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
||||
endif()
|
||||
|
||||
|
||||
# ======================
|
||||
# Pagamenti sicuri
|
||||
|
|
@ -1353,6 +1440,7 @@ install(TARGETS bastionguard-pacd RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
|||
|
||||
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF AND ENABLE_CEF_DAEMON)
|
||||
# ======================
|
||||
# BastionGuard CEF Proxy (bastionguard-cef)
|
||||
# ======================
|
||||
|
|
@ -1425,6 +1513,9 @@ bg_set_rpath(bastionguard-cef)
|
|||
|
||||
install(TARGETS bastionguard-cef RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
||||
endif()
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
# ======================
|
||||
# BastionGuard Secure Payments
|
||||
# - BastionGuard-secure (CLI opener)
|
||||
|
|
@ -1542,6 +1633,8 @@ endif()
|
|||
|
||||
install(TARGETS BastionGuard-secure-gui RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
||||
endif()
|
||||
|
||||
|
||||
# ======================
|
||||
# BastionGuard-mailproxy — proxy SMTP utente
|
||||
|
|
@ -2257,10 +2350,16 @@ install(FILES data/service/org.BastionGuard.RansomwareAlert.service
|
|||
install(FILES actions/policy/org.BastionGuard.policy
|
||||
FILES actions/policy/org.BastionGuard.ransomware.policy
|
||||
FILES actions/policy/org.BastionGuard.USBD.policy
|
||||
FILES actions/policy/eu.bastionguard.install-ca.policy
|
||||
DESTINATION /usr/share/polkit-1/actions
|
||||
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF AND ENABLE_SYSTEM_CA_INSTALL)
|
||||
install(FILES actions/policy/eu.bastionguard.install-ca.policy
|
||||
DESTINATION /usr/share/polkit-1/actions
|
||||
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
|
||||
)
|
||||
endif()
|
||||
|
||||
install(FILES actions/dbus/org.BastionGuard.USBD.conf
|
||||
DESTINATION /usr/share/dbus-1/system.d
|
||||
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
|
||||
|
|
@ -2289,9 +2388,11 @@ install(FILES data/sudoers/bastionguard-helper
|
|||
# ======================
|
||||
# Permission Policy – Bank helper
|
||||
# ======================
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
install(FILES data/sudoers/bastionguard-bank
|
||||
DESTINATION /etc/sudoers.d
|
||||
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
|
||||
endif()
|
||||
|
||||
# ======================
|
||||
# Permission Policy – Helper anti-phishing-update
|
||||
|
|
@ -2300,10 +2401,12 @@ install(FILES data/sudoers/bastionguard-phishing
|
|||
DESTINATION /etc/sudoers.d
|
||||
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF)
|
||||
install(PROGRAMS
|
||||
data/scripts/bank-helper
|
||||
DESTINATION /usr/bin/
|
||||
)
|
||||
endif()
|
||||
|
||||
# ======================
|
||||
# Services
|
||||
|
|
@ -2332,12 +2435,20 @@ install(FILES
|
|||
data/service/BastionGuard-ransomware-realtime-alert.service
|
||||
data/service/BastionGuard-ransomware-scanner.service
|
||||
data/service/BastionGuard-pacd.service
|
||||
data/service/BastionGuard-cef.service
|
||||
data/service/BastionGuard-mailproxy.service
|
||||
data/service/BastionGuard-user-session-watch.service
|
||||
DESTINATION /usr/lib/systemd/user
|
||||
)
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF AND ENABLE_CEF_DAEMON)
|
||||
install(FILES data/service/BastionGuard-cef.service
|
||||
DESTINATION /usr/lib/systemd/user
|
||||
)
|
||||
install(FILES data/service/BastionGuard-cef.service
|
||||
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/BastionGuard/data/service
|
||||
)
|
||||
endif()
|
||||
|
||||
|
||||
|
||||
# helper script to enable user agents for logged-in users
|
||||
|
|
@ -2352,6 +2463,12 @@ install(PROGRAMS
|
|||
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/BastionGuard/data/scripts
|
||||
)
|
||||
|
||||
if(ENABLE_EMBEDDED_CEF AND ENABLE_SYSTEM_CA_INSTALL)
|
||||
install(PROGRAMS data/scripts/install-ca-system.sh
|
||||
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/BastionGuard/data/scripts
|
||||
)
|
||||
endif()
|
||||
|
||||
install(PROGRAMS
|
||||
data/extension/bastionguard-tb-extension/install-tb-extension.sh
|
||||
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/BastionGuard/data/extension/bastionguard-tb-extension
|
||||
|
|
|
|||
BIN
src/Archivio.zip
BIN
src/Archivio.zip
Binary file not shown.
|
|
@ -86,18 +86,40 @@ namespace BastionGuard::Platform {
|
|||
const std::string id = distribution_id();
|
||||
|
||||
return id == "ubuntu" ||
|
||||
id == "linuxmint";
|
||||
id == "linuxmint";
|
||||
}
|
||||
|
||||
inline bool is_mageia() {
|
||||
return distribution_id() == "mageia";
|
||||
}
|
||||
|
||||
inline bool is_openmandriva() {
|
||||
const std::string id = distribution_id();
|
||||
|
||||
return id == "openmandriva" ||
|
||||
id == "openmandriva_lx";
|
||||
}
|
||||
|
||||
inline bool is_opensuse() {
|
||||
const std::string id = distribution_id();
|
||||
|
||||
return id == "opensuse-leap" ||
|
||||
id == "opensuse-tumbleweed" ||
|
||||
id == "opensuse";
|
||||
}
|
||||
|
||||
/*
|
||||
* Il daemon CEF e l'installazione della CA di sistema sono disabilitati
|
||||
* su Fedora/RHEL, Ubuntu e Linux Mint.
|
||||
* su Fedora/RHEL, Ubuntu, Linux Mint, Mageia, OpenMandriva e openSUSE.
|
||||
*
|
||||
* Debian non viene incluso.
|
||||
*/
|
||||
inline bool cef_daemon_supported() {
|
||||
return !is_fedora_rhel_family() &&
|
||||
!is_ubuntu_family();
|
||||
!is_ubuntu_family() &&
|
||||
!is_mageia() &&
|
||||
!is_openmandriva() &&
|
||||
!is_opensuse();
|
||||
}
|
||||
|
||||
#ifndef BASTIONGUARD_HAS_EMBEDDED_CEF
|
||||
|
|
|
|||
|
|
@ -374,11 +374,10 @@ WizardWindow::WizardWindow()
|
|||
|
||||
build_pages();
|
||||
|
||||
if ((BastionGuard::Platform::is_fedora_rhel_family() ||
|
||||
BastionGuard::Platform::is_ubuntu_family())) {
|
||||
if (!BastionGuard::Platform::cef_daemon_supported()) {
|
||||
m_chk_certs.set_active(false);
|
||||
m_chk_certs.set_sensitive(false);
|
||||
m_desc_certs.set_text(_("Installazione della CA di sistema e del daemon CEF disabilitata su Fedora, RHEL, AlmaLinux, Rocky Linux, Ubuntu e Linux Mint. Secure Browser e Bank GUI restano disponibili."));
|
||||
m_desc_certs.set_text(_("Installazione della CA di sistema e del daemon CEF disabilitata su Fedora, RHEL, AlmaLinux, Rocky Linux, Ubuntu, Linux Mint, Mageia, OpenMandriva e openSUSE. Secure Browser e Bank GUI restano disponibili."));
|
||||
}
|
||||
|
||||
set_page(0);
|
||||
|
|
@ -554,6 +553,8 @@ void WizardWindow::build_pages() {
|
|||
m_combo_os.append("auto", _("Rilevamento automatico"));
|
||||
m_combo_os.append("debian", "Debian / Ubuntu / Mint");
|
||||
m_combo_os.append("fedora", "Fedora / RHEL / CentOS / Alma / Rocky");
|
||||
m_combo_os.append("mageia", "Mageia");
|
||||
m_combo_os.append("openmandriva", "OpenMandriva");
|
||||
m_combo_os.append("arch", "Arch / Manjaro / Endeavour");
|
||||
m_combo_os.append("opensuse", "openSUSE / SLE");
|
||||
m_combo_os.append("gentoo", "Gentoo");
|
||||
|
|
@ -655,8 +656,7 @@ void WizardWindow::set_page(int idx) {
|
|||
? Glib::ustring("✔ ") + _("Firewall avanzato nftables (installazione e configurazione automatica)") + "\n"
|
||||
: Glib::ustring("✘ ") + _("Firewall avanzato nftables") + "\n";
|
||||
|
||||
if ((BastionGuard::Platform::is_fedora_rhel_family() ||
|
||||
BastionGuard::Platform::is_ubuntu_family())) {
|
||||
if (!BastionGuard::Platform::cef_daemon_supported()) {
|
||||
summary += Glib::ustring("⊘ ") + _("Installazione CA di sistema e daemon CEF disabilitati su questa distribuzione; Secure Browser e Bank GUI restano disponibili") + "\n";
|
||||
} else {
|
||||
summary += m_chk_certs.get_active()
|
||||
|
|
@ -825,11 +825,10 @@ void WizardWindow::worker_run() {
|
|||
}
|
||||
}
|
||||
|
||||
if (m_chk_certs.get_active() && !(BastionGuard::Platform::is_fedora_rhel_family() ||
|
||||
BastionGuard::Platform::is_ubuntu_family())) {
|
||||
if (m_chk_certs.get_active() && BastionGuard::Platform::cef_daemon_supported()) {
|
||||
gen_cert_commands(cmds);
|
||||
} else if (m_chk_certs.get_active()) {
|
||||
append_log(_("Certificati ignorati: installazione CA di sistema disabilitata su Fedora/RHEL/Alma/Rocky e Ubuntu/Linux Mint."));
|
||||
append_log(_("Certificati ignorati: installazione CA di sistema disabilitata su Fedora/RHEL/Alma/Rocky, Ubuntu/Linux Mint, Mageia, OpenMandriva e openSUSE."));
|
||||
}
|
||||
|
||||
if (m_chk_webconf.get_active()) {
|
||||
|
|
@ -1154,6 +1153,8 @@ std::string WizardWindow::detect_distro() const {
|
|||
if (id.find("debian") != std::string::npos || id.find("ubuntu") != std::string::npos || id.find("mint") != std::string::npos) return "debian";
|
||||
if (id.find("fedora") != std::string::npos || id.find("rhel") != std::string::npos || id.find("centos")!= std::string::npos
|
||||
|| id.find("almalinux")!=std::string::npos || id.find("rocky")!=std::string::npos) return "fedora";
|
||||
if (id.find("mageia") != std::string::npos) return "mageia";
|
||||
if (id.find("openmandriva") != std::string::npos || id.find("openmandriva_lx") != std::string::npos) return "openmandriva";
|
||||
if (id.find("arch") != std::string::npos || id.find("manjaro")!= std::string::npos || id.find("endeavour")!=std::string::npos) return "arch";
|
||||
if (id.find("suse") != std::string::npos) return "opensuse";
|
||||
if (id.find("gentoo") != std::string::npos) return "gentoo";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue