Skip to content

IoT, Edge Computing, and Green Networking: Energy Harvesting, Information-Centric Networking (NDN), and Post-Quantum Security in ns-3

An authoritative architectural deep dive into simulating IoT, Edge Computing, and Green Networking under ns-3. Evaluates ambient Energy Harvesting and Wake-Up Radios (WuR) for battery-free zero-energy devices, Information-Centric Networking (NDN / ICN) with in-network edge caching via ndnSIM, and the latency, fragmentation, and battery depletion impacts of NIST Post-Quantum Cryptography (ML-KEM & ML-DSA) over constrained wireless links.

Green Networking & Security
IoT / ndnSIM / PQC / ns-3
Author: Charles Pandian  |  Est. Reading Time: 24 min

An exhaustive architectural guide to simulating Internet of Things (IoT), Edge Computing, and Green Networking in ns-3. This article dissects Energy Harvesting & Wake-Up Radios (WuR) for battery-free zero-energy devices, Information-Centric Networking (ICN / NDN) with in-network edge caching in ndnSIM, and the performance and fragmentation impacts of Post-Quantum Cryptography (PQC – ML-KEM/Kyber & ML-DSA/Dilithium) over constrained wireless links.

IoT Edge Computing and Green Networking Simulation in ns-3 with Energy Harvesting, NDN, and PQC
Figure 1: Sustainable Green IoT and Edge Computing ecosystem showing solar and RF ambient energy harvesting, low-power mesh networking, Information-Centric Networking (NDN) in-network caching, and post-quantum cryptographic security shields.

1. The Sustainability Imperative in Massive IoT

The global proliferation of the Internet of Things is accelerating toward an estimated 30 to 50 billion connected devices by 2030. From smart agriculture sensor fields and structural health monitoring on bridges to industrial telemetry and biomedical implants, computing is permeating every facet of the physical world.

However, this massive expansion faces three existential engineering crises:

  • The Battery Replacement Crisis: Powering billions of scattered IoT nodes with conventional chemical batteries (e.g., lithium coin cells) is physically impossible and ecologically disastrous. Disposing of hundreds of millions of depleted batteries annually creates severe environmental toxicity, while manually replacing batteries embedded inside concrete pillars or remote farmland is economically unviable. The solution is Zero-Energy / Self-Powered IoT driven by ambient energy harvesting and ultra-low-power radios.
  • The Host-Centric IP Inefficiency: Traditional host-centric TCP/IP networking binds content to static IP addresses. In intermittent, sleeping IoT meshes, trying to establish point-to-point connections to duty-cycled sensors results in massive retransmissions and backhaul waste. Information-Centric Networking (ICN / NDN) replaces IP endpoints with content-name routing and in-network edge caching.
  • The Post-Quantum Cryptographic Crisis: With the advent of scalable quantum computers capable of running Shor’s algorithm, legacy public-key encryption (RSA, ECC, ECDSA) will be completely compromised. Migrating constrained IoT devices to NIST Post-Quantum Cryptography (PQC) standards (such as ML-KEM and ML-DSA) introduces unprecedented payload expansion, severely testing low-power wireless links.

Evaluating these interrelated challenges requires an integrated, mathematically rigorous simulation platform. In ns-3, researchers can model the physics of energy harvesting, analyze duty-cycled wake-up radios, evaluate NDN forwarding strategies via ndnSIM, and measure the latency and battery tax of post-quantum handshakes over lossy wireless channels.

2. Energy Harvesting & Wake-Up Radios: Zero-Energy IoT in ns-3

Traditional low-power wide-area networks (LPWANs)—such as LoRaWAN, NB-IoT, and IEEE 802.15.4 / 6LoWPAN—minimize energy consumption through duty-cycling: devices sleep for 99% of the time and wake up periodically. However, even during sleep, internal clocks and leakage currents deplete batteries. Furthermore, periodic wake-up introduces substantial latency for downlink traffic.

2.1 Modeling Ambient Energy Harvesting in ns-3

Green networking shifts the paradigm from fixed battery energy budgets to Energy-Neutral Operation (ENO), where a device’s consumed energy is strictly less than or equal to the energy harvested from the environment over an operational window:

int_{0}^{T} P_{text{consume}}(t) , dt le int_{0}^{T} P_{text{harvest}}(t) , dt + E_{text{stored}}(0)

ns-3 provides a comprehensive, modular Energy Framework consisting of three interconnected class hierarchies:

  • EnergySource: Represents the energy storage reservoir (such as a rechargeable Li-Ion battery via LiIonEnergySource or a high-cycle supercapacitor via BasicEnergySource). It models real-world non-linear effects including voltage decay, self-discharge leakage, and capacity degradation.
  • DeviceEnergyModel: Installed on network devices (e.g., LrWpanRadioEnergyModel or LoraRadioEnergyModel). It dynamically tracks the transceiver state machine (Sleep, Idle, Rx, Tx) and draws current from the associated EnergySource:
    I_{text{total}}(t) = I_{text{sleep}} cdot mathbb{I}_{text{sleep}} + I_{text{rx}} cdot mathbb{I}_{text{rx}} + I_{text{tx}} cdot mathbb{I}_{text{tx}}
  • EnergyHarvester: Models the stochastic ambient energy influx (e.g., BasicEnergyHarvester). Researchers can implement custom harvesting models representing:

    1. Solar Photovoltaic: Diurnal sinusoidal irradiance profiles ($10text{–}100text{ mW/cm}^2$ outdoors, $10text{–}100 mutext{W/cm}^2$ indoors under ambient LED lighting).

    2. RF Electromagnetic Harvesting: Rectifying ambient RF signals from Wi-Fi routers and cellular towers ($0.1text{–}10 mutext{W/cm}^2$).

    3. Thermoelectric (TEG): Harvesting Seebeck voltage from industrial machinery temperature gradients.

2.2 Wake-Up Radios (WuR / IEEE 802.11ba): Eliminating Idle Listening

In classical duty-cycled MAC protocols, idle listening (waking up to check for incoming preambles when no data is being sent) accounts for up to 70% to 90% of total energy wasted.

Wake-Up Radio (WuR) architecture introduces an ultra-low-power, passive or near-passive secondary receiver alongside the primary high-speed transceiver:

Component Power Consumption Operating Function Active Duty Cycle
Primary Transceiver (e.g. 802.15.4 / LoRa) 20 mW – 120 mW (Rx/Tx) High-speed payload transmission and reception 0.01% (Deep Sleep ~ 1 μW)
Secondary Wake-Up Radio (WuR) 100 nW – 5 μW Continuous listening for Wake-Up Packet (WUP) 100% (Always Listening)

When an edge gateway needs to contact a sleeping sensor, it emits a short, Manchester-coded Wake-Up Packet (WUP) containing the target node’s hardware address. The WuR receiver decodes the WUP at nanowatt power, triggers a hardware interrupt line, wakes the primary radio from deep sleep, and exchanges data immediately. In ns-3, this completely decouples transmission latency from energy conservation, enabling perpetual battery-free operation on small ambient solar panels.

3. Information-Centric Networking (ICN / NDN) in Constrained IoT

Traditional Internet architectures rely on the host-centric IP protocol, which requires establishing point-to-point connections between endpoints. In resource-constrained, multi-hop wireless sensor networks, this model is fundamentally mismatched with application needs:

  • Users care about the data itself (e.g., “What is the temperature in Greenhouse 4?”), not which physical device produced it.
  • If 20 neighboring smart home controllers simultaneously request the same weather telemetry, an IP server must dispatch 20 separate unicast packets, flooding the wireless medium.

3.1 Named Data Networking (NDN) Architecture

Named Data Networking (NDN) replaces host IP addresses with hierarchically structured, human-readable content names (e.g., /agri/zone1/soil/moisture). Communication is entirely consumer-driven via two packet types:

  1. Interest Packet: Dispatched by a consumer querying for named content.
  2. Data Packet: Returned by any node that holds the requested content, containing the content name, payload, and a cryptographic signature.

The Three Core NDN Node Data Structures

Every NDN node (including constrained edge routers) maintains three internal state tables:
1. Content Store (CS): In-network memory cache. When an Interest arrives, the node checks its CS. If the named data is cached, it immediately returns the Data packet without forwarding the Interest.
2. Pending Interest Table (PIT): Records outstanding Interests awaiting data, mapping the requested name to incoming network interfaces. If multiple consumers request the same content before it returns, the PIT aggregates them into a single entry, suppressing redundant upstream queries.
3. Forwarding Information Base (FIB): Name-based routing prefix table populated by routing protocols, guiding Interests toward authoritative producers.

3.2 In-Network Edge Caching and Simulation via `ndnSIM`

In ns-3, NDN research is executed via ndnSIM, the official NS-3-based simulator developed by UCLA. In constrained edge topologies:

  • Edge Caching Strategies: Constrained routers implement replacement algorithms (LRU, LFU, Freshness-Aware Caching) tailored to small RAM limits (e.g., 64 KB cache).
  • Interest Aggregation & Multicast: When 50 nodes query the same content within a short interval, only a single Interest traverses the uplink to the cloud edge. The returning Data packet travels back down the reverse PIT trail, satisfying all 50 consumers in a single broadcast transmission.
  • Energy & Bandwidth Savings: In simulated smart grid sensor networks, in-network caching reduces average latency by 60–80% and slashes wireless radio transmissions by up to 75%, directly extending the lifespan of energy-harvesting nodes.

4. Architectural Blueprint: Green IoT, NDN & PQC Integration in ns-3

The diagrammatic layout below illustrates how renewable energy harvesting, Wake-Up Radios, Information-Centric Networking (ndnSIM), and Post-Quantum Cryptography handshakes interface within a complete ns-3 simulation:

SYSTEM ARCHITECTURE BLUEPRINT

Green IoT, Edge NDN Caching & Post-Quantum Security Pipeline in ns-3

1. Energy Harvesting & WuR
Hardware Tier
Energy Harvesting Sources: Solar PV • Ambient RF • TEG Thermoelectric
Energy Reservoir: Supercapacitor / Li-Ion (BasicEnergySource)
Radio Hierarchy: Nanowatt WuR Receiver (1 μW) → Hardware Interrupt → Main Transceiver (802.15.4 / LoRa)

2. ndnSIM & Edge Caching
Network Tier
Named Packets: Interest Packet • Data Packet (/sensor/zone1/temp)
Core Tables: Content Store (CS) • Pending Interest Table (PIT) • FIB
Optimization: In-network Edge Caching suppresses redundant upstream requests, saving 75% RF transmissions.

3. Post-Quantum Security
Security Tier
NIST Algorithms: ML-KEM (Kyber-512) • ML-DSA (Dilithium-2)
Fragmentation: 2,420-byte Signature → 25+ 6LoWPAN 127-byte frames
Overhead Profiling: Handshake latency inflation and battery depletion measured under lossy fading channels.

Sequential Interaction Loop: WuR, NDN & PQC Handshake (Mermaid)

sequenceDiagram
    autonumber
    participant Gateway as Edge IoT Gateway / Consumer
    participant WuR as Sensor Wake-Up Radio (1 μW)
    participant Sensor as Sensor Main MCU & Radio (802.15.4)
    participant Harvester as Solar Energy Harvester (ns-3)

    Harvester->>Sensor: Harvest ambient energy & charge supercapacitor
    Note over Sensor: Primary radio in deep sleep (0.01% duty cycle)
    
    Gateway->>WuR: Emit Wake-Up Packet (WUP with node ID)
    WuR->>Sensor: Trigger hardware interrupt pin (Wake MCU!)
    Sensor->>Sensor: Power up primary transceiver
    
    Gateway->>Sensor: Send NDN Interest Packet ("/sensor/data")
    Note over Sensor: Content Store miss → Sample fresh reading
    
    Sensor->>Sensor: Generate ML-DSA (Dilithium) Quantum Signature
    Note over Sensor: Signature is 2,420 bytes → Fragment into 25x 6LoWPAN frames!
    
    Sensor->>Gateway: Transmit multi-frame PQC Data Packet
    Gateway->>Gateway: Verify PQC signature & cache in Edge Content Store (CS)
    
    Sensor->>Sensor: Primary transceiver returns to Deep Sleep
    Note over Sensor: WuR remains listening at nanowatt standby
  

5. Post-Quantum Cryptography (PQC) & Security in Constrained Networks

The advent of fault-tolerant quantum computers represents an existential threat to the Internet of Things. Shor’s algorithm will effortlessly factor large integers and solve discrete logarithms in polynomial time, completely destroying classical asymmetric cryptography: RSA, Diffie-Hellman, ECDH, and ECDSA will offer zero security.

Because infrastructure IoT devices (smart electric grids, municipal water control valves, cardiac implants) are deployed with 10 to 20-year operational lifecycles, they are actively vulnerable today to “Harvest Now, Decrypt Later” adversarial attacks.

5.1 The NIST-Standardized PQC Algorithms

In August 2024, the National Institute of Standards and Technology (NIST) finalized its premier post-quantum standards based on hard lattice mathematical problems:

  • FIPS 203: ML-KEM (Module-Lattice-Based Key-Encapsulation Mechanism – derived from CRYSTALS-Kyber): Primary standard for general encryption and key establishment.
  • FIPS 204: ML-DSA (Module-Lattice-Based Digital Signature Algorithm – derived from CRYSTALS-Dilithium): Primary standard for digital authentication and identity certificates.
  • FIPS 205: SLH-DSA (Stateless Hash-Based Digital Signature Algorithm – derived from SPHINCS+): Backup digital signature standard relying strictly on hash security.

5.2 The “PQC Tax”: Key and Ciphertext Inflation

While lattice-based algorithms execute rapidly in software (relying on Number Theoretic Transforms – NTT), they impose an enormous bandwidth and memory tax compared to classical Elliptic Curve Cryptography (ECC):

Algorithm Security Level Public Key Size Ciphertext / Signature Size Relative Size Expansion
Classical ECDH (P-256) 128-bit (Pre-quantum) 64 bytes 32 bytes (shared secret) Baseline (1x)
Classical ECDSA (P-256) 128-bit (Pre-quantum) 64 bytes 64 bytes (signature) Baseline (1x)
ML-KEM-512 (Kyber-512) NIST Level 1 (AES-128 equivalent) 800 bytes 768 bytes (ciphertext) 12.5x Key / 24x Ciphertext
ML-DSA-44 (Dilithium-2) NIST Level 2 (SHA-256 equivalent) 1,312 bytes 2,420 bytes (signature) 20.5x Key / 37.8x Signature
SLH-DSA-128f (SPHINCS+) NIST Level 1 (Conservative Hash) 32 bytes 17,088 bytes (signature) 267x Signature Expansion!

5.3 The Fragmentation and Battery Depletion Crisis in ns-3

When researchers simulate PQC handshakes (e.g., DTLS 1.3 or TLS 1.3 over 6LoWPAN, BLE, or LoRaWAN) in ns-3, the severe impact of this size inflation becomes immediately visible:

1. The 6LoWPAN Fragmentation Avalanche

The maximum physical payload of an IEEE 802.15.4 frame is strictly 127 bytes. After deducting 802.15.4 MAC headers and 6LoWPAN encapsulation headers, the effective MTU available for upper-layer data is roughly 80 to 95 bytes per frame.

Transmitting a single ML-DSA-44 signature (2,420 bytes) requires 26 consecutive fragmented frames! Over a wireless sensor link with a modest 5% packet error rate ($PER = 0.05$), the probability of successfully delivering the entire signature without fragment loss drops precipitously:
$$P_{text{success}} = (1 – PER)^{26} = (0.95)^{26} approx 0.263 (26.3%)$$
More than 73% of signature handshakes fail on the first attempt, triggering catastrophic end-to-end retransmission storms that choke the constrained wireless channel.

2. The RF Transmission Energy Penalty

While software benchmark tests often focus on CPU clock cycles, in wireless IoT systems, RF transmission energy dwarfs MCU compute energy. In an 802.15.4 transceiver, transmitting 1 byte consumes roughly 1,000x more microjoules than computing a modular addition in software.

Executing an ML-KEM + ML-DSA authenticated handshake transmits over 5.3 KB of cryptographic material across the air, consuming over 18 to 25 milli-Joules of energy per handshake—an 8.5x energy surge over classical ECDSA. On an energy-harvesting node, a single PQC handshake can completely drain the supercapacitor reservoir, forcing the node into a multi-hour reboot and recharge blackout.

6. Complete C++ Simulation Blueprint in ns-3

Below is a production-grade C++ simulation script demonstrating how to configure energy-harvesting IoT nodes in ns-3, attaching a solar energy harvester, supercapacitor energy source, and 802.15.4 radio energy model to track power levels over time:

// green-iot-simulation.cc: Energy Harvesting and Low-Power 802.15.4 Simulation Blueprint
#include “ns3/core-module.h”
#include “ns3/network-module.h”
#include “ns3/mobility-module.h”
#include “ns3/lr-wpan-module.h”
#include “ns3/energy-module.h”
#include “ns3/internet-module.h”

using namespace ns3;

void RemainingEnergyTrace(Ptr stream, double oldValue, double newValue) {
    *stream->GetStream() << Simulator::Now().GetSeconds() << “t” << newValue << std::endl;
}

int main(int argc, char *argv[]) {
    CommandLine cmd(__FILE__);
    cmd.Parse(argc, argv);

    // 1. Create IoT Sensor Nodes
    NodeContainer iotNodes;
    iotNodes.Create(5);

    // 2. Configure Mobility
    MobilityHelper mobility;
    mobility.SetMobilityModel(“ns3::ConstantPositionMobilityModel”);
    mobility.Install(iotNodes);

    // 3. Configure IEEE 802.15.4 PHY & MAC
    LrWpanHelper lrWpanHelper;
    NetDeviceContainer devContainer = lrWpanHelper.Install(iotNodes);
    lrWpanHelper.AssociateToPan(devContainer, 10);

    // 4. Configure Energy Source (Supercapacitor: 3.3V, Initial 50 Joules)
    BasicEnergySourceHelper basicSourceHelper;
    basicSourceHelper.Set(“BasicEnergySourceInitialEnergyJ”, DoubleValue(50.0));
    basicSourceHelper.Set(“BasicEnergySupplyVoltageV”, DoubleValue(3.3));
    EnergySourceContainer sources = basicSourceHelper.Install(iotNodes);

    // 5. Configure Solar Energy Harvester (Harvesting 15 mW average power)
    BasicEnergyHarvesterHelper harvesterHelper;
    harvesterHelper.Set(“PeriodicHarvestedPowerUpdateInterval”, TimeValue(Seconds(1.0)));
    harvesterHelper.Set(“BasicEnergyHarvesterInitialHarvestedPower”, DoubleValue(0.015)); // 15 mW
    EnergyHarvesterContainer harvesters = harvesterHelper.Install(sources);

    // 6. Connect Energy Trace Listener
    AsciiTraceHelper asciiTraceHelper;
    Ptr stream = asciiTraceHelper.CreateFileStream(“energy-trace.dat”);
    sources.Get(0)->TraceConnectWithoutContext(“RemainingEnergy”, MakeBoundCallback(&RemainingEnergyTrace, stream));

    Simulator::Stop(Seconds(60.0));
    Simulator::Run();
    Simulator::Destroy();
    return 0;
}

7. Synthesis & Future Outlook: The Sustainable Quantum-Safe Edge

The convergence of Green Networking, Edge Computing, and Quantum-Resistant Security represents the true technological frontier of the Internet of Things. As we transition into the next era of pervasive computing, success will no longer be measured merely by how many billions of chips we manufacture, but by how sustainably they draw power from their environment and how securely they protect human data against future quantum decryption.

Through ns-3 and ndnSIM, researchers possess an unmatched simulation engine to solve these multidimensional challenges: engineering energy harvesting circuits that sustain perpetual operation, deploying Named Data Networking to eliminate backhaul waste via in-network caching, and designing compression and hybrid architectures that tame the severe fragmentation tax of Post-Quantum Cryptography over constrained wireless links.

CP

Written by Charles Pandian

Green networking researcher and systems simulation architect specializing in ns-2, ns-3, ndnSIM, energy harvesting wireless sensor networks, Wake-Up Radios, and Post-Quantum Cryptographic protocol benchmarking. Regular contributor to ProjectGuideline.com academic guides and simulation architectures.

Leave a Reply

WhatsApp Discuss Through WhatsApp