Penetration Test Report (RadicallyOpenSecurity): 2022 Pentest F Droid v1.0

Penetration Test Report
Tracking the Trackers
V 1.0
Amsterdam, September 28th, 2022
Confidential
Document Properties
Client Tracking the Trackers
Title Penetration Test Report
Targets Deployment scripts
F-droid client
Version 1.0
Pentester Abhinav Mishra
Authors Abhinav Mishra, Marcus Bointon
Reviewed by Marcus Bointon
Approved by Melanie Rieback
Version control
Version Date Author Description
0.1 September 19th, 2022 Abhinav Mishra Initial draft
0.2 September 28th, 2022 Marcus Bointon Review
1.0 September 28th, 2022 Marcus Bointon 1.0
Contact
For more information about this document and its contents please contact Radically Open Security B.V.
Name Melanie Rieback
Address Science Park 608
1098 XH Amsterdam
The Netherlands
Phone +31 (0)20 2621 255
Email info@radicallyopensecurity.com
Radically Open Security B.V. is registered at the trade register of the Dutch chamber of commerce under number 60628081.
Table of Contents
1 Executive Summary 4
1.1 Introduction 4
1.2 Scope of work 4
1.3 Project objectives 4
1.4 Timeline 4
1.5 Results In A Nutshell 4
1.6 Summary of Findings 5
1.6.1 Findings by Threat Level 6
1.6.2 Findings by Type 6
1.7 Summary of Recommendations 6
2 Methodology 8
2.1 Planning 8
2.2 Risk Classification 8
3 Reconnaissance and Fingerprinting 10
4 Findings 11
4.1 CLN-002 — XML parsers might be vulnerable to XXE attacks 11
4.2 CLN-005 — Vulnerable TLS versions accepted 12
4.3 CLN-001 — Encryption algorithms using insecure mode and padding scheme 13
4.4 CLN-003 — Clear text traffic is enabled in the application 15
4.5 CLN-004 — HTTP Request URLs are logged 16
5 Non-Findings 17
5.1 NF-007 — Review of Nearby Swap Feature 17
5.2 NF-006 — Review of Deployment Scripts 17
6 Future Work 18
7 Conclusion 19
Appendix 1 Testing team 20
1 Executive Summary
1.1 Introduction
Between September 5, 2022 and September 19, 2022, Radically Open Security B.V. carried out a penetration test for
Tracking the Trackers
This report contains our findings as well as detailed explanations of exactly how ROS performed the penetration test.
1.2 Scope of work
The scope of the penetration test was limited to the following targets:
• Deployment scripts
• F-droid client
The scoped services are broken down as follows:
• Review of deployment scripts: 1 days
• F-droid client review: 3 days
• Reporting: 1 days
• Total effort: 5 days
1.3 Project objectives
ROS will perform a penetration test of the F-droid client and review the deployment scripts with Tracking the Trackers
in order to assess their security. To do so ROS will access the F-droid client app and the deployment scripts, and guide
Tracking the Trackers in attempting to find vulnerabilities, exploiting any such found to try and gain further access and
elevated privileges.
1.4 Timeline
The Security Audit took place between September 5, 2022 and September 19, 2022.
1.5 Results In A Nutshell
During this crystal-box penetration test we found 2 Elevated and 3 Low-severity issues.
4 Radically Open Security B.V.
Confidential
The review of the deployment scripts did not uncover any security issues. However, the F-droid client application had
some misconfiguration. The elevated severity issues are about insecure configuration of TLS, where the application
backend accepts TLS version 1.0 and 1.1. The other elevated severity issue is about a possible issue with the XML
parser in the application.
Three low-severity issues were also discovered related to the Android app leaking URLs in the Android log, an insecure
base network config, and the cryptography implementation in the app.
By exploiting these issues, an attacker might be able to capture the traffic between the Android client and the server,
leak information from the device, perform XXE attacks etc.
1.6 Summary of Findings
ID Type Description Threat level
CLN-002 Input validation The application's XML parser implementation might be Elevated
vulnerable to XML External entity (XXE) attacks.
CLN-005 Insecure configuration The backend domains used by the application accept Elevated
obsolete TLS 1.0 and TLS 1.1 protocols.
CLN-001 Weak Cryptography The encryption algorithms used in the app use an Low
insecure mode and padding scheme.
CLN-003 Insecure configuration The base network config of the application allows clear- Low
text traffic.
CLN-004 Information leakage The Android app (org.fdroid.fdroid.debug ver. 1.14- Low
alpha3-505-gc8514adb9-debug) logs URLs.
Executive Summary 5
1.6.1 Findings by Threat Level
Elevated (2)
Low (3)
40.0%
60.0%
1.6.2 Findings by Type
Insecure configuration (2)
Input validation (1)
20.0%
Weak cryptography (1)
Information leakage (1)
40.0%
20.0%
20.0%
1.7 Summary of Recommendations
ID Type Recommendation
CLN-002 Input validation • Limit resolution of external entities when XML input is parsed.
6 Radically Open Security B.V.
Confidential
CLN-005 Insecure configuration • Unless support for legacy browsers/devices is needed, disable TLS 1.0
and TLS 1.1.
• If TLS 1.0 support is required, disable TLS 1.0 compression to avoid
CRIME attacks.
CLN-001 Weak Cryptography • Replace all uses of RSA/ECB/PKCS1Padding and SHA1 with more
secure alternatives.
CLN-003 Insecure configuration • Unless it is very explicitly needed for the app to work, do not allow or
use unencrypted, clear-text traffic.
• If it is needed, only allow it to explicitly permitted, trusted domains.
CLN-004 Information leakage • Avoid logging any sensitive information like usernames, passwords,
URLs, tokens etc in the Android log.
Executive Summary 7
2 Methodology
2.1 Planning
Our general approach during penetration tests is as follows:
1. Reconnaissance
We attempt to gather as much information as possible about the target. Reconnaissance can take two forms:
active and passive. A passive attack is always the best starting point as this would normally defeat intrusion
detection systems and other forms of protection afforded to the app or network. This usually involves trying to
discover publicly available information by visiting websites, newsgroups, etc. An active form would be more
intrusive, could possibly show up in audit logs and might take the form of a social engineering type of attack.
2. Enumeration
We use various fingerprinting tools to determine what hosts are visible on the target network and, more
importantly, try to ascertain what services and operating systems they are running. Visible services are researched
further to tailor subsequent tests to match.
3. Scanning
Vulnerability scanners are used to scan all discovered hosts for known vulnerabilities or weaknesses. The results
are analyzed to determine if there are any vulnerabilities that could be exploited to gain access or enhance
privileges to target hosts.
4. Obtaining Access
We use the results of the scans to assist in attempting to obtain access to target systems and services, or to
escalate privileges where access has been obtained (either legitimately though provided credentials, or via
vulnerabilities). This may be done surreptitiously (for example to try to evade intrusion detection systems or rate
limits) or by more aggressive brute-force methods. This step also consist of manually testing the application
against the latest (2017) list of OWASP Top 10 risks. The discovered vulnerabilities from scanning and manual
testing are moreover used to further elevate access on the application.
2.2 Risk Classification
Throughout the report, vulnerabilities or risks are labeled and categorized according to the Penetration Testing Execution
Standard (PTES). For more information, see: http://www.pentest-standard.org/index.php/Reporting
These categories are:
• Extreme
Extreme risk of security controls being compromised with the possibility of catastrophic financial/reputational
losses occurring as a result.
8 Radically Open Security B.V.
Confidential
• High
High risk of security controls being compromised with the potential for significant financial/reputational losses
occurring as a result.
• Elevated
Elevated risk of security controls