Repository navigation
Updates calamine to 0.38.0 to remove a reader panic on malformed .xls files - #3466
Merged
Merged
Conversation
RUSTSEC-2026-0436: calamine before 0.38.0 can panic and can allocate without a limit in its compound file reader on a malformed .xls file. A linked spreadsheet of a drawing reaches that reader. The update adds zip 9 next to zip 8 in the lockfile, and moves quick-xml 0.41 to 0.42. Co-Authored-By: Claude
travisjhughes
force-pushed
the
calamine-update
branch
from
November 22, 2026 23:45
b000ffe to
eede69b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change summary
calaminereads the spreadsheet of a data link. Version 0.36.1 has the advisory RUSTSEC-2026-0436: a panic and an allocation without a limit in the compound file reader on a malformed file (.xlsfiles and VBA projects). Version 0.38.0 repairs it.This change moves
calaminefrom 0.36.1 to 0.38.0. No source file of the app changes: the API that the app uses is the same.What specifically changed
One commit.
Cargo.toml:calamine = "0.38.0".Cargo.lock, fromcargo update -p calamine --precise 0.38.0:calamine0.36.1 → 0.38.0;quick-xml0.41.0 → 0.42.0;zip9.8.1 (forcalamine; the app keepszip8.6.0, so the build has both),typed-path0.13.0,constant_time_eq0.6.1,nix0.32.0,zeroize_derive1.5.0.Why
cargo auditon main965e1976creports RUSTSEC-2026-0436 forcalamine0.36.1, patched in 0.38.0 and later. With this change the report has no line forcalamine(21 advisories before, 20 after).catch_unwindstops that.Other changes of 0.37 and 0.38 that a user of a data link can see (from the changelog of
calamine):.xlsb: a whole-number cell with a date format is a date, not an integer.xlsx:_xHHHH_escapes are decoded for all code units.xls: aWORKBOOKstream name in capitals is accepted.xls: BIFF5 strings in multibyte code pages are decoded correctly.ods: error cells give their text; tabs and line breaks are keptTesting
On main
0ca03459b.cargo test --workspace --locked --no-fail-fast,cargo check --workspace --all-targets, clippy, the wasm32 check, the golden file): 7,729 passed and 1 failed before; 7,730 passed and 0 failed after. No other difference. One test of main,picklocked_off_makes_locked_layer_objects_unselectable, failed in the run of main and passed in the run with this change; it also passed in three other runs on the same main, so it is not stable on main and not from this change. Warnings, the wasm32 check, clippy, rustfmt and the golden file are the same.src/app/annotation_data.rsthat read a workbook pass with 0.38.0.cargo mutants: not run. The diff has no source code.Not covered
calamine0.38.0 still panics on a damaged.xlsfile:Sectors::get_chain(src/cfb.rs) follows the sector chain withfats[sector_id as usize]and does not check the index. A 512-byte file is enough. The app needs its owncatch_unwindaround the reads for that; that is a separate change (Prevents a crash when a data link reads a damaged spreadsheet #3465). Thecalamineproject has a report of the panic (its issue 764), and its master branch (93e2e6b) gives an error for that file. No release has that repair yet.zipin the build. To remove the second one, the app must move tozip9.cargo auditreport.Impact to Contributors
None.
Co-Authored-By: Claude