Adversarial Effectiveness vs. Computational Cost: An Analysis of GCG and nanoGCG Adversarial Suffix Attacks

  • Carlos D. S. Bunn UDESC
  • Matheus R. S. UDESC
  • Milton P. P. Neto UDESC
  • Charles C. Miers UDESC

Resumo


Small Language Models (SLMs) are gaining widespread adoption due to their lower computational cost, faster inference speed, and suitability for deployment on edge devices and resource-constrained environments. The adoption of SLMs in Generative Artificial Intelligence (GenAI) applications makes security evaluation dependent on both adversarial effectiveness and computational cost. We compare Greedy Coordinate Gradient (GCG) and nanoGCG adversarial suffix generation under equivalent experimental conditions using Python Risk Identification Tool (PyRIT). The evaluation considers Attack Success Rate (ASR), execution time, memory usage, estimated cost, and throughput. Our results support defensive red-teaming evaluations by relating attack success to the computational effort required to obtain it.

Referências

Abdin, M. et al. (2024). Phi-3 technical report: A highly capable language model locally on your phone. arXiv preprint arXiv:2404.14219.

GraySwanAI (2025). nanogcg: A fast + lightweight implementation of the gcg algorithm in pytorch. [link]. GitHub repository. Latest release: v0.3.0 (commit 33d8418).

Microsoft AI Red Team (2026). Pyrit documentation: The python risk identification tool for generative ai. [link]. Acesso em: 20 fev. 2026.

Munoz, G. D. L., Minnich, A. J., Lutz, R., Lundeen, R., Dheekonda, R. S. R., Chikanov, N., Jagdagdorj, B.-E., Pouliot, M., Chawla, S., Maxwell, W., et al. (2024). Pyrit: A framework for security risk identification and red teaming in generative ai system. arXiv preprint arXiv:2410.02828.

NVIDIA (2023). Train with mixed precision. NVIDIA Deep Learning Performance Documentation. Acesso em 12 maio 2026.

PyTorch Contributors (2026). CUDA semantics. Disponível em: [link].

Vassilev, A., Oprea, A., Fordyce, A., Anderson, H., Davies, X., and Hamin, M. (2025). Adversarial machine learning: A taxonomy and terminology of attacks and mitigations. NIST Technical Series Publication NIST AI 100-2e2025, National Institute of Standards and Technology, Gaithersburg, MD.

Zou, A., Wang, Z., Carlini, N., Nasr, M., Kolter, J. Z., and Fredrikson, M. (2023). Universal and transferable adversarial attacks on aligned language models. arXiv preprint arXiv:2307.15043.
Publicado
01/09/2026
BUNN, Carlos D. S.; S., Matheus R.; P. NETO, Milton P.; MIERS, Charles C.. Adversarial Effectiveness vs. Computational Cost: An Analysis of GCG and nanoGCG Adversarial Suffix Attacks. In: WORKSHOP DE TRABALHOS DE INICIAÇÃO CIENTÍFICA E DE GRADUAÇÃO - SIMPÓSIO BRASILEIRO DE CIBERSEGURANÇA (SBSEG), 26. , 2026, Armação dos Búzios/RJ. Anais [...]. Porto Alegre: Sociedade Brasileira de Computação, 2026 . p. 335-345. DOI: https://doi.org/10.5753/sbseg_estendido.2026.29263.

Artigos mais lidos do(s) mesmo(s) autor(es)

1 2 > >>