Skip to content

Commit

Permalink
update syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
dolevf committed Apr 1, 2024
1 parent 6b19550 commit 467be22
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ch04/host_monitor_notification.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ TO_ADDR="[email protected]"
while true; do
echo "Performing an ARP scan against ${NETWORK}..."
sudo arp-scan -x -I ${INTERFACE} ${NETWORK} | while read -r line; do
host="$(echo "${line}" | awk '{print $1}')"
host=$(echo "${line}" | awk '{print $1}')
if ! grep -q "${host}" "${KNOWN_HOSTS}"; then
echo "Found a new host: ${host}!"
echo "${host}" >> "${KNOWN_HOSTS}"
Expand Down
4 changes: 2 additions & 2 deletions ch04/port_watchdog.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash
LOG_FILE="watchdog.log"
IP_ADDRESS="$1"
WATCHED_PORT="$2"
IP_ADDRESS="${1}"
WATCHED_PORT="${2}"

service_discovery(){
local host
Expand Down

0 comments on commit 467be22

Please sign in to comment.