File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change 4
4
5
5
use Illuminate \Console \Application ;
6
6
use Illuminate \Foundation \Application as Foundation ;
7
+ use Illuminate \Routing \Router ;
7
8
use Illuminate \Support \Arr ;
8
9
use Illuminate \Support \Facades \Artisan ;
9
10
use Illuminate \Support \Facades \DB ;
23
24
use Native \Laravel \Events \EventWatcher ;
24
25
use Native \Laravel \Exceptions \Handler ;
25
26
use Native \Laravel \GlobalShortcut as GlobalShortcutImplementation ;
27
+ use Native \Laravel \Http \Middleware \PreventRegularBrowserAccess ;
26
28
use Native \Laravel \Logging \LogWatcher ;
27
29
use Native \Laravel \PowerMonitor as PowerMonitorImplementation ;
28
30
use Native \Laravel \Windows \WindowManager as WindowManagerImplementation ;
@@ -84,6 +86,11 @@ public function packageRegistered()
84
86
Handler::class
85
87
);
86
88
89
+ // Automatically prevent browser access
90
+ $ this ->app ->make (Router::class)->pushMiddlewareToGroup ('web ' , [
91
+ PreventRegularBrowserAccess::class,
92
+ ]);
93
+
87
94
Application::starting (function ($ app ) {
88
95
$ app ->resolveCommands ([
89
96
LoadStartupConfigurationCommand::class,
You can’t perform that action at this time.
0 commit comments