๐Ÿ“ก Mobile Network Security Framework

December 19, 2025 ยท View on GitHub

License Python SDR Telecom Open Source Research

An open-source, modular framework for security testing, vulnerability research, and protocol analysis of multi-generation mobile networks (2G/3G/4G/5G). Built with SDR hardware and open-source telecom stacks to emulate realistic telecom environments for security research and defensive testing.

๐Ÿ“‹ Table of Contents

๐ŸŽฏ Overview

The Mobile Network Security Framework provides a comprehensive platform for analyzing security vulnerabilities across 2G, 3G, 4G, and 5G mobile networks. By leveraging Software-Defined Radio (SDR) and open-source telecom stacks, it enables researchers to conduct security assessments in controlled lab environments without affecting production networks.

Research Paper: This framework is based on the research paper "Active Exploitation Framework for Mobile Network Protocols Using Specialized Tactical Hardware" by Tri Sumarno and Muhammad Mustafa Fagan.

โœจ Key Features

FeatureDescription
Multi-generation SupportFull stack implementations for GSM (2G), UMTS (3G), LTE (4G), and 5G NR
Modular ArchitectureThree core modules for different attack vectors: SIM Swap, Intercept, and Physical Layer
Hardware IntegrationUSRP 2901, BladeRF, and other SDR platforms with GPSDO synchronization
Realistic EmulationComplete RAN to Core network simulation with IMS and packet data support
Open Source StackBuilt on OpenBTS, Osmocom, Open5GS, srsRAN, and UERANSIM
Protocol AnalysisComprehensive signaling analysis across MAP, Diameter, GTP, NAS, SIP/RTP
Lab-ReadyDesigned for isolated lab environments with full reproducibility

๐Ÿ— Architecture

High-Level Architecture Diagramdeepseek_mermaid_20251219_5408ed

Component Overview

ComponentPurposeKey Protocols
OpenBTSGSM BTS emulationUm, A-bis, SIP
Osmocom2G/3G core and BTSSS7, MAP, GTP
Open5GS4G/5G core networkNGAP, PFCP, HTTP/2
srsRAN4G LTE RANS1-AP, GTP-U
UERANSIM4G/5G UE simulatorNAS, RRC
OsmocomBBGSM handset emulationGSM L1/L2

๐Ÿ”ง Installation

Prerequisites

Hardware Requirements

  • SDR Hardware: USRP 2901, BladeRF, or similar SDR platform
  • Computing: Intel i7 or equivalent (8+ cores recommended)
  • Memory: 16GB RAM minimum (32GB recommended)
  • Storage: 100GB+ SSD
  • Networking: Dual NIC recommended (for separation of control/user planes)
  • Synchronization: GPSDO for timing synchronization (optional but recommended)

Software Requirements

  • OS: Ubuntu 22.04 LTS (recommended) or 20.04 LTS
  • Kernel: 5.15+ with real-time patches (for SDR performance)
  • Dependencies: GNU Radio 3.10+, UHD 4.0+, Docker 20.10+

Complete Installation Guide

1. System Preparation

# Update system
sudo apt update && sudo apt upgrade -y

# Install base dependencies
sudo apt install -y git build-essential cmake autoconf libtool \
    pkg-config libboost-all-dev libusb-1.0-0-dev libfftw3-dev \
    libsctp-dev libgnutls28-dev libgcrypt-dev libssl-dev \
    libmongoc-dev libbson-dev libyaml-dev libpcsclite-dev \
    libtalloc-dev libpcap-dev libosmocore-dev libosmo-netif-dev \
    libosmo-sccp-dev libasn1c-dev sofia-sip-utils

2. System Preparation

# Clone the repository
git clone https://github.com/noz-co-id/MNSF.git
cd MNSF

# Run automated installation script (takes 30-60 minutes)
chmod +x install.sh
sudo ./install.sh --all

๐Ÿ“ฆ Modules

The Mobile Network Security Framework consists of three core modules, each designed to test specific vulnerabilities and attack vectors in mobile networks. These modules can be used independently or in combination for comprehensive security assessments.

1. SIM Swap Module

๐ŸŽฏ Purpose

The SIM Swap Module is designed to analyze vulnerabilities in subscriber identity management and authentication procedures across 2G, 3G, 4G, and 5G mobile networks. It enables security researchers to simulate and test SIM swap attacks in controlled lab environments.

๐Ÿ”ง Features

  • IMSI Collection: Passive and active IMSI harvesting techniques
  • Authentication Bypass: Testing of AKA, MILENAGE, COMP128 algorithms
  • Location Update Attacks: Manipulation of VLR/HLR registration
  • Roaming Scenarios: Inter-PLMN attack simulations
  • Multi-Generation Support: Testing across 2G/3G/4G/5G networks

๐Ÿ— Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚            SIM Swap Module                  โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Attack Scenarios                           โ”‚
โ”‚  โ€ข Traditional SIMSwap(HLR/HSS manipulation)โ”‚
โ”‚  โ€ข Authentication Bypass                    โ”‚
โ”‚  โ€ข Location Update Hijacking                โ”‚
โ”‚  โ€ข Roaming-based Attacks                    โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Core Components                            โ”‚
โ”‚  โ€ข IMSI Catcher                             โ”‚
โ”‚  โ€ข HLR/HSS Emulator                         โ”‚
โ”‚  โ€ข Authentication Vector Generator          โ”‚
โ”‚  โ€ข Signaling Analyzer                       โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Supported Protocols                        โ”‚
โ”‚  โ€ข MAP (2G/3G)                              โ”‚
โ”‚  โ€ข Diameter (4G/5G)                         โ”‚
โ”‚  โ€ข EAP-AKA/5G-AKA                           โ”‚
โ”‚  โ€ข GSM-AUTH/MAP-AUTH                        โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ“‹ Supported Attack Scenarios

ScenarioDescriptionTarget Network
Traditional SIM SwapManipulating HLR/HSS to redirect subscriber services2G/3G/4G/5G
Authentication BypassBypassing SIM authentication procedures2G/3G/4G/5G
Location Update HijackForcing location updates to malicious VLR/MME2G/3G/4G/5G
Roaming SIM SwapExploiting roaming interfaces for identity theft2G/3G/4G/5G
Silent SMS AttackUsing silent SMS for IMSI discovery2G/3G/4G

2. Intercept Module

๐ŸŽฏ Purpose

The Intercept Module implements lawful intercept architectures and analyzes signaling/data interception points across mobile network generations. It enables testing of interception capabilities and validation of privacy protections.

๐Ÿ”ง Features

  • Signaling Interception: MAP, Diameter, GTP-C monitoring
  • User Plane Interception: GTP-U, RTP, SIP content capture
  • LI Compliance Testing: 3GPP-compliant lawful intercept (HI1/HI2/HI3)
  • MSISDN-IMSI Correlation: Identity resolution across interfaces
  • Real-time Analysis: Live traffic inspection and filtering

๐Ÿ— Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚          Intercept Module                   โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Interception Points                        โ”‚
โ”‚  โ€ข HLR/HSS/UDM Interfaces                   โ”‚
โ”‚  โ€ข MME/AMF/SGSN Signaling                   โ”‚
โ”‚  โ€ข PGW/UPF User Plane                       โ”‚
โ”‚  โ€ข MSC/IMS Call Control                     โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Analysis Components                        โ”‚
โ”‚  โ€ข Protocol Decoders                        โ”‚
โ”‚  โ€ข Session Reconstructor                    โ”‚
โ”‚  โ€ข Metadata Extractor                       โ”‚
โ”‚  โ€ข Forensic Timeline Builder                โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Output Formats                             โ”‚
โ”‚  โ€ข PCAP with decoded layers                 โ”‚
โ”‚  โ€ข JSON/XML structured logs                 โ”‚
โ”‚  โ€ข HTML interactive reports                 โ”‚
โ”‚  โ€ข Real-time WebSocket streams              โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ“‹ Supported Interception Types

TypeProtocolInterfaceContent
Signaling (HI2)MAP, CAPHLR-VLR, HSS-MMEAuthentication, Location, SMS
Signaling (HI2)DiameterS6a, S13, ShSubscriber data, Equipment info
Signaling (HI2)GTP-CS11, S5/S8Session management, Bearer control
Content (HI3)GTP-US1-U, S5/S8User data packets
Content (HI3)RTP/SRTPIMS, MGWVoice/media streams
Content (HI3)SIPIMS, MSCCall setup, messaging

3. Peripheral Module (Layer 1)

๐ŸŽฏ Purpose

The Peripheral Module implements Physical Layer (Layer 1) attack vectors in mobile networks. It operates at the radio interface level, exploiting vulnerabilities in modulation, synchronization, and frame structure. These attacks are particularly stealthy as they bypass traditional cryptographic protections

๐Ÿ”ง Features

  • Synchronization Attacks: PSS/SSS jamming and spoofing
  • Reference Signal Manipulation: CRS, DMRS, SRS manipulation
  • Cell Spoofing: Malicious eNodeB/gNodeB emulation
  • DoS Attacks: Physical channel disruption
  • Baseband Exploits: RCE via SIB, RAR, PDCCH payloads
  • Custom Waveform Generation: Arbitrary signal generation

๐Ÿ— Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚        Peripheral Module (Layer 1)          โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Attack Categories                          โ”‚
โ”‚  โ€ข Jamming & Interference                   โ”‚
โ”‚  โ€ข Spoofing & Impersonation                 โ”‚
โ”‚  โ€ข Resource Exhaustion                      โ”‚
โ”‚  โ€ข Protocol Exploitation                    โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  SDR Integration                            โ”‚
โ”‚  โ€ข USRP B210/N310/X310                      โ”‚
โ”‚  โ€ข BladeRF 2.0 micro xA4/A9                 โ”‚
โ”‚  โ€ข LimeSDR/LimeNET                          โ”‚
โ”‚  โ€ข HackRF One/PortaPack                     โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Signal Processing                          โ”‚
โ”‚  โ€ข GNU Radio Companion flows                โ”‚
โ”‚  โ€ข Custom C++ blocks                        โ”‚
โ”‚  โ€ข Python-controlled SDR                    โ”‚
โ”‚  โ€ข Real-time spectrum analysis              โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ“‹ Supported Attack Types

Attack TypeTargetEffectStealth Level
Sync Signal JammingPSS/SSS (LTE/NR)Prevents cell synchronizationMedium
Reference Signal JammingCRS/DMRS (LTE/NR)Degrades channel estimationHigh
Broadcast Channel SpoofingPBCH (LTE/NR)Fake system informationHigh
RACH Jamming PRACH(LTE/NR)Prevents network accessLow
Control Channel DoSPDCCH (LTE)Blocks scheduling informationMedium
SIB InjectionBCCH (LTE)Malicious system infoVery High
Beacon FloodingAll cellsNetwork discovery confusionLow

๐Ÿ’ก Use Cases

๐ŸŽ“ Academic Research

  • Protocol Analysis: Detailed study of 3GPP protocol implementations
  • Vulnerability Research: Discovery of new attack vectors
  • Thesis Projects: Complete platform for graduate research
  • Publications: Reproducible experiments for paper submissions

๐Ÿ”’ Telecom Security

  • Operator Assessments: Security testing for mobile operators
  • Penetration Testing: Red team exercises in controlled environments
  • Compliance Validation: 3GPP security requirement verification
  • Forensic Analysis: Incident response and investigation training

๐Ÿ›ก๏ธ Defense Development

  • IDS/IPS Testing: Validation of intrusion detection/prevention systems
  • Security Patch Validation: Testing fixes before deployment
  • Threat Modeling: Real-world attack simulation for defense planning
  • Training Platforms: Hands-on labs for security teams

๐Ÿ”ฌ Protocol Development

  • Interoperability Testing: Multi-vendor compatibility testing
  • Standard Compliance: 3GPP specification verification
  • Performance Analysis: Protocol efficiency and optimization
  • Feature Validation: New feature security impact assessment

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

โš ๏ธ Disclaimer

IMPORTANT LEGAL NOTICE Intended Use This framework is ONLY intended for:

  • โœ… Authorized security research in controlled lab environments
  • โœ… Educational and academic purposes
  • โœ… Defensive security testing with explicit permission
  • โœ… Telecommunications security training and certification
  • โœ… Compliance testing on networks you own or have written permission to test

Prohibited Use DO NOT use this framework for:

  • โŒ Testing networks without explicit written authorization
  • โŒ Disrupting telecommunications services
  • โŒ Intercepting communications without legal authority
  • โŒ Any illegal activities or unauthorized access
  • โŒ Testing production networks without permission

Legal Compliance Users of this framework must:

  • ๐Ÿ”’ Comply with all applicable laws and regulations
  • ๐Ÿ”’ Obtain proper authorization before testing
  • ๐Ÿ”’ Use only in isolated, controlled environments
  • ๐Ÿ”’ Respect privacy and data protection regulations

No Warranty THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND. The developers assume no liability for any misuse, damage, or legal issues arising from the use of this framework.

๐Ÿ“ž Contact

Project Maintainers

๐Ÿ™ Acknowledgments

Open Source Projects This framework builds upon the following amazing open source projects:

ProjectContributionLink
OpenBTSGSM BTS implementationGitHub
Osmocom2G/3G mobile communications suiteOsmocom
Open5GSOpen source 5G Core implementationOpen5GS
srsRAN4G/5G software radio suitesrsRAN
UERANSIM5G UE and RAN simulatorUERANSIM
GNU RadioSDR signal processing toolkitGNURadio

Research Foundations

  • 3GPP Specifications: TS 33.102, TS 33.401, TS 33.501
  • Telecommunications Security Research Community
  • Open Source Security Initiatives