All Projects → al0ne → Nmap_bypass_ids

al0ne / Nmap_bypass_ids

Nmap&Zmap特征识别,绕过IDS探测

Projects that are alternatives of or similar to Nmap bypass ids

altprobe
collector for XDR and security posture service
Stars: ✭ 62 (-70.05%)
Mutual labels:  nmap, suricata
Biu
网络资产发现、漏洞扫描
Stars: ✭ 199 (-3.86%)
Mutual labels:  nmap
Vulscan
Advanced vulnerability scanning with Nmap NSE
Stars: ✭ 2,305 (+1013.53%)
Mutual labels:  nmap
Nndefaccts
nnposter's alternate fingerprint dataset for Nmap script http-default-accounts
Stars: ✭ 180 (-13.04%)
Mutual labels:  nmap
Ip Attack
Auto IP or Domain Attack Tool ( #1 )
Stars: ✭ 162 (-21.74%)
Mutual labels:  nmap
Webmap
A Python tool used to automate the execution of the following tools : Nmap , Nikto and Dirsearch but also to automate the report generation during a Web Penetration Testing
Stars: ✭ 188 (-9.18%)
Mutual labels:  nmap
T14m4t
Automated brute-forcing attack tool.
Stars: ✭ 160 (-22.71%)
Mutual labels:  nmap
Py Idstools
idstools: Snort and Suricata Rule and Event Utilities in Python (Including a Rule Update Tool)
Stars: ✭ 205 (-0.97%)
Mutual labels:  suricata
Abuse Ssl Bypass Waf
Bypassing WAF by abusing SSL/TLS Ciphers
Stars: ✭ 201 (-2.9%)
Mutual labels:  bypass
Ivre
Network recon framework, published by @cea-sec & @ANSSI-FR. Build your own, self-hosted and fully-controlled alternatives to Shodan / ZoomEye / Censys and GreyNoise, run your Passive DNS service, collect and analyse network intelligence from your sensors, and much more!
Stars: ✭ 2,331 (+1026.09%)
Mutual labels:  nmap
Stracciatella
OpSec-safe Powershell runspace from within C# (aka SharpPick) with AMSI, Constrained Language Mode and Script Block Logging disabled at startup
Stars: ✭ 171 (-17.39%)
Mutual labels:  bypass
Aboutsecurity
A list of payload and bypass lists for penetration testing and red team infrastructure build.
Stars: ✭ 166 (-19.81%)
Mutual labels:  bypass
Security Scripts
A collection of security related Python and Bash shell scripts. Analyze hosts on generic security vulnerabilities. Wrapper around popular tools like nmap (portscanner), nikto (webscanner) and testssl.sh (SSL/TLS scanner)
Stars: ✭ 188 (-9.18%)
Mutual labels:  nmap
Asnlookup
Leverage ASN to look up IP addresses (IPv4 & IPv6) owned by a specific organization for reconnaissance purposes, then run port scanning on it.
Stars: ✭ 163 (-21.26%)
Mutual labels:  nmap
Discover
Custom bash scripts used to automate various penetration testing tasks including recon, scanning, parsing, and creating malicious payloads and listeners with Metasploit.
Stars: ✭ 2,548 (+1130.92%)
Mutual labels:  nmap
Antimalware Research
Research on Anti-malware and other related security solutions
Stars: ✭ 163 (-21.26%)
Mutual labels:  bypass
Sharesniffer
Network share sniffer and auto-mounter for crawling remote file systems
Stars: ✭ 168 (-18.84%)
Mutual labels:  nmap
Briarids
An All-In-One home intrusion detection system (IDS) solution for the Raspberry PI.
Stars: ✭ 187 (-9.66%)
Mutual labels:  suricata
Cve 2020 16898
CVE-2020-16898 (Bad Neighbor) Microsoft Windows TCP/IP Vulnerability Detection Logic and Rule
Stars: ✭ 207 (+0%)
Mutual labels:  suricata
Awesome Nmap Grep
Awesome Nmap Grep
Stars: ✭ 203 (-1.93%)
Mutual labels:  nmap

Nmap_Bypass_IDS

扫描参数:nmap -sS -sV -O -vv 1.1.1.1

nmap 系统识别绕过ids检测

nmap使用-O参数扫描时会发送tcp,udp,icmp 然后在根据响应的tcp window,TTL,IPID等对比指纹库识别操作系统,IDS识别nmap扫描一般都是根据UDP data区域填充的'C'字符串,ICMP填充的是0(正常windows下是a-z,Linux下是0-9)

alert udp $EXTERNAL_NET 10000: -> $HOME_NET 10000: (msg:"ET SCAN NMAP OS Detection Probe"; dsize:300; content:"CCCCCCCCCCCCCCCCCCCC"; fast_pattern:only; content:"CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC"; depth:255; content:"CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC"; within:45; classtype:attempted-recon; sid:2018489; rev:3; metadata:created_at 2014_05_20, updated_at 2014_05_20;)

https://raw.githubusercontent.com/nmap/nmap/master/osscan2.cc

static u8 patternbyte = 0x43; /* character 'C' / 替换为 static u8 patternbyte = 0x46; / character 'F' */

nmap UA 修改

alert http $EXTERNAL_NET any -> $HOME_NET any (msg:"ET SCAN Nmap Scripting Engine User-Agent Detected (Nmap Scripting Engine)"; flow:to_server,established; content:"Mozilla/5.0 (compatible|3b| Nmap Scripting Engine"; nocase; http_user_agent; depth:46; reference:url,doc.emergingthreats.net/2009358; classtype:web-application-attack; sid:2009358; rev:5; metadata:created_at 2010_07_30, updated_at 2010_07_30;)

修改nselib/http.lua

USER_AGENT = stdnse.get_script_args('http.useragent') or "Mozilla/5.0 (compatible; )"

TCP window 修改tcp window 窗口大小

nmap 默认扫描的tcp window size 大小是1024,将其修改为10240来绕过ids

alert tcp $EXTERNAL_NET any -> $HOME_NET any (msg:"ET SCAN NMAP -sS window 1024"; fragbits:!D; dsize:0; flags:S,12; ack:0; window:1024; threshold: type both, track by_dst, count 1, seconds 60; reference:url,doc.emergingthreats.net/2009582; classtype:attempted-recon; sid:2009582; rev:3; metadata:created_at 2010_07_30, updated_at 2010_07_30;)

tcpip.cc:729: tcp->th_win = htons(1024); /* Who cares */

if (window)

tcp->th_win = htons(10240); /* Who cares */

修改nmap-service-probes

alert tcp $EXTERNAL_NET any -> $HOME_NET $HTTP_PORTS (msg:"ET SCAN NMAP SIP Version Detect OPTIONS Scan"; flow:established,to_server; content:"OPTIONS sip|3A|nm SIP/"; depth:19; classtype:attempted-recon; sid:2018317; rev:1; metadata:created_at 2014_03_25, updated_at 2014_03_25;)

-Probe TCP SIPOptions q|OPTIONS sip:nm SIP/2.0\r\nVia: SIP/2.0/TCP nm;branch=foo\r\nFrom: sip:[email protected];tag=root\r\nTo: sip:[email protected]\r\nCall-ID: 50000\r\nCSeq: 42 OPTIONS\r\nMax-Forwards: 70\r\nContent-Length: 0\r\nContact: sip:[email protected]\r\nAccept: application/sdp\r\n\r\n|

去掉OPTIONS sip

修改3389 cookie

nmap-service-probes
Probe TCP TerminalServerCookie q|\x03\0\0*%\xe0\0\0\0\0\0Cookie: mstshash=nmap\r\n\x01\0\x08\0\x03\0\0\0|
nselib/rdp.lua
local cookie = "mstshash=nmap"

Zmap识别

很多网络扫描器会使用固定的tcp window或者ipid,这些都可以作为特征识别的一部分。
例如在使用zmap扫描时,通过抓包分析发现zmap使用了固定的IPID 54321以及固定的window值 65535,那么我可以写一个IDS规则来检测它

alert tcp any any -> any any (msg:"Detect ZMAP scan"; dsize:0; flags:S; window:65535; id:54321; threshold: type both, track by_src, count 60, seconds 60; sid:19010201; rev:1; metadata:created_at 2019_01_02, by al0ne;)

alert 是记录告警日志, tcp $EXTERNAL_NET any -> $HOME_NET any 这些对应着协议 源ip 源端口 方向 目标ip 目标端口,这里是匹配任意ip和任意端口, dsize代表tcp data区大小扫描时没有附加其他数据所以为0,flags:S 是指tcp的flags为s即三次握手时syn请求,并且计算阀值60秒内出现60才告警

修改绕过
src/probe_modules/packet.c

tcp_header->th_win = htons(65535);
iph->ip_id = htons(54321);
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].