missing_direct_file_access_protection

Missing direct file access protection

A PHP file in the plugin can be loaded directly instead of through WordPress.

medium weight

Why It Shows Up

Plugin Check found a PHP file without an early guard such as an ABSPATH check. Without that guard, a browser or script can request the file by path.

Why It Matters

Direct access can run code outside the normal WordPress bootstrap, expose output, or trigger assumptions about loaded functions, permissions, and request context.

How to Fix

  • Add a guard near the top of PHP files that are not intended to be requested directly.
  • Use `if ( ! defined( 'ABSPATH' ) ) { exit; }` before the file performs work or sends output.
  • Keep template partials and bootstrap files protected too, not only the main plugin file.

Notes

  • Files that are deliberately public endpoints should route through WordPress APIs or explicitly validate the request before doing work.

Affected Plugins

RankPluginScoreErrorsWarningsInstallsAddedUpdatedTop Issue
#1001SureDash – Community, Courses & Member Dashboard254228081k+Non-prefixed global variable
#1002OttoKit: All-in-One Automation Platform251,5581,82590k+Missing direct file access protection
#1003Survey Maker by AYS255672,3976k+Non-prefixed global variable
#1004TablePress – Tables in WordPress made easy258472,174600k+Non-prefixed global variable
#1005Tamara Checkout256012282k+Exception output is not escaped
#1006Taskbuilder – Project Management & Task Management Tool With Kanban Board251274,332800Non-prefixed global variable
#1007Tax Exemption for WooCommerce255521,402700Non-prefixed global variable
#1008TemplateSpare – 1000+ WordPress Starter Templates & Full Site Migration Tool | 1-Click Import/Export & No-Code Builder257051,58710k+Non-prefixed global variable
#1009Themify Event Post253971433k+Output is not escaped
#1010Timeline Express255311479k+Text Domain Mismatch
#1011Toocheke Companion254291,2271k+Non-prefixed global variable
#1012Travelly – Tour & Travel Booking Manager for WooCommerce | Tour & Hotel Booking Plugin251737261k+Non-prefixed global variable
#1013Tourfic – AI Powered Travel Booking, Hotel Booking & Car Rental WordPress Plugin251192,7042k+Non-prefixed global variable
#1014TrackShip for WooCommerce254059546k+Non-prefixed global variable
#1015TranslatePress – Translate Multilingual sites with AI Translation254991,639400k+Non-prefixed hook name
#1016Spectra Legacy – Gutenberg Blocks252533,2261m+Non-prefixed global variable
#1017Ultimate Blocks – 25+ Gutenberg Blocks for Block Editor256911,58150k+Non-prefixed global variable
#1018Ultimate Bootstrap Elements for Elementor256,3261226k+Text Domain Mismatch
#1019Social Media Share Buttons & Social Sharing Icons252,4331,383100k+Unsafe printing function
#1020Social Share Icons & Social Share Buttons252,3651,35710k+Output is not escaped
#1021Vayu Blocks – Website Builder for the Gutenberg Block Editor251742331k+Text Domain Mismatch
#1022VikAppointments Services Booking Calendar259,7535,207500Output is not escaped
#1023VikBooking Hotel Booking Engine & PMS2513,2518,3168k+Output is not escaped
#1024VikRentCar Car Rental Management System255,5375,0484k+Non-prefixed global variable
#1025VikRestaurants Table Reservations and Take-Away2511,6444,932600Output is not escaped
#10263D viewer by Visody258321,3221k+Non-prefixed global variable
#1027WC Disable Zoom / Lightbox features255291,297700Non-prefixed global variable
#1028Product Customer List for WooCommerce256101,3349k+Non-prefixed global variable
#1029Webcomic25593308600Output is not escaped
#1030weDocs: AI Powered Knowledge Base, Docs, Documentation, Wiki & AI Chatbot252795184k+Non-prefixed global variable
#1031weForms – Easy Drag & Drop Contact Form Builder For WordPress2591645010k+Output is not escaped
#1032Advanced Shipment Tracking for WooCommerce2549970460k+Non-prefixed global variable
#1033Secure Gateway for Authorize.net and WooCommerce by Pledged Plugins259071,41810k+Non-prefixed global variable
#1034Bulk Edit Products for WooCommerce – WP Sheet Editor2595796810k+Text Domain Mismatch
#1035Bulk Edit Coupons for WooCommerce – WP Sheet Editor251,022982500Text Domain Mismatch
#1036WFatture for WooCommerce Fattureincloud25229774800Non-prefixed global variable
#1037XT Floating Cart for WooCommerce251,2321,9854k+Non-prefixed global variable
#1038PDF Builder for WooCommerce. Create invoices,packing slips and more253725032k+Non-prefixed global variable
#1039Product Table for WooCommerce251838965k+Non-prefixed global variable
#1040Pay with Vipps and MobilePay for WooCommerce258465145k+Output is not escaped
#1041Wordfence Login Security2524841860k+Output is not escaped
#1042WordPress Importer252381102m+Output is not escaped
#1043WP 2FA – Two-factor authentication for WordPress25283716100k+Non-prefixed global variable
#1044WP Airbnb Review Slider253256461k+Non-prefixed global variable
#1045Super Page Cache – Cloudflare Cache, Page Speed & Core Web Vitals2514335760k+Input is not sanitized
#1046Comments Extra Fields For Post,Pages and CPT25577418500Text Domain Mismatch
#1047WP Coupons and Deals – WordPress Coupon Plugin259141,4601k+Non-prefixed global variable
#1048WP-DownloadManager256075083k+Unsafe printing function
#1049WP Review Slider251,1862,2796k+Non-prefixed global variable
#1050WP Go Maps – Google Map, OpenStreetMap, Leaflet Map254,9961,008300k+Unsafe printing function