TP-Net: Self-Supervised Pretrained Network Traffic Representations for Few-Shot Threat Detection in IoT and Sensor Networks

Encrypted traffic now dominates IoT and sensor networks, and fully supervised classifiers are bottlenecked by label scarcity and the retraining cost of recognizing new attacks at the resource-constrained edge. TP-Net (Traffic Pretraining Network) couples self-supervised contrastive pretraining with N-way K-shot evaluation: a four-branch 1D-CNN encoder is trained once under SimCLR on packet, burst, flow-statistical, and TLS-handshake features with five traffic-specific augmentations, and it is then frozen at deployment. Our contributions are threefold. First, we build a protocol-fair benchmark that evaluates six supervised-traffic baselines and TP-Net under the same per-episode linear head with a frozen encoder, showing that TP-Net’s SSL encoder stays competitive, trailing the strongest fully trained supervised model by at most 9.75 pp, without any encoder fine-tuning while supervised baselines require retraining. Second, we demonstrate novel-class and encrypted-only generalization, reaching 99.3%/72.9% on unseen novel attacks (CIC two-way/USTC five-way; ISCX’s one-way split is trivial and excluded) and +28.66 pp over no pretrain on fully encrypted DoHBrw-2020 traffic. Third, we show that augmentation strength must adapt to task complexity, overturning the canonical SimCLR stronger-is-better rule on IoT traffic. TP-Net lifts five-shot accuracy over a random encoder by +13.14/+7.76/+4.11 pp and yields a 5-alert, no-finetune, hour-level deployment path for novel encrypted attacks at the edge.

Authors

Publication Details

Journal
Sensors
Published
2026-10-30
DOI
https://doi.org/10.3390/s26216861
Primary Topic
Network Security and Intrusion Detection
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

TP-Net: Self-Supervised Pretrained Network Traffic Representations for Few-Shot Threat Detection in IoT and Sensor Networks

Q. Wang, Xi Yao, Yan Feng
3 links
Sensors
Network Security and Intrusion Detection
article

TP-Net: Self-Supervised Pretrained Network Traffic Representations for Few-Shot Threat Detection in IoT and Sensor Networks

Q. Wang, Xi Yao, Yan Feng
article en

Abstract

Encrypted traffic now dominates IoT and sensor networks, and fully supervised classifiers are bottlenecked by label scarcity and the retraining cost of recognizing new attacks at the resource-constrained edge. TP-Net (Traffic Pretraining Network) couples self-supervised contrastive pretraining with N-way K-shot evaluation: a four-branch 1D-CNN encoder is trained once under SimCLR on packet, burst, flow-statistical, and TLS-handshake features with five traffic-specific augmentations, and it is then frozen at deployment. Our contributions are threefold. First, we build a protocol-fair benchmark that evaluates six supervised-traffic baselines and TP-Net under the same per-episode linear head with a frozen encoder, showing that TP-Net’s SSL encoder stays competitive, trailing the strongest fully trained supervised model by at most 9.75 pp, without any encoder fine-tuning while supervised baselines require retraining. Second, we demonstrate novel-class and encrypted-only generalization, reaching 99.3%/72.9% on unseen novel attacks (CIC two-way/USTC five-way; ISCX’s one-way split is trivial and excluded) and +28.66 pp over no pretrain on fully encrypted DoHBrw-2020 traffic. Third, we show that augmentation strength must adapt to task complexity, overturning the canonical SimCLR stronger-is-better rule on IoT traffic. TP-Net lifts five-shot accuracy over a random encoder by +13.14/+7.76/+4.11 pp and yields a 5-alert, no-finetune, hour-level deployment path for novel encrypted attacks at the edge.

SensorsVol. 26(21)
Industry, innovation and infrastructure
Openalex Percentile: Top 12%
Network Security and Intrusion Detection
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon