Skip to content

Releases: tukaani-project/xz

XZ Utils 5.6.3 (stable)

01 Oct 17:20
v5.6.3
9331ce4
Compare
Choose a tag to compare
5.6.3 (2024-10-01)

    IMPORTANT: This includes a Windows-specific security fix to
    the command line tools. liblzma isn't affected by this issue.

    * liblzma:

        - Fix x86-64 inline assembly compatibility with GNU Binutils
          older than 2.27.

        - Fix the build with GCC 4.2 on OpenBSD/sparc64.

    * xzdec: Display an error instead of failing silently if the
      unsupported option -M is specified.

    * lzmainfo: Fix integer overflows when rounding the dictionary and
      uncompressed sizes to the nearest mebibyte.

    * Windows (except Cygwin and MSYS2): Add an application manifest to
      xz, xzdec, lzmadec, and lzmainfo executables:

        - Declare them compatible with Vista/7/8/8.1/10/11. This way
          the programs won't needlessly use Operating System Context
          of Vista when running on later Windows versions. This setting
          doesn't mean that the executables cannot run on even older
          versions if otherwise built that way.

        - Declare them as UAC-compliant. MSVC added this by default
          already but it wasn't done with MinGW-w64, at least not
          with all toolchain variants.

        - Declare them long path aware. This makes long path names
          work on Windows 10 and 11 if the feature has been enabled
          in the Windows registry.

        - Use the UTF-8 code page on Windows 10 version 1903 and later.

            * Now command line tools can access files whose names
              contain characters that don't exist in the current
              legacy code page.

            * The options --files and --files0 now expect file lists
              to be in UTF-8 instead of the legacy code page.

            * This fixes a security issue: If a command line contains
              Unicode characters (for example, filenames) that don't
              exist in the current legacy code page, the characters are
              converted to similar-looking characters with best-fit
              mapping. Some best-fit mappings result in ASCII
              characters that change the meaning of the command line,
              which can be exploited with malicious filenames to do
              argument injection or directory traversal attacks.
              UTF-8 avoids best-fit mappings and thus fixes the issue.

              Forcing the process code page to UTF-8 is possible only
              on Windows 10 version 1903 and later. The command line
              tools remain vulnerable if used on an old older
              version of Windows.

              This issue was discovered by Orange Tsai and splitline
              from DEVCORE Research Team.

              A related smaller issue remains: Windows filenames may
              contain unpaired surrogates (invalid UTF-16). These are
              converted to the replacement character U+FFFD in the
              UTF-8 code page. Thus, filenames with different unpaired
              surrogates appear identical and aren't distinguishable
              from filenames that contain the actual replacement
              character U+FFFD.

            * When building with MinGW-w64, it is recommended to use
              UCRT version instead of the old MSVCRT. For example,
              non-ASCII characters from filenames won't print
              correctly in messages to console with MSVCRT with
              the UTF-8 code page (a cosmetic issue). liblzma-only
              builds are still fine with MSVCRT.

        - Cygwin and MSYS2 process command line options differently and
          the above issues don't exist. There is no need to replace the
          default application manifest on Cygwin and MSYS2.

    * Autotools-based build:

        - Fix feature checks with link-time optimization (-flto).

        - Solaris: Fix a compatibility issue in version.sh. It matters
          if one wants to regenerate configure by running autoconf.

    * CMake:

        - Use paths relative to ${prefix} in liblzma.pc when possible.
          This is done only with CMake >= 3.20.

        - MSVC: Install liblzma.pc as it can be useful with MSVC too.

        - Windows: Fix liblzma filename prefix, for example:

            * Cygwin: The DLL was incorrectly named liblzma-5.dll.
              Now it is cyglzma-5.dll.

            * MSVC: Rename import library from liblzma.lib to lzma.lib
              while keeping liblzma.dll name as is. This helps with
              "pkgconf --msvc-syntax --libs liblzma" because it mungles
              "-llzma" in liblzma.pc to "lzma.lib".

            * MinGW-w64: No changes.

        - Windows: Use the correct resource file for lzmadec.exe.
          Previously the resource file for xzdec.exe was used for both.
          Autotools-based build isn't affected.

        - Prefer a C11 compiler over a C99 compiler but accept both.

        - Link Threads::Threads against liblzma using PRIVATE so that
          -pthread and such flags won't unnecessarily get included in
          the usage requirements of shared liblzma. That is,
          target_link_libraries(foo PRIVATE liblzma::liblzma) no
          longer adds -pthread if using POSIX threads and linking
          against shared liblzma. The threading flags are still added
          if linking against static liblzma.

    * Updated translations: Catalan, Chinese (simplified), and
      Brazilian Portuguese.

XZ Utils 5.6.2 (stable)

29 May 17:10
v5.6.2
Compare
Choose a tag to compare

NOTE: 5.2.13, 5.4.7, and 5.6.2 have a build system issue that prevents building of shared libraries on some systems like mips64. See the patch itself for details. The same patch applies to 5.2.13, 5.4.7, and 5.6.2.

5.6.2 (2024-05-29)

    * Remove the backdoor (CVE-2024-3094).

    * Not changed: Memory sanitizer (MSAN) has a false positive
      in the CRC CLMUL code which also makes OSS Fuzz unhappy.
      Valgrind is smarter and doesn't complain.

      A revision to the CLMUL code is coming anyway and this issue
      will be cleaned up as part of it. It won't be backported to
      5.6.x or 5.4.x because the old code isn't wrong. There is
      no reason to risk introducing regressions in old branches
      just to silence a false positive.

    * liblzma:

        - lzma_index_decoder() and lzma_index_buffer_decode(): Fix
          a missing output pointer initialization (*i = NULL) if the
          functions are called with invalid arguments. The API docs
          say that such an initialization is always done. In practice
          this matters very little because the problem can only occur
          if the calling application has a bug and these functions
          return LZMA_PROG_ERROR.

        - lzma_str_to_filters(): Fix a missing output pointer
          initialization (*error_pos = 0). This is very similar
          to the fix above.

        - Fix C standard conformance with function pointer types.

        - Remove GNU indirect function (IFUNC) support. This is *NOT*
          done for security reasons even though the backdoor relied on
          this code. The performance benefits of IFUNC are too tiny in
          this project to make the extra complexity worth it.

        - FreeBSD on ARM64: Add error checking to CRC32 instruction
          support detection.

        - Fix building with NVIDIA HPC SDK.

    * xz:

        - Fix a C standard conformance issue in --block-list parsing
          (arithmetic on a null pointer).

        - Fix a warning from GNU groff when processing the man page:
          "warning: cannot select font 'CW'"

    * xzdec: Add support for Linux Landlock ABI version 4. xz already
      had the v3-to-v4 change but it had been forgotten from xzdec.

    * Autotools-based build system (configure):

        - Symbol versioning variant can now be overridden with
          --enable-symbol-versions. Documentation in INSTALL was
          updated to match.

        - Add new configure option --enable-doxygen to enable
          generation and installation of the liblzma API documentation
          using Doxygen. Documentation in INSTALL and PACKAGERS was
          updated to match.

    CMake:

        - Fix detection of Linux Landlock support. The detection code
          in CMakeLists.txt had been sabotaged.

        - Disable symbol versioning on non-glibc Linux to match what
          the Autotools build does. For example, symbol versioning
          isn't enabled with musl.

        - Symbol versioning variant can now be overridden by setting
          SYMBOL_VERSIONING to "OFF", "generic", or "linux".

        - Add support for all tests in typical build configurations.
          Now the only difference to the tests coverage to Autotools
          is that CMake-based build will skip more tests if features
          are disabled. Such builds are only for special cases like
          embedded systems.

        - Separate the CMake code for the tests into tests/tests.cmake.
          It is used conditionally, thus it is possible to

              rm -rf tests

          and the CMake-based build will still work normally except
          that no tests are then available.

        - Add a option ENABLE_DOXYGEN to enable generation and
          installation of the liblzma API documentation using Doxygen.

    * Documentation:

        - Omit the Doxygen-generated liblzma API documentation from the
          package. Instead, the generation and installation of the API
          docs can be enabled with a configure or CMake option if
          Doxygen is available.

        - Remove the XZ logo which was used in the API documentation.
          The logo has been retired and isn't used by the project
          anymore. However, it's OK to use it in contexts that refer
          to the backdoor incident.

        - Remove the PDF versions of the man pages from the source
          package. These existed primarily for users of operating
          systems which don't come with tools to render man page
          source files. The plain text versions are still included
          in doc/man/txt. PDF files can still be generated to doc/man,
          if the required tools are available, using "make pdf" after
          running "configure".

        - Update home page URLs back to their old locations on
          tukaani.org.

        - Update maintainer info.

    * Tests:

        - In tests/files/README, explain how to recreate the ARM64
          test files.

        - Remove two tests that used tiny x86 and SPARC object files
          as the input files. The matching .c file was included but
          the object files aren't easy to reproduce. The test cases
          weren't great anyway; they were from the early days (2009)
          of the project when the test suite had very few tests.

        - Improve a few tests.

XZ Utils 5.4.7 (old stable)

29 May 17:09
v5.4.7
Compare
Choose a tag to compare

NOTE: 5.2.13, 5.4.7, and 5.6.2 have a build system issue that prevents building of shared libraries on some systems like mips64. See the patch itself for details. The same patch applies to 5.2.13, 5.4.7, and 5.6.2.

5.4.7 (2024-05-29)

    * Not changed: Memory sanitizer (MSAN) has a false positive
      in the CRC CLMUL code which also makes OSS Fuzz unhappy.
      Valgrind is smarter and doesn't complain.

      A revision to the CLMUL code is coming anyway and this issue
      will be cleaned up as part of it. It won't be backported to
      5.6.x or 5.4.x because the old code isn't wrong. There is
      no reason to risk introducing regressions in old branches
      just to silence a false positive.

    * liblzma:

        - lzma_index_decoder() and lzma_index_buffer_decode(): Fix
          a missing output pointer initialization (*i = NULL) if the
          functions are called with invalid arguments. The API docs
          say that such an initialization is always done. In practice
          this matters very little because the problem can only occur
          if the calling application has a bug and these functions
          return LZMA_PROG_ERROR.

        - lzma_str_to_filters(): Fix a missing output pointer
          initialization (*error_pos = 0). This is very similar
          to the fix above.

        - Fix C standard conformance with function pointer types.
          This newly showed up with Clang 17 with -fsanitize=undefined.
          There are no bug reports about this.

        - Fix building with NVIDIA HPC SDK.

    * xz:

        - Fix a C standard conformance issue in --block-list parsing
          (arithmetic on a null pointer).

        - Fix a warning from GNU groff when processing the man page:
          "warning: cannot select font 'CW'"

        - Fix outdated threading related information on the man page.

    * xzless:

        - With "less" version 451 and later, use "||-" instead of "|-"
          in the environment variable LESSOPEN. This way compressed
          files that contain no uncompressed data are shown correctly
          as empty.

        - With "less" version 632 and later, use --show-preproc-errors
          to make "less" show a warning on decompression errors.

    * Autotools-based build system (configure):

        - Symbol versioning variant can now be overridden with
          --enable-symbol-versions. Documentation in INSTALL was
          updated to match.

    CMake:

        - Linux on MicroBlaze is handled specially now. This matches
          the changes made to the Autotools-based build in XZ Utils
          5.4.2 and 5.2.11.

        - Disable symbol versioning on non-glibc Linux to match what
          the Autotools build does. For example, symbol versioning
          isn't enabled with musl.

        - Symbol versioning variant can now be overridden by setting
          SYMBOL_VERSIONING to "OFF", "generic", or "linux".

    * Documentation:

        - Clarify the description of --disable-assembler in INSTALL.
          The option only affects 32-bit x86 assembly usage.

        - Add doc/examples/11_file_info.c. It was added to the
          Git repository in 2017 but forgotten to be added into
          distribution tarballs.

        - Don't install the TODO file as part of the documentation.
          The file is out of date.

        - Update home page URLs back to their old locations on
          tukaani.org.

        - Update maintainer info.

XZ Utils 5.2.13 (old old stable)

29 May 17:09
v5.2.13
Compare
Choose a tag to compare

NOTE: 5.2.13, 5.4.7, and 5.6.2 have a build system issue that prevents building of shared libraries on some systems like mips64. See the patch itself for details. The same patch applies to 5.2.13, 5.4.7, and 5.6.2.

5.2.13 (2024-05-29)

    * liblzma:

        - lzma_index_append(): Fix an assertion failure that could be
          triggered by a large unpadded_size argument. It was verified
          that there was no other bug than the assertion failure.

        - lzma_index_decoder() and lzma_index_buffer_decode(): Fix
          a missing output pointer initialization (*i = NULL) if the
          functions are called with invalid arguments. The API docs
          say that such an initialization is always done. In practice
          this matters very little because the problem can only occur
          if the calling application has a bug and these functions
          return LZMA_PROG_ERROR.

        - Fix C standard conformance with function pointer types.
          This newly showed up with Clang 17 with -fsanitize=undefined.
          There are no bug reports about this.

        - Fix building with NVIDIA HPC SDK.

        - Fix building with Windows Vista threads and --enable-small.
          (CMake build doesn't support ENABLE_SMALL in XZ Utils 5.2.x.)

    * xz:

        - Fix a C standard conformance issue in --block-list parsing
          (arithmetic on a null pointer).

        - Fix a warning from GNU groff when processing the man page:
          "warning: cannot select font 'CW'"

        - Windows: Handle special files such as "con" or "nul". Earlier
          the following wrote "foo" to the console and deleted the input
          file "con_xz":

              echo foo | xz > con_xz
              xz --suffix=_xz --decompress con_xz

        - Windows: Fix an issue that prevented reading from or writing
          to non-terminal character devices like NUL.

    * xzless:

        - With "less" version 451 and later, use "||-" instead of "|-"
          in the environment variable LESSOPEN. This way compressed
          files that contain no uncompressed data are shown correctly
          as empty.

        - With "less" version 632 and later, use --show-preproc-errors
          to make "less" show a warning on decompression errors.

    * Build systems:

        - Add a new line to liblzma.pc for MSYS2 (Windows):

              Cflags.private: -DLZMA_API_STATIC

          When compiling code that will link against static liblzma,
          the LZMA_API_STATIC macro needs to be defined on Windows.

        - Autotools (configure):

            * Symbol versioning variant can now be overridden with
              --enable-symbol-versions. Documentation in INSTALL was
              updated to match.

        - CMake:

            * Fix a bug that prevented other projects from including
              liblzma multiple times using find_package().

            * Fix a bug where configuring CMake multiple times resulted
              in HAVE_CLOCK_GETTIME and HAVE_CLOCK_MONOTONIC not being
              defined.

            * Fix the build with MinGW-w64-based Clang/LLVM 17.
              llvm-windres now has more accurate GNU windres emulation
              so the GNU windres workaround from 5.4.1 is needed with
              llvm-windres version 17 too.

            * The import library on Windows is now properly named
              "liblzma.dll.a" instead of "libliblzma.dll.a"

            * Add large file support by default for platforms that
              need it to handle files larger than 2 GiB. This includes
              MinGW-w64, even 64-bit builds.

            * Linux on MicroBlaze is handled specially now. This
              matches the changes made to the Autotools-based build
              in XZ Utils 5.4.2 and 5.2.11.

            * Disable symbol versioning on non-glibc Linux to match
              what the Autotools build does. For example, symbol
              versioning isn't enabled with musl.

            * Symbol versioning variant can now be overridden by
              setting SYMBOL_VERSIONING to "OFF", "generic", or
              "linux".

    * Documentation:

        - Clarify the description of --disable-assembler in INSTALL.
          The option only affects 32-bit x86 assembly usage.

        - Don't install the TODO file as part of the documentation.
          The file is out of date.

        - Update home page URLs back to their old locations on
          tukaani.org.

        - Update maintainer info.

XZ Utils 5.4.6 Stable

26 Jan 12:22
Compare
Choose a tag to compare
5.4.6 (2024-01-26)

    * Fixed a bug involving internal function pointers in liblzma not
      being initialized to NULL. The bug can only be triggered if
      lzma_filters_update() is called on a LZMA1 encoder, so it does
      not affect xz or any application known to us that uses liblzma.

    * xz:

        - Fixed a regression introduced in 5.4.2 that caused encoding
          in the raw format to unnecessarily fail if --suffix was not
          used. For instance, the following command no longer reports
          that --suffix must be used:

              echo foo | xz --format=raw --lzma2 | wc -c

        - Fixed an issue on MinGW-w64 builds that prevented reading
          from or writing to non-terminal character devices like NUL.

    * Added a new test.

XZ Utils 5.4.5 Stable

01 Nov 13:18
Compare
Choose a tag to compare
5.4.5 (2023-11-01)

    * liblzma:

        - Use __attribute__((__no_sanitize_address__)) to avoid address
          sanitization with CRC64 CLMUL. It uses 16-byte-aligned reads
          which can extend past the bounds of the input buffer and
          inherently trigger address sanitization errors. This isn't
          a bug.

        - Fixed an assertion failure that could be triggered by a large
          unpadded_size argument. It was verified that there was no
          other bug than the assertion failure.

        - Fixed a bug that prevented building with Windows Vista
          threading when __attribute__((__constructor__)) is not
          supported.

    * xz now properly handles special files such as "con" or "nul" on
      Windows. Before this fix, the following wrote "foo" to the
      console and deleted the input file "con_xz":

          echo foo | xz > con_xz
          xz --suffix=_xz --decompress con_xz

    * Build systems:

        - Allow builds with Windows win95 threading and small mode when
          __attribute__((__constructor__)) is supported.

        - Added a new line to liblzma.pc for MSYS2 (Windows):

              Cflags.private: -DLZMA_API_STATIC

          When compiling code that will link against static liblzma,
          the LZMA_API_STATIC macro needs to be defined on Windows.

        - CMake specific changes:

            * Fixed a bug that allowed CLOCK_MONOTONIC to be used even
              if the check for it failed.

            * Fixed a bug where configuring CMake multiple times
              resulted in HAVE_CLOCK_GETTIME and HAVE_CLOCK_MONOTONIC
              not being set.

            * Fixed the build with MinGW-w64-based Clang/LLVM 17.
              llvm-windres now has more accurate GNU windres emulation
              so the GNU windres workaround from 5.4.1 is needed with
              llvm-windres version 17 too.

            * The import library on Windows is now properly named
              "liblzma.dll.a" instead of "libliblzma.dll.a"

            * Fixed a bug causing the Ninja Generator to fail on
              UNIX-like systems. This bug was introduced in 5.4.0.

            * Added a new option to disable CLMUL CRC64.

            * A module-definition (.def) file is now created when
              building liblzma.dll with MinGW-w64.

            * The pkg-config liblzma.pc file is now installed on all
              builds except when using MSVC on Windows.

            * Added large file support by default for platforms that
              need it to handle files larger than 2 GiB. This includes
              MinGW-w64, even 64-bit builds.

    * Small fixes and improvements to the tests.

    * Updated translations: Chinese (simplified) and Esperanto.

XZ Utils 5.4.4 Stable

02 Aug 13:03
Compare
Choose a tag to compare
5.4.4 (2023-08-02)

    * liblzma and xzdec can now build against WASI SDK when threading
      support is disabled. xz and tests don't build yet.

    * CMake:

        - Fixed a bug preventing other projects from including liblzma
          multiple times using find_package().

        - Don't create broken symlinks in Cygwin and MSYS2 unless
          supported by the environment. This prevented building for the
          default MSYS2 environment. The problem was introduced in
          xz 5.4.0.

    * Documentation:

        - Small improvements to man pages.

        - Small improvements and typo fixes for liblzma API
          documentation.

    * Tests:

        - Added a new section to INSTALL to describe basic test usage
          and address recent questions about building the tests when
          cross compiling.

        - Small fixes and improvements to the tests.

    * Translations:

        - Fixed a mistake that caused one of the error messages to not
          be translated. This only affected versions 5.4.2 and 5.4.3.

        - Updated the Chinese (simplified), Croatian, Esperanto, German,
          Korean, Polish, Romanian, Spanish, Swedish, Ukrainian, and
          Vietnamese translations.

        - Updated the German, Korean, Romanian, and Ukrainian man page
          translations.

XZ Utils 5.4.3 Stable

04 May 15:46
Compare
Choose a tag to compare
5.4.3 (2023-05-04)

    * All fixes from 5.2.12

    * Features in the CMake build can now be disabled as CMake cache
      variables, similar to the Autotools build.

    * Minor update to the Croatian translation.

XZ Utils 5.2.12 Old Stable

04 May 15:45
Compare
Choose a tag to compare
5.2.12 (2023-05-04)

    * Fixed a build system bug that prevented building liblzma as a
      shared library when configured with --disable-threads. This bug
      affected releases 5.2.6 to 5.2.11 and 5.4.0 to 5.4.2.

    * Include <intrin.h> for Windows intrinsic functions where they are
      needed. This fixed a bug that prevented building liblzma using
      clang-cl on Windows.

    * Minor update to the Croatian translation. The small change
      applies to a string in both 5.2 and 5.4 branches.

5.4.2 Stable

18 Mar 17:14
Compare
Choose a tag to compare
5.4.2 (2023-03-18)

    * All fixes from 5.2.11 that were not included in 5.4.1.

    * If xz is built with support for the Capsicum sandbox but running
      in an environment that doesn't support Capsicum, xz now runs
      normally without sandboxing instead of exiting with an error.

    * liblzma:

        - Documentation was updated to improve the style, consistency,
          and completeness of the liblzma API headers.

        - The Doxygen-generated HTML documentation for the liblzma API
          header files is now included in the source release and is
          installed as part of "make install". All JavaScript is
          removed to simplify license compliance and to reduce the
          install size.

        - Fixed a minor bug in lzma_str_from_filters() that produced
          too many filters in the output string instead of reporting
          an error if the input array had more than four filters. This
          bug did not affect xz.

    * Build systems:

        - autogen.sh now invokes the doxygen tool via the new wrapper
          script doxygen/update-doxygen, unless the command line option
          --no-doxygen is used.

        - Added microlzma_encoder.c and microlzma_decoder.c to the
          VS project files for Windows and to the CMake build. These
          should have been included in 5.3.2alpha.

    * Tests:

        - Added a test to the CMake build that was forgotten in the
          previous release.

        - Added and refactored a few tests.

    * Translations:

        - Updated the Brazilian Portuguese translation.

        - Added Brazilian Portuguese man page translation.