<!-- Copyright (c) 2026 defconxt. All rights reserved. -->
<!-- Licensed under AGPL-3.0 — see LICENSE file for details. -->
<!-- NERF is a trademark of defconxt. -->
---
name: reverse-engineering-android-applications
description: >-
  Reverse engineer Android APK files to decompile Dalvik bytecode, analyze native libraries, and identify security vulnerabilities.
domain: cybersecurity
subdomain: reverse-engineering
tags:
  - android
  - apk
  - dalvik
  - smali
  - jadx
version: "1.0"
author: defconxt
license: AGPL-3.0
metadata:
  mitre-attack: ["T1409"]
  cwe: ["CWE-200"]
  tools: ["jadx", "apktool", "dex2jar", "Frida", "objection"]
---

# Reverse Engineering Android Applications

## Overview

Reverse engineer Android APK files to decompile Dalvik bytecode, analyze native libraries, and identify security vulnerabilities.

## Prerequisites

| Tool / Requirement | Details |
|---|---|
| `jadx` | Security tooling |
| `apktool` | Security tooling |
| `dex2jar` | Security tooling |
| `Frida` | Security tooling |
| `objection` | Security tooling |
| Isolated lab environment for testing | Environment requirement |
| Authorization and signed Rules of Engagement (RoE) | Environment requirement |
| Relevant target samples or systems acquired through authorized channels | Environment requirement |

## Quick Reference

```bash
# Decompile APK with jadx
jadx -d ./output ./target.apk

# Decode with apktool
apktool d ./target.apk -o ./decoded

# Analyze manifest
aapt dump xmltree ./target.apk AndroidManifest.xml

# Frida instrumentation
frida -U -l hook.js com.target.app
```

## Workflow

### Step 1: Preparation and Reconnaissance

```bash
# Identify target and gather initial intelligence
file ./target_sample
jadx --version 2>/dev/null || echo "Install jadx"

# Set up working directory
mkdir -p /tmp/reverse-engineering-android-applications/{output,logs,artifacts}
```

### Step 2: Primary Analysis

```bash
# Execute primary analysis with jadx
# Refer to Quick Reference above for detailed commands
echo "[*] Running Reverse Engineering Android Applications with jadx..."

# Log all operations
script -q /tmp/reverse-engineering-android-applications/logs/session.log
```

### Step 3: Deep Investigation

```bash
# Apply apktool for secondary analysis
echo "[*] Deep investigation with apktool..."

# Cross-reference findings
diff /tmp/reverse-engineering-android-applications/output/primary.json /tmp/reverse-engineering-android-applications/output/secondary.json
```

### Step 4: Documentation and Reporting

```bash
# Generate structured findings report
cat <<'EOF' > /tmp/reverse-engineering-android-applications/output/report.json
{
  "technique": "reverse-engineering-android-applications",
  "domain": "reverse-engineering",
  "tools_used": ["jadx", "apktool"],
  "findings": [],
  "recommendations": []
}
EOF
```

## Detection

```yaml
title: Reverse Engineering Android Applications Detection
id: 479ab9e8-59d1-493e-b2b0-0e32305459fd
status: experimental
description: Detects suspicious activity related to reverse engineering android applications techniques in reverse engineering context
logsource:
  category: process_creation
  product: windows
detection:
  selection:
    CommandLine: "*reverse*engineering*"
  condition: selection
level: medium
tags:
  - attack.t1409
  - attack.defense_evasion
falsepositives:
  - Malware analysis sandbox performing automated binary inspection
```


**Detection Opportunities**

| Indicator | Source | Detection Logic |
|---|---|---|
| Reverse Engineering Android Applications Detection | windows/process_creation | Sigma rule (medium) |
| ATT&CK Coverage | MITRE ATT&CK | T1409 |

## Verification

- [ ] Environment and tools verified and operational
- [ ] Target samples acquired through authorized channels
- [ ] Primary analysis completed with findings documented
- [ ] Secondary validation performed with independent tooling
- [ ] All artifacts preserved in structured output directory
- [ ] Detection opportunities documented for blue team

## References

- [MITRE ATT&CK T1409](https://attack.mitre.org/techniques/T1409) — Related technique
- [jadx Documentation](https://jadx.org/) — Primary tooling
- [apktool Reference](https://apktool.org/) — Secondary tooling
