Please use this identifier to cite or link to this item:
https://hdl.handle.net/1822/82993
Title: | Fast scan, an improved approach using machine learning for vulnerability identification |
Author(s): | Baptista, Tiago João Fernandes |
Advisor(s): | Henriques, Pedro Rangel Oliveira, Nuno |
Keywords: | Vulnerability Attention models Atatic analysis Security Vulnerabilidade Modelos de atenção Análise estática Segurança |
Issue date: | 3-Mar-2022 |
Abstract(s): | This document presents a Master Thesis in the Integrated Master’s in Informatics Engi neering focused on the automatic identification of vulnerabilities, that was accomplished at
Universidade do Minho in Braga, Portugal.
This thesis work aims at developing a machine learning based tool for automatic iden tification of vulnerabilities on programs (source, high level code), that uses an abstract
syntax11tree representation. It is based on FastScan, using code2seq approach. Fastscan
is a recently developed system aimed capable of detecting vulnerabilities in source code
using machine learning techniques. Nevertheless, FastScan is not able of identifying the
vulnerability type. In the presented work the main goal is to go further and develop a
method to identify specific types of vulnerabilities. As will be shown, the goal will be
achieved by changing the method of receiving and processing in a different way the input
data and developing an architecture that brings together multiple models to predict different
specific vulnerabilities. The best f1 metric obtained is 93% resulting in a precision of 90% and
accuracy of 85%, according to the performed tests and regarding a trained model to predict
vulnerabilities of the injection type. These results were obtained with the contribution given
by the optimization of the model’s hyperparameters and also the use of the Search Cluster
from University of Minho that greatly diminished the necessary time to perform training
and testing. It is important to refer that overfitting was detected in the late stages of the tests,
so this results do not represent the true value in real context. Also an interface is presented,
it allows to better interact with the models and analyse the scan results. Este documento apresenta uma dissertação do Mestrado Integrado em Engenharia Infor mática, que tem como foco a automação da deteção de vulnerabilidades e foi concluída na Universidade do Minho em Braga, Portugal. O trabalho apresentado nesta tese pretende desenvolver uma ferramenta que utiliza machine learning e que seja capaz de identificar vulnerabilidades em código. Utilizando para isso a representação do mesmo numa abstract syntax tree. Tem como base FastScan que utiliza a abordagem do code2seq. Fastscan é um projeto recentemente desenvolvido que é capaz de detetar vulnerabilidades em código utilizando técnicas de machine learning, sendo que tem algumas lacunas como o facto de não ser capaz de identificar vulnerabilidades específicas. No trabalho apresentado o objetivo é ir mais além e desenvolver um método capaz de identificar qual o tipo específico de vulnerabilidade presente. Como será apresentado ao longo do documento, este objetivo será alcançado pela alteração do método de receção e processamento dos dados recebidos, assim como o desenvolvimento de uma arquitetura que junte os vários modelos de maneira a cooperarem e a ferramenta ser capaz de detetar e prever a presença de vulnerabilidades específicas. A melhor métrica de f1 obtida foi de 93%, com precisão de 90% e accuracy de 85%, de acordo com os testes efetuados sobre um modelo treinado para prever a presença de vulnerabilidades do tipo de injection. Os resultados foram obtidos devido à otimização dos hiper-parâmetros dos modelos e o cluster Search da Universidade do Minho diminuiu consideravelmente o tempo necessário para efetuar o traino e testes dos modelos. É importante referir que foi detetado overfitting na fase final do desenvolvimento deste trabalho, sendo que os resultados apresentados não representam o valor real dos modelos em contexto real. Para além disso é apresentada uma interface que permite interagir e analisar os resultados de um scan feito pelos modelos. |
Type: | Master thesis |
Description: | Dissertação de mestrado integrado em Engenharia Informática |
URI: | https://hdl.handle.net/1822/82993 |
Access: | Open access |
Appears in Collections: | BUM - Dissertações de Mestrado DI - Dissertações de Mestrado |
Files in This Item:
File | Description | Size | Format | |
---|---|---|---|---|
Tiago Joao Fernandes Baptista.pdf | 3,56 MB | Adobe PDF | View/Open |
This item is licensed under a Creative Commons License