| @@ -792,24 +792,8 @@ | ||
| 792 | 792 | return false; |
| 793 | 793 | } |
| 794 | 794 | |
| 795 | 795 | /** |
| 796 | - * Check for PHP execution in uploads | |
| 797 | - * | |
| 798 | - * @return string|false Error message or false if safe. | |
| 799 | - */ | |
| 800 | - private function check_php_in_uploads() { | |
| 801 | - $uri = $this->inspection_haystack(); | |
| 802 | - | |
| 803 | - // Check if accessing PHP in uploads directory | |
| 804 | - if ( preg_match( '/\/wp-content\/uploads\/.*\.ph(p[345s]?|tml)/i', $uri ) ) { | |
| 805 | - return __( 'PHP execution in uploads blocked', 'vigilante' ); | |
| 806 | - } | |
| 807 | - | |
| 808 | - return false; | |
| 809 | - } | |
| 810 | - | |
| 811 | - /** | |
| 812 | 796 | * Check for bad bots |
| 813 | 797 | * |
| 814 | 798 | * @return string|false Error message or false if safe. |
| 815 | 799 | */ |
| @@ -996,10 +980,10 @@ | ||
| 996 | 980 | |
| 997 | 981 | foreach ( $bad_bots as $bot ) { |
| 998 | 982 | if ( strpos( $user_agent, $bot ) !== false ) { |
| 999 | 983 | return sprintf( |
| 1000 | - /* translators: %s: Bot name */ | |
| 1001 | - __( 'Bad bot blocked: %s', 'vigilante' ), | |
| 984 | + /* translators: %s: The entry of the bad bots list that was found in the User-Agent */ | |
| 985 | + __( 'Bad bot blocked: the User-Agent contains "%s"', 'vigilante' ), | |
| 1002 | 986 | $bot |
| 1003 | 987 | ); |
| 1004 | 988 | } |
| 1005 | 989 | } |