DINOv3 LoRA Multi Source Fusion for Adversarially Robust Firmware Similarity Retrieval
Authors
Files
Abstract
Firmware similarity retrieval requires preserving computational identity across byte-layout and instruction-encoding changes while tracing which evidence sources support a candidate ranking. This study evaluates a DINOv3-LoRA fusion model combining deterministic byte rasters, decoded structural descriptors and instruction-semantic summaries. A pretrained DINOv3 ViT-S/16 provides cached visual tokens, and a rank-four update to the final attention projection adapts its representation. Independently encoded 48-dimensional structural and semantic vectors join the adapted visual output in a normalized 64-dimensional retrieval embedding learned through identity-balanced contrastive training. The execution- checked corpus contains 648 records from 72 twelve-operation computation identities, each with nine layout views. Forty- eight identities support fitting, twelve checkpoint selection and twelve independent assessment. The assessment places three views per identity in a 36-record gallery and six views per identity among 72 queries, with three relevant gallery records for each query. Complete fusion obtains Recall@1 and Recall@5 of 100.00%, mean reciprocal rank 1.0000 and mean average precision 1.0000. Frozen DINOv3 alone has Recall@1 5.56%, whereas direct descriptor concatenation and structural cosine also achieve 100.00% Recall@1 and mAP 1.0000 on this controlled gallery. Frozen-visual fusion attains mAP 0.9988, indicating a small measured increment from the low-rank attention update under the shared input design. At the fixed complete-model checkpoint, structural-source interruption lowers Recall@1 to 93.06% and mAP to 0.9154; semantic interruption retains perfect ranking. Under that structural interruption, a smallest-margin review budget of eighteen queries, one quarter of the assessment set, captures two of five first-rank errors, or 40.00%, while sixteen selected queries remain correctly matched. These findings characterize controlled layout transfer, source dependence and retrospective review selection. Independent firmware architectures, larger candidate galleries and explicit attack models remain essential tests of external robustness.
References
Wang, H., Gao, Z., Zhang, C., Sun, M., Zhou, Y., Qiu, H., & Xiao, X. (2024). CEBin: A cost-effective framework for large-scale binary code similarity detection. Proceedings of the 33rd ACM SIGSOFT International Symposium on Software Testing and Analysis, 149–161. https://doi.org/10.1145/3650212.3652117 DOI: https://doi.org/10.1145/3650212.3652117
Gu, Y., Shu, H., Kang, F., & Hu, F. (2025). UniASM: Binary code similarity detection without fine-tuning. Neurocomputing, 630, 129646. https://doi.org/10.1016/j.neucom.2025.129646 DOI: https://doi.org/10.1016/j.neucom.2025.129646
Agiza, A., Neseem, M., & Reda, S. (2024). MTLoRA: A low-rank adaptation approach for efficient multi-task learning. 2024 IEEE/CVF Conference on Computer Vision and Pattern Recognition, 16196–16205. https://doi.org/10.1109/CVPR52733.2024.01533 DOI: https://doi.org/10.1109/CVPR52733.2024.01533
Zhao, F., Zhang, C., & Geng, B. (2024). Deep multimodal data fusion. ACM Computing Surveys, 56(9), 1–36. https://doi.org/10.1145/3649447 DOI: https://doi.org/10.1145/3649447
Capozzi, G., D’Elia, D. C., Di Luna, G. A., & Querzoni, L. (2024). Adversarial attacks against binary similarity systems. IEEE Access, 12, 161247–161269. https://doi.org/10.1109/ACCESS.2024.3488204 DOI: https://doi.org/10.1109/ACCESS.2024.3488204
Apicella, A., Isgrò, F., & Prevete, R. (2025). Don’t push the button! Exploring data leakage risks in machine learning and transfer learning. Artificial Intelligence Review, 58, 339. https://doi.org/10.1007/s10462-025-11326-3 DOI: https://doi.org/10.1007/s10462-025-11326-3
Lyu, Q., Apidianaki, M., & Callison-Burch, C. (2024). Towards faithful model explanation in NLP: A survey. Computational Linguistics, 50(2), 657–723. https://doi.org/10.1162/coli_a_00511 DOI: https://doi.org/10.1162/coli_a_00511
Hallberg Szabadváry, J., Löfström, T., Johansson, U., Sönströd, C., Ahlberg, E., & Carlsson, L. (2025). Classification with reject option: Distribution-free error guarantees via conformal prediction. Machine Learning with Applications, 20, 100664. https://doi.org/10.1016/j.mlwa.2025.100664 DOI: https://doi.org/10.1016/j.mlwa.2025.100664
Wang, T., Xie, Q., Yu, L., Pan, Z., & Zhang, M. (2025). A survey of binary code representation technology. Frontiers of Information Technology & Electronic Engineering, 26(5), 671–694. https://doi.org/10.1631/FITEE.2400088 DOI: https://doi.org/10.1631/FITEE.2400088
Jia, L., Wu, C., Zhang, P., & Wang, Z. (2024). CodeExtract: Enhancing binary code similarity detection with code extraction techniques. Proceedings of the 25th ACM SIGPLAN/SIGBED International Conference on Languages, Compilers, and Tools for Embedded Systems, 143–154. https://doi.org/10.1145/3652032.3657572 DOI: https://doi.org/10.1145/3652032.3657572
Zhang, Y., Liu, Y., Cheng, G., & Ou, B. (2024). GTrans: Graph Transformer-based obfuscation-resilient binary code similarity detection. Proceedings of the 2024 Workshop on Binary Analysis Research. https://doi.org/10.14722/bar.2024.23006 DOI: https://doi.org/10.14722/bar.2024.23006
Zhou, A., Hu, Y., Xu, X., & Zhang, C. (2024). ARCTURUS: Full coverage binary similarity analysis with reachability-guided emulation. ACM Transactions on Software Engineering and Methodology, 33(4), 1–31. https://doi.org/10.1145/3640337 DOI: https://doi.org/10.1145/3640337
Sasse, L., Nicolaisen-Sobesky, E., Dukart, J., Eickhoff, S. B., Götz, M., Hamdan, S., Komeyer, V., Kulkarni, A., Lahnakoski, J. M., Love, B. C., Raimondo, F., & Patil, K. R. (2025). Overview of leakage scenarios in supervised machine learning. Journal of Big Data, 12, 135. https://doi.org/10.1186/s40537-025-01193-8 DOI: https://doi.org/10.1186/s40537-025-01193-8
Gui, J., Chen, T., Zhang, J., Cao, Q., Sun, Z., Luo, H., & Tao, D. (2024). A survey on self-supervised learning: Algorithms, applications, and future trends. IEEE Transactions on Pattern Analysis and Machine Intelligence, 46(12), 9052–9071. https://doi.org/10.1109/TPAMI.2024.3415112 DOI: https://doi.org/10.1109/TPAMI.2024.3415112
Mao, Y., Ge, Y., Fan, Y., Xu, W., Mi, Y., Hu, Z., & Gao, Y. (2025). A survey on LoRA of large language models. Frontiers of Computer Science, 19(7), 197605. https://doi.org/10.1007/s11704-024-40663-9 DOI: https://doi.org/10.1007/s11704-024-40663-9
Jiang, S., Fu, C., He, S., Lv, J., Han, L., & Hu, H. (2024). BinCola: Diversity-sensitive contrastive learning for binary code similarity detection. IEEE Transactions on Software Engineering, 50(10), 2485–2497. https://doi.org/10.1109/TSE.2024.3411072 DOI: https://doi.org/10.1109/TSE.2024.3411072
Vasileiou, A., & Eberle, O. (2024). Explaining text similarity in Transformer models. Proceedings of the 2024 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1, 7859–7873. https://doi.org/10.18653/v1/2024.naacl-long.435 DOI: https://doi.org/10.18653/v1/2024.naacl-long.435
Zhao, W. X., Liu, J., Ren, R., & Wen, J.-R. (2024). Dense text retrieval based on pretrained language models: A survey. ACM Transactions on Information Systems, 42(4), 1–60. https://doi.org/10.1145/3637870 DOI: https://doi.org/10.1145/3637870
Zhang, P., Wu, C., & Wang, Z. (2024). BinCodex: A comprehensive and multi-level dataset for evaluating binary code similarity detection techniques. BenchCouncil Transactions on Benchmarks, Standards and Evaluations, 4(2), 100163. https://doi.org/10.1016/j.tbench.2024.100163 DOI: https://doi.org/10.1016/j.tbench.2024.100163
Joseph, M. H., & Ravana, S. D. (2024). Reliable information retrieval systems performance evaluation: A review. IEEE Access, 12, 51740–51751. https://doi.org/10.1109/ACCESS.2024.3377239 DOI: https://doi.org/10.1109/ACCESS.2024.3377239
VenkataKeerthy, S., Banerjee, S., Dey, S., Andaluri, Y., PS, R., Kalyanasundaram, S., Pereira, F. M. Q., & Upadrasta, R. (2025). VexIR2Vec: An architecture-neutral embedding framework for binary similarity. ACM Transactions on Software Engineering and Methodology, 34(8), 1–54. https://doi.org/10.1145/3721481 DOI: https://doi.org/10.1145/3721481
Gundersen, O. E., Helmert, M., & Hoos, H. (2024). Improving reproducibility in AI research: Four mechanisms adopted by JAIR. Journal of Artificial Intelligence Research, 81, 1019–1041. https://doi.org/10.1613/jair.1.16905 DOI: https://doi.org/10.1613/jair.1.16905
Baratchi, M., Wang, C., Limmer, S., van Rijn, J. N., Hoos, H., Bäck, T., & Olhofer, M. (2024). Automated machine learning: Past, present and future. Artificial Intelligence Review, 57, 122. https://doi.org/10.1007/s10462-024-10726-1 DOI: https://doi.org/10.1007/s10462-024-10726-1
Wang, L., Chen, S., Jiang, L., Pan, S., Cai, R., Yang, S., & Yang, F. (2025). Parameter-efficient fine-tuning in large language models: A survey of methodologies. Artificial Intelligence Review, 58, 227. https://doi.org/10.1007/s10462-025-11236-4 DOI: https://doi.org/10.1007/s10462-025-11236-4
Liang, P. P., Zadeh, A., & Morency, L.-P. (2024). Foundations & trends in multimodal machine learning: Principles, challenges, and open questions. ACM Computing Surveys, 56(10), 1–42. https://doi.org/10.1145/3656580 DOI: https://doi.org/10.1145/3656580
Baciu, V.-E., Stiens, J., & da Silva, B. (2024). MLino bench: A comprehensive benchmarking tool for evaluating ML models on edge devices. Journal of Systems Architecture, 155, 103262. https://doi.org/10.1016/j.sysarc.2024.103262 DOI: https://doi.org/10.1016/j.sysarc.2024.103262
Dai, R., Li, C., Yan, Y., Mo, L., Qin, K., & He, T. (2025). Unbiased missing-modality multimodal learning. 2025 IEEE/CVF International Conference on Computer Vision, 24507–24517. https://doi.org/10.1109/ICCV51701.2025.02272 DOI: https://doi.org/10.1109/ICCV51701.2025.02272
Bennetot, A., Donadello, I., El Qadi El Haouari, A., Dragoni, M., Frossard, T., Wagner, B., Sarranti, A., Tulli, S., Trocan, M., Chatila, R., Holzinger, A., d’Avila Garcez, A., & Díaz-Rodríguez, N. (2025). A practical tutorial on explainable AI techniques. ACM Computing Surveys, 57(2), 1–44. https://doi.org/10.1145/3670685 DOI: https://doi.org/10.1145/3670685
Liu, H., Zhan, J., & Zhang, Q. (2025). Uncertainty-aware contrastive learning with hard negative sampling for code search tasks. Proceedings of the AAAI Conference on Artificial Intelligence, 39(18), 18807–18815. https://doi.org/10.1609/aaai.v39i18.34070 DOI: https://doi.org/10.1609/aaai.v39i18.34070
Capozzi, G., Tang, T., Wan, J., Yang, Z., D’Elia, D. C., Di Luna, G. A., Cavallaro, L., & Querzoni, L. (2025). On the lack of robustness of binary function similarity systems. 2025 IEEE 10th European Symposium on Security and Privacy, 980–1001. https://doi.org/10.1109/EuroSP63326.2025.00060 DOI: https://doi.org/10.1109/EuroSP63326.2025.00060
Traub, J., Bungert, T., Lüth, C., Baumgartner, M., Maier-Hein, K., Maier-Hein, L., & Jäger, P. (2024). Overcoming common flaws in the evaluation of selective classification systems. Advances in Neural Information Processing Systems, 37, 2323–2347. https://doi.org/10.52202/079017-0076 DOI: https://doi.org/10.52202/079017-0076
Kusa, W., Peikos, G., Staudinger, M., Lipani, A., & Hanbury, A. (2024). Normalised precision at fixed recall for evaluating TAR. Proceedings of the 2024 ACM SIGIR International Conference on Theory of Information Retrieval, 43–49. https://doi.org/10.1145/3664190.3672532 DOI: https://doi.org/10.1145/3664190.3672532
Shi, J., Chen, Y., Xiao, Y., Li, Y., Xu, Z., Qiu, S., Zhang, C., Qi, K., Li, Y., Chen, X., Zou, Y., Liu, Y., & Huo, W. (2025). A large-scale study of AI-based binary function similarity detection techniques for security researchers and practitioners. 2025 40th IEEE/ACM International Conference on Automated Software Engineering, 1070–1082. https://doi.org/10.1109/ASE63991.2025.00093 DOI: https://doi.org/10.1109/ASE63991.2025.00093
