what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

Drupal H5P Module 2.0.0 Zip Slip Traversal

Drupal H5P Module 2.0.0 Zip Slip Traversal
Posted Dec 5, 2022
Authored by EgiX | Site karmainsecurity.com

Drupal H5P Module versions 2.0.0 and below suffer from a traversal vulnerability when handling a zipped filename on windows.

tags | exploit, file inclusion
systems | windows
SHA-256 | 29cd61d23f4b78dbb93cdc479cba570c70b094e72db31910170d0c3eb73d58f8

Drupal H5P Module 2.0.0 Zip Slip Traversal

Change Mirror Download
------------------------------------------------------------------
Drupal H5P Module <= 2.0.0 (isValidPackage) Zip Slip Vulnerability
------------------------------------------------------------------


[-] Software Link:

https://www.drupal.org/project/h5p


[-] Affected Versions:

Version 2.0.0-alpha2 and prior versions.
Version 7.x-1.50 and prior versions.


[-] Vulnerability Description:

The vulnerability is located within the H5PValidator::isValidPackage()
method. This implements the following check in order to skip any file or
folder starting with a dot or underscore within the uploaded h5p
archive:

891. $fileName = $zip->statIndex($i)['name'];
892.
893. if (preg_match('/(^[\._]|\/[\._])/', $fileName) !== 0) {
894. continue; // Skip any file or folder starting with a . or _
894. }

This regex check should be enough to prevent path traversal attacks
through zipped filenames (Zip Slip attacks), because it checks for the
string “/.” within the filename, thus preventing directory traversal
attacks. However, the vulnerability exists if Drupal is running on a
Windows server, because in this case the attacker can provide a
malicious h5p archive containing a filename with path traversal
sequences like “..\..\..”, which would bypass the above regex check.
This can be exploited to write (or overwrite) semi-arbitrary files in
the file system via directory traversal sequences, potentially leading
to Stored Cross-Site Scripting (XSS) and other kind of attacks.


[-] Solution:

No official solution is currently available.


[-] Disclosure Timeline:

[22/11/2021] - Vendor notified
[28/02/2022] - Vendor proposed a possible patch
[28/02/2022] - Vendor notified about the ineffective patch, provided a
fix suggestion
[01/03/2022] - Vendor fixed the previous patch
[30/03/2022] - Asked update about the public disclosure and release of a
patch, no response
[22/11/2022] - After one year still no official solution available
[03/12/2022] - Public disclosure


[-] CVE Reference:

The Common Vulnerabilities and Exposures project (cve.mitre.org)
has not assigned a CVE identifier for this vulnerability.


[-] Credits:

Vulnerability discovered by Egidio Romano.


[-] Other References:

https://security.drupal.org/node/175968


[-] Original Advisory:

http://karmainsecurity.com/KIS-2022-06

Login or Register to add favorites

File Archive:

March 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Mar 1st
    16 Files
  • 2
    Mar 2nd
    0 Files
  • 3
    Mar 3rd
    0 Files
  • 4
    Mar 4th
    32 Files
  • 5
    Mar 5th
    28 Files
  • 6
    Mar 6th
    42 Files
  • 7
    Mar 7th
    17 Files
  • 8
    Mar 8th
    13 Files
  • 9
    Mar 9th
    0 Files
  • 10
    Mar 10th
    0 Files
  • 11
    Mar 11th
    15 Files
  • 12
    Mar 12th
    19 Files
  • 13
    Mar 13th
    21 Files
  • 14
    Mar 14th
    38 Files
  • 15
    Mar 15th
    15 Files
  • 16
    Mar 16th
    0 Files
  • 17
    Mar 17th
    0 Files
  • 18
    Mar 18th
    10 Files
  • 19
    Mar 19th
    32 Files
  • 20
    Mar 20th
    46 Files
  • 21
    Mar 21st
    16 Files
  • 22
    Mar 22nd
    13 Files
  • 23
    Mar 23rd
    0 Files
  • 24
    Mar 24th
    0 Files
  • 25
    Mar 25th
    12 Files
  • 26
    Mar 26th
    31 Files
  • 27
    Mar 27th
    19 Files
  • 28
    Mar 28th
    42 Files
  • 29
    Mar 29th
    0 Files
  • 30
    Mar 30th
    0 Files
  • 31
    Mar 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close