unsupported
  !   ˆ981Ãa–Ãa¾”*j"Tâ€rãMÜmµ1hßÂ Õ    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
 <head>
  <title>Index of /FSS-BCZ/root/opt/alt/python-internal/lib64/python3.11/wsgiref</title>
 </head>
 <body>
<h1>Index of /FSS-BCZ/root/opt/alt/python-internal/lib64/python3.11/wsgiref</h1>
  <table>
   <tr><th valign="top">&nbsp;</th><th><a href="?C=N;O=A">Name</a></th><th><a href="?C=M;O=A">Last modified</a></th><th><a href="?C=S;O=A">Size</a></th><th><a href="?C=D;O=A">Description</a></th></tr>
   <tr><th colspan="5"><hr></th></tr>
<tr><td valign="top">&nbsp;</td><td><a href="/FSS-BCZ/root/opt/alt/python-internal/lib64/python3.11/">Parent Directory</a>       </td><td>&nbsp;</td><td align="right">  - </td><td>&nbsp;</td></tr>
<tr><td valign="top">&nbsp;</td><td><a href="__pycache__/">__pycache__/</a>           </td><td align="right">2025-08-05 04:30  </td><td align="right">  - </td><td>&nbsp;</td></tr>
   <tr><th colspan="5"><hr></th></tr>
</table>
</body></html>
  "   	ˆl–ß=¿Jµ5*q@³p@¸ÛÊbÑ¿Áƒp ¿Ã Ô    	#!/usr/bin/bash
# vi:syntax=sh

set -eo pipefail

progname=$(basename "$0")

sub_help(){
    echo "Usage: $progname <subcommand> [options]"
    echo ""
    echo "Subcommands:"
    echo "    init   [username ...]"
    echo "    disable"
    echo ""
    echo "For help with each subcommand run:"
    echo "$progname <subcommand> -h|--help"
    echo ""
}

subcommand=$1
KCARE_PROFILE='/etc/profile.d/kernelcare.sh'
KCARE_SUDOERS='/etc/sudoers.d/kernelcare'
TMP_SUDOERS="/root/kernelcare.sudoers.tmp"
KCARE_FALCON_OVERRIDE_DIR='/etc/systemd/system/falcon-sensor.service.d'
KCARE_FALCON_OVERRIDE="${KCARE_FALCON_OVERRIDE_DIR}/kcare-scanner-interface.conf"


function clean_env_file(){
    [ -f "$1" ] && sed -i '/kpatch_package/d' "$1" || :
}

function patch_env_file(){
    clean_env_file "$1"
    echo "$2${KCARE_PACKAGE_ENV}$3" >> "$1"
}

function patch_falcon(){
    # CrowdStrike Falcon's unit file declares no EnvironmentFile, so a
    # systemd drop-in is the only supported way to inject LD_PRELOAD.
    command -v systemctl >/dev/null 2>&1 || return 0
    systemctl cat falcon-sensor.service >/dev/null 2>&1 || return 0

    mkdir -p "${KCARE_FALCON_OVERRIDE_DIR}"
    cat > "${KCARE_FALCON_OVERRIDE}" << FALCONOVERRIDE
# Managed by kcare-scanner-interface â€” do not edit manually
[Service]
Environment="${KCARE_PACKAGE_ENV}"
FALCONOVERRIDE
    chmod 0644 "${KCARE_FALCON_OVERRIDE}"
    systemctl daemon-reload >/dev/null 2>&1 || :
    echo "Restart falcon-sensor.service to apply: systemctl restart falcon-sensor.service"
}

function unpatch_falcon(){
    [ -f "${KCARE_FALCON_OVERRIDE}" ] || return 0
    rm -f "${KCARE_FALCON_OVERRIDE}"
    rmdir "${KCARE_FALCON_OVERRIDE_DIR}" 2>/dev/null || :
    command -v systemctl >/dev/null 2>&1 && systemctl daemon-reload >/dev/null 2>&1 || :
    echo "Restart falcon-sensor.service to drop the LD_PRELOAD wrapper: systemctl restart falcon-sensor.service"
}

function patch_agents(){
    # Patch environment of the Qualys agent
    patch_env_file "/etc/sysconfig/qualys-cloud-agent" 'export ' '.qualys'
    patch_env_file "/etc/default/qualys-cloud-agent" '' '.qualys'
    # Patch environment of the Nessus agent
    patch_env_file "/etc/sysconfig/nessusagent" '' ''
    # Patch environment of the CrowdStrike Falcon agent
    patch_falcon
}


function patch_bashrc(){
    BASHRC=$1
    SOURCE_LINE="test -f ${KCARE_PROFILE} && source ${KCARE_PROFILE} > /dev/null ||:"
    test -f "${BASHRC}" && sed -i "2 i${SOURCE_LINE}" "${BASHRC}" 2> /dev/null || :
}

function patch_user(){
    KCARE_SCANNER_USER=$1

    # Setup scanner interface for one user defined in $KCARE_SCANNER_USER
    if [ "$KCARE_SCANNER_USER" == '*' ]; then
        cat >> ${KCARE_PROFILE} << PROFILECONTENT
export ${KCARE_PACKAGE_ENV}
PROFILECONTENT
    else
        # Ensure profile script always exits with code 0 to avoid breaking job execution
        cat >> ${KCARE_PROFILE} << PROFILECONTENT
[ \$(logname 2>/dev/null || echo \${SUDO_USER:-\$USER}) = ${KCARE_SCANNER_USER} ] &&