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

推荐订阅源

WordPress大学
WordPress大学
The Cloudflare Blog
大猫的无限游戏
大猫的无限游戏
小众软件
小众软件
V
Visual Studio Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 司徒正美
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
酷 壳 – CoolShell
酷 壳 – CoolShell
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
月光博客
月光博客
The GitHub Blog
The GitHub Blog
L
LangChain Blog
D
DataBreaches.Net
T
The Blog of Author Tim Ferriss
F
Fortinet All Blogs
博客园 - Franky
阮一峰的网络日志
阮一峰的网络日志
GbyAI
GbyAI
Apple Machine Learning Research
Apple Machine Learning Research
宝玉的分享
宝玉的分享
Engineering at Meta
Engineering at Meta
V
V2EX
MyScale Blog
MyScale Blog

Todyl Blog

Achieving Zero Trust with SASE: A Practical Roadmap for Modern Network Securityso like MSP Security Maturity Assessment: Why 79% of MSPs Are Stuck in 2025 The Rising Threat of Malicious AI: What Every Organization Needs to Know Iran Cyber Threat 2026: What SMBs and MSPs Need to Know The OneStart AI Browser Deception Cyber Insurance Requirements Based on Industry Why Third-Party Security Certification Is Your MSP's Competitive Edge Why Cyber Insurance Carriers Are Shifting to Security Assurance Iran Conflict and Cyber Risk: What North American Organizations Need to Know ‍ Why Cyber Resilience Requires Security, Compliance, and Insurance MSP Security Services: How to Position Identity Protection as Competitive Advantage Identity Security Gap Assessment: A Step-by-Step Guide for MSPs How Credential Theft Attacks Are Costing MSP Clients Millions Do I Need Cyber Insurance as a Small Business? Advanced Persistent Threats (APTs) Explained Preparing for CMMC Level 1: What Your Organization Needs to Do The Real Cost of Doing Nothing in Cybersecurity MSP Security: Build vs Buy SOC The Rise of a Cybercrime Alliance: What LockBit, Qilin, and DragonForce Mean for Business Risk Cyber Threat Recovery Strategies for MSPs What MSPs Need to Know about CIRCIA Final Rule ClickFix: The Evolution of Copy-Paste Social Engineering Akira Ransomware: Threat Assessment of a Scalable RaaS Operation The Dos and Don’ts of Applying for a Cyber Insurance Policy What Is Threat Hunting? A Practical Guide for MSPs and SMBs The Business Case for Cyber Threat Management Evaluating Free and Open Source SIEM Tools in 2026 How organizations can combat BEC Using SASE to help meet cyber insurance requirements Introducing the Anomaly Framework
CyberChef: How to Decode & Decrypt Malicious Scripts (Ste...
Keira Stevens · 2026-06-05 · via Todyl Blog

As a security researcher, I am always looking to augment my toolkit. Whether they’re helping me increase efficiency, automate faster or just get the job done, I use an arsenal of different tools. Today, I’d like to share how I use CyberChef in my day-to-day work.

Tackling PowerShell Obfuscation with CyberChef

At Todyl, we see many bad actors’ malicious scripts, which they use to further their goals of attacking an organization. I use CyberChef to decode these scripts and uncover their purpose without compromising my systems. As an example, let’s walk through using CyberChef to help decode a small part of an obfuscated PowerShell script.

CyberChef interface showing AES decryption of obfuscated PowerShell script

Decrypting with AES

When looking at the script above, we can see that the creator used Advanced Encryption Standard (AES) to encrypt the data. We need to take several steps to finally reach the end, where the data is saved in the variable $TYRWNYQCXRTYBVYBRUNI.

The first step in the decryption process is converting the key from base64. A nice feature we can use is the AES decryption function, simply inputting the key as the base64 string so we don't have to worry about decoding it first. In the next screenshot, you can see how I pasted the whole code snippet into CyberChef then use the register to save the key as a variable called $R0.

Next, we need the initialization vector (IV) for AES decryption. The IV is $AULTOCDHKXWFHVBEGBTK, which is the first 16 characters of variable $MAKHTXZWRQWKBJPIPWTN. From here, we can create a subsection, inserting a regular expression (regex) to capture the contents of variable $SPYINETGVONCZTYZRGJN.

Our next step is to use a base64 operation to decode the $MAKHTXZWRQWKBJPIPWTN variable. We will use another register to capture the first 16 characters as indicated by [0..15]. Below, you can see that $SPYINETGVONCZTYZRGJN is base64 decoded in the output and the first 16 characters are now assigned to $R1.

We are almost done. Now, only the variable $RZCAYMDDGPRXNWULGIAO Is left to go. First, we need to merge using our created register. This combines the data into our final format. We will create a regex to select the target data for $RZCAYMDDGPRXNWULGIAO. Then, we base64 decode it like we see for variable $TIAQUPOTHMERVLOZYDGG. After that, we are now ready to decrypt the data using our key stored in $R0. Our IV is ifhvwilthih34o8t ($R1). Within CyberChef, we use the cipher block chaining (CBC) mode as indicated in the script. The result is the decoded PowerShell command, which would run on the machine and further the attacker’s goals.

Conclusion

Threat actors are constantly evolving their obfuscation tactics to evade detection and carry out their nefarious operations. Using tools like CyberChef, researchers can quickly decode scripts and follow the trail to stop attackers from successfully compromising a system.

Of course, there are dozens of other tools available to help facilitate security research. I’m always looking to expand my toolbelt, so please, let me know if there are any other tools you particularly like and leverage in your work. I’d love to explore them. Reach out to us or post on Todyl Community to share your thoughts.

About Keira Stevens

Keira Stevens is a Senior Security Research Engineer at Todyl, where she spends most of her time writing and tuning detection rules, and researching threats seen at Todyl. She has almost two decades of experience in the security field that includes giving talks at conferences, writing papers and publishing blogs. Keira as helped stop APT actors attacking companies, working with LE on criminal group takedowns, and mentor new people coming into the security field. When not at work Keira likes to spend time with her family and smashing buttons in online video games.