make_result( array( 'id' => 'debug_log_exists', 'title' => __( 'Debug log file exists in wp-content', 'aipatch-security-scanner' ), 'description' => sprintf( /* translators: %s: Human-readable debug.log file size. */ __( 'A debug.log file (%s) was found. This file might be accessible publicly.', 'aipatch-security-scanner' ), size_format( $size ) ), 'severity' => 'high', 'confidence' => 'high', 'category' => 'configuration', 'why_it_matters' => __( 'The debug log can contain sensitive information like file paths, database queries, plugin errors, and user data.', 'aipatch-security-scanner' ), 'recommendation' => __( 'Delete the debug.log file and block access to it via .htaccess. If debugging is needed, use a custom log path outside the web root.', 'aipatch-security-scanner' ), 'dismissible' => true, 'evidence' => sprintf( 'debug.log found (%s)', size_format( $size ) ), 'meta' => array( 'file_size' => $size ), ) ), ); } }