Exploit databaseDownload repository ZIP
GH-51b9dee0a9fc2b7176517ada2bbd6d8e
2dukes/cyber-range-framework
Sources for CVE-2021-44228
465 sourcesPreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source
Repository files3
2dukes/cyber-range-frameworkRevision 7888f66930ff
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
project/scenarios/log4j/root/usr/local/bin/docker-healthcheck.sh
Shell · 1,012 bytes#!/usr/bin/env bash
# entrypoint-functions.sh script for UniFi Docker container
# License: Apache-2.0
# Github: https://github.com/goofball222/unifi
HEALTHCHECK_VERSION="1.0.1"
# Last updated date: 2019-12-06
BASEDIR="/usr/lib/unifi"
DATADIR=${BASEDIR}/data
[ ! -f ${DATADIR}/system.properties ] || api_port=$(grep "^[^#;]" ${DATADIR}/system.properties | sed -n 's/unifi.http.port=\([0-9]\+\)/\1/p')
api_port=${api_port:-8080}
http_code=$(curl -s --connect-timeout 1 -o /dev/null -w "%{http_code}" http://localhost:${api_port}/status)
#MAX_WAIT=25
#for i in `seq 1 ${MAX_WAIT}` ; do
# if [ "${http_code}" != "200" ]; then
# sleep 1 http_code=$(curl -s --connect-timeout 1 -o /dev/null -w "%{http_code}" http://localhost:${api_port}/status)
# else
# break
# fi
#done
if [ "${http_code}" != "200" ]; then
echo "Error: UniFi API http status code ${http_code}, expecting 200"
exit 1
else
echo "UniFi API http status code ${http_code}: OK"
exit 0
fi