m-server@1.0.3

M-Server is a mini http static server that without any dependencies;

  • latest version

    1.4.2

  • first published

    9 years ago

  • latest version published

    8 years ago

  • licenses detected

  • Direct Vulnerabilities

    Known vulnerabilities in the m-server package. This does not include vulnerabilities belonging to this package’s dependencies.

    Fix vulnerabilities automatically

    Snyk's AI Trust Platform automatically finds the best upgrade path and integrates with your development workflows. Secure your code at zero cost.

    Fix for free
    VulnerabilityVulnerable Version
    • H
    Cross-site Scripting (XSS)

    m-server is a mini http static server that without any dependencies.

    Affected versions of this package are vulnerable to Cross-site Scripting (XSS). In m-server/lib/utils.js line 59 and 64, html push does not escapeHtml for variable path. By changing the path of URL via traversal, attacker can control this variable path.

    PoC

    GET /../../../../home/vagrant/tmp/test/<svg/onload=alert(document.domain)>/../../../test/ HTTP/1.1
    Host: 192.168.57.105:3001
    User-Agent: curl/7.54.0
    Accept: */*
    Connection: close
    

    How to fix Cross-site Scripting (XSS)?

    There is no fixed version for m-server.

    *
    • M
    Cross-site Scripting (XSS)

    m-server is a mini http static server.

    Affected versions of this package are vulnerable to Cross-site Scripting (XSS) attacks. It displays content of selected directory as HTML in the browser without escaping. A malicious user could inject iframe element with JavaScript code via crafted filename.

    How to fix Cross-site Scripting (XSS)?

    Upgrade m-server to version 1.4.2 or higher.

    <1.4.2
    • H
    Directory Traversal

    m-server is a M-Server is a mini http static server that without any dependencies;.

    Affected versions of the package are vulnerable to Directory Traversal, which may allow access to sensitive files and data on the server. For example, requesting the following url /..%2f..%2fetc/passwd would result in /etc/passwd leak.

    How to fix Directory Traversal?

    There is no fixed version for m-server.

    <1.4.2