CVE-2023-4435 (published 2023-08-20T01:15Z)

Improper Input Validation in GitHub repository hamza417/inure prior to build88.

CVSS v3 base score: 5.5, MEDIUM (CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N)

Weakness information:
cwe_id: CWE-20
cwe_name: Improper Input Validation
description: The product receives input or data, but it does
        not validate or incorrectly validates that the input has the
        properties that are required to process the data safely and
        correctly.
extended_description: 
	   Input validation is a frequently-used technique
	   for checking potentially dangerous inputs in order to
	   ensure that the inputs are safe for processing within the
	   code, or when communicating with other components.  When
	   software does not validate input properly, an attacker is
	   able to craft the input in a form that is not expected by
	   the rest of the application. This will lead to parts of the
	   system receiving unintended input, which may result in
	   altered control flow, arbitrary control of a resource, or
	   arbitrary code execution.
	   Input validation is not the only technique for
	   processing input, however.  Other techniques attempt to
	   transform potentially-dangerous input into something safe, such
	   as filtering (CWE-790) - which attempts to remove dangerous
	   inputs - or encoding/escaping (CWE-116), which attempts to
	   ensure that the input is not misinterpreted when it is included
	   in output to another component. Other techniques exist as well
	   (see CWE-138 for more examples.)
	   Input validation can be applied to:
	   
	     raw data - strings, numbers, parameters, file contents, etc.
	     metadata - information about the raw data, such as headers or size
	   
	   Data can be simple or structured.  Structured data
	   can be composed of many nested layers, composed of
	   combinations of metadata and raw data, with other simple or
	   structured data.
	   Many properties of raw data or metadata may need
	   to be validated upon entry into the code, such
	   as:
	   
	     specified quantities such as size, length, frequency, price, rate, number of operations, time, etc.
	     implied or derived quantities, such as the actual size of a file instead of a specified size
	     indexes, offsets, or positions into more complex data structures
	     symbolic keys or other elements into hash tables, associative arrays, etc.
	     well-formedness, i.e. syntactic correctness - compliance with expected syntax 
	     lexical token correctness - compliance with rules for what is treated as a token
	     specified or derived type - the actual type of the input (or what the input appears to be)
	     consistency - between individual data elements, between raw data and metadata, between references, etc.
	     conformance to domain-specific rules, e.g. business logic 
	     equivalence - ensuring that equivalent inputs are treated the same
	     authenticity, ownership, or other attestations about the input, e.g. a cryptographic signature to prove the source of the data
	   
	   Implied or derived properties of data must often
	   be calculated or inferred by the code itself.  Errors in
	   deriving properties may be considered a contributing factor
	   to improper input validation.
	   
	   Note that "input validation" has very different
	   meanings to different people, or within different
	   classification schemes.  Caution must be used when
	   referencing this CWE entry or mapping to it.  For example,
	   some weaknesses might involve inadvertently giving control
	   to an attacker over an input when they should not be able
	   to provide an input at all, but sometimes this is referred
	   to as input validation.
	   Finally, it is important to emphasize that the
	   distinctions between input validation and output escaping
	   are often blurred, and developers must be careful to
	   understand the difference, including how input validation
	   is not always sufficient to prevent vulnerabilities,
	   especially when less stringent data types must be
	   supported, such as free-form text. Consider a SQL injection
	   scenario in which a person's last name is inserted into a
	   query. The name "O'Reilly" would likely pass the validation
	   step since it is a common last name in the English
	   language. However, this valid name cannot be directly
	   inserted into the database because it contains the "'"
	   apostrophe character, which would need to be escaped or
	   otherwise transformed. In this case, removing the
	   apostrophe might reduce the risk of SQL injection, but it
	   would produce incorrect behavior because the wrong name
	   would be recorded.
       
         

Fix information:
repo_url: https://github.com/hamza417/inure
commit_details: repo_url: https://github.com/hamza417/inure
author: Hamza417
author_date: 2023-08-15 20:25:21+05:30
msg: Build88

  - Fixed SH file exploit
repository: repo_url: https://github.com/hamza417/inure
repo_name: Hamza417/Inure
description: An elegant and beautiful premium Android app manager for rooted and non-rooted devices with a built-in terminal, analytics, debloat, stats and various other panels with an independent custom theme engine, developed with purely custom APIs created for this app.
repo_language: Kotlin
owner: hamza417
file_changes: filename: SECURITY.md
change_type: ModificationType.MODIFY
diff: @@ -11,16 +11,21 @@ you to report it to me confidentially. To report a security vulnerability, pleas
 1. **Do Not Disclose Publicly:** Please do not share potential vulnerabilities publicly until I have
 had a chance to address them.
 
-2. **Email Notification:** Send an email to [Hamza Rizwan](mailto:hamzarizwan243@gmail.com) describing 
-the potential vulnerability. Please include the following details in your report:
+2. **Email Notification:** Send an email to [Hamza Rizwan](mailto:hamzarizwan243@gmail.com)
+   describing
+   the potential vulnerability. Please include the following details in your report:
 
     - Description of the vulnerability and the potential impact.
     - Steps to reproduce the vulnerability.
     - Any relevant technical details that could assist in reproducing or understanding the issue.
 
-3. **Wait for Response:** You should receive an acknowledgment of your report within a few hours. I will work with you to understand and verify the issue.
+3. **Wait for Response:** You should receive an acknowledgment of your report within a few hours. I
+   will work
+   with you to understand and verify the issue.
 
-4. **Cooperation:** I appreciate your cooperation in keeping the details of the vulnerability confidential until we've resolved the issue.
+4. **Cooperation:** I appreciate your cooperation in keeping the details of the vulnerability
+   confidential
+   until we've resolved the issue.
 
 ## Responsible Disclosure Guidelines
 

programming_language: Markdown
filename: AndroidManifest.xml
change_type: ModificationType.MODIFY
diff: @@ -528,6 +528,7 @@
             android:exported="true"
             android:icon="@mipmap/ic_terminal"
             android:label="@string/execute"
+            android:enabled="false"
             android:launchMode="singleTask"
             android:roundIcon="@mipmap/ic_terminal_round">
             <intent-filter>

programming_language: Ruby
filename: changelogs.html
change_type: ModificationType.MODIFY
diff: @@ -59,6 +59,9 @@
 <ul>
     <li>Fixed a few issues with unlocker detection.</li>
     <li>Internal code protection.</li>
+    <li>Disabled support for execute as Android default FS model doesn't allow efficient file
+        parsing and using this also poses a major security risk.
+    </li>
 </ul>
 
 <br>

programming_language: HTML
filename: BashAssociation.kt
change_type: ModificationType.MODIFY
diff: @@ -13,6 +13,11 @@ class BashAssociation : BaseActivity() {
     override fun onCreate(savedInstanceState: Bundle?) {
         super.onCreate(savedInstanceState)
 
+        showWarning("ERR: This is not supported anymore, kindly use the terminal app to run scripts")
+
+        return
+
+        @Suppress("UNREACHABLE_CODE")
         intent.data?.let {
             contentResolver.openInputStream(it)?.use { inputStream ->
                 val file = File(applicationContext.cacheDir?.path + "/" + DocumentFile.fromSingleUri(applicationContext, it)!!.name)

programming_language: Scala
filename: ComponentManager.kt
change_type: ModificationType.MODIFY
diff: @@ -9,7 +9,6 @@ import app.simple.inure.R
 import app.simple.inure.activities.association.ApkInstallerActivity
 import app.simple.inure.activities.association.AppInformationActivity
 import app.simple.inure.activities.association.AudioPlayerActivity
-import app.simple.inure.activities.association.BashAssociation
 import app.simple.inure.activities.association.ImageActivity
 import app.simple.inure.activities.association.InformationActivity
 import app.simple.inure.activities.association.ManifestAssociationActivity
@@ -49,7 +48,7 @@ class ComponentManager : ScopedFragment() {
                     Triple(R.mipmap.ic_launcher, R.string.manifest, ManifestAssociationActivity::class.java),
                     Triple(R.mipmap.ic_launcher, R.string.text_viewer, TextViewerActivity::class.java),
                     Triple(R.mipmap.ic_launcher, R.string.ttf_viewer, TTFViewerActivity::class.java),
-                    Triple(R.mipmap.ic_terminal, R.string.execute, BashAssociation::class.java),
+                    // Triple(R.mipmap.ic_terminal, R.string.execute, BashAssociation::class.java),
             )
 
             list.sortBy {

programming_language: Scala