Abstract
Pre-training has effectively addressed the challenge of scarce labeled data in encrypted traffic analysis, particularly in IoT scenarios where diverse device types and highly heterogeneous protocols make labeled data acquisition even more difficult. The paradigm of learning general representations from large-scale unlabeled data and adapting them to downstream tasks has gained widespread attention in traffic analysis across both traditional networks and IoT environments. Current mainstream methods predominantly adopt masked reconstruction as the pre-training objective, which aims to recover masked features. However, these masked reconstruction-based pre-training approaches force models to overfocus on fine-grained, semanticsagnostic details - such as exactly reconstructing packet length mean values or port numbers - while neglecting the overall semantic invariance that traffic should maintain under different perturbations. To address this issue, we propose Janus, a heterogeneous augmentation-enhanced contrastive pre-training framework. Janus explicitly partitions traffic features into metric features and attribute features, and applies Gaussian noise and random masking as tailored augmentation operations, respectively. Through independent stochastic augmentation, two complete views with semantically consistent yet distinct perturbation patterns are generated for each original sample, enabling contrastive pre-training that pulls positive pairs closer and pushes negative pairs apart. This design forces the encoder to learn universal traffic representations robust to both numerical fluctuations and discrete missing, fundamentally avoiding the semantic destruction of either feature type caused by a uniform augmentation strategy, and guiding the model to focus on cross-sample global semantic invariance rather than precise reconstruction of local values. Experiments conducted on public encrypted traffic datasets covering both traditional network and IoT scenarios show that Janus achieves an average classification accuracy exceeding 98%. Controlled ablations confirm that the heterogeneous augmentation strategy, rather than the input representation, drives the performance gains, validating the effectiveness of Janus in encrypted traffic detection tasks.
| Original language | English |
|---|---|
| Journal | IEEE Internet of Things Journal |
| DOIs | |
| State | Accepted/In press - 2026 |
| Externally published | Yes |
Keywords
- Contrastive learning
- Heterogeneous augmentation
- pre-training
- traffic detection
Fingerprint
Dive into the research topics of 'Janus: Heterogeneous Contrastive Pre-training for Encrypted Traffic Detection in IoT Environments'. Together they form a unique fingerprint.Cite this
- APA
- Author
- BIBTEX
- Harvard
- Standard
- RIS
- Vancouver