Skip to content

Code injection vulnerability on /system/log endpoint #120

@pondzikk

Description

@pondzikk

os.system('journalctl --since \"{} hours ago\" -u craftbeerpi.service > {}'.format(logtime, fullname))

URL GET parameter {logtime} utilized within the downloadlog function from cbpi/http_endpoints/http_system.py is subsequently passed to the os.system function in cbpi/controller/system_controller.py without prior validation allowing to execute arbitrary code.

Vulnerability exists from 4.0.0.58 version (563fae9 commit)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions