Skip to content

Commit 4104b10

Browse files
committed
fix curly quotes
1 parent 5658212 commit 4104b10

29 files changed

+62
-62
lines changed

Document/0x02b-MASVS-MASTG-Adoption.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ The [National Institute of Standards and Technology (NIST)](https://www.nist.gov
4949
BSI stands for "Federal Office for Information Security", it has the goal to promote IT security in Germany and is the central IT security service provider for the federal government.
5050

5151
- [Technical Guideline BSI TR-03161 Security requirements for eHealth applications v1.0, 2020](https://www.bsi.bund.de/SharedDocs/Downloads/EN/BSI/Publications/TechGuidelines/TR03161/TR-03161.pdf)
52-
- [Prüfvorschrift für den Produktgutachter des „ePA-Frontend des Versicherten und des „E-Rezept-Frontend des Versicherten v2.0, 2021](https://www.bsi.bund.de/SharedDocs/Downloads/DE/BSI/DigitaleGesellschaft/Pruefvorschrift_Produktgutachter_ePA-Frontend.pdf)
52+
- [Prüfvorschrift für den Produktgutachter des „ePA-Frontend des Versicherten" und des „E-Rezept-Frontend des Versicherten v2.0, 2021](https://www.bsi.bund.de/SharedDocs/Downloads/DE/BSI/DigitaleGesellschaft/Pruefvorschrift_Produktgutachter_ePA-Frontend.pdf)
5353

5454
### ioXt
5555

Document/0x02c-Acknowledgements.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ To achieve this status, you'll need to demonstrate that you **make consistent hi
3434

3535
If you'd like to apply please contact the project leaders by sending an email to [Sven Schleier](mailto:sven.schleier@owasp.org) and [Carlos Holguera](mailto:carlos.holguera@owasp.org) who will validate your application and provide you with a _contribution report_.
3636

37-
After the initial evaluation period (see above), youll need to send back the contribution report including sufficient evidence (e.g links to PRs) showing what you've done in that period that goes inline with **the minimum meaningful monthly contributions**.
37+
After the initial evaluation period (see above), you'll need to send back the contribution report including sufficient evidence (e.g links to PRs) showing what you've done in that period that goes inline with "**the minimum meaningful monthly contributions**".
3838

3939
### Important Disclaimers
4040

Document/0x04a-Mobile-App-Taxonomy.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
When we use the term "mobile application" or "mobile app," we are referring to a self-contained computer program designed to execute on a mobile device. At the time of publication, the Android and iOS operating systems cumulatively comprise [more than 99% of the mobile OS market share](https://www.idc.com/promo/smartphone-market-share/os) and mobile Internet usage has surpassed desktop usage for the first time in history. This means that mobile apps are the [most widespread types of Internet-capable apps](https://www.idc.com/promo/smartphone-market-share/os).
44

5-
Also, this guide uses the term "app" as a general term which refers to any kind of application that runs on a mobile OS. Usually, apps run directly on the platform for which theyre designed, run on top of a smart devices mobile browser, or they use a mix of these two methods. In this chapter, we will develop a mobile app taxonomy which will fit all apps into categories then discuss the variations of each app category.
5+
Also, this guide uses the term "app" as a general term which refers to any kind of application that runs on a mobile OS. Usually, apps run directly on the platform for which they're designed, run on top of a smart device's mobile browser, or they use a mix of these two methods. In this chapter, we will develop a mobile app taxonomy which will fit all apps into categories then discuss the variations of each app category.
66

77
We place mobile apps into four categories:
88

@@ -31,7 +31,7 @@ If an app is developed using these these frameworks, the app will use the intern
3131

3232
## Web Apps
3333

34-
Mobile web apps (or simply, _web apps_) are websites designed to look and feel like a _native app_. These apps run on top of a devices browser and are usually developed in HTML5, much like a modern web page. Launcher icons may be used to parallel the same feel of accessing a _native app_; however, these icons are essentially the same as a browser bookmark, simply opening the default web browser to load the referenced web page.
34+
Mobile web apps (or simply, _web apps_) are websites designed to look and feel like a _native app_. These apps run on top of a device's browser and are usually developed in HTML5, much like a modern web page. Launcher icons may be used to parallel the same feel of accessing a _native app_; however, these icons are essentially the same as a browser bookmark, simply opening the default web browser to load the referenced web page.
3535

3636
Because they run within the confines of a browser, web apps have limited integration with the general components of the device (i.e. they are "sandboxed") and their performance is usually inferior compared to native apps. Since developers usually target multiple platforms with a web app, their UIs generally do not follow the design principles of any specific platform. However, _web apps_ are popular because developers can use a single code base to reduce development and maintenance costs and distribute updates without going through the platform-specific app stores. For example, a change to the HTML file for a _web app_ can serve as viable, cross-platform update whereas an update to a store-based app requires considerably more effort.
3737

Document/0x04c-Tampering-and-Reverse-Engineering.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ stp x22, x21, [sp, #-0x30]!
103103
mov rbp, rsp
104104
```
105105

106-
After the obfuscation we can observe that the symbols name is no longer meaningful as shown on the listing below.
106+
After the obfuscation we can observe that the symbol's name is no longer meaningful as shown on the listing below.
107107

108108
```assembly
109109
__T07DVIA_v232zNNtWKQptikYUBNBgfFVMjSkvRdhhnbyyFySbyypF:
@@ -127,11 +127,11 @@ The image shows how control flow flattening alters code. See ["Obfuscating C++ p
127127

128128
#### Dead Code Injection
129129

130-
This technique makes the program's control flow more complex by injecting dead code into the program. Dead code is a stub of code that doesnt affect the original programs behavior but increases the overhead of the reverse engineering process.
130+
This technique makes the program's control flow more complex by injecting dead code into the program. Dead code is a stub of code that doesn't affect the original program's behavior but increases the overhead of the reverse engineering process.
131131

132132
#### String Encryption
133133

134-
Applications are often compiled with hardcoded keys, licences, tokens and endpoint URLs. By default, all of them are stored in plaintext in the data section of an applications binary. This technique encrypts these values and injects stubs of code into the program that will decrypt that data before it is used by the program.
134+
Applications are often compiled with hardcoded keys, licences, tokens and endpoint URLs. By default, all of them are stored in plaintext in the data section of an application's binary. This technique encrypts these values and injects stubs of code into the program that will decrypt that data before it is used by the program.
135135

136136
#### Packing
137137

Document/0x04h-Testing-Code-Quality.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ For example, while an app might query a local SQLite database, such databases us
2121

2222
A _SQL injection_ attack involves integrating SQL commands into input data, mimicking the syntax of a predefined SQL command. A successful SQL injection attack allows the attacker to read or write to the database and possibly execute administrative commands, depending on the permissions granted by the server.
2323

24-
Apps on both Android and iOS use SQLite databases as a means to control and organize local data storage. Assume an Android app handles local user authentication by storing the user credentials in a local database (a poor programming practice well overlook for the sake of this example). Upon login, the app queries the database to search for a record with the username and password entered by the user:
24+
Apps on both Android and iOS use SQLite databases as a means to control and organize local data storage. Assume an Android app handles local user authentication by storing the user credentials in a local database (a poor programming practice we'll overlook for the sake of this example). Upon login, the app queries the database to search for a record with the username and password entered by the user:
2525

2626
```java
2727
SQLiteDatabase db;
@@ -223,7 +223,7 @@ Memory corruption bugs are a popular mainstay with hackers. This class of bug re
223223

224224
- **Integer overflows**: When the result of an arithmetic operation exceeds the maximum value for the integer type defined by the programmer, this results in the value "wrapping around" the maximum integer value, inevitably resulting in a small value being stored. Conversely, when the result of an arithmetic operation is smaller than the minimum value of the integer type, an _integer underflow_ occurs where the result is larger than expected. Whether a particular integer overflow/underflow bug is exploitable depends on how the integer is used. For example, if the integer type were to represent the length of a buffer, this could create a buffer overflow vulnerability.
225225

226-
- **Format string vulnerabilities**: When unchecked user input is passed to the format string parameter of the `printf` family of C functions, attackers may inject format tokens such as ‘%c’ and ‘%n’ to access memory. Format string bugs are convenient to exploit due to their flexibility. Should a program output the result of the string formatting operation, the attacker can read and write to memory arbitrarily, thus bypassing protection features such as ASLR.
226+
- **Format string vulnerabilities**: When unchecked user input is passed to the format string parameter of the `printf` family of C functions, attackers may inject format tokens such as '%c' and '%n' to access memory. Format string bugs are convenient to exploit due to their flexibility. Should a program output the result of the string formatting operation, the attacker can read and write to memory arbitrarily, thus bypassing protection features such as ASLR.
227227

228228
The primary goal in exploiting memory corruption is usually to redirect program flow into a location where the attacker has placed assembled machine instructions referred to as _shellcode_. On iOS, the data execution prevention feature (as the name implies) prevents execution from memory defined as data segments. To bypass this protection, attackers leverage return-oriented programming (ROP). This process involves chaining together small, pre-existing code chunks ("gadgets") in the text segment where these gadgets may execute a function useful to the attacker or, call `mprotect` to change memory protection settings for the location where the attacker stored the _shellcode_.
229229

Document/0x04i-Testing-User-Privacy-Protection.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Like the classic triad of security protection goals: confidentiality, integrity,
3737
- Includes: privacy policies, user education, proper logging and auditing mechanisms, etc.
3838
- **Intervenability**:
3939
- Users should know how to correct their personal information, request its deletion, withdraw any given consent at any time, and receive instructions on how to do so.
40-
- Includes: privacy settings directly in the app, single points of contact for individuals intervention requests (e.g. in-app chat, telephone number, e-mail), etc.
40+
- Includes: privacy settings directly in the app, single points of contact for individuals' intervention requests (e.g. in-app chat, telephone number, e-mail), etc.
4141

4242
> For more details, see Section 5.1.1 "Introduction to data protection goals" in ENISA's ["Privacy and data protection in mobile applications"](https://www.enisa.europa.eu/publications/privacy-and-data-protection-in-mobile-applications "ENISA - Privacy and data protection in mobile applications").
4343

Document/0x05a-Platform-Overview.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Android's software stack is composed of several different layers. Each layer def
1818

1919
<img src="Images/Chapters/0x05a/android_software_stack.png" width="400px" />
2020

21-
**Kernel:** At the lowest level, Android is based on a [variation of the Linux Kernel](https://source.android.com/devices/architecture/kernel) containing some significant additions, including [Low Memory Killer](https://source.android.com/devices/tech/perf/lmkd), wake locks, the [Binder IPC](https://source.android.com/devices/architecture/hidl/binder-ipc) driver, etc. For the purpose of the MASTG, we'll focus on the user-mode part of the OS, where Android significantly differs from a typical Linux distribution. The two most important components for us are the managed runtime used by applications (ART/Dalvik) and [Bionic](https://en.wikipedia.org/wiki/Bionic_(software) "Android (Bionic)"), Androids version of glibc, the GNU C library.
21+
**Kernel:** At the lowest level, Android is based on a [variation of the Linux Kernel](https://source.android.com/devices/architecture/kernel) containing some significant additions, including [Low Memory Killer](https://source.android.com/devices/tech/perf/lmkd), wake locks, the [Binder IPC](https://source.android.com/devices/architecture/hidl/binder-ipc) driver, etc. For the purpose of the MASTG, we'll focus on the user-mode part of the OS, where Android significantly differs from a typical Linux distribution. The two most important components for us are the managed runtime used by applications (ART/Dalvik) and [Bionic](https://en.wikipedia.org/wiki/Bionic_(software) "Android (Bionic)"), Android's version of glibc, the GNU C library.
2222

2323
**HAL:** On top of the kernel, the Hardware Abstraction Layer (HAL) defines a standard interface for interacting with built-in hardware components. Several HAL implementations are packaged into shared library modules that the Android system calls when required. This is the basis for allowing applications to interact with the device's hardware. For example, it allows a stock phone application to use a device's microphone and speaker.
2424

@@ -265,7 +265,7 @@ The process `Zygote` starts up during [Android initialization](https://github.co
265265

266266
#### App Lifecycle
267267

268-
In Android, the lifetime of an app process is controlled by the operating system. A new Linux process is created when an app component is started and the same app doesnt yet have any other components running. Android may kill this process when the latter is no longer necessary or when reclaiming memory is necessary to run more important apps. The decision to kill a process is primarily related to the state of the user's interaction with the process. In general, processes can be in one of four states.
268+
In Android, the lifetime of an app process is controlled by the operating system. A new Linux process is created when an app component is started and the same app doesn't yet have any other components running. Android may kill this process when the latter is no longer necessary or when reclaiming memory is necessary to run more important apps. The decision to kill a process is primarily related to the state of the user's interaction with the process. In general, processes can be in one of four states.
269269

270270
- A foreground process (e.g., an activity running at the top of the screen or a running BroadcastReceiver)
271271
- A visible process is a process that the user is aware of, so killing it would have a noticeable negative impact on user experience. One example is running an activity that's visible to the user on-screen but not in the foreground.
@@ -297,7 +297,7 @@ We recommend that you test both the APK with and without the additional modules,
297297

298298
### Android Manifest
299299

300-
Every app has an Android Manifest file, which embeds content in binary XML format. The standard name of this file is AndroidManifest.xml. It is located in the root directory of the apps Android Package Kit (APK) file.
300+
Every app has an Android Manifest file, which embeds content in binary XML format. The standard name of this file is AndroidManifest.xml. It is located in the root directory of the app's Android Package Kit (APK) file.
301301

302302
The manifest file describes the app structure, its components (activities, services, content providers, and intent receivers), and requested permissions. It also contains general app metadata, such as the app's icon, version number, and theme. The file may list other information, such as compatible APIs (minimal, targeted, and maximal SDK version) and the [kind of storage it can be installed on (external or internal)](https://developer.android.com/guide/topics/data/install-location.html "Define app install location").
303303

@@ -637,7 +637,7 @@ According to [Changes to System Broadcasts](https://developer.android.com/guide/
637637

638638
## Android Application Publishing
639639

640-
Once an app has been successfully developed, the next step is to publish and share it with others. However, apps can't simply be added to a store and shared, they must be first signed. The cryptographic signature serves as a verifiable mark placed by the developer of the app. It identifies the apps author and ensures that the app has not been modified since its initial distribution.
640+
Once an app has been successfully developed, the next step is to publish and share it with others. However, apps can't simply be added to a store and shared, they must be first signed. The cryptographic signature serves as a verifiable mark placed by the developer of the app. It identifies the app's author and ensures that the app has not been modified since its initial distribution.
641641

642642
### Signing Process
643643

@@ -699,7 +699,7 @@ An Android certificate must have a validity period that's longer than that of th
699699

700700
#### Signing an Application
701701

702-
The goal of the signing process is to associate the app file (.apk) with the developer's public key. To achieve this, the developer calculates a hash of the APK file and encrypts it with their own private key. Third parties can then verify the app's authenticity (e.g., the fact that the app really comes from the user who claims to be the originator) by decrypting the encrypted hash with the authors public key and verifying that it matches the actual hash of the APK file.
702+
The goal of the signing process is to associate the app file (.apk) with the developer's public key. To achieve this, the developer calculates a hash of the APK file and encrypts it with their own private key. Third parties can then verify the app's authenticity (e.g., the fact that the app really comes from the user who claims to be the originator) by decrypting the encrypted hash with the author's public key and verifying that it matches the actual hash of the APK file.
703703

704704
Many Integrated Development Environments (IDE) integrate the app signing process to make it easier for the user. Be aware that some IDEs store private keys in clear text in configuration files; double-check this in case others are able to access such files and remove the information if necessary.
705705
Apps can be signed from the command line with the 'apksigner' tool provided by the Android SDK (API level 24 and higher). It is located at `[SDK-Path]/build-tools/[version]`. For API 24.0.2 and below, you can use 'jarsigner', which is part of the Java JDK. Details about the whole process can be found in official Android documentation; however, an example is given below to illustrate the point.

Document/0x05g-Testing-Network-Communication.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ For example, the following configuration uses the `base-config` to prevent clear
5151

5252
Learn more:
5353

54-
- ["A Security Analysts Guide to Network Security Configuration in Android P"](https://www.nowsecure.com/blog/2018/08/15/a-security-analysts-guide-to-network-security-configuration-in-android-p/)
54+
- ["A Security Analyst's Guide to Network Security Configuration in Android P"](https://www.nowsecure.com/blog/2018/08/15/a-security-analysts-guide-to-network-security-configuration-in-android-p/)
5555
- [Android Developers - Network Security Configuration](https://developer.android.com/training/articles/security-config)
5656
- [Android Codelab - Network Security Configuration](https://developer.android.com/codelabs/android-network-security-config)
5757

0 commit comments

Comments
 (0)