Skip to content

Commit

Permalink
Merge pull request #683 from m-1-k-3/restart_emulation
Browse files Browse the repository at this point in the history
Little cleanups
  • Loading branch information
HoxhaEndri authored Jul 4, 2023
2 parents 374a928 + 3a18374 commit 2925ee7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/trivy-container-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
docker save -o vuln-image.tar embeddedanalyzer/emba
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@master
uses: aquasecurity/trivy-action@7b7aa264d83dc58691451798b4d117d53d21edfe
with:
input: /github/workspace/vuln-image.tar
timeout: "60m"
Expand Down
1 change: 1 addition & 0 deletions config/bin_version_strings.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ binutils;;gplv3;"\(GNU\ Binutils\ for\ Debian\)\ [0-9](\.[0-9]+)+?$";"sed -r 's/
bird;;unknown;"^BIRD\ version\ [0-9](\.[0-9]+)+?$";"sed -r 's/BIRD\ version\ ([0-9](\.[0-9]+)+?)$/bird:\1/'";
blkid;;unknown;"^blkid\ [0-9](\.[0-9]+)+?\ \(.*\)$";"sed -r 's/blkid\ ([0-9](\.[0-9]+)+?)\ .*/blkid:\1/'";
blockman;;unknown;"^blockman\ [0-9](\.[0-9]+)+?\.blockman\ build-[0-9]+$";"sed -r 's/blockman\ ([0-9](\.[0-9]+)+?)\..*/blockman:\1/'";
boa;;unknown;"Boa\ HTTPd\ [0-9](\.[0-9]+)+?(rc[0-9]+)?";"sed -r 's/Boa\ HTTPd\ ([0-9](\.[0-9]+)+?(rc[0-9]+)?)/boa:boa:\1/'";
booster;;unknown;"BoosterMainFunction:305:\ Version:\ [0-9](\.[0-9])+?";"sed -r 's/BoosterMainFunction:305:\ Version:\ ([0-9](\.[0-9]+)+?).*/booster:\1/'";
bootlogd;;unknown;"\ bootlogd\ [0-9](\.[0-9]+)+?\ ";"sed -r 's/\ bootlogd\ ([0-9](\.[0-9]+)+?)\ .*/bootlogd:\1/'";
bpalogin;;gplv2;"BPALogin\ v[0-9](\.[0-9])+?\ -\ portable\ BigPond\ Broadband\ login\ client$";"sed -r 's/BPALogin\ v([0-9](\.[0-9]+)+?)\ .*/bpalogin:\1/'";
Expand Down
5 changes: 3 additions & 2 deletions modules/L22_upnp_hnap_checks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ L22_upnp_hnap_checks() {

export UPNP_UP=0
export HNAP_UP=0
export JNAP_UP=0

if [[ "$SYS_ONLINE" -eq 1 ]] && [[ "$TCP" == "ok" ]]; then
module_log_init "${FUNCNAME[0]}"
Expand Down Expand Up @@ -131,7 +132,7 @@ check_basic_hnap_jnap() {
curl -v -L --max-redir 0 -f -m 5 -s -X POST -H "${JNAP_ACTION}" -d "{}" https://"${IP_ADDRESS_}":"${PORT}"/JNAP/ >> "$LOG_PATH_MODULE"/jnap-discovery-check.txt || true
fi

if [[ -f "$LOG_PATH_MODULE"/hnap-discovery-check.txt ]]; then
if [[ -s "$LOG_PATH_MODULE"/hnap-discovery-check.txt ]]; then
print_ln
# tee -a "$LOG_FILE" < "$LOG_PATH_MODULE"/hnap-discovery-check.txt
sed 's/></>\n</g' "$LOG_PATH_MODULE"/hnap-discovery-check.txt | tee -a "$LOG_FILE"
Expand All @@ -140,7 +141,7 @@ check_basic_hnap_jnap() {
HNAP_UP=$(grep -c "HNAP1" "$LOG_PATH_MODULE"/hnap-discovery-check.txt || true)
fi

if [[ -f "$LOG_PATH_MODULE"/jnap-discovery-check.txt ]]; then
if [[ -s "$LOG_PATH_MODULE"/jnap-discovery-check.txt ]]; then
print_ln
tee -a "$LOG_FILE" < "$LOG_PATH_MODULE"/jnap-discovery-check.txt
print_ln
Expand Down

0 comments on commit 2925ee7

Please sign in to comment.