惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

酷 壳 – CoolShell
酷 壳 – CoolShell
H
Hacker News: Front Page
P
Palo Alto Networks Blog
T
ThreatConnect
Apple Machine Learning Research
Apple Machine Learning Research
博客园_首页
T
True Tiger Recordings
P
Privacy & Cybersecurity Law Blog
B
Blog
IT之家
IT之家
Last Week in AI
Last Week in AI
F
Full Disclosure
Hacker News: Ask HN
Hacker News: Ask HN
C
Comments on: Blog
Microsoft Azure Blog
Microsoft Azure Blog
C
Cybersecurity and Infrastructure Security Agency CISA
Microsoft Security Blog
Microsoft Security Blog
博客园 - 【当耐特】
N
News and Events Feed by Topic
NISL@THU
NISL@THU
腾讯CDC
雷峰网
雷峰网
Security Latest
Security Latest
李成银的技术随笔
M
Microsoft Research Blog - Microsoft Research
L
LangChain Blog
L
Lohrmann on Cybersecurity
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
C
Check Point Blog
Y
Y Combinator Blog
Recent Announcements
Recent Announcements
博客园 - Franky
N
News | PayPal Newsroom
V
V2EX
A
About on SuperTechFans
The Register - Security
The Register - Security
月光博客
月光博客
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Google Online Security Blog
Google Online Security Blog
MyScale Blog
MyScale Blog
Cisco Talos Blog
Cisco Talos Blog
Vercel News
Vercel News
WordPress大学
WordPress大学
C
Cyber Attacks, Cyber Crime and Cyber Security
The Hacker News
The Hacker News
IntelliJ IDEA : IntelliJ IDEA – the Leading IDE for Professional Development in Java and Kotlin | The JetBrains Blog
IntelliJ IDEA : IntelliJ IDEA – the Leading IDE for Professional Development in Java and Kotlin | The JetBrains Blog
爱范儿
爱范儿
A
Arctic Wolf
L
LINUX DO - 最新话题
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More

Black Hills Information Security, Inc.

Same Problem, Different Angles: When Red Team and Blue Team Actually Talk to Each Other How to Identify and Exploit New Vulnerabilities Swapper – A Pure Regex Match/Replace Burp Extension A Practical Guide to BloodHound Data Collection Network Engineering Basics Signed, Trusted, and Abused: Proxy Execution via WebView2 Getting Started In Pentesting – Advice From The BHIS Pentest Lead Cloud Security: Tips and Resources for Securing the Cloud Lessons From A Chatbot Incident How to Lead Effective Tabletops Understanding GRC: How to Navigate Risks and Compliance Standards The “P” in PAM is for Persistence: Linux Persistence Technique Malware Analysis: How to Analyze and Understand Malware OSINT: How to Find, Use, and Control Open-Source Intelligence What to Do with Your First Home Lab When the SOC Goes to Deadwood: A Night to Remember Social Engineering and Microsoft SSPR: The Road to Pwnage is Paved with Good Intentions Common Cyber Threats Finding the Right Penetration Testing Company Deceptive-Auditing: An Active Directory Honeypots Tool The Curious Case of the Comburglar How to Set Smart Goals (That Actually Work For You) Inside the BHIS SOC: A Conversation with Hayden Covington Abusing Delegation with Impacket (Part 3): Resource-Based Constrained Delegation Why You Got Hacked – 2025 Super Edition Abusing Delegation with Impacket (Part 2): Constrained Delegation Abusing Delegation with Impacket (Part 1): Unconstrained Delegation GoSpoof – Turning Attacks into Intel Model Context Protocol (MCP) Bypassing WAFs Using Oversized Requests Getting Started with AI Hacking Part 2: Prompt Injection Wrangling Windows Event Logs with Hayabusa & SOF-ELK (Part 2) DomCat: A Domain Categorization Tool Wrangling Windows Event Logs with Hayabusa & SOF-ELK (Part 1) Microsoft Store and WinGet: Security Risks for Corporate Environments Default Web Content MailFail Commonly Abused Administrative Utilities: A Hidden Risk to Enterprise Security Stop Spoofing Yourself! Disabling M365 Direct Send Bypassing CSP with JSONP: Introducing JSONPeek and CSP B Gone Offensive Tooling Cheatsheets: An Infosec Survival Guide Resource DNS Triage Cheatsheet GraphRunner Cheatsheet Burp Suite Cheatsheet Impacket Cheatsheet Wireshark Cheatsheet Hashcat Cheatsheet EyeWitness Cheatsheet Nmap Cheatsheet Netcat (nc) Cheatsheet Hunt for Weak Spots in Your Wireless Network with Airodump-ng from the Aircrack-ng Suite Detecting ADCS Privilege Escalation Vulnerability Scanning with Nmap Getting Started with NetExec: Streamlining Network Discovery and Access How to Use Dirsearch Augmenting Penetration Testing Methodology with Artificial Intelligence – Part 3: Arcanum Cyber Security Bot How to Design and Execute Effective Social Engineering Attacks by Phone Abusing S4U2Self for Active Directory Pivoting Why Use a Macro Pad? Espanso: Text Replacement, the Easy Way Caging Copilot: Lessons Learned in LLM Security Augmenting Penetration Testing Methodology with Artificial Intelligence – Part 2: Copilot Augmenting Penetration Testing Methodology with Artificial Intelligence – Part 1: Burpference Intercepting Traffic for Mobile Applications that Bypass the System Proxy How to Root Android Phones Communicating Security to the C-Suite: A Strategic Approach Offline Memory Forensics With Volatility Getting Started with AI Hacking: Part 1 Go-Spoof: A Tool for Cyber Deception How to Test Adversary-in-the-Middle Without Hacking Tools Canary in the Code: Alert()-ing on XSS Exploits How to Hack Wi-Fi with No Wi-Fi Why Your Org Needs a Penetration Test Program Burp Suite Extension: Copy For Light at the End of the Dark Web Wi-Fi Forge: Practice Wi-Fi Security Without Hardware Avoiding Dirty RAGs: Retrieval-Augmented Generation with Ollama and LangChain Gone Phishing: Installing GoPhish and Creating a Campaign 5 Things We Are Going to Continue to Ignore in 2025 John Strand’s 5 Phase Plan For Starting in Computer Security Questions From a Beginner Threat Hunter GRC for Security Managers: From Checklists to Influence AI Large Language Models and Supervised Fine Tuning Attack Tactics 9: Shadow Creds for PrivEsc w/ Kent & Jordan One Active Directory Account Can Be Your Best Early Warning Introduction to Zeek Log Analysis Indecent Exposure: Your Secrets are Showing Creating Burp Extensions: A Beginner’s Guide Pitting AI Against AI: Using PyRIT to Assess Large Language Models (LLMs) The Top Ten List of Why You Got Hacked This Year (2023/2024) ICS Hard Knocks: Mitigations to Scenarios Found in ICS/OT Backdoors & Breaches Intro to Data Analytics Using SQL Finding Access Control Vulnerabilities with Autorize The Detection Engineering Process Cyber Risk Lessons We Can Learn From Hurricane Preparedness Intro to Desktop Application Testing Methodology What Is Penetration Testing? Adversary in the Middle (AitM): Post-Exploitation Pentesting, Threat Hunting, and SOC: An Overview QEMU, MSYS2, and Emacs: Open-Source Solutions to Run Virtual Machines on Windows
How to Bypass Web-Proxy Filtering
2017-04-13 · via Black Hills Information Security, Inc.

Brian Fehrman //

Someone recently posed a question to BHIS about creating C2 channels in environments where heavily restrictive egress filtering is being utilized. Testers at BHIS, and in the industry as a whole, routinely run into this type of scenario. BHIS strongly encourages the use of egress filtering. As with many other security approaches, however, it is important to realize that this is just one piece of the overall security puzzle.

There are multiple ways to get around heavy egress-filtering (thanks to Beau for the links and insights in this section). In some cases, tools such as ICMPSploit [1] can be used to create C2 channels using the ICMP protocol. DNScat is a well-known tool that utilizes DNS requests and responses for C2 traffic. For this blog, we are going to focus solely on environments that are only allowing web-based traffic in and out of the environment. We will place an additional restriction on this scenario and assume that the environment also uses web-proxy filtering. It’s becoming more common to see companies not only block known bad sites but also block access to sites that have not received a categorization (e.g., Shopping, Financial, Sports, etc.) Even in this type of environment, there are numerous ways to establish C2 channels. Some of the methods include leveraging Gmail [2] and Outlook [3]. Domain-fronting via CDN services is also becoming increasingly popular [4].

I would like to focus on a web-proxy filtering bypass method that is known as domain-categorization take-over (thanks to harmj0y for the idea). I will walk you through the process of getting your own categorized domain and talk about some of the ways you can utilize it.

The first step is to find a recently expired domain that received a “good” categorization before it expired. The idea is that if you re-register a domain shortly after its previous owner failed to renew it, the categorization that was given to that domain will remain intact. How do we go about doing that? Easy!! Head on over to the site located at https://www.expireddomains.net. Now, you can use this service without signing up for anything. I suggest taking just a few minutes to sign up for a free account. With a registered account, you are afforded access to a lot more content than you do if you just browse anonymously. After logging in, you should see something similar to the screenshot below. I’ve highlighted the main area of interest. Click on one of the domain suffixes (e.g., “Deleted .info Domains”). The .com sites will likely be the most expensive to register. I typically go for .info, which can usually be bought for about $1/year.

After clicking a Deleted Domain suffix, you will be taken to a page that shows recently expired domains with that suffix and a lot of information to go along with it. What does all of it mean? Well, I will talk about what I feel are the most important statistics. First, click on the “Show Filter” option.

The first thing that I like to do is to check the “no Adult Names” box. We don’t pass judgment here, but web-proxy filters sure do! Next, I check the “only available Domains” box to ensure that domains that are currently registered do not appear in the list. The last change that I make is to select the “SimilarWeb Top Country” to be the country in which my target resides. This can help to reduce the suspicion of web-proxy filters. Once you’re satisfied with the filter options, click the “Apply Filter” button towards the bottom of the page.

Next, click on the “SimilarWeb” heading to sort the expired domains by their SimilarWeb ranking. Essentially, the lower the number the more “reputable” the site. Once I’ve applied the sorting, I start clicking through the SimilarWeb rating for the domains until I find one that has been assigned a category. In this case, clicking the SimilarWeb link for gtavdata.info shows that this site was categorized as “Reference->Maps” site. Seems innocuous enough for our needs!

Now that we’ve found a suitable categorized-domain, we need to register it. I suggest using https://www.namesilo.com since it has a nice interface, seems to keep the domain categorization intact, and provides free WHOIS privacy. We don’t need hosting or anything fancy, just something to register the domain and set the A record for the domain. NameSilo also makes it easy to set up Office 365 Mail with your domain but that is a discussion for another blog post. Just type in the name of the domain that you found in the previous step and register away. Make sure to pick the correct domain extension (e.g., .info, .com, .net, etc.) or else the trick likely won’t work.

After registering the domain name, sign in to namesilo.com and head to the DNS settings for that domain. The sequence of images below shows the general steps to get there.

Once you’ve found the DNS settings, click the edit button next to the first A record in the list. Change the IP address of that A record to be the IP address of your C2/testing server and then click submit button.

Next, delete the other three default DNS records that NameSilo created for you so that you are left with only the A record that you just edited in the previous step.

Now, we patiently wait for the A record changes to propagate to the public. Namesilo.com seems to propagate the changes within fifteen minutes in most cases. Keep checking for the update by using your favorite DNS resolution tool against your new domain. In the image below, you can see that I’ve used dig to verify that gtavdata.info now points to my C2 server.

The next step that I usually take is to generate a valid, signed SSL-certificate for the new domain. Having a trusted certificate to use for encrypting your traffic will add to the ability to bypass traffic-filtering mechanisms, help protect any sensitive data that might be transferred, and it can also evade some anti-virus tools that would otherwise see the unencrypted payload coming across the network. I suggest logging into your C2 server and then checking out Carrie’s awesome blog post on how to do this quickly and for free! [5]

After generating your shiny-new SSL certificate, you’re ready to use your categorized domain-name for testing! Continue reading Carrie’s post to see how to use your domain with PowerShell Empire.

You can also use your certificate and categorized domain with meterpreter and metasploit. Below is an example of using msfvenom to generate an HTA payload for my domain.

Before starting a listener for meterpreter, you might want to host your payload so that you can transfer it into your testing environment. You might also have other tools that you’d like to have on your testing system for the assessment. Apache is one easy way to do this that takes advantage of your certificate and domain. One suggestion is to create a folder in the /var/www/html directory on your system. For this example, let’s call it serverfolder.

mkdir /var/www/html/serverfolder

Copy your payload file and other tools to the directory that you just created. After copying the files, make sure that the Apache service is running. In the image below, I’ve copied the met_pay.hta payload file and the PowerLine toolset (teaser:upcoming webcast!) to my serverfolder directory.

You can now reach your files by opening a web browser and typing https://yourdomainname.net/serverfolder.

The next task we will do is to create a listener for our meterpreter payload. After downloading the files to your testing system, kill the Apache service on your server and start-up msfconsole.

Issue the commands shown in the screenshot below. Make sure to replace the handlersslcert value with the path to your certificate file.

Head back to the testing system on which you downloaded the payload and run it. Head back over to your server and enjoy the new session that was created using your categorized domain and signed SSL-certificate.

Follow Brian on the Twitters: @fullmetalcache

Shout-outs: Carrie Roberts, Sally Vandeven, Derek Banks, Beau Bullock, harmj0y (and APT team), and others that I’m probably forgetting…

[1] http://www.labofapenetrationtester.com/2015/05/week-of-powershell-shells-day-5.html

[2] https://github.com/byt3bl33d3r/gcat

[3] https://github.com/colemination/PowerOutlook

[4] https://blog.cobaltstrike.com/2017/02/06/high-reputation-redirectors-and-domain-fronting/

[5] http://www.blackhillsinfosec.com/?p=5447



Ready to learn more?

Level up your skills with affordable classes from Antisyphon!

Pay-Forward-What-You-Can Training

Available live/virtual and on-demand