Skip to main content
QUICK REVIEW

[Paper Review] PacketCGAN: Exploratory Study of Class Imbalance for Encrypted Traffic Classification Using CGAN

Pan Wang, Shuhang Li|arXiv (Cornell University)|Nov 27, 2019
Internet Traffic Analysis and Secure E-votingComputer Science29 references6 citations
TL;DR

This paper proposes PacketCGAN, a conditional GAN-based data augmentation method to address class imbalance in encrypted traffic classification. By generating synthetic minority-class traffic samples, PacketCGAN improves deep learning model performance—particularly with CNNs—on imbalanced datasets like ISCX2012 and USTC-TFC2016, outperforming ROS, SMOTE, and vanilla GAN baselines in accuracy and F1-score.

ABSTRACT

With more and more adoption of Deep Learning (DL) in the field of image processing, computer vision and NLP, researchers have begun to apply DL to tackle with encrypted traffic classification problems. Although these methods can automatically extract traffic features to overcome the difficulty of traditional classification methods like DPI in terms of feature engineering, a large amount of data is needed to learn the characteristics of various types of traffic. Therefore, the performance of classification model always significantly depends on the quality of datasets. Nevertheless, the building of datasets is a time-consuming and costly task, especially encrypted traffic data. Apparently, it is often more difficult to collect a large amount of traffic samples of those unpopular encrypted applications than well-known, which leads to the problem of class imbalance between major and minor encrypted applications in datasets. In this paper, we proposed a novel traffic data augmenting method called PacketCGAN using Conditional GAN. As a generative model, PacketCGAN exploit the benefit of CGAN to generate specified traffic to address the problem of the datasets' imbalance. As a proof of concept, three classical DL models like Convolutional Neural Network (CNN) were adopted and designed to classify four encrypted traffic datasets augmented by Random Over Sampling (ROS), SMOTE(Synthetic Minority Over-sampling Techinique) , vanilla GAN and PacketCGAN respectively based on two public datasets: ISCX2012 and USTC-TFC2016. The experimental evaluation results demonstrate that DL based encrypted traffic classifier over dataset augmented by PacketCGAN can achieve better performance than the others.

Motivation & Objective

  • Address the challenge of class imbalance in encrypted traffic datasets, where minority applications have far fewer samples than popular ones.
  • Overcome the limitations of traditional traffic classification methods like port and payload matching, which fail on encrypted traffic.
  • Develop a data augmentation technique that generates realistic, application-specific encrypted traffic samples to balance minority classes.
  • Evaluate the effectiveness of the proposed method using deep learning models on real-world encrypted traffic datasets.

Proposed method

  • Employ Conditional Generative Adversarial Networks (CGAN) to generate synthetic encrypted traffic samples conditioned on application labels.
  • Train the generator to learn the statistical and temporal features of real encrypted traffic flows from ISCX2012 and USTC-TFC2016 datasets.
  • Use the discriminator to distinguish real traffic samples from generated ones, ensuring high-fidelity synthetic data.
  • Augment minority classes by combining real and generated samples to balance the dataset before training deep learning models.
  • Apply standard deep learning models (e.g., CNN) to the augmented datasets for classification, comparing performance across augmentation techniques.
  • Optimize the CGAN architecture with conditional labels to control the type of traffic generated, ensuring class-specific data synthesis.

Experimental results

Research questions

  • RQ1Can CGAN-based data augmentation effectively reduce class imbalance in encrypted traffic datasets?
  • RQ2How does PacketCGAN compare to traditional data augmentation methods (ROS, SMOTE, vanilla GAN) in improving classification performance?
  • RQ3Does the use of conditional generation lead to more realistic and discriminative synthetic traffic samples than unconditional GANs?
  • RQ4To what extent does data augmentation via PacketCGAN improve the F1-score and accuracy of deep learning models on minority encrypted application classes?
  • RQ5Is the performance gain of PacketCGAN consistent across different benchmark encrypted traffic datasets?

Key findings

  • PacketCGAN-generated synthetic data significantly improved the F1-score for minority classes compared to ROS, SMOTE, and vanilla GAN augmentation.
  • The CNN classifier trained on data augmented with PacketCGAN achieved the highest overall accuracy across all four datasets tested (ISCX2012, USTC-TFC2016, and two derived subsets).
  • PacketCGAN outperformed SMOTE and ROS in macro-averaged F1-score, indicating better generalization to underrepresented traffic types.
  • The conditional nature of the GAN allowed for precise control over the type of encrypted traffic generated, resulting in more semantically relevant synthetic samples.
  • Compared to vanilla GAN, PacketCGAN produced higher-quality synthetic traffic that preserved temporal and statistical features critical for classification.
  • The performance gain was most pronounced in datasets with high class imbalance, confirming the method's effectiveness in real-world scenarios with skewed data distributions.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.