You are not logged in.

#1 2023-03-25 14:58:21

fistrosan
Member
Registered: 2020-04-01
Posts: 171

problems installing Cortex XRD

Hi all,

My employer demands that all computers connected to our network must install the Cortex XRD software for virus and malware protection. See: https://www.paloaltonetworks.com/cyberpedia/what-is-xdr

Does anyone know about this software and how to install it in arch ? They do support Linux with several packages (.deb and .rpm mostly) but nothing that can be readily be used with arch. For generic distros (in which they include arch) they provide an installation script (.sh) but this one fails because it does not detect that I already have openssl installed. For instance:

$which openssl
/usr/sbin/openssl

$sudo ./cortex-8.0.0.94458.sh 
[sudo] password for XXXXXXXX: 
Verifying archive integrity... All good.
Uncompressing Cortex XDR 8.0.0.94458 installer  100%  
Active kernel LSM: capability,landlock,lockdown,yama,bpf
[ 1] Checking prerequisites
Verifying Ubuntu [!] Detected non-numeric distro version ("rolling")
0 (dpkg) packages:
  * openssl ... MISSING
Prerequisites not met. Please install missing packages
  Aborting.

So I have been trying to use debtap to install create a .xz package out of a .deb package. It does create the package but later, when trying to install it with pacman -U it fails because the scripts have problems with the syntax.

sudo pacman -U cortex-agent-8.0.0.94458-1-x86_64.pkg.tar.zst
[sudo] password for XXXXXX: 
loading packages...
resolving dependencies...
looking for conflicting packages...

Packages (1) cortex-agent-8.0.0.94458-1

Total Installed Size:  55.24 MiB

:: Proceed with installation? [Y/n] Y
(1/1) checking keys in keyring                                                                                     [#####################################################################] 100%
(1/1) checking package integrity                                                                                   [#####################################################################] 100%
(1/1) loading package files                                                                                        [#####################################################################] 100%
(1/1) checking for file conflicts                                                                                  [#####################################################################] 100%
(1/1) checking available disk space                                                                                [#####################################################################] 100%
:: Processing package changes...
stty: 'standard input': Inappropriate ioctl for device
/tmp/alpm_MZvnCc/.INSTALL: line 1325: syntax error near unexpected token `}'
/tmp/alpm_MZvnCc/.INSTALL: line 1325: `}'
stty: 'standard input': Inappropriate ioctl for device
error: command failed to execute correctly
(1/1) installing cortex-agent                                                                                      [#####################################################################] 100%
stty: 'standard input': Inappropriate ioctl for device
/tmp/alpm_kkdCHE/.INSTALL: line 1325: syntax error near unexpected token `}'
/tmp/alpm_kkdCHE/.INSTALL: line 1325: `}'
/usr/bin/bash: line 1: post_install: command not found
error: command failed to execute correctly
:: Running post-transaction hooks...
(1/1) Refreshing PackageKit...

Any ideas how to deal with this ? I am being forced to use this and I would hate to change to a different distro just because I can't get it running in arch.

Offline

#2 2023-04-04 09:08:05

tux@work
Member
Registered: 2023-04-04
Posts: 1

Re: problems installing Cortex XRD

Hi,

i have the same problem. I was able to set the environment variables, but still get the message "mission openssl". I installed the rpm package as follows:

mkdir -p /tmp/cortex
cp ./cortex*.rpm /tmp/cortex

touch PKGBUILD

nano PKGBUILD

---------------------------------------

pkgname=cortex
pkgver=1
pkgrel=1
pkgdesc="cortex xdr"
arch=('x86_64')

#depends=('gtk2' 'hicolor-icon-theme' 'dbus-glib' 'traceroute')
#optdepends=('gconf: for shell integration')

source=('cortex-8.0.0.94458.rpm')

sha256sums=('SKIP')

package() {
  find $srcdir/ -mindepth 1 -maxdepth 1 -type d | xargs cp -r -t "$pkgdir"
}

----------------------------------

makepkg -si


So all files and scrips installed to /opt/traps

But when you go to /opt/traps and  execute "setup.sh" you got the same error.


best regards

Offline

#3 2023-04-04 09:59:30

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 14,249

Re: problems installing Cortex XRD

Is there a publicly available download for those packages or for the install.sh script ?

Without such info I can make a guess :
Archlinux uses openssl 3 which is fairly new and not compatible with the previous version . Does installing https://archlinux.org/packages/core/x86_64/openssl-1.1/ help ?


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#4 2023-04-22 07:26:56

fistrosan
Member
Registered: 2020-04-01
Posts: 171

Re: problems installing Cortex XRD

Hi Lone_Wolf, I think I missed your answer so sorry for the late reply. I was also thinking that openssl 3 might be the issue here. How would I go about installing openssl 1 instead ? can I have both coexisting in my system simultaneously ? should I get rid of openssl 3 before ? if so, would this not break my system ? pacman -Sii openssl lists at least 50 packages that depend on it so I don't want to mess this up.

Offline

#5 2023-04-22 15:00:47

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 14,249

Re: problems installing Cortex XRD

Both openssl versions have their own folder structure and coexist fine.


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#6 2023-04-22 16:40:33

fistrosan
Member
Registered: 2020-04-01
Posts: 171

Re: problems installing Cortex XRD

Ok, so I downloaded and untar openssl-1 in /usr/ ... the package was flagged out of date, but I guess that is ok ? Anyhow, a bunch of staff was installed in my / tree (which I guess it's normal) ... when I run the installer it still fails. There are a whole bunch of scripts that have to be run. I copy below the first one that fails (others might fail later on, but let us go one step at a time).

#! /bin/bash

[[ -n "${TRACE:-}" ]] && set -x

set -u

_check_kernel_version() {
    declare -r kernel_major_min=2
    declare -r kernel_minor_min=6
    declare -r kernel_patch_min=32

    declare -r kernel_version="$(uname -r)"
    if [[ ! "$kernel_version" =~ ([0-9]+)\.([0-9]+)\.([0-9]+).* ]]; then
        return 1
    fi

    declare -r major="${BASH_REMATCH[1]}"
    declare -r minor="${BASH_REMATCH[2]}"
    declare -r patch="${BASH_REMATCH[3]}"

    if [[ "$major" -lt "$kernel_major_min" ]]; then
        return 1
    elif [[ "$major" -eq "$kernel_major_min" ]];then
        if [[ "$minor" -lt "$kernel_minor_min" ]]; then
            return 1
        elif [[ "$minor" -eq "$kernel_minor_min" ]]; then
            if [[ "$patch" -lt "$kernel_patch_min" ]]; then
                return 1
            fi
        fi
    fi

    return 0#! /bin/bash

[[ -n "${TRACE:-}" ]] && set -x

set -u

_check_kernel_version() {
    declare -r kernel_major_min=2
    declare -r kernel_minor_min=6
    declare -r kernel_patch_min=32

    declare -r kernel_version="$(uname -r)"
    if [[ ! "$kernel_version" =~ ([0-9]+)\.([0-9]+)\.([0-9]+).* ]]; then
        return 1
    fi

    declare -r major="${BASH_REMATCH[1]}"
    declare -r minor="${BASH_REMATCH[2]}"
    declare -r patch="${BASH_REMATCH[3]}"

    if [[ "$major" -lt "$kernel_major_min" ]]; then
        return 1
    elif [[ "$major" -eq "$kernel_major_min" ]];then
        if [[ "$minor" -lt "$kernel_minor_min" ]]; then
            return 1
        elif [[ "$minor" -eq "$kernel_minor_min" ]]; then
            if [[ "$patch" -lt "$kernel_patch_min" ]]; then
                return 1
            fi
        fi
    fi

    return 0
}

_rpm_get_desired_arch() {
    arch=$(rpm -q --qf "%{arch}\n" "$1" 2>/dev/null)
    if [[ "$?" -ne 0 ]]; then
        echo "UNKNOWN"
    elif [[ "$arch" == "noarch" ]]; then
        echo "noarch"
    elif [[ "$arch" == "aarch64" ]]; then
        echo "aarch64"
    else
        echo "x86_64"
    fi
}

_rpm_verify_pkg() {
    arch=$(_rpm_get_desired_arch "$1")
    result=$(rpm -q --qf "%{name}\n" "$1.$arch" 2>/dev/null)
    if [[ "$result" != "$1" ]]; then
        return 1
    fi
}

_rpm_get_pkg_version() {
    arch=$(_rpm_get_desired_arch "$1")
    result=$(rpm -q --qf "%{version}\n" "$1.$arch" 2>/dev/null)
    echo "$result"
}

_deb_get_desired_arch() {
    arch=$(dpkg-query -W -f='${Architecture}\n' "$1" 2>/dev/null)
    if [[ "$?" -ne 0 ]]; then
        echo "UNKNOWN"
    elif [[ "$arch" == "all" ]]; then
        echo "all"
    elif [[ "$arch" == "arm64" ]]; then
        echo "arm64"
    else
        echo "amd64"
    fi
}

_deb_verify_pkg() {
    arch=$(_deb_get_desired_arch "$1")
    result=$(dpkg-query -W -f='${Status}\n' "${1}:$arch" 2>/dev/null)
    if [[ "$result" != "install ok installed" && "$result" != "hold ok installed" ]]; then
        return 1
    fi
}

_deb_get_pkg_version() {
    arch=$(_deb_get_desired_arch "$1")
    result=$(dpkg-query -W -f='${Version}\n' "${1}:$arch" 2>/dev/null)
    echo "$result"
}

_resolve_distribution_operations() {
    case "$distro" in
        "$g_distro_name_redhat"    | \
        "$g_distro_name_centos"    | \
        "$g_distro_name_oracle"    | \
        "$g_distro_name_amazon"    | \
        "$g_distro_name_suse"      | \
        "$g_distro_name_opensuse"  | \
        "$g_distro_name_almalinux" | \
        "$g_distro_name_rockylinux")
            verify_pkg() { _rpm_verify_pkg "$1"; }
            get_pkg_version() { _rpm_get_pkg_version "$1"; }
            ;;

        "$g_distro_name_ubuntu" | \
        "$g_distro_name_debian" | \
        "$g_distro_name_thinpro")
            verify_pkg() { _deb_verify_pkg "$1"; }
            get_pkg_version() { _deb_get_pkg_version "$1"; }
            ;;

        *)

            verify_pkg() { return 1; }
            get_pkg_version() { echo ""; }
            ;;
    esac
}

_verify_required_libraries() {
    declare -a prereq_packages=(
        "openssl"
    )

    # Resolve distribution name, version and operations.
    declare -r distro="$(resolve_distro_name)"
    declare -r os_version="$(resolve_distro_major_version)"
    _resolve_distribution_operations

    if [[ "$distro" == "suse" && "$os_version" -eq 11 ]]; then
        prereq_packages+=("openssl-certs")
    else
        prereq_packages+=("ca-certificates")
    fi

    if $has_selinux; then
        case "$distro" in
            "$g_distro_name_redhat" | \
            "$g_distro_name_centos" | \
            "$g_distro_name_oracle" | \
            "$g_distro_name_almalinux" | \
            "$g_distro_name_rockylinux")
                if [[ "$os_version" -le 7 ]]; then
                    prereq_packages+=("policycoreutils-python")
                else
                    prereq_packages+=("policycoreutils-python-utils")
                fi

                if [[ "$os_version" -ge 7 ]]; then
                    prereq_packages+=("selinux-policy-devel")
                fi
                ;;

            "$g_distro_name_amazon")
                if [[ "$os_version" -eq 2 ]]; then
                    prereq_packages+=("policycoreutils-python" "selinux-policy-devel")
                else
                    prereq_packages+=("policycoreutils-python" "selinux-policy")
                fi
                ;;

            "$g_distro_name_suse" | \
            "$g_distro_name_opensuse")
                prereq_packages+=("policycoreutils-python" "selinux-policy-devel")
                ;;

            "$g_distro_name_ubuntu" | \
            "$g_distro_name_debian" | \
            "$g_distro_name_thinpro")
                prereq_packages+=("policycoreutils" "selinux-policy-dev")
                ;;

            *)
                ;;
        esac
    fi

    case "$distro" in
        "$g_distro_name_redhat" | \
        "$g_distro_name_centos" | \
        "$g_distro_name_oracle" | \
        "$g_distro_name_almalinux" | \
        "$g_distro_name_rockylinux")
            echo "Verifying RHEL/CentOS/Oracle/AlmaLinux/RockyLinux $os_version (rpm) packages:"
            ;;

        "$g_distro_name_amazon")
            echo "Verifying Amazon $os_version (rpm) packages:"
            ;;

        "$g_distro_name_suse" | \
        "$g_distro_name_opensuse")
            echo "Verifying OpenSuSE/SLES $os_version (rpm) packages:"
            ;;

        "$g_distro_name_ubuntu")
            echo "Verifying Ubuntu $os_version (dpkg) packages:"
            ;;

        "$g_distro_name_debian")
            echo "Verifying Debian $os_version (dpkg) packages:"
            ;;

        "$g_distro_name_thinpro")
            echo "Verifying ThinPro $os_version (dpkg) packages:"
            ;;

        *)
            notice_bad "Cannot verify packages for distro ($distro)"
            return 1
            ;;
    esac

    for package in "${prereq_packages[@]}"; do
        echo -n "  * $package ... "
        verify_pkg "$package"
        if [[ $? -eq 0 ]]; then
            notice_good "OK"
        else
            notice_bad "MISSING"
            return 1
        fi
    done

    declare -r openssl_version="$(get_pkg_version "openssl")"

    if [[ "$distro" == "suse" && "$os_version" -eq 11 ]]; then
        declare -r openssl_min_ver="0.9.8"
    else
        declare -r openssl_min_ver="1.0.0"
    fi

    if ! _is_version_ge "$openssl_version" "$openssl_min_ver"; then
        error "Installed 'openssl' version $openssl_version is not supported (<$openssl_min_ver)"
        return 1
    fi

    case "$distro" in
        "$g_distro_name_redhat" | \
        "$g_distro_name_centos" | \
        "$g_distro_name_oracle" | \
        "$g_distro_name_amazon" | \
        "$g_distro_name_almalinux" | \
        "$g_distro_name_rockylinux")
            if [[ ! -f "/etc/pki/tls/certs/ca-bundle.trust.crt" ]]; then
                error "Trusted certificate store missing"
                return 1
            fi
            ;;

        "$g_distro_name_ubuntu" | \
        "$g_distro_name_debian" | \
        "$g_distro_name_thinpro")
            if [[ ! -f "/etc/ssl/certs/ca-certificates.crt" ]]; then
                error "Trusted certificate store missing"
                return 1
            fi
            ;;

        "$g_distro_name_suse")
            if [[ ! -d "/etc/ssl/certs/" ]]; then
                error "Trusted certificate directory missing"
                return 1
            fi
            ;;

        *)
            echo "Skipping certificate store verification"
            ;;
    esac

    return 0
}

pre_install() {
    declare -r should_verify_requirements="$1"

    if [[ "$EUID" -ne 0 ]]; then
        echo "Please run Cortex XDR installer as root"
        return 1
    fi

    if ! _check_kernel_version; then
        echo "System kernel version is not supported"
        return 1
    fi

    if $should_verify_requirements; then
        step_start "Checking prerequisites"

        _verify_required_libraries
        if [[ "$?" -ne 0 ]]; then
            echo "Prerequisites not met. Please install missing packages"
            return 1
        fi

        step_end
    else
        step_start "Skipping prerequisites check"

    fi

    if ! is_valid_proxy_list "$proxy_list"; then
        error "Invalid proxy list: $proxy_list"
        return 1
    fi

    if [[ -z "$install_path" ]]; then
        install_path="$deploy_dir"
    fi

    if $upgrade_traps; then
        if [[ "$deploy_dir" != "$install_path" ]]; then
            echo "Custom installation path used only on initial install. Ignoring."
        fi
        return 0
    fi

    if $btrfs_subvol; then
        step_start "Creating btrfs subvolume at $deploy_dir"
        if ! _create_btrfs_subvolume "$deploy_dir"; then
            return 1
        fi
        step_end
    fi

    if [[ -e "$deploy_dir" ]]; then
        if [[ "$deploy_dir" != "$install_path" ]]; then

            echo "Found existing installation path at: $deploy_dir, ignoring custom path"
        fi
        return 0
    fi

    if ! _create_deploy_dir; then

        return 1
    fi

    return 0
}

}

_rpm_get_desired_arch() {
    arch=$(rpm -q --qf "%{arch}\n" "$1" 2>/dev/null)
    if [[ "$?" -ne 0 ]]; then
        echo "UNKNOWN"
    elif [[ "$arch" == "noarch" ]]; then
        echo "noarch"
    elif [[ "$arch" == "aarch64" ]]; then
        echo "aarch64"
    else
        echo "x86_64"
    fi
}

_rpm_verify_pkg() {
    arch=$(_rpm_get_desired_arch "$1")
    result=$(rpm -q --qf "%{name}\n" "$1.$arch" 2>/dev/null)
    if [[ "$result" != "$1" ]]; then
        return 1
    fi
}

_rpm_get_pkg_version() {
    arch=$(_rpm_get_desired_arch "$1")
    result=$(rpm -q --qf "%{version}\n" "$1.$arch" 2>/dev/null)
    echo "$result"
}

_deb_get_desired_arch() {
    arch=$(dpkg-query -W -f='${Architecture}\n' "$1" 2>/dev/null)
    if [[ "$?" -ne 0 ]]; then
        echo "UNKNOWN"
    elif [[ "$arch" == "all" ]]; then
        echo "all"
    elif [[ "$arch" == "arm64" ]]; then
        echo "arm64"
    else
        echo "amd64"
    fi
}

_deb_verify_pkg() {
    arch=$(_deb_get_desired_arch "$1")
    result=$(dpkg-query -W -f='${Status}\n' "${1}:$arch" 2>/dev/null)
    if [[ "$result" != "install ok installed" && "$result" != "hold ok installed" ]]; then
        return 1
    fi
}

_deb_get_pkg_version() {
    arch=$(_deb_get_desired_arch "$1")
    result=$(dpkg-query -W -f='${Version}\n' "${1}:$arch" 2>/dev/null)
    echo "$result"
}

_resolve_distribution_operations() {
    case "$distro" in
        "$g_distro_name_redhat"    | \
        "$g_distro_name_centos"    | \
        "$g_distro_name_oracle"    | \
        "$g_distro_name_amazon"    | \
        "$g_distro_name_suse"      | \
        "$g_distro_name_opensuse"  | \
        "$g_distro_name_almalinux" | \
        "$g_distro_name_rockylinux")
            verify_pkg() { _rpm_verify_pkg "$1"; }
            get_pkg_version() { _rpm_get_pkg_version "$1"; }
            ;;

        "$g_distro_name_ubuntu" | \
        "$g_distro_name_debian" | \
        "$g_distro_name_thinpro")
            verify_pkg() { _deb_verify_pkg "$1"; }
            get_pkg_version() { _deb_get_pkg_version "$1"; }
            ;;

        *)

            verify_pkg() { return 1; }
            get_pkg_version() { echo ""; }
            ;;
    esac
}

_verify_required_libraries() {
    declare -a prereq_packages=(
        "openssl"
    )

    # Resolve distribution name, version and operations.
    declare -r distro="$(resolve_distro_name)"
    declare -r os_version="$(resolve_distro_major_version)"
    _resolve_distribution_operations

    if [[ "$distro" == "suse" && "$os_version" -eq 11 ]]; then
        prereq_packages+=("openssl-certs")
    else
        prereq_packages+=("ca-certificates")
    fi

    if $has_selinux; then
        case "$distro" in
            "$g_distro_name_redhat" | \
            "$g_distro_name_centos" | \
            "$g_distro_name_oracle" | \
            "$g_distro_name_almalinux" | \
            "$g_distro_name_rockylinux")
                if [[ "$os_version" -le 7 ]]; then
                    prereq_packages+=("policycoreutils-python")
                else
                    prereq_packages+=("policycoreutils-python-utils")
                fi

                if [[ "$os_version" -ge 7 ]]; then
                    prereq_packages+=("selinux-policy-devel")
                fi
                ;;

            "$g_distro_name_amazon")
                if [[ "$os_version" -eq 2 ]]; then
                    prereq_packages+=("policycoreutils-python" "selinux-policy-devel")
                else
                    prereq_packages+=("policycoreutils-python" "selinux-policy")
                fi
                ;;

            "$g_distro_name_suse" | \
            "$g_distro_name_opensuse")
                prereq_packages+=("policycoreutils-python" "selinux-policy-devel")
                ;;

            "$g_distro_name_ubuntu" | \
            "$g_distro_name_debian" | \
            "$g_distro_name_thinpro")
                prereq_packages+=("policycoreutils" "selinux-policy-dev")
                ;;

            *)
                ;;
        esac
    fi

    case "$distro" in
        "$g_distro_name_redhat" | \
        "$g_distro_name_centos" | \
        "$g_distro_name_oracle" | \
        "$g_distro_name_almalinux" | \
        "$g_distro_name_rockylinux")
            echo "Verifying RHEL/CentOS/Oracle/AlmaLinux/RockyLinux $os_version (rpm) packages:"
            ;;

        "$g_distro_name_amazon")
            echo "Verifying Amazon $os_version (rpm) packages:"
            ;;

        "$g_distro_name_suse" | \
        "$g_distro_name_opensuse")
            echo "Verifying OpenSuSE/SLES $os_version (rpm) packages:"
            ;;

        "$g_distro_name_ubuntu")
            echo "Verifying Ubuntu $os_version (dpkg) packages:"
            ;;

        "$g_distro_name_debian")
            echo "Verifying Debian $os_version (dpkg) packages:"
            ;;

        "$g_distro_name_thinpro")
            echo "Verifying ThinPro $os_version (dpkg) packages:"
            ;;

        *)
            notice_bad "Cannot verify packages for distro ($distro)"
            return 1
            ;;
    esac

    for package in "${prereq_packages[@]}"; do
        echo -n "  * $package ... "
        verify_pkg "$package"
        if [[ $? -eq 0 ]]; then
            notice_good "OK"
        else
            notice_bad "MISSING"
            return 1
        fi
    done

    declare -r openssl_version="$(get_pkg_version "openssl")"

    if [[ "$distro" == "suse" && "$os_version" -eq 11 ]]; then
        declare -r openssl_min_ver="0.9.8"
    else
        declare -r openssl_min_ver="1.0.0"
    fi

    if ! _is_version_ge "$openssl_version" "$openssl_min_ver"; then
        error "Installed 'openssl' version $openssl_version is not supported (<$openssl_min_ver)"
        return 1
    fi

    case "$distro" in
        "$g_distro_name_redhat" | \
        "$g_distro_name_centos" | \
        "$g_distro_name_oracle" | \
        "$g_distro_name_amazon" | \
        "$g_distro_name_almalinux" | \
        "$g_distro_name_rockylinux")
            if [[ ! -f "/etc/pki/tls/certs/ca-bundle.trust.crt" ]]; then
                error "Trusted certificate store missing"
                return 1
            fi
            ;;

        "$g_distro_name_ubuntu" | \
        "$g_distro_name_debian" | \
        "$g_distro_name_thinpro")
            if [[ ! -f "/etc/ssl/certs/ca-certificates.crt" ]]; then
                error "Trusted certificate store missing"
                return 1
            fi
            ;;

        "$g_distro_name_suse")
            if [[ ! -d "/etc/ssl/certs/" ]]; then
                error "Trusted certificate directory missing"
                return 1
            fi
            ;;

        *)
            echo "Skipping certificate store verification"
            ;;
    esac

    return 0
}

pre_install() {
    declare -r should_verify_requirements="$1"

    if [[ "$EUID" -ne 0 ]]; then
        echo "Please run Cortex XDR installer as root"
        return 1
    fi

    if ! _check_kernel_version; then
        echo "System kernel version is not supported"
        return 1
    fi

    if $should_verify_requirements; then
        step_start "Checking prerequisites"

        _verify_required_libraries
        if [[ "$?" -ne 0 ]]; then
            echo "Prerequisites not met. Please install missing packages"
            return 1
        fi

        step_end
    else
        step_start "Skipping prerequisites check"

    fi

    if ! is_valid_proxy_list "$proxy_list"; then
        error "Invalid proxy list: $proxy_list"
        return 1
    fi

    if [[ -z "$install_path" ]]; then
        install_path="$deploy_dir"
    fi

    if $upgrade_traps; then
        if [[ "$deploy_dir" != "$install_path" ]]; then
            echo "Custom installation path used only on initial install. Ignoring."
        fi
        return 0
    fi

    if $btrfs_subvol; then
        step_start "Creating btrfs subvolume at $deploy_dir"
        if ! _create_btrfs_subvolume "$deploy_dir"; then
            return 1
        fi
        step_end
    fi

    if [[ -e "$deploy_dir" ]]; then
        if [[ "$deploy_dir" != "$install_path" ]]; then

            echo "Found existing installation path at: $deploy_dir, ignoring custom path"
        fi
        return 0
    fi

    if ! _create_deploy_dir; then

        return 1
    fi

    return 0
}

And so, the current errors comes because it cannot detect which distro is installed and crashes. I suppose I could create a case "$distro" in for arch and make it point to the right location of the openssl ca-cartificates and see what happens. It will probably crash somewhere down the line ... so I am now just wondering how much I want to put into this ...

Offline

#7 2023-04-23 07:07:56

fistrosan
Member
Registered: 2020-04-01
Posts: 171

Re: problems installing Cortex XRD

So, I give up on this. Changing the script to detect arch linux and point to the right location of the certificates is of little use, because later on another script performs a checksum and if anything was changed before it crashes saying the files have been corrupted. I could perhaps remove the checksum or whatever, but this is just going too deep into the rabbit hole because it's too much work and there is no guarantee that it is going to work. So, for the moment all I can do is submit a ticket to the cortex dudes and see if they can do something about it.

Offline

#8 2023-04-23 10:20:57

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 14,249

Re: problems installing Cortex XRD

Forget the installer script, it is way to complex and fragile to adjust to a rolling release system.

There are (atleast) 2 approaches that can help to get software only available as binary rpm/deb archives working on archlinux .

- rpm
inside the. rpm archive there should be a file with .spec as extension that contains the instructions to install the software .
Using that file as base to create an archlinux PKGBUILD is doable .

- deb
.deb archives typically use helper programs (like debhelper) to determine where to install stuff and what dependencies are needed . The differences between archlinux and debian/ubuntu are too big for those helper programs .
There are however tools that assist in converting  .deb archives to archives suitable for archlinux pacman .
https://aur.archlinux.org/packages/debtap seems to be the best one for that purpose .

The description of the cortex xrd software suggests it interacts with OSes on a low level , so getting this to work on archlinux will likely require arch users and cortex devs working together. I suggest you mention this thread in the ticket.

Last edited by Lone_Wolf (2023-04-23 10:22:27)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#9 2023-05-30 22:33:07

lichenenthusiast
Member
Registered: 2021-03-14
Posts: 3

Re: problems installing Cortex XRD

I had the same issue and was able to install using the shell script provided by Cortex if I added "--skip-prereq" to the top of the "/etc/panw/cortex.conf" file.

Offline

#10 2023-05-30 22:35:35

2ManyDogs
Forum Fellow
Registered: 2012-01-15
Posts: 4,646

Re: problems installing Cortex XRD

The OP has not been back since April 22, so I am going to consider this thread abandoned and close it now.

fistrosan, if you come back and want this thread reopened, use the Report link to let Staff know.

Offline

Board footer

Powered by FluxBB