Estudio de los protocolos empleados por bluetooth y desarrollo de un programa para su análisis

Bookmark (0)
Please login to bookmark Close

En el desarrollo de este proyecto se pueden diferenciar tres partes claramente, las cuales contribuyen al objetivo final: servir como introducción al mundo de las tecnologías Bluetooth. Estas tres secciones son las siguientes: “Teoría”, “Desarrollo del Programa” y “Casos de Uso”. Este trabajo cuenta con una introducción que describe el enfoque y los objetivos de este. En la parte de “Teoría”, se expone a que nos referimos con la palabra “Bluetooth” de forma más concreta. Bluetooth hace referencia a dos tecnologías distintas: Bluetooth Classic y Bluetooth Low Energy. A menudo nos referimos a Bluetooth como si fuera una sola tecnología, pero estas dos son incompatibles, aunque compartan ciertas características. Se hace una breve introducción de la función común y características físicas que estas comparten y de las características que diferencian ambas tecnologías. Una vez hecho esto, se estudia en mayor detalle cada una de estas. Estudiamos los protocolos más comunes y componentes más importantes de Classic y LE para sentar unas bases que nos permitan entender la comunicación entre dispositivos conectados por Bluetooth. Se dedican también dos secciones suplementarias al HCI y a los codecs, los cuales son partes fundamentales en la comunicación. En la sección “Desarrollo del Programa”, se describe paso a paso como se ha desarrollado el programa. Contiene apartados para cada uno de los elementos indispensables en el proyecto, además de una pequeña introducción que indica lo que ha guiado el desarrollo. El apartado de versionamiento explica cómo se ha creado un repositorio GitHub para preservar y actualizar el trabajo. En el siguiente apartado se explica punto por punto cómo obtener las fuentes de los datos Bluetooth que vamos a analizar y en el que viene a continuación, qué programa se usa para tratar los datos y que datos se seleccionan según cada protocolo. Por último, se explica cómo configurar un entorno virtual de python y como se ha programado y el aspecto y funcionalidades que tiene el programa. Por último, ponemos a prueba los conocimientos obtenidos y el programa mediante 7 casos de prueba con 7 dispositivos diferentes que usan tecnología Bluetooth. La finalidad de esto es mostrar la utilidad que tiene el programa a la hora de analizar tráfico Bluetooth de cualquier tipo y de cómo con una introducción para nada extensa, se puede comenzar a comprender cómo funcionan las tecnologías Bluetooth. Para cada uno de estos casos de prueba, se establecen varios tests que permiten ver los distintos paquetes que se envían relacionados a cada uno de los protocolos usados durante la comunicación. Se analizan los paquetes para intentar averiguar cómo funcionan los dispositivos y cómo utilizan los distintos protocolos para cada situación. En ocasiones se pueden distinguir patrones que nos permiten hacer hipótesis bastante factibles y en otras resulta más difícil, dependiendo en gran medida de cómo los desarrolladores de estos dispositivos hayan decidido implementar los envíos de información. Como se puede observar, es un proyecto amplio que trata los temas de forma superficial. El objetivo no es una comprensión completa si no conocer los elementos principales. Esto abre la posibilidad de que cada individuo se especialice en las partes que más le interesen.
ABSTRACT
In the development of this project, three sections that contribute to the final objective, which is to serve as an introduction to the world of Bluetooth technologies, can be clearly distinguished. The three sections mentioned before are the following: “Theory”, “Development of the Programme” and “Use Cases”. It also presents an introduction that describes the point of view used to develop the project and the objectives related to it. In the “Theory” part, we describe what is meant with the term “Bluetooth” in a more precise form. Bluetooth refers to two different technologies: Bluetooth Classic and Bluetooth Low Energy. Although we generally use Bluetooth as it were just a technology, Classic and LE are not compatible even though they share some characteristics. A brief introduction about the common functionality and physical characteristics that they share and about the ones that are different is presented. Afterwards, we study each of them in more detail. A study of the most common protocols and components is performed to allow the reader to comprehend how the communication between two Bluetooth devices is performed. Two additional sections are dedicated to explain the concepts of the HCI and the codecs, which are fundamental elements in Bluetooth communications. In the section of “Development of the Programme”, it is described step by step how the programme is developed. It contains parts for each of the essential elements needed for this project. Additionally, it also has a small introduction describing the points that have guided it. The versioning section explains how a GitHub repository has been created to preserve and update the project. In the next section, it is described point by point how to obtain the Bluetooth source data that is going to be analyzed. Afterwards, the software that is used to treat the data is presented and the data fields that are selected for each of the protocols. Finally, it is shown how to configure a python virtual environment and how the programme has been coded and the visual aspects and functionalities that it presents. In the last section, the acquired knowledge and the programme are put to the test with 7 different use cases involving 7 different devices which all use Bluetooth technologies. The purpose of this is to show the usefulness the developed programme has and how it is able to analyze all sorts of Bluetooth traffic. It also serves to demonstrate that it is possible to begin to comprehend how Bluetooth technologies work with just a brief introduction to the theory. For each of the use cases, various tests are performed that allow us to see the different protocols and their data frames that are sent during the communication. The data frames are analyzed to try to discover how the devices work and how they use the different protocols for each situation. Occasionally, some patterns can be distinguished that allow us to formulate reasonably feasible hypotheses. On other occasions, it is more difficult. It depends on how the manufacturers have decided to implement the delivery of the data. As it can be noted, it is a broad project that treats themes in a superficial way. The objective is not an in-depth understanding of the technologies, but to 4 know the main elements that are used by them. This gives the opportunity to every individual to specialise in the fields that they find most interesting.

​En el desarrollo de este proyecto se pueden diferenciar tres partes claramente, las cuales contribuyen al objetivo final: servir como introducción al mundo de las tecnologías Bluetooth. Estas tres secciones son las siguientes: “Teoría”, “Desarrollo del Programa” y “Casos de Uso”. Este trabajo cuenta con una introducción que describe el enfoque y los objetivos de este. En la parte de “Teoría”, se expone a que nos referimos con la palabra “Bluetooth” de forma más concreta. Bluetooth hace referencia a dos tecnologías distintas: Bluetooth Classic y Bluetooth Low Energy. A menudo nos referimos a Bluetooth como si fuera una sola tecnología, pero estas dos son incompatibles, aunque compartan ciertas características. Se hace una breve introducción de la función común y características físicas que estas comparten y de las características que diferencian ambas tecnologías. Una vez hecho esto, se estudia en mayor detalle cada una de estas. Estudiamos los protocolos más comunes y componentes más importantes de Classic y LE para sentar unas bases que nos permitan entender la comunicación entre dispositivos conectados por Bluetooth. Se dedican también dos secciones suplementarias al HCI y a los codecs, los cuales son partes fundamentales en la comunicación. En la sección “Desarrollo del Programa”, se describe paso a paso como se ha desarrollado el programa. Contiene apartados para cada uno de los elementos indispensables en el proyecto, además de una pequeña introducción que indica lo que ha guiado el desarrollo. El apartado de versionamiento explica cómo se ha creado un repositorio GitHub para preservar y actualizar el trabajo. En el siguiente apartado se explica punto por punto cómo obtener las fuentes de los datos Bluetooth que vamos a analizar y en el que viene a continuación, qué programa se usa para tratar los datos y que datos se seleccionan según cada protocolo. Por último, se explica cómo configurar un entorno virtual de python y como se ha programado y el aspecto y funcionalidades que tiene el programa. Por último, ponemos a prueba los conocimientos obtenidos y el programa mediante 7 casos de prueba con 7 dispositivos diferentes que usan tecnología Bluetooth. La finalidad de esto es mostrar la utilidad que tiene el programa a la hora de analizar tráfico Bluetooth de cualquier tipo y de cómo con una introducción para nada extensa, se puede comenzar a comprender cómo funcionan las tecnologías Bluetooth. Para cada uno de estos casos de prueba, se establecen varios tests que permiten ver los distintos paquetes que se envían relacionados a cada uno de los protocolos usados durante la comunicación. Se analizan los paquetes para intentar averiguar cómo funcionan los dispositivos y cómo utilizan los distintos protocolos para cada situación. En ocasiones se pueden distinguir patrones que nos permiten hacer hipótesis bastante factibles y en otras resulta más difícil, dependiendo en gran medida de cómo los desarrolladores de estos dispositivos hayan decidido implementar los envíos de información. Como se puede observar, es un proyecto amplio que trata los temas de forma superficial. El objetivo no es una comprensión completa si no conocer los elementos principales. Esto abre la posibilidad de que cada individuo se especialice en las partes que más le interesen.
ABSTRACT
In the development of this project, three sections that contribute to the final objective, which is to serve as an introduction to the world of Bluetooth technologies, can be clearly distinguished. The three sections mentioned before are the following: “Theory”, “Development of the Programme” and “Use Cases”. It also presents an introduction that describes the point of view used to develop the project and the objectives related to it. In the “Theory” part, we describe what is meant with the term “Bluetooth” in a more precise form. Bluetooth refers to two different technologies: Bluetooth Classic and Bluetooth Low Energy. Although we generally use Bluetooth as it were just a technology, Classic and LE are not compatible even though they share some characteristics. A brief introduction about the common functionality and physical characteristics that they share and about the ones that are different is presented. Afterwards, we study each of them in more detail. A study of the most common protocols and components is performed to allow the reader to comprehend how the communication between two Bluetooth devices is performed. Two additional sections are dedicated to explain the concepts of the HCI and the codecs, which are fundamental elements in Bluetooth communications. In the section of “Development of the Programme”, it is described step by step how the programme is developed. It contains parts for each of the essential elements needed for this project. Additionally, it also has a small introduction describing the points that have guided it. The versioning section explains how a GitHub repository has been created to preserve and update the project. In the next section, it is described point by point how to obtain the Bluetooth source data that is going to be analyzed. Afterwards, the software that is used to treat the data is presented and the data fields that are selected for each of the protocols. Finally, it is shown how to configure a python virtual environment and how the programme has been coded and the visual aspects and functionalities that it presents. In the last section, the acquired knowledge and the programme are put to the test with 7 different use cases involving 7 different devices which all use Bluetooth technologies. The purpose of this is to show the usefulness the developed programme has and how it is able to analyze all sorts of Bluetooth traffic. It also serves to demonstrate that it is possible to begin to comprehend how Bluetooth technologies work with just a brief introduction to the theory. For each of the use cases, various tests are performed that allow us to see the different protocols and their data frames that are sent during the communication. The data frames are analyzed to try to discover how the devices work and how they use the different protocols for each situation. Occasionally, some patterns can be distinguished that allow us to formulate reasonably feasible hypotheses. On other occasions, it is more difficult. It depends on how the manufacturers have decided to implement the delivery of the data. As it can be noted, it is a broad project that treats themes in a superficial way. The objective is not an in-depth understanding of the technologies, but to 4 know the main elements that are used by them. This gives the opportunity to every individual to specialise in the fields that they find most interesting. Read More