Skip to content

yath displays arbitrary filenames without escaping #286

@robrwo

Description

@robrwo

Inspired by https://www.openwall.com/lists/oss-security/2025/08/13/4 which talks about how unescaped filenames can be used to trigger vulnerabilities in terminals etc.

mkdir -p t
touch t/$(printf "file\e[H\e[0j\e[1mBoo\e[0m.t"))

yath

this will output unescaped filenames and run some annoying ANSI sequences.

Either escape the filenames before printing, or be more restrictive about the filenames that are handled (though escape them when showing errors)

See also Perl-Toolchain-Gang/Test-Harness#144

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