File tree Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -418,6 +418,14 @@ about possibly installed software on a developer machine or file names. Impact i
418
418
usually low, but it is very common.
419
419
420
420
421
+ postdebug
422
+ ---------
423
+
424
+ Some web frameworks show a debugging console when they receive an unexpected HTTP
425
+ method. This can often be triggered by sending a POST request to the main page. This
426
+ test looks for such debugging consoles from Laravel, Symfony, and Rails.
427
+
428
+
421
429
axfr
422
430
----
423
431
Original file line number Diff line number Diff line change @@ -785,6 +785,24 @@ def test_desktopini(url):
785
785
pout ("desktopini" , url + "/Desktop.ini" )
786
786
787
787
788
+ @DEFAULT
789
+ def test_postdebug (url ):
790
+ try :
791
+ r = pool .request ("POST" , url , retries = False , redirect = False )
792
+ data = r .data .decode ("ascii" , errors = "ignore" )
793
+ if (
794
+ "The POST method is not supported for" in data
795
+ and "Symfony\\ Component\\ HttpKernel\\ Exception" in data
796
+ ):
797
+ pout ("postdebug_laravel" , url + " POST" )
798
+ elif "Symfony Exception" in data and '<div class="exception-' in data :
799
+ pout ("postdebug_symfony" , url + " POST" )
800
+ elif "<title>Action Controller: Exception caught" in data :
801
+ pout ("postdebug_rails" , url + " POST" )
802
+ except (urllib3 .exceptions .HTTPError , UnicodeError , ConnectionRefusedError ):
803
+ pass
804
+
805
+
788
806
@DEFAULT
789
807
@HOSTNAME
790
808
def test_axfr (qhost ):
You can’t perform that action at this time.
0 commit comments