Search

Find a vulnerability

Search criteria Use this form to refine search results.
Full-text search supports keyword queries with ranking and filtering.
You can combine vendor, product, and sources to narrow results.
Enable “Apply ordering” to sort by date instead of relevance.

    2 vulnerabilities by Webklex

    CVE-2023-35169 (GCVE-0-2023-35169)

    Vulnerability from nvd – Published: 2023-06-23 20:37 – Updated: 2024-11-27 20:22
    VLAI
    Title
    php-imap vulnerable to RCE through a directory traversal vulnerability
    Summary
    PHP-IMAP is a wrapper for common IMAP communication without the need to have the php-imap module installed / enabled. Prior to version 5.3.0, an unsanitized attachment filename allows any unauthenticated user to leverage a directory traversal vulnerability, which results in a remote code execution vulnerability. Every application that stores attachments with `Attachment::save()` without providing a `$filename` or passing unsanitized user input is affected by this attack. An attacker can send an email with a malicious attachment to the inbox, which gets crawled with `webklex/php-imap` or `webklex/laravel-imap`. Prerequisite for the vulnerability is that the script stores the attachments without providing a `$filename`, or providing an unsanitized `$filename`, in `src/Attachment::save(string $path, string $filename = null)`. In this case, where no `$filename` gets passed into the `Attachment::save()` method, the package would use a series of unsanitized and insecure input values from the mail as fallback. Even if a developer passes a `$filename` into the `Attachment::save()` method, e.g. by passing the name or filename of the mail attachment itself (from email headers), the input values never get sanitized by the package. There is also no restriction about the file extension (e.g. ".php") or the contents of a file. This allows an attacker to upload malicious code of any type and content at any location where the underlying user has write permissions. The attacker can also overwrite existing files and inject malicious code into files that, e.g. get executed by the system via cron or requests. Version 5.3.0 contains a patch for this issue.
    SSVC
    Exploitation: poc Automatable: no Technical Impact: total
    CISA Coordinator (v2.0.3)
    CWE
    • CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
    Assigner
    Impacted products
    Vendor Product Version
    Webklex php-imap Affected: < 5.3.0
    Create a notification for this product.
    Show details on NVD website

    {
      "containers": {
        "adp": [
          {
            "providerMetadata": {
              "dateUpdated": "2024-08-02T16:23:59.360Z",
              "orgId": "af854a3a-2127-422b-91ae-364da2661108",
              "shortName": "CVE"
            },
            "references": [
              {
                "name": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9",
                "tags": [
                  "x_refsource_CONFIRM",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9"
              },
              {
                "name": "https://github.com/Webklex/php-imap/pull/414",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/pull/414"
              },
              {
                "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255"
              },
              {
                "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252"
              },
              {
                "name": "https://github.com/Webklex/php-imap/releases/tag/5.3.0",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/releases/tag/5.3.0"
              }
            ],
            "title": "CVE Program Container"
          },
          {
            "metrics": [
              {
                "other": {
                  "content": {
                    "id": "CVE-2023-35169",
                    "options": [
                      {
                        "Exploitation": "poc"
                      },
                      {
                        "Automatable": "no"
                      },
                      {
                        "Technical Impact": "total"
                      }
                    ],
                    "role": "CISA Coordinator",
                    "timestamp": "2024-11-27T20:22:04.218611Z",
                    "version": "2.0.3"
                  },
                  "type": "ssvc"
                }
              }
            ],
            "providerMetadata": {
              "dateUpdated": "2024-11-27T20:22:12.801Z",
              "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
              "shortName": "CISA-ADP"
            },
            "title": "CISA ADP Vulnrichment"
          }
        ],
        "cna": {
          "affected": [
            {
              "product": "php-imap",
              "vendor": "Webklex",
              "versions": [
                {
                  "status": "affected",
                  "version": "\u003c 5.3.0"
                }
              ]
            }
          ],
          "descriptions": [
            {
              "lang": "en",
              "value": "PHP-IMAP is a wrapper for common IMAP communication without the need to have the php-imap module installed / enabled. Prior to version 5.3.0, an unsanitized attachment filename allows any unauthenticated user to leverage a directory traversal vulnerability, which results in a remote code execution vulnerability. Every application that stores attachments with `Attachment::save()` without providing a `$filename` or passing unsanitized user input is affected by this attack.\n\nAn attacker can send an email with a malicious attachment to the inbox, which gets crawled with `webklex/php-imap` or `webklex/laravel-imap`. Prerequisite for the vulnerability is that the script stores the attachments without providing a `$filename`, or providing an unsanitized `$filename`, in `src/Attachment::save(string $path, string $filename = null)`. In this case, where no `$filename` gets passed into the `Attachment::save()` method, the package would use a series of unsanitized and insecure input values from the mail as fallback. Even if a developer passes a `$filename` into the `Attachment::save()` method, e.g. by passing the name or filename of the mail attachment itself (from email headers), the input values never get sanitized by the package. There is also no restriction about the file extension (e.g. \".php\") or the contents of a file. This allows an attacker to upload malicious code of any type and content at any location where the underlying user has write permissions. The attacker can also overwrite existing files and inject malicious code into files that, e.g. get executed by the system via cron or requests.\n\nVersion 5.3.0 contains a patch for this issue."
            }
          ],
          "metrics": [
            {
              "cvssV3_1": {
                "attackComplexity": "HIGH",
                "attackVector": "NETWORK",
                "availabilityImpact": "HIGH",
                "baseScore": 9.1,
                "baseSeverity": "CRITICAL",
                "confidentialityImpact": "HIGH",
                "integrityImpact": "HIGH",
                "privilegesRequired": "NONE",
                "scope": "CHANGED",
                "userInteraction": "NONE",
                "vectorString": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H",
                "version": "3.1"
              }
            }
          ],
          "problemTypes": [
            {
              "descriptions": [
                {
                  "cweId": "CWE-22",
                  "description": "CWE-22: Improper Limitation of a Pathname to a Restricted Directory (\u0027Path Traversal\u0027)",
                  "lang": "en",
                  "type": "CWE"
                }
              ]
            }
          ],
          "providerMetadata": {
            "dateUpdated": "2023-06-23T20:37:28.324Z",
            "orgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
            "shortName": "GitHub_M"
          },
          "references": [
            {
              "name": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9",
              "tags": [
                "x_refsource_CONFIRM"
              ],
              "url": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9"
            },
            {
              "name": "https://github.com/Webklex/php-imap/pull/414",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/pull/414"
            },
            {
              "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255"
            },
            {
              "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252"
            },
            {
              "name": "https://github.com/Webklex/php-imap/releases/tag/5.3.0",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/releases/tag/5.3.0"
            }
          ],
          "source": {
            "advisory": "GHSA-47p7-xfcc-4pv9",
            "discovery": "UNKNOWN"
          },
          "title": "php-imap vulnerable to RCE through a directory traversal vulnerability"
        }
      },
      "cveMetadata": {
        "assignerOrgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
        "assignerShortName": "GitHub_M",
        "cveId": "CVE-2023-35169",
        "datePublished": "2023-06-23T20:37:28.324Z",
        "dateReserved": "2023-06-14T14:17:52.179Z",
        "dateUpdated": "2024-11-27T20:22:12.801Z",
        "state": "PUBLISHED"
      },
      "dataType": "CVE_RECORD",
      "dataVersion": "5.1"
    }

    CVE-2023-35169 (GCVE-0-2023-35169)

    Vulnerability from cvelistv5 – Published: 2023-06-23 20:37 – Updated: 2024-11-27 20:22
    VLAI
    Title
    php-imap vulnerable to RCE through a directory traversal vulnerability
    Summary
    PHP-IMAP is a wrapper for common IMAP communication without the need to have the php-imap module installed / enabled. Prior to version 5.3.0, an unsanitized attachment filename allows any unauthenticated user to leverage a directory traversal vulnerability, which results in a remote code execution vulnerability. Every application that stores attachments with `Attachment::save()` without providing a `$filename` or passing unsanitized user input is affected by this attack. An attacker can send an email with a malicious attachment to the inbox, which gets crawled with `webklex/php-imap` or `webklex/laravel-imap`. Prerequisite for the vulnerability is that the script stores the attachments without providing a `$filename`, or providing an unsanitized `$filename`, in `src/Attachment::save(string $path, string $filename = null)`. In this case, where no `$filename` gets passed into the `Attachment::save()` method, the package would use a series of unsanitized and insecure input values from the mail as fallback. Even if a developer passes a `$filename` into the `Attachment::save()` method, e.g. by passing the name or filename of the mail attachment itself (from email headers), the input values never get sanitized by the package. There is also no restriction about the file extension (e.g. ".php") or the contents of a file. This allows an attacker to upload malicious code of any type and content at any location where the underlying user has write permissions. The attacker can also overwrite existing files and inject malicious code into files that, e.g. get executed by the system via cron or requests. Version 5.3.0 contains a patch for this issue.
    SSVC
    Exploitation: poc Automatable: no Technical Impact: total
    CISA Coordinator (v2.0.3)
    CWE
    • CWE-22 - Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
    Assigner
    Impacted products
    Vendor Product Version
    Webklex php-imap Affected: < 5.3.0
    Create a notification for this product.
    Show details on NVD website

    {
      "containers": {
        "adp": [
          {
            "providerMetadata": {
              "dateUpdated": "2024-08-02T16:23:59.360Z",
              "orgId": "af854a3a-2127-422b-91ae-364da2661108",
              "shortName": "CVE"
            },
            "references": [
              {
                "name": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9",
                "tags": [
                  "x_refsource_CONFIRM",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9"
              },
              {
                "name": "https://github.com/Webklex/php-imap/pull/414",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/pull/414"
              },
              {
                "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255"
              },
              {
                "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252"
              },
              {
                "name": "https://github.com/Webklex/php-imap/releases/tag/5.3.0",
                "tags": [
                  "x_refsource_MISC",
                  "x_transferred"
                ],
                "url": "https://github.com/Webklex/php-imap/releases/tag/5.3.0"
              }
            ],
            "title": "CVE Program Container"
          },
          {
            "metrics": [
              {
                "other": {
                  "content": {
                    "id": "CVE-2023-35169",
                    "options": [
                      {
                        "Exploitation": "poc"
                      },
                      {
                        "Automatable": "no"
                      },
                      {
                        "Technical Impact": "total"
                      }
                    ],
                    "role": "CISA Coordinator",
                    "timestamp": "2024-11-27T20:22:04.218611Z",
                    "version": "2.0.3"
                  },
                  "type": "ssvc"
                }
              }
            ],
            "providerMetadata": {
              "dateUpdated": "2024-11-27T20:22:12.801Z",
              "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
              "shortName": "CISA-ADP"
            },
            "title": "CISA ADP Vulnrichment"
          }
        ],
        "cna": {
          "affected": [
            {
              "product": "php-imap",
              "vendor": "Webklex",
              "versions": [
                {
                  "status": "affected",
                  "version": "\u003c 5.3.0"
                }
              ]
            }
          ],
          "descriptions": [
            {
              "lang": "en",
              "value": "PHP-IMAP is a wrapper for common IMAP communication without the need to have the php-imap module installed / enabled. Prior to version 5.3.0, an unsanitized attachment filename allows any unauthenticated user to leverage a directory traversal vulnerability, which results in a remote code execution vulnerability. Every application that stores attachments with `Attachment::save()` without providing a `$filename` or passing unsanitized user input is affected by this attack.\n\nAn attacker can send an email with a malicious attachment to the inbox, which gets crawled with `webklex/php-imap` or `webklex/laravel-imap`. Prerequisite for the vulnerability is that the script stores the attachments without providing a `$filename`, or providing an unsanitized `$filename`, in `src/Attachment::save(string $path, string $filename = null)`. In this case, where no `$filename` gets passed into the `Attachment::save()` method, the package would use a series of unsanitized and insecure input values from the mail as fallback. Even if a developer passes a `$filename` into the `Attachment::save()` method, e.g. by passing the name or filename of the mail attachment itself (from email headers), the input values never get sanitized by the package. There is also no restriction about the file extension (e.g. \".php\") or the contents of a file. This allows an attacker to upload malicious code of any type and content at any location where the underlying user has write permissions. The attacker can also overwrite existing files and inject malicious code into files that, e.g. get executed by the system via cron or requests.\n\nVersion 5.3.0 contains a patch for this issue."
            }
          ],
          "metrics": [
            {
              "cvssV3_1": {
                "attackComplexity": "HIGH",
                "attackVector": "NETWORK",
                "availabilityImpact": "HIGH",
                "baseScore": 9.1,
                "baseSeverity": "CRITICAL",
                "confidentialityImpact": "HIGH",
                "integrityImpact": "HIGH",
                "privilegesRequired": "NONE",
                "scope": "CHANGED",
                "userInteraction": "NONE",
                "vectorString": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H",
                "version": "3.1"
              }
            }
          ],
          "problemTypes": [
            {
              "descriptions": [
                {
                  "cweId": "CWE-22",
                  "description": "CWE-22: Improper Limitation of a Pathname to a Restricted Directory (\u0027Path Traversal\u0027)",
                  "lang": "en",
                  "type": "CWE"
                }
              ]
            }
          ],
          "providerMetadata": {
            "dateUpdated": "2023-06-23T20:37:28.324Z",
            "orgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
            "shortName": "GitHub_M"
          },
          "references": [
            {
              "name": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9",
              "tags": [
                "x_refsource_CONFIRM"
              ],
              "url": "https://github.com/Webklex/php-imap/security/advisories/GHSA-47p7-xfcc-4pv9"
            },
            {
              "name": "https://github.com/Webklex/php-imap/pull/414",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/pull/414"
            },
            {
              "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L251-L255"
            },
            {
              "name": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/blob/5.2.0/src/Attachment.php#L252"
            },
            {
              "name": "https://github.com/Webklex/php-imap/releases/tag/5.3.0",
              "tags": [
                "x_refsource_MISC"
              ],
              "url": "https://github.com/Webklex/php-imap/releases/tag/5.3.0"
            }
          ],
          "source": {
            "advisory": "GHSA-47p7-xfcc-4pv9",
            "discovery": "UNKNOWN"
          },
          "title": "php-imap vulnerable to RCE through a directory traversal vulnerability"
        }
      },
      "cveMetadata": {
        "assignerOrgId": "a0819718-46f1-4df5-94e2-005712e83aaa",
        "assignerShortName": "GitHub_M",
        "cveId": "CVE-2023-35169",
        "datePublished": "2023-06-23T20:37:28.324Z",
        "dateReserved": "2023-06-14T14:17:52.179Z",
        "dateUpdated": "2024-11-27T20:22:12.801Z",
        "state": "PUBLISHED"
      },
      "dataType": "CVE_RECORD",
      "dataVersion": "5.1"
    }