Bug 209587 - Divide by zero in calc_stripe_length() with fuzzed image
Summary: Divide by zero in calc_stripe_length() with fuzzed image
Status: NEW
Alias: None
Product: File System
Classification: Unclassified
Component: btrfs (show other bugs)
Hardware: All Linux
: P1 low
Assignee: BTRFS virtual assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-10-09 00:43 UTC by Daniel Xu
Modified: 2020-10-09 18:34 UTC (History)
0 users

See Also:
Kernel Version: master (5.9)
Subsystem:
Regression: No
Bisected commit-id:


Attachments
repro (10.14 KB, application/zstd)
2020-10-09 00:43 UTC, Daniel Xu
Details

Description Daniel Xu 2020-10-09 00:43:40 UTC
Created attachment 292901 [details]
repro

There's a divide by zero error in calc_stripe_length() if you try to mount the attached image.

Note: the attached image is zstd compressed.
Comment 1 Daniel Xu 2020-10-09 18:34:06 UTC
I've got a fix up here: https://lore.kernel.org/linux-btrfs/20201009010910.270794-1-dxu@dxuuu.xyz/T/#u

Note You need to log in before you can comment on or make changes to this bug.