The following shell script is run by cron on a regular basis: x=$(find /home -name .rhost 2>/dev/null)
for i in $x; do
$y=$(echo $I | cut -d/ -f3);z=”$z $y”
rm $I;done
echo “Notice: $z” | mail [email protected]
Which best defines the action of this script?
A. Verify the existence of users’ .rhost files and removes the user.
B. Remove all .rhosts files and notify each user of your action.
C. Find all misplaced rhost files and remove them.
D. This script checks for the existence of .rhost files, deletes them and reports the offending user names to root.
E. Notify the root user of all .rhost files.
that should be a capital I in the for loop
for I in $x; do
linux, famously is sorta case sensitive….