Skip to content

Crash on malformed input #32

Closed
Closed
@Shnatsel

Description

@Shnatsel

When given a malformed input lewton attempts to allocate enormous amounts of memory and crashes. Testcase: minimized_crash_testcase.ogg.gz (gzipped so that github would accept the upload)

Command to reproduce the crash:
RUSTFLAGS='--cfg=fuzzing' cargo run --release --example perf /path/to/testcase
The output will be:

memory allocation of 4611686018427387908 bytes failed
fish: “env RUSTFLAGS='--cfg=fuzzing' c…” terminated by signal SIGABRT (Abort)

When run in debug mode with command
RUSTFLAGS='--cfg=fuzzing' cargo run --example perf /path/to/testcase the error message is:

thread 'main' panicked at 'attempt to subtract with overflow', src/audio.rs:639:18

Found using afl.rs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions