Skip to content

[security vulnerability] Arbitrary file deletion vulnerability  #1695

@GatekeeperBuster

Description

@GatekeeperBuster

Recently, our team found a Arbitrary file deletion vulnerability
The vulnerability logic is present in the file:
https://github.com/LibreHealthIO/lh-ehr/blob/master/interface/fax/fax_dispatch.php#L49
https://github.com/LibreHealthIO/lh-ehr/blob/master/interface/fax/fax_dispatch.php#L50
https://github.com/LibreHealthIO/lh-ehr/blob/master/interface/fax/fax_dispatch.php#L315

image
image

The variable $filename can be controlled by $_GET['scan']. By concatenating $filename with $filepath and passing it directly into the unlink function, it can lead to arbitrary file deletion vulnerability.

To fix this vulnerability, we recommend that developers implement properly sanitize for user input before displaying it on the webpage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions