With the advent of the digital age, along with the need of building sophisticated applications, the necessity of being able to analyze software developed by third parties was born, in order to move from a black box approach to a decidedly more complex analysis process based on reverse engineering. For example, it may be important for a company to analyze a program that it plans to use, in order to maintain the security of the organization. There are currently many tools aimed at extracting information from software with the purpose of studying it, understanding it and, in certain cases, customize it. Despite the many strengths and applications of these tools, their usage in real application contexts is negatively affected by serious limitations that significantly reduce their usefulness. The main goal of this study is to create a software analysis tool that can obtain, with the best precision possible, the original structure of the source files of a program before its compilation and eventually provide support to already existing reverse engineering tools. In order to understand the importance of this work, it's fundamental to highlight that the complex constructs of high level programming languages that enable the hierarchical organization of code in functions, classes, but mostly in files, are not maintained into executable code, which is instead composed by a raw sequence of binary instructions. It's easy to understand that this, along with the fact that each high level instruction in the source code is translated into multiple low level instructions in the final binary, makes the analysis significantly harder to perform as software complexity grows. Since reverse engineering is meant to provide a deeper knowledge about the inner workings of applications and that long, unstructured results are often counterproductive, structuring information and knowing the original files split of code can be very helpful to understand the original organization of software.

Con l'avvento dell'era digitale è nata, contemporaneamente all'esigenza di creare software su misura, quella di poter analizzare software prodotto da terze parti, in modo da passare da un approccio black box ad analisi decisamente più complesse basate su reverse engineering. Un'azienda potrebbe ad esempio avere necessità di analizzare un programma a fini di sicurezza. Al momento esistono diversi strumenti in via di sviluppo e in commercio per estrarre informazioni da un software con lo scopo di poterlo studiare, capire ed eventualmente modificare. Nonostante gli innumerevoli pregi e utilizzi di questi strumenti, il loro uso in contesti applicativi reali è negativamente affetto da serie limitazioni che ne riducono fortemente la praticità. Questa tesi ha l'obiettivo di creare uno tool di analisi software in grado di identificare, con la migliore approssimazione possibile, la struttura originale dei file sorgenti di un programma prima della sua compilazione, nonché fornire eventualmente supporto a strumenti di reverse engineering già esistenti. Al fine di comprendere l'importanza di questo lavoro, è fondamentale sottolineare, infatti, che i costrutti complessi dei linguaggi di alto livello per l'organizzazione gerarchica del codice in funzioni, classi, ma soprattuto file, non vengono mantenuti all'interno del codice eseguibile, che si presenta invece come un'unica sequenza di istruzioni macchina. Si può quindi intuire che ciò, unitamente al fatto che ogni istruzione di alto livello è tradotta in molteplici istruzioni di basso livello, comporta un drastico aumento di difficoltà d'analisi al crescere della complessità del programma studiato. Considerando che lo scopo del reverse engineering è la comprensione del software e che risultati d'analisi di dimensioni di difficile gestione e non opportunamente strutturati risultano spesso controproducenti, cercare di recuperare l'organizzazione originaria dei file sorgenti può aiutare notevolmente a capire l'organizzazione originaria del software.

Unlinker : an approach to identify original compilation units in stripped binaries

CAPELLETTI, MAURO
2016/2017

Abstract

With the advent of the digital age, along with the need of building sophisticated applications, the necessity of being able to analyze software developed by third parties was born, in order to move from a black box approach to a decidedly more complex analysis process based on reverse engineering. For example, it may be important for a company to analyze a program that it plans to use, in order to maintain the security of the organization. There are currently many tools aimed at extracting information from software with the purpose of studying it, understanding it and, in certain cases, customize it. Despite the many strengths and applications of these tools, their usage in real application contexts is negatively affected by serious limitations that significantly reduce their usefulness. The main goal of this study is to create a software analysis tool that can obtain, with the best precision possible, the original structure of the source files of a program before its compilation and eventually provide support to already existing reverse engineering tools. In order to understand the importance of this work, it's fundamental to highlight that the complex constructs of high level programming languages that enable the hierarchical organization of code in functions, classes, but mostly in files, are not maintained into executable code, which is instead composed by a raw sequence of binary instructions. It's easy to understand that this, along with the fact that each high level instruction in the source code is translated into multiple low level instructions in the final binary, makes the analysis significantly harder to perform as software complexity grows. Since reverse engineering is meant to provide a deeper knowledge about the inner workings of applications and that long, unstructured results are often counterproductive, structuring information and knowing the original files split of code can be very helpful to understand the original organization of software.
DI FEDERICO, ALESSANDRO
ING - Scuola di Ingegneria Industriale e dell'Informazione
27-lug-2017
2016/2017
Con l'avvento dell'era digitale è nata, contemporaneamente all'esigenza di creare software su misura, quella di poter analizzare software prodotto da terze parti, in modo da passare da un approccio black box ad analisi decisamente più complesse basate su reverse engineering. Un'azienda potrebbe ad esempio avere necessità di analizzare un programma a fini di sicurezza. Al momento esistono diversi strumenti in via di sviluppo e in commercio per estrarre informazioni da un software con lo scopo di poterlo studiare, capire ed eventualmente modificare. Nonostante gli innumerevoli pregi e utilizzi di questi strumenti, il loro uso in contesti applicativi reali è negativamente affetto da serie limitazioni che ne riducono fortemente la praticità. Questa tesi ha l'obiettivo di creare uno tool di analisi software in grado di identificare, con la migliore approssimazione possibile, la struttura originale dei file sorgenti di un programma prima della sua compilazione, nonché fornire eventualmente supporto a strumenti di reverse engineering già esistenti. Al fine di comprendere l'importanza di questo lavoro, è fondamentale sottolineare, infatti, che i costrutti complessi dei linguaggi di alto livello per l'organizzazione gerarchica del codice in funzioni, classi, ma soprattuto file, non vengono mantenuti all'interno del codice eseguibile, che si presenta invece come un'unica sequenza di istruzioni macchina. Si può quindi intuire che ciò, unitamente al fatto che ogni istruzione di alto livello è tradotta in molteplici istruzioni di basso livello, comporta un drastico aumento di difficoltà d'analisi al crescere della complessità del programma studiato. Considerando che lo scopo del reverse engineering è la comprensione del software e che risultati d'analisi di dimensioni di difficile gestione e non opportunamente strutturati risultano spesso controproducenti, cercare di recuperare l'organizzazione originaria dei file sorgenti può aiutare notevolmente a capire l'organizzazione originaria del software.
Tesi di laurea Magistrale
File allegati
File Dimensione Formato  
2017_07_Capelletti.PDF

accessibile in internet per tutti

Descrizione: Testo della tesi
Dimensione 19.66 MB
Formato Adobe PDF
19.66 MB Adobe PDF Visualizza/Apri

I documenti in POLITesi sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.

Utilizza questo identificativo per citare o creare un link a questo documento: https://hdl.handle.net/10589/135107