| Server IP : 152.69.216.235 / Your IP : 80.80.80.28 Web Server : Apache/2.4.37 (Oracle Linux Server) System : Linux ust-wp4-prod 5.15.0-310.184.5.2.el8uek.x86_64 #2 SMP Wed Jul 9 16:08:33 PDT 2025 x86_64 User : apache ( 48) PHP Version : 8.4.10 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /bin/ |
Upload File : |
#!/bin/bash
# Interactive script to check if other users can read WordPress files
echo "đ§ WordPress File Permission Checker"
read -rp "Enter your WordPress path (e.g. /home/ajels/public_html): " WP_PATH
if [ ! -d "$WP_PATH" ]; then
echo "â The path $WP_PATH does not exist. Exiting."
exit 1
fi
echo
echo "đ Checking for world-readable files under $WP_PATH ..."
echo
# Find files that are readable by "others"
find "$WP_PATH" -type f -perm -o+r -exec ls -l {} \; > /tmp/world_readable.txt
if [[ -s /tmp/world_readable.txt ]]; then
echo "â ī¸ These files are world-readable (others can read):"
cat /tmp/world_readable.txt
else
echo "â
No world-readable files found!"
fi
echo
echo "đ Checking for world-readable wp-config.php ..."
if [ -f "$WP_PATH/wp-config.php" ]; then
if [ $(stat -c "%A" "$WP_PATH/wp-config.php" | cut -c8) == "r" ]; then
echo "â ī¸ wp-config.php is world-readable!"
else
echo "â
wp-config.php is NOT world-readable."
fi
else
echo "âšī¸ wp-config.php not found in $WP_PATH"
fi
echo
echo "â
Scan complete."