A Lightweight Network for Encrypted Traffic Classification Based on Convolutional Positional Encoding and Efficient Multi-Scale Attention
Network traffic classification is a cornerstone of network management and security. Addressing the challenges of feature extraction in encrypted traffic and the deployment limitations of traditional deep learning models on resource-constrained edge devices due to their large parameter sizes, this paper proposes a lightweight network for encrypted traffic classification, termed CEMA-Net (Convolutional Positional Encoding and Efficient Multi-scale Attention Network). Specifically, the proposed model integrates an Efficient Multi-scale Attention (EMA) mechanism with a Convolutional Positional Encoding (CPE) strategy to jointly capture global dependencies and local contextual information. To enable efficient adaptation to traffic data, an Efficient Multi-scale Attention Adapter (EMAAdapter) is designed, which reconstructs one-dimensional traffic sequences into a pseudo-2D representation and extracts horizontal, vertical, and local features in parallel. This design facilitates effective modeling of complex cross-scale dependencies in encrypted traffic with minimal computational overhead. Experimental results on three public datasets demonstrate that the proposed method, with only 0.66 M parameters, achieves superior classification performance compared with mainstream vision-based models such as ResNet-101, while significantly reducing computational cost. These results highlight the effectiveness of combining convolutional positional encoding with multi-scale attention mechanisms and provide an efficient solution for encrypted traffic classification in resource-constrained environments.
Authors
- J. Yang
- Zengyu Cai (ORCID: https://orcid.org/0000-0002-3441-467X)
- Yuan Feng
- Jianwei Zhang
- Yifan Ren
- Liang Zhu (ORCID: https://orcid.org/0000-0002-6766-4544)
Institutions
- Zhengzhou University of Light Industry (CN)
- Zhengzhou University of Industrial Technology (CN)
- Henan Polytechnic University (CN)
Publication Details
- Journal
- Electronics
- Published
- 2026-05-22
- DOI
- https://doi.org/10.3390/electronics15112248
- Primary Topic
- Internet Traffic Analysis and Secure E-voting
- Type
- article
- Field-Weighted Citation Impact
- 0.00
Funders
- National Natural Science Foundation of China