Semi-Supervised Adversarial Learning Framework for Controller Area Network Bus Intrusion Detection
Jonggwon Kim, Hyungchul Im, Semin Kim, Seongsoo LeeModern connected vehicles rely on the controller area network (CAN) to disseminate safety-critical in-vehicle information, including sensor-related and vehicle-state signals such as engine revolutions per minute (RPM) and gear state, among electronic control units (ECUs). Because CANs lack built-in authentication and encryption, malicious message injection and spoofing can compromise the integrity and availability of vehicular sensing and control functions. Existing deep-learning-based intrusion-detection systems (IDSs) show a clear trade-off: supervised methods perform well on known attacks but rely on costly labels, whereas unsupervised methods can identify unseen attacks but often suffer from high false-positive rates. To address these limitations, this paper proposes a semi-supervised generative adversarial network (SGAN) framework for CAN bus intrusion detection that combines image-based CAN representation with adversarial learning. Consecutive CAN messages are converted into 64×9 grayscale images, and the proposed framework is trained in three phases. First, the discriminator establishes an initial decision boundary using a small labeled subset. It then refines this boundary through distribution-level likelihood objectives and generated samples. Finally, the generator is trained to produce realistic samples capable of deceiving the discriminator. The proposed method was evaluated on the Hacking and Countermeasure Research Lab (HCRL) car-hacking dataset using leave-one-class-out experiments to simulate unknown attacks and achieved an average accuracy of 99.73% and an average F1-score of 99.63% on unknown attacks. Moreover, with only 0.21 M parameters and 3.25 M floating-point operations (FLOPs), the model is well suited for resource-constrained in-vehicle platforms. These results indicate that the proposed framework can serve as a practical cybersecurity component for protecting CAN-carried data in vehicular sensing applications.