EUVIMEDEUVIMED entdecken
Open Access · CC BY-SA 4.0

Transformer-based multiclass classification for detecting cross-site scripting attacks using supervised feature representation learning with transformer encoder

Arda Surya Editya, Ntivuguruzwa Jean De La Croix

Journal of Soft Computing Exploration · 02.05.2026 · 7 (2) · 199-216

DOI: 10.52465/joscex.v7i2.44 ↗

Kurz gefasst

Fachartikel in der Zeitschrift Journal of Soft Computing Exploration, online erschienen am 02.05.2026. Verfasst von Arda Surya Editya und 1 weiteren Autor:innen. Der Volltext ist frei zugänglich (Open Access, CC BY-SA 4.0).

AbstractBibliografische AngabenZitierenVerwandte Studien

Abstract (Originalsprache)

Cross-Site Scripting (XSS) remains one of the most prevalent web application attacks, allowing malicious scripts to be injected into web pages and executed in users’ browsers. The increasing diversity and structural complexity of XSS payloads make conventional rule-based and signature-based detection methods less adaptive, particularly in multiclass classification scenarios. This study proposes a Transformer-based multiclass classification approach for detecting XSS attacks using supervised feature representation learning with a Transformer encoder. Experimental results show that the proposed Transformer achieved an accuracy of 0.9904, a weighted F1-score of 0.9898, and a macro F1-score of 0.7301. However, the CNN model achieved the highest overall accuracy (0.9934), while Logistic Regression and SVM demonstrated stronger macro-level performance, indicating better class-wise balance under imbalanced data conditions. These findings show that Transformer-based sequence modeling is effective for capturing contextual payload patterns, but its performance on minority classes remains limited in the current experimental setting. Overall, this study highlights both the potential and the limitations of Transformer-based multiclass XSS detection and contributes to the development of more intelligent and practical web attack detection systems.

Zitieren

APA

Editya, A. S., & Croix, N. J. D. L. (2026). Transformer-based multiclass classification for detecting cross-site scripting attacks using supervised feature representation learning with transformer encoder. Journal of Soft Computing Exploration, 7(2), 199-216. https://doi.org/10.52465/joscex.v7i2.44

Vancouver

Editya AS, Croix NJDL. Transformer-based multiclass classification for detecting cross-site scripting attacks using supervised feature representation learning with transformer encoder. Journal of Soft Computing Exploration. 2026;7(2):199-216. doi:10.52465/joscex.v7i2.44

BibTeX
@article{Editya2026,
  author = {Editya, Arda Surya and Croix, Ntivuguruzwa Jean De La},
  title = {Transformer-based multiclass classification for detecting cross-site scripting attacks using supervised feature representation learning with transformer encoder},
  journal = {Journal of Soft Computing Exploration},
  year = {2026},
  volume = {7},
  number = {2},
  pages = {199--216},
  doi = {10.52465/joscex.v7i2.44}
}
Kostenlos starten →