Securing Databases: A Comparative Study on the Impact of Implementing SSL on MySQL 8.0.33

—The increasing reliance on online communication and data storage has made protecting sensitive information a top priority for businesses and individuals. This study investigates the effectiveness of different security protocols in safeguarding databases from external threats. By comparing the performance of databases that use SSL and those that do not, this project provided valuable insights into the importance of securing data in transit and the impact of security protocols on database performance. The results of this research could be helpful for companies and individuals looking to improve the security of their databases and protect sensitive information. These research findings demonstrate that enabling SSL encryption leads to longer average execution times for database operations. This latency can be attributed to the computational workload associated with SSL's encryption and decryption processes. However, the trade-off between performance and security is essential to safeguarding data in transit.


I. INTRODUCTION
Database security has seen significant advancement over the past decades, yet the challenge of securing databases against external threats remains pertinent. According to studies by [1]- [3], databases remain a prime target for cyber attackers due to the value of the information stored. Consequently, the demand for adequate security protocols is more crucial than ever.
A variety of security protocols have been developed and implemented in attempts to safeguard data. Among these, Secure Sockets Layer (SSL) has gained widespread attention. SSL provides an added layer of security, ensuring data integrity and confidentiality during electronic transmission [4]. It establishes an encrypted link between a web server and a browser, ensuring that all data remains private [5]. However, studies have noted potential performance trade-offs associated with implementing SSL, such as the increased computational overhead of web applications [6].
Many researchers have emphasized the importance of data security during transit. The [7]- [9] posted that the security of data in transit is equally, if not more, important than at-rest security. While data encryption at rest can help prevent unauthorized access, ensuring data security during transit is vital to prevent interception attacks.
However, there is a knowledge gap concerning the comparative effectiveness of databases that use SSL versus those that do not. Limited empirical research has been conducted to investigate the impact of SSL on database performance and security, leading to a lack of concrete guidance for businesses and individuals.
This study aims to fill this gap by comparing the performance and security of databases with and without SSL implementation. It will enhance understanding of SSL's role in database security and provide insights into the potential trade-offs that businesses might need to consider when implementing SSL.

II. METHOD
To answer the research question and compare the performance and security of databases that use SSL versus Non SSL, this study adopted an experimental research Design, specifically, a comparison experiment.

A. Data Collection 1) Database Selection:
The study was conducted on two distinct sets of databases those with SSL implementation and Non-SSL. These databases were selected across various industries and sizes to represent real-world scenarios comprehensively. The databases were chosen based on their availability, access permissions, and the ability to manipulate security settings.

2) Performance Measurement:
The performance of these databases was measured using a variety of key performance indicators (KPIs), such as response time, ram used, and CPU used. These KPIs were chosen due to their relevance to daily database operations and their potential impact on business productivity.

B. Data Analysis
The collected data were statistically analyzed to identify trends and differences in performance and security between databases with SSL and those without. This analysis helped determine whether SSL use significantly affects database performance and security.

1) Identification of Hardware and Software Requirements
The hardware and software used in the testing process are identified in this phase. This research utilizes virtualization, explicitly making use of VirtualBox. The specifications of virtual machine components are shown in Table I.

2) Dataset Determination
In this case study, the dataset consists of dummy data taken from the Mockaroo website in CSV format for testing on MySQL. The data is then converted to SQL using the Python programming language, allowing it to be input into the database. Experiments will use 10 thousand data records. Step of testing the performances.

3) Design of Testing Steps
In this phase, we detail the steps taken to test the performance of both databases, utilizing the 'mysqlslap' utility in both SSL-required mode and disabled mode with additional SELECT, INSERT, UPDATE, and DELETE queries. The step of testing performances is shown in Fig.1.

4) Implementing and Testing
At this stage, testing begins on both sample database models with testing Mysqlslap Utility, displaying direct implementation along with the results in tables and graphs.
-Testing Insert Query Performance in SSL Mode Required and SSL Mode Disable. In this stage, we tried to input 10000 data records into the database. We are using the mysqlslap to do this stage as per the below syntax.
-Testing Update Query Performance in SSL Mode Required and SSL Mode Disable.
In this stage, we tried to input 10000 data records into the database. We are using mysqlslap to do this stage as per the below syntax.

SSL Mode Required (update)
-Testing Delete Query Performance in SSL Mode Required and SSL Mode Disable.
In this stage, we tried to input 10000 data records into the database. We are using mysqlslap to do this stage as per the below syntax.

SSL Mode Required
-Testing Select Query Performance in SSL Mode Required and SSL Mode Disable.
In this stage, we tried to input 10000 data records into a database. We are using mysqlslap to do this stage as per the below syntax.

III. RESULTS AND DISCUSSION
This study examined the impact of using Secure Sockets Layer (SSL) encryption on the performance of MySQL databases. Using the mysqlslap utility, we evaluated the performance of four types of queries (Insert, Update, Delete, and Select) under two different settings: SSL Mode Required and SSL Mode Disabled. The aim was to evaluate the tradeoff between enhanced security and potential performance degradation.
Our experiments were conducted using a consistent testing environment and the same volume of data for each type of query. Based on the results obtained from the CPU usage, RAM utilization, and response time, it was evident that using SSL encryption affects database performance.
As online threats continue to evolve and proliferate, ensuring data security in transit has become a critical concern for organizations. While SSL encryption may introduce some overhead to database operations, this study illustrates that the cost is justifiable considering the high level of protection it provides against data breaches and theft. Therefore, businesses and individuals should use SSL, or similar security measures, when transmitting sensitive data. Table II provides the data CPU usage comparing SSL required and SSL disabled.
In the provided Table II, we are focusing on the '%system' column, which signifies the CPU utilization by the system for operational management. Our analysis shows that without SSL, the highest value lies at the 30-second mark with a %system value of 19.71%. However, with SSL, the highest value also lies at the 30-second mark but with a %system value of 25.78%.
In addition, the average CPU usage also shows a disparity between conditions with and without SSL. For non-SSL conditions, the average CPU usage (%system) stands at 14.11%, whereas, with SSL, the average CPU usage (%system) is 17.53%.
From this analysis, we can infer that the usage of SSL in this system significantly impacts the rise in CPU utilization. This aligns with the general understanding that SSL encryption and decryption require additional computational resources. Despite this, the increase in resource usage is seen as a necessary cost for improving the security level of data transactions, which is a critical requirement in many applications. Therefore, security and performance must be considered when designing and managing systems.
Based on table III, it can be seen that the maximum value of %system in the insert query process that does not use SSL is at 8.26% at 25 seconds. While the maximum value for %system that uses SSL is at 9.24% at 20 seconds. average on the process of inserting SSL and No SSL. For insert processes that do not use SSL, the average value obtained is 5.95% and for insert processes that use SSL, the average value obtained is 6.40%.
Based on this analysis, it proves that there is an additional use of %system resources when using SSL. Even though these results are not significant, this proves that there is an influence on the use of SSL in the insert query.The analysis of the table above provides an insightful depiction of the variations in system resource usage under the SSL and non-SSL scenarios during the execution of 'Insert' database operations. Each record in the table symbolizes the system resource consumption at different points in time while running the 'Insert' operation.
Focusing on the '%system' column, which represents the percentage of CPU time spent on system-level operations, we can note a few striking observations. In the case of operations without SSL, the CPU usage peaks at 8.26% at the 25-second mark. This indicates the highest level of system resources allocated towards managing the 'Insert' query within the span of the operation. It is important to note that these results depict the system's response under an environment without the added overhead of encryption and decryption, inherent to SSL. On the other hand, when the same operation is performed with SSL, we observe a slightly higher peak system usage of 9.24% at the 20-second mark. This increase can likely be attributed to the extra computational work associated with the SSL's encryption and decryption processes, effectively demanding more from the system resources.
Examining the averages, we see a subtle increase from the non-SSL 'Insert' operations to those with SSL, moving from 5.95% to 6.40% respectively. This underlines the slight additional overhead that comes with using SSL.
Despite the marginally increased demand on system resources with SSL, the difference may not significantly impact the overall performance of the system. However, the increased security provided by SSL during data transmission cannot be overlooked.
Based on table IV, it can be seen that at 5-15 seconds the value of the %system update process that does not use SSL has a lower value compared to the %system update process that uses SSL. Whereas the maximum value for the %system update process that does not use SSL is 3.38% at 45 seconds and for the %system update process that uses SSL is 1.9 at 15 seconds. For the average value, the update process does not use SSL has a value of 2.18% while the update process using SSL has an average value of 1.26%.
Based on the analysis, this is very different from the other three processes because the %system update process that does not use SSL has a higher value than the %system process that uses SSL. This may be caused by many things and this requires further research. Analyzing the '%system' column, we observe that in the initial 15 seconds, the Update Query process with SSL enabled records higher CPU utilization at the system level compared to the process without SSL. This can be attributed to the additional computational overhead induced by SSL due to encryption and decryption operations. However, interestingly, post the 20-second mark, the '%system' values for the process without SSL consistently supersede the process with SSL enabled. The maximum CPU utilization at the system level for the No SSL process peaks at 3.38% at the 45-second mark, while for the SSL process, it reaches a high of 1.9% at the 15-second mark. The average CPU utilization at the system level is recorded at 2.18% for the No SSL process and 1.26% for the SSL process. Based on table V, it can be seen that the maximum value of %system in the delete query process that does not use SSL is at 9.17% at 15 seconds. While the maximum value at %system that uses SSL is at 10.58% at 60 seconds. For the average value -average on the process of deleting SSL and No SSL. For the delete process that does not use SSL, the average value obtained is 7.78% and the delete process that uses SSL, the average value obtained is 7.86%.
Based on these results, it was found that implementing SSL in the delete process can affect the needs of the %system process on the CPU. Even so, the average value shows that there is not too much a significant difference.    Overall, this data suggests that enabling SSL does lead to an increase in the average time taken to perform database operations. This increase in latency is likely due to the computational overhead associated with SSL's encryption and decryption processes. While this overhead may impact performance, it also significantly enhances the security of data transactions, an aspect critical in many application scenarios. Consequently, system designers and administrators must consider this trade-off between performance and security.

IV. CONCLUSION
In conclusion, as reliance on online data storage and communication continues to grow, so does the importance of securing this data. This research provides valuable insights into how SSL encryption. At the same time, it may affect performance, which is a critical component in maintaining the confidentiality, integrity, and availability of data in MySQL databases and enabling SSL results in longer average execution times for database operations. This latency is probably caused by the additional computational workload required for SSL's encryption and decryption procedures. Further research is recommended to investigate performance impacts under different network conditions using larger datasets and alternative encryption methods. It would also be interesting to evaluate the performance impacts of SSL on other types of databases or under different workloads.