mirror of
https://github.com/asciinema/asciinema.git
synced 2026-04-25 16:05:52 +03:00
[GH-ISSUE #718] hex parsing is prone to accepting "+" prefix #975
Labels
No labels
bug
compatibility
feature request
fit for beginners
help wanted
hosting
idea
improvement
packaging
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/asciinema#975
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Rudxain on GitHub (Dec 10, 2025).
Original GitHub issue: https://github.com/asciinema/asciinema/issues/718
Pre-submission checks
Bug Description
The private
fn parse_colorhas a mistake (rust-lang/rust-clippy#16213) that could allow hex strings like "+a/+b/+c":github.com/asciinema/asciinema@e5b64815c3/src/tty.rs (L263-L274)The tests are incomplete:
github.com/asciinema/asciinema@e5b64815c3/src/tty.rs (L293-L316)Steps to Reproduce
I haven't tested it yet
Expected Behavior
It should reject the plus-signs
Operating System
irrelevant
asciinema CLI Version
commit-hash already included
Installation Method
Built from source
Terminal Information
No response
Additional Context
No response
@ku1ik commented on GitHub (Dec 11, 2025):
Thanks. I can see it being prone to that, but does this actually happen in practice here? I doubt that. The parsing here applies to terminal responses, and it would require explicit
+sign in the output of terminal emulator for this to trigger, and I'm pretty sure none of them do this, because why :)