RITA

RITA

One-liner: Open-source framework for detecting C2 communication by analyzing network traffic via Zeek logs.

🎯 What Is It?

RITA (Real Intelligence Threat Analytics) is an open-source framework created by Active Countermeasures. Its core functionality is to detect Command and Control (C2) communication by analyzing network traffic captures and logs. RITA correlates captured fields including IP addresses, ports, timestamps, and connection durations to identify suspicious behavior patterns.

🔬 How It Works

RITA only accepts network traffic input as Zeek logs. It runs several analysis modules collecting information like:

⚡ Quick Reference

Installation

# RITA is typically run via Docker or native install
# See: https://github.com/activecm/rita

Convert PCAP to Zeek Logs

zeek readpcap <pcapfile> <outputdirectory>
# Example:
zeek readpcap pcaps/suspicious.pcap zeek_logs/suspicious

Import Zeek Logs to RITA

rita import --logs ~/zeek_logs/suspicious/ --database suspicious

View Analysis Results

rita view <database-name>

📖 Detection Features

Feature Description
C2 Beacon Detection Identifies periodic "check-in" connections
DNS Tunneling Detection Flags excessive queries, long subdomains
Long Connection Detection Unusual persistent connections
Data Exfiltration Detection Large outbound data volumes
Threat Intel Feeds Cross-references known malicious IPs
Severity Scoring Ranks connections by risk level

📊 RITA Results Columns

Column What It Shows
Severity Risk score based on threat modifiers
Source/Destination IP addresses or FQDNs
Beacon Likelihood of beaconing behavior (%)
Duration Connection length (long = suspicious)
Subdomains Number of subdomains (high = suspicious)
Threat Intel Matches on threat intel feeds

🔧 Threat Modifiers

Modifier Detection Purpose
MIME type/URI mismatch HTTP header doesn't match URI
Rare signature Unusual TLS handshake patterns
Prevalence Low % of hosts connecting to destination
First Seen New external host on network
Missing host header HTTP connections without host header
Large outgoing data Potential exfiltration
No direct connections Hidden/complex C2 patterns

🔍 Search Syntax

# Enter search mode with /
/

# Search fields
dst:<destination>           # Filter by destination
src:<source>                # Filter by source
beacon:>=<percentage>       # Beacon score threshold
sort:duration-desc          # Sort by duration descending

# Example: Find all high-beacon connections to a domain
dst:rabbithole.malhare.net beacon:>=70 sort:duration-desc

💡 Pro Tips

📝 My Use Cases

🎤 Interview Angles

Common Questions

STAR Story

Situation: Large volume of network traffic needed analysis for potential C2 activity.
Task: Identify any command and control communication without manually reviewing PCAPs.
Action: Converted PCAP to Zeek logs, imported into RITA, analyzed beacon scores and threat modifiers. Identified high-severity connections with regular intervals and long FQDNs.
Result: Detected AsyncRAT C2 beacon to a malicious Cloudflare tunnel. Blocked the C2 domain and initiated incident response.

📚 References