Description
The comm utility in uutils coreutils silently corrupts data by performing lossy UTF-8 conversion on all output lines. The implementation uses String::from_utf8_lossy(), which replaces invalid UTF-8 byte sequences with the Unicode replacement character (U+FFFD). This behavior differs from GNU comm, which processes raw bytes and preserves the original input. This results in corrupted output when the utility is used to compare binary files or files using non-UTF-8 legacy encodings.
Problem types
CWE-176: Improper Handling of Unicode Encoding
Product status
Any version before 0.6.0
Credits
Zellic
References
github.com/uutils/coreutils/issues/10192
github.com/uutils/coreutils/pull/10206
github.com/uutils/coreutils/issues/10192
github.com/uutils/coreutils/releases/tag/0.6.0