{"id":6437,"date":"2024-06-11T16:45:11","date_gmt":"2024-06-11T19:45:11","guid":{"rendered":"https:\/\/base4sec.com\/sin-categorizar\/owasp-mobile-top-10-2024\/2024\/06\/11\/"},"modified":"2024-06-11T16:45:11","modified_gmt":"2024-06-11T19:45:11","slug":"owasp-mobile-top-10-2024","status":"publish","type":"post","link":"https:\/\/base4sec.com\/en\/research-en\/owasp-mobile-top-10-2024\/2024\/06\/11\/","title":{"rendered":"OWASP Mobile Top 10 2024"},"content":{"rendered":"<p>OWASP Mobile Top 10 is a list compiled by the Open Web Application Security Project (OWASP), a non-profit security community focused on improving software security. This list identifies and describes the ten most critical and common vulnerabilities affecting mobile applications. The purpose of the OWASP Mobile Top 10 is to raise awareness of mobile security threats and provide guidance to developers, security professionals and organizations to mitigate these risks.<\/p>\n<p>Each vulnerability in the list is detailed with a description, indicators that may indicate its presence, mitigation recommendations and examples of related attacks. These vulnerabilities cover a wide range of security issues ranging from poor authentication and authorization, to insecure data storage and insufficient cryptographic protection. The OWASP Mobile Top 10 has been updated in 2024, after 8 years and reflects the latest trends and challenges in the field of mobile security, thus providing valuable guidance for the application development community.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M1: Improper Credential Usage<\/span><\/p>\n<p>Vulnerability M1, &#8220;Improper Credential Usage&#8221;, refers to inappropriate practices related to credential management and storage in mobile applications. This vulnerability can arise when credentials (such as usernames, passwords, authentication tokens, etc.) are not handled securely, exposing them to potential attackers.<\/p>\n<p><span class=\"subtitulo-nota\">Risk indicators<\/span><\/p>\n<p>\u2022\u00a0Insecure storage: Credentials are stored in plain text on the device&#8217;s file system, in unencrypted databases or in unprotected shared preferences.<\/p>\n<p>\u2022\u00a0Insecure transmission: Credentials are sent over the network unencrypted (e.g., using HTTP instead of HTTPS)..<\/p>\n<p>\u2022\u00a0Improper session handling: Sessions are not properly invalidated when logging out, allowing an attacker to reuse session tokens.<\/p>\n<p>\u2022\u00a0Use of obsolete authentication mechanisms: Use of weak encryption algorithms or authentication methods that have been compromised.<\/p>\n<p><span class=\"subtitulo-nota\">Recommended mitigations<\/span><\/p>\n<p>\u2022\u00a0Use secure storage provided by the operating system (e.g. Keychain on iOS, Keystore on Android).<br \/>\n\u2022\u00a0Avoid storing credentials in plain text or in unsecured locations.<br \/>\n\u2022\u00a0Encrypt all communications containing credentials using TLS\/SSL.<br \/>\n\u2022\u00a0Implement HTTPS with secure configurations and valid certificates.<br \/>\n\u2022\u00a0Invalidate session tokens at logout.<br \/>\n\u2022\u00a0Use session tokens with appropriate expiration and revocation times.<br \/>\n\u2022\u00a0Implement secure token renewal mechanisms.<br \/>\n\u2022\u00a0Use multi-factor authentication (MFA) whenever possible.<br \/>\n\u2022\u00a0Employ strong, up-to-date encryption and hashing algorithms.<br \/>\n\u2022\u00a0Do not reuse credentials in different services or applications.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Unsafe storage:<\/b><\/p>\n<p>An attacker with physical access to the device or through an exploit can access a plain text file containing unencrypted stored credentials, thereby gaining unauthorized access to the application or associated services.<\/p>\n<p><b>Traffic interception:<\/b><\/p>\n<p>If an application transmits credentials over HTTP, an attacker who can intercept network traffic (e.g., via a man-in-the-middle attack) can capture the credentials and use them to access the application.<\/p>\n<p><b>Session hijacking:<\/b><\/p>\n<p>If session tokens are not properly invalidated at logout, an attacker who obtains a valid token (e.g., through an XSS attack) can reuse it to access the user&#8217;s session without needing to know the user&#8217;s credentials.<\/p>\n<p><b>Obsolete authentication:<\/b><\/p>\n<p>Using weak hashing algorithms such as MD5 to store passwords can allow an attacker who obtains the password database to crack passwords with relative ease using brute force or dictionary attacks.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M2: Inadequate Supply Chain Security<\/span><\/p>\n<p>Vulnerability M2, &#8220;Inadequate Supply Chain Security,&#8221; refers to risks associated with the software supply chain in mobile application development. This includes the use of third-party components, libraries, frameworks and external services that are not adequately verified or maintained. The security of an application can be compromised if any of these elements contain vulnerabilities, are compromised or intentionally include malicious code.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0Use of obsolete or unmaintained libraries: Integration of software components that do not receive regular security updates.<\/p>\n<p>\u2022\u00a0Lack of component verification: Failure to perform adequate checks on the integrity and authenticity of third-party components used.<\/p>\n<p>\u2022\u00a0Lack of continuous monitoring: Vulnerabilities of external components used in the application are not actively monitored.<\/p>\n<p>\u2022\u00a0Lack of security policies: Lack of clear policies and procedures to assess and manage risks in the software supply chain.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Use digital signatures and hashes to verify the integrity and authenticity of software components.<\/p>\n<p>\u2022\u00a0Download components only from trusted and verified sources.<\/p>\n<p>\u2022\u00a0Keep all third-party components used in the application up to date.<\/p>\n<p>\u2022\u00a0Regularly monitor vulnerability databases (such as NVD) to detect known problems in the components used.<\/p>\n<p>\u2022\u00a0Conduct periodic security assessments and penetration tests to identify vulnerabilities in third-party components.<\/p>\n<p>\u2022\u00a0Establish an evaluation and approval process for the integration of new components.<\/p>\n<p>\u2022\u00a0Implement clear security policies that address the selection, evaluation and use of third-party components.<\/p>\n<p>\u2022\u00a0Foster a safety culture that values the importance of a safe supply chain.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Injection of malicious code into libraries:<\/b><\/p>\n<p>An attacker compromises a popular library used by many developers. Applications that integrate this library without verifying its integrity may include malicious code that allows the attacker to execute arbitrary code on users&#8217; devices.<\/p>\n<p><b>Use of vulnerable components:<\/b><\/p>\n<p>An application uses an outdated version of an encryption library that has a known vulnerability. An attacker can exploit this vulnerability to decrypt sensitive data transmitted or stored by the application.<\/p>\n<p><b>Supply chain attacks:<\/b><\/p>\n<p>A third-party software vendor is compromised, and the attacker injects malware into a software update. Developers who integrate this update without performing proper checks can inadvertently distribute malware to end users.<\/p>\n<p><b>Unverified units:<\/b><\/p>\n<p>A developer includes an open source library without verifying its origin or security history. The library contains a backdoor that allows an attacker to remotely access the application and user data.<\/p>\n<p><span class=\"subtitulo-nota\">M3 Vulnerability: Insecure Authentication\/Authorization<\/span><\/p>\n<p>The M3 vulnerability, &#8220;Insecure Authentication\/Authorization&#8221;, refers to flaws in the authentication and authorization mechanisms of a mobile application. This includes any weaknesses in how users authenticate to the application and how their permissions and access to different resources within the application are handled. Deficiencies in these mechanisms can allow attackers to impersonate identities, gain unauthorized access to resources and data, or escalate privileges.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0Session tokens that do not expire or are not properly invalidated at logout.<br \/>\n\u2022\u00a0Sessions that do not close automatically after a period of inactivity.<br \/>\n\u2022\u00a0Use of easy-to-guess passwords or passwords without minimum security requirements.<br \/>\n\u2022\u00a0Absence of multi-factor authentication (MFA).<br \/>\n\u2022\u00a0Do not limit the number of failed login attempts.<br \/>\n\u2022\u00a0Transmission of unencrypted credentials.<br \/>\n\u2022\u00a0Storage of credentials in plain text on the device.<br \/>\n\u2022\u00a0Lack of adequate control of access to resources and functionalities.<br \/>\n\u2022\u00a0Users who can escalate privileges due to insufficient controls.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Implement multi-factor authentication (MFA) to add an extra layer of security.<\/p>\n<p>\u2022\u00a0Require strong passwords and enforce periodic password change policies.<\/p>\n<p>\u2022\u00a0Limit the number of failed login attempts and temporarily lock accounts after multiple failed attempts.<\/p>\n<p>\u2022\u00a0Use secure session tokens and set them to expire after a period of inactivity.<\/p>\n<p>\u2022\u00a0Ensure that session tokens are properly invalidated when logging out.<\/p>\n<p>\u2022\u00a0Implement secure cookies with HttpOnly and Secure flags to protect session tokens.<\/p>\n<p>\u2022\u00a0Encrypt credentials during transmission using HTTPS.<\/p>\n<p>\u2022\u00a0Use the operating system&#8217;s secure storage (Keychain on iOS, Keystore on Android) to store credentials.<\/p>\n<p>\u2022\u00a0Implement granular access controls based on roles and permissions.<\/p>\n<p>\u2022\u00a0Perform authorization checks on the server for all sensitive operations.<\/p>\n<p>\u2022\u00a0Avoid relying solely on client-side authorization controls.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Brute force:<\/b><\/p>\n<p>An attacker attempts to log in to the application with multiple username and password combinations, taking advantage of the lack of login attempt limitation. If the application does not have brute force protection, the attacker can eventually guess the correct credentials.<\/p>\n<p><b>Session hijacking:<\/b><\/p>\n<p>If an application does not properly invalidate session tokens at logout, an attacker who obtains a valid session token (e.g., through an XSS attack) can reuse it to access the user&#8217;s account.<\/p>\n<p><b>Escalation of privileges:<\/b><\/p>\n<p>An attacker with access to a normal user account can exploit flaws in authorization controls to gain access to functionality or data reserved for administrators or users with higher privileges.<\/p>\n<p><b>Phishing and man-in-the-middle attacks:<\/b><\/p>\n<p>If credentials are transmitted unencrypted, an attacker can intercept communications and capture credentials using a man-in-the-middle attack. He can also trick users into entering their credentials on a fake website using phishing techniques.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M4: Insufficient Input\/Output Validation<\/span><\/p>\n<p>Vulnerability M4, &#8220;Insufficient Input\/Output Validation,&#8221; refers to the failure to properly validate data being received and sent in a mobile application. This includes failing to properly validate or sanitize user input data, API responses, data received from other applications, or data stored and processed internally. Insufficient validation can allow attackers to inject malicious data, manipulate application behavior, and access sensitive data.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0Form fields that accept any type of data without restrictions.<\/p>\n<p>\u2022\u00a0No checks are performed on limits, formats, data types or characters allowed in the data entered by the user.<\/p>\n<p>\u2022\u00a0Data sent to the browser or other applications without being sanitized, which may allow the injection of malicious scripts or commands.<\/p>\n<p>\u2022\u00a0API responses that are not validated before being processed by the application.<\/p>\n<p>\u2022\u00a0Data displayed to the user without being filtered or sanitized.<\/p>\n<p>\u2022\u00a0Lack of validation in interactions between applications.<\/p>\n<p>\u2022\u00a0Data received from other applications that are not validated before use.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Implement robust client-side and server-side validations for all user input.<\/p>\n<p>\u2022\u00a0Use whitelists to define the formats and types of data allowed.br&gt;<br \/>\n\u2022\u00a0Verify limits, ranges and sizes of data entered.<\/p>\n<p>\u2022\u00a0Use secure libraries and functions to validate input data.<\/p>\n<p>\u2022\u00a0Sanitize all data before displaying it to the user or sending it to other applications.<\/p>\n<p>\u2022\u00a0Correctly escape special characters to avoid script or command injections.<\/p>\n<p>\u2022\u00a0Validate and sanitize responses received from APIs before processing or displaying them to the user.<\/p>\n<p>\u2022\u00a0Implement additional security controls for interactions with external APIs.<\/p>\n<p>\u2022\u00a0Validate data received from other applications before use.<\/p>\n<p>\u2022\u00a0Establish secure communication protocols and validate the authenticity of data sources.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>SQL Injection:<\/b><\/p>\n<p>If an application does not properly validate input data and allows a user to enter malicious data into a form field, an attacker can execute unauthorized SQL commands that compromise the database.<\/p>\n<p><b>Cross-Site Scripting (XSS):<\/b><\/p>\n<p>If an application displays user-entered data without sanitizing it, an attacker can inject malicious scripts that execute in the user&#8217;s browser, allowing the theft of cookies, credentials and other sensitive data.<\/p>\n<p><b>Command injection:<\/b><\/p>\n<p>If a mobile application allows input data to be passed directly to the operating system command line without validation, an attacker can execute arbitrary commands on the device.<\/p>\n<p><b>API data manipulation:<\/b><\/p>\n<p>If an application does not validate external API responses before processing them, an attacker who controls the API or intercepts communications can send malicious data that alters the application&#8217;s behavior or exposes sensitive data.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M5: Insecure Communication<\/span><\/p>\n<p>Vulnerability M5, &#8220;Insecure Communication&#8221;, refers to the lack of adequate protection of data transmitted between the mobile application and its backend servers or between the application and other services. This lack of protection can allow attackers to intercept, modify or eavesdrop on the transmitted data. Insecure communications can expose sensitive data, such as user credentials, personal information, or financial data, to potential attackers.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0Data transmission over HTTP instead of HTTPS.<\/p>\n<p>\u2022\u00a0Use of outdated and vulnerable versions of security protocols (e.g. SSL 2.0\/3.0, TLS 1.0\/1.1).<\/p>\n<p>\u2022\u00a0Failure to properly validate SSL\/TLS certificates.<\/p>\n<p>\u2022\u00a0Use of self-signed certificates without adequate validation mechanisms.<\/p>\n<p>\u2022\u00a0Sending or receiving sensitive data without encryption.<\/p>\n<p>\u2022\u00a0Temporary storage of data in plain text during transmission.<\/p>\n<p>\u2022\u00a0Failure to implement measures to detect and prevent Man-in-the-Middle attacks.<\/p>\n<p>\u2022\u00a0Failure to use server and client identity assurance mechanisms.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Use HTTPS instead of HTTP for all communications.<\/p>\n<p>\u2022\u00a0Implement modern and secure versions of TLS (such as TLS 1.2 or TLS 1.3).<\/p>\n<p>\u2022\u00a0Properly validate the server&#8217;s SSL\/TLS certificates.<\/p>\n<p>\u2022\u00a0Use certificates issued by trustworthy certification authorities.<\/p>\n<p>\u2022\u00a0Implement certificate pinning to ensure that the application only communicates with trusted servers.<\/p>\n<p>\u2022\u00a0Encrypt all sensitive data both in transit and at rest.<\/p>\n<p>\u2022\u00a0Use strong, up-to-date encryption algorithms (such as AES with an appropriate key size).<\/p>\n<p>\u2022\u00a0Implement detection of changes in certificates and alerts about possible Man-in-the-Middle attacks.<\/p>\n<p>\u2022\u00a0Use techniques such as HSTS (HTTP Strict Transport Security) to force the use of HTTPS.<\/p>\n<p>\u2022\u00a0Implement mutual authentication (client-side certificates) to ensure that both client and server can verify each other&#8217;s identity.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Traffic interception (sniffing):<\/b><\/p>\n<p>An attacker can use tools such as Wireshark to intercept unencrypted HTTP traffic and obtain sensitive information such as usernames, passwords or personal data.<\/p>\n<p><b>Man-in-the-Middle attacks:<\/b><\/p>\n<p>An attacker can intercept the communication between the mobile application and the server by presenting a fake SSL certificate. If the application does not validate the certificates correctly, the attacker can decrypt and modify the traffic at will.<\/p>\n<p><b>Downgrade attacks:<\/b><\/p>\n<p>An attacker can force the application to use older and vulnerable versions of security protocols (such as SSL 3.0), exposing the communication to known vulnerabilities.<br \/>\nInjection of malicious content:<br \/>\nIf the communication is not encrypted, an attacker can modify the data in transit, injecting malicious commands, scripts or redirecting users to phishing sites.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M6: Inadequate Privacy Controls<\/span><\/p>\n<p>Vulnerability M6, &#8220;Inadequate Privacy Controls,&#8221; refers to the lack of adequate measures to protect the privacy of users&#8217; personal data in mobile apps. This can include excessive data collection, insecure storage of personal data, lack of adequate consent, and lack of transparency about how data is handled and shared. This vulnerability can lead to privacy breaches, exposure of sensitive data and potential legal issues.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0The application requests permissions to access more information than is necessary for its operation.<\/p>\n<p>\u2022\u00a0Collection of sensitive data without clear justification or functional necessity.<\/p>\n<p>\u2022\u00a0The user&#8217;s explicit consent is not requested before collecting and processing their personal data.<\/p>\n<p>\u2022\u00a0Unclear or difficult to understand terms of service and privacy policies.<\/p>\n<p>\u2022\u00a0Storage of personal data without encryption.<\/p>\n<p>\u2022\u00a0Transmission of personal data without using secure connections (such as HTTPS).<\/p>\n<p>\u2022\u00a0Users cannot access, modify or delete their personal data.<\/p>\n<p>\u2022\u00a0Lack of options for users to limit data collection.<\/p>\n<p>\u2022\u00a0Personal data shared with third parties without adequately informing users.<\/p>\n<p>\u2022\u00a0It is not specified with whom the data is shared and for what purpose.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Collect only the data necessary for the operation of the application.<\/p>\n<p>\u2022\u00a0Evaluate and justify each request for permission or collection of sensitive data.<\/p>\n<p>\u2022\u00a0Request explicit and specific consent from users before collecting and processing their personal data.<\/p>\n<p>\u2022\u00a0Provide clear, accessible and easy to understand terms of service and privacy policies.<\/p>\n<p>\u2022\u00a0Encrypt personal data both at rest and in transit.<\/p>\n<p>\u2022\u00a0Use secure connections (such as HTTPS) for data transmission.<\/p>\n<p>\u2022\u00a0Provide users with options to access, modify and delete their personal data.<\/p>\n<p>\u2022\u00a0Implement privacy controls that allow users to limit the collection and use of their data.<\/p>\n<p>\u2022\u00a0Clearly inform users about what data is collected, how it is used and with whom it is shared.<\/p>\n<p>\u2022\u00a0Establish and communicate clear policies on data sharing with third parties.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Exposure of sensitive data:<\/b><\/p>\n<p>An application that stores personal data without encryption can be exploited by an attacker who gains access to the device or database, exposing sensitive information such as names, addresses, phone numbers, etc.<\/p>\n<p><b>Lack of informed consent:<\/b><\/p>\n<p>An application that collects location data in the background without the user&#8217;s explicit consent may be violating the user&#8217;s privacy, potentially allowing unauthorized tracking and surveillance.<\/p>\n<p><b>Interception of personal data:<\/b><\/p>\n<p>If an application transmits personal data over an unsecured connection (HTTP instead of HTTPS), an attacker intercepting the traffic can capture sensitive information, such as login credentials, financial data, etc.<\/p>\n<p><b>Improperly shared data:<\/b><\/p>\n<p>An application that shares personal data with third parties without properly informing users can lead to the exploitation of that data by advertisers, data brokers or even malicious actors, compromising user privacy.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M7: Insufficient Binary Protections<\/span><\/p>\n<p>The M7 vulnerability, &#8220;Insufficient Binary Protections,&#8221; refers to the lack of adequate measures to protect the binary code of a mobile application against analysis, manipulation and reverse engineering. These protections are crucial to prevent attackers from obtaining sensitive information, discovering vulnerabilities in the app or modifying its behavior to perform malicious activities.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0The binary code is not obfuscated, which facilitates analysis and reverse engineering.<\/p>\n<p>\u2022\u00a0Integrity checks are not implemented to detect unauthorized modifications to the application code.<\/p>\n<p>\u2022\u00a0Debugging tools and settings not disabled in the production version of the application.<\/p>\n<p>\u2022\u00a0No techniques are used to hinder the use of analysis and decompilation tools.<\/p>\n<p>\u2022\u00a0Sensitive information, such as encryption keys and credentials, stored directly in the binary code.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Use obfuscation tools to make binary code more difficult to understand and analyze.<\/p>\n<p>\u2022\u00a0Obfuscate both native code and Java\/Kotlin code in Android apps, and Swift\/Objective-C in iOS apps.<\/p>\n<p>\u2022\u00a0Implement integrity checks at runtime to detect and respond to unauthorized code modifications.<\/p>\n<p>\u2022\u00a0Use hashes and digital signatures to verify the integrity of binaries.<\/p>\n<p>\u2022\u00a0Ensure that debugging options and development tools are disabled in production versions of the application.<\/p>\n<p>\u2022\u00a0Use techniques such as anti-debugging to detect and prevent the use of debuggers in the application.<\/p>\n<p>\u2022\u00a0Use techniques to make it difficult to use analysis and decompilation tools, such as packaging native code and using secure execution environments.<\/p>\n<p>\u2022\u00a0Implement emulator detection and static analysis environments.<\/p>\n<p>\u2022\u00a0Avoid storing encryption keys, credentials and other sensitive information directly in the binary code.<\/p>\n<p>\u2022\u00a0Use the secure storage provided by the operating system (Keychain on iOS, Keystore on Android) to handle sensitive information.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Reverse engineering:<\/b><\/p>\n<p>An attacker uses tools such as Apktool to decompile an Android application and analyze its code. Without proper protections, the attacker can identify vulnerabilities, extract sensitive information or modify the app&#8217;s behavior for his own benefit.<\/p>\n<p><b>Binary modification:<\/b><\/p>\n<p>An attacker modifies the binary code of an application to remove security features, such as authentication checks, and redistribute the modified application. This can allow unauthorized use of the application or exploitation of vulnerabilities.<\/p>\n<p><b>Extraction of encryption keys:<\/b><\/p>\n<p>An attacker analyzes the binary code of an application to extract encryption keys stored in plaintext. With these keys, the attacker can decrypt sensitive data, compromising the user&#8217;s privacy and security.<\/p>\n<p><b>Use of debugging tools:<\/b><\/p>\n<p>If an application does not disable debugging options in the production version, an attacker can use debugging tools to intercept and modify the application&#8217;s execution flow, allowing vulnerabilities to be exploited or data to be manipulated.<\/p>\n<p><span class=\"subtitulo-nota\">M8 Vulnerability: Security Misconfigurations<\/span><\/p>\n<p>Vulnerability M8, &#8220;Security Misconfiguration,&#8221; refers to the misconfiguration of security components in a mobile application or its environment. This can include insecure default configurations, excessive permissions, debugging options enabled in production, and errors in backend server configuration. Misconfigurations can allow attackers to exploit weaknesses in the application, accessing sensitive data or compromising its operation.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0Use of default settings that are not secure by default.<\/p>\n<p>\u2022\u00a0Do not change the default passwords of databases, servers or services.<\/p>\n<p>\u2022\u00a0The application requests more permissions than necessary for its operation.<\/p>\n<p>\u2022\u00a0The principle of least privilege does not apply to access configurations.<\/p>\n<p>\u2022\u00a0Debugging options or detailed logs enabled in the production version.<\/p>\n<p>\u2022\u00a0Exposure of sensitive information through logs or detailed error messages.<\/p>\n<p>\u2022\u00a0Backend servers configured without HTTPS.<\/p>\n<p>\u2022\u00a0Security settings such as Content Security Policy (CSP) or protection against XSS attacks are missing.<\/p>\n<p>\u2022\u00a0Failure to keep application and server components up to date.<\/p>\n<p>\u2022\u00a0Use of deprecated and vulnerable versions of libraries or frameworks.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Review and secure all default settings before deploying the application.<\/p>\n<p>\u2022\u00a0Change default passwords and secure service access settings.<\/p>\n<p>\u2022\u00a0Request only the permissions strictly necessary for the operation of the application.<\/p>\n<p>\u2022\u00a0Apply the principle of least privilege in all access configurations.<\/p>\n<p>\u2022\u00a0Make sure that debugging options and detailed logs are disabled in the production version.<\/p>\n<p>\u2022\u00a0Use appropriate logs that do not expose sensitive information.<\/p>\n<p>\u2022\u00a0Use HTTPS for all communications between the application and the servers.<\/p>\n<p>\u2022\u00a0Implement security policies such as CSP, XSS protection, and input validation.<\/p>\n<p>\u2022\u00a0Apply updates and security patches regularly.<\/p>\n<p>\u2022\u00a0Use updated and secure versions of libraries and frameworks.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Exploitation of default configurations:<\/b><\/p>\n<p>An attacker can access an application&#8217;s database because the default passwords were left unchanged. This allows the attacker to access sensitive data stored in the database.<\/p>\n<p><b>Excess of permits:<\/b><\/p>\n<p>A mobile app that requests permissions to access location, contacts and camera, without functional need, exposes more user data than it should. An attacker exploiting a vulnerability in the app can access this excessive data.<\/p>\n<p><b>Debugging options enabled in production:<\/b><\/p>\n<p>If an application has debugging options enabled, an attacker can obtain detailed information about the inner workings of the application, including possible entry points for exploits.<\/p>\n<p><b>Lack of HTTPS in communications:<\/b><\/p>\n<p>An application that communicates with its backend server via HTTP allows an attacker to perform a Man-in-the-Middle attack to intercept and manipulate transmitted data, including user credentials and other sensitive data.<\/p>\n<p><b>Updates and patches not applied:<\/b><\/p>\n<p>An application using an outdated vulnerable library can be exploited by an attacker to execute malicious code or compromise data. Known vulnerabilities can be easily exploited if available security patches are not applied.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M9: Insecure Data Storage<\/span><\/p>\n<p>Vulnerability M9, &#8220;Insecure Data Storage,&#8221; refers to the lack of adequate measures to protect data stored on a mobile device. This vulnerability can allow attackers to access sensitive data, such as user credentials, personal information and financial data, if they manage to compromise the device or access its storage files.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0Sensitive data stored unencrypted in the device&#8217;s local storage.<\/p>\n<p>\u2022\u00a0Use of storage APIs that do not provide encryption or adequate security measures.<\/p>\n<p>\u2022\u00a0Sensitive data recorded in accessible log files.<\/p>\n<p>\u2022\u00a0Local databases that do not implement encryption for stored sensitive data.<\/p>\n<p>\u2022\u00a0Sensitive data files that do not have appropriately restricted access permissions.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Use strong encryption (such as AES) for all sensitive data stored locally.<\/p>\n<p>\u2022\u00a0Implement encryption both at rest and in transit.<\/p>\n<p>\u2022\u00a0Employ the secure storage APIs provided by the operating system (e.g. Keychain on iOS and Keystore on Android).<\/p>\n<p>\u2022\u00a0Avoid using unsecured external storage for sensitive data.<\/p>\n<p>\u2022\u00a0Store as little sensitive data locally as possible.<\/p>\n<p>\u2022\u00a0Consider whether it is necessary to store certain data on the device.<\/p>\n<p>\u2022\u00a0Avoid recording sensitive data in log files.<\/p>\n<p>\u2022\u00a0Ensure that logs are protected and accessible only to authorized users.<\/p>\n<p>\u2022\u00a0Set appropriate file permissions to restrict access to sensitive data.<\/p>\n<p>\u2022\u00a0Use operating system access control mechanisms to protect files.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Access to plain text data:<\/b><\/p>\n<p>If an application stores user credentials in plain text in local storage, an attacker who gains physical access to the device or manages to compromise it through malware can read this data without the need to decrypt anything.<\/p>\n<p><b>Exploitation of insecure storage APIs:<\/b><\/p>\n<p>An application that uses a storage API without proper encryption can allow an attacker to easily access stored data through malicious applications or data analysis tools.<\/p>\n<p><b>Log data extraction:<\/b><\/p>\n<p>If an application records sensitive data, such as authentication tokens, in log files, an attacker who has access to these files can steal this data and compromise user accounts.<\/p>\n<p><b>Compromise of unencrypted local databases:<\/b><\/p>\n<p>If an application stores personal information in an unencrypted SQLite database, an attacker who gains access to the database file can read all the information without additional authentication.<\/p>\n<p><b>Access to files with inappropriate permissions:<\/b><\/p>\n<p>If files containing sensitive data have overly broad access permissions, any application or device user can access them. This can lead to exposure of critical information.<\/p>\n<p><span class=\"subtitulo-nota\">Vulnerability M10: Insufficient Cryptography<\/span><\/p>\n<p>Vulnerability M10, &#8220;Insufficient Cryptography,&#8221; refers to the inadequate or weak use of encryption techniques in a mobile application to protect sensitive data. This can include the use of weak encryption algorithms, improper implementation of encryption, and failure to adequately protect keys and sensitive data. Inadequate cryptographic implementation can allow attackers to access, modify or compromise sensitive data, compromising the security of the application and the privacy of users.<\/p>\n<p><b>Risk indicators<\/b><\/p>\n<p>\u2022\u00a0Implementation of obsolete or weak encryption algorithms, such as DES or RC4.<\/p>\n<p>\u2022\u00a0Use of weak or predictable encryption keys, such as simple passwords or passwords derived from easily accessible information.<\/p>\n<p>\u2022\u00a0Sensitive data stored or transmitted without encryption or with insufficient encryption.<\/p>\n<p>\u2022\u00a0Insecure storage of encryption keys, such as storing them in plaintext or unsecured storage.<\/p>\n<p>\u2022\u00a0Improper implementation of security protocols, such as SSL\/TLS, which may allow man-in-the-middle attacks or expose sensitive data.<\/p>\n<p><b>Recommended mitigations<\/b><\/p>\n<p>\u2022\u00a0Use modern and secure encryption algorithms, such as AES, to protect sensitive data.<\/p>\n<p>\u2022\u00a0Avoid obsolete or weak algorithms.<\/p>\n<p>\u2022\u00a0Generate robust and random encryption keys using secure cryptographic functions.<\/p>\n<p>\u2022\u00a0Avoid using passwords or predictable patterns for key generation.<\/p>\n<p>\u2022\u00a0Encrypt all sensitive data both at rest and in transit using strong encryption algorithms.<\/p>\n<p>\u2022\u00a0Use reliable and well-tested cryptographic libraries to implement encryption.<\/p>\n<p>\u2022\u00a0Store encryption keys securely using mechanisms such as Keychain on iOS or Keystore on Android.<\/p>\n<p>\u2022\u00a0Avoid storing keys in plain text or in places accessible to unauthorized applications.<\/p>\n<p>\u2022\u00a0Configure and use security protocols such as SSL\/TLS properly and securely.<\/p>\n<p>\u2022\u00a0Enable secure configuration options, such as end-to-end encryption and certificate validation, to protect communications.<\/p>\n<p><span class=\"subtitulo-nota\">Examples of attacks<\/span><\/p>\n<p><b>Brute force attacks on weak keys:<\/b><\/p>\n<p>An attacker can perform a brute force attack against a weak or predictable encryption key to decrypt sensitive data stored or transmitted by the application.<\/p>\n<p><b>Dictionary attacks on poorly protected passwords:<\/b><\/p>\n<p>If an application stores user passwords using weak encryption or without adequate protection, an attacker can use a dictionary attack to crack passwords and gain unauthorized access to user accounts.<\/p>\n<p><b>Man-in-the-Middle attacks on unsecured communications:<\/b><\/p>\n<p>If an application transmits sensitive data unencrypted or with weak encryption, an attacker who can intercept the communication can read and modify the data, compromising the confidentiality and integrity of the information.<\/p>\n<p><b>Exploitation of unprotected stored encryption keys:<\/b><\/p>\n<p>If encryption keys are stored insecurely, such as in plain text in a configuration file, an attacker who gains access to these keys can decrypt sensitive data stored or transmitted by the application.<\/p>\n<p><b>Exploitation of misconfigured security protocols:<\/b><\/p>\n<p>If an application uses security protocols such as SSL\/TLS incorrectly or insecurely, an attacker can exploit weaknesses in the configuration to perform man-in-the-middle attacks and compromise communications.<\/p>\n<p><span class=\"subtitulo-nota\">Conclusion<\/span><\/p>\n<p>These vulnerabilities represent a wide range of security risks that can affect mobile applications. From fundamental issues such as improper credential handling and lack of authentication, to critical failures in the storage and transmission of sensitive data, these vulnerabilities jeopardize the privacy, integrity and security of mobile applications and user data.<\/p>\n<p>To effectively address these vulnerabilities, it is crucial to implement a combination of technical security measures and secure development processes. This includes adopting good encryption practices, proper use of encryption and authentication, implementing appropriate access controls, conducting thorough security testing, and training staff on security issues.<\/p>\n<p>By taking proactive steps to identify, remediate and mitigate these vulnerabilities, organizations can significantly improve the security of their mobile applications, thereby protecting both users and sensitive data. Continued awareness of mobile security threats and commitment to security best practices are essential to ensure a secure and reliable mobile experience for all users.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>OWASP Mobile Top 10 is a list compiled by the Open Web Application Security Project (OWASP), a non-profit security community focused on improving software security. This list identifies and describes the ten most critical and common vulnerabilities affecting mobile applications. The purpose of the OWASP Mobile Top 10 is to raise awareness of mobile security [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":5650,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"advanced_seo_description":"","jetpack_seo_html_title":"","jetpack_seo_noindex":false,"footnotes":""},"categories":[95],"tags":[],"class_list":{"0":"post-6437","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-research-en"},"jetpack_featured_media_url":"https:\/\/base4sec.com\/wp-content\/uploads\/2024\/12\/blog_96.png","_links":{"self":[{"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/posts\/6437","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/comments?post=6437"}],"version-history":[{"count":0,"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/posts\/6437\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/media\/5650"}],"wp:attachment":[{"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/media?parent=6437"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/categories?post=6437"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/base4sec.com\/en\/wp-json\/wp\/v2\/tags?post=6437"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}