Skip to content

Releases: arvidn/libtorrent

v2.1.1

Choose a tag to compare

@arvidn arvidn released this 10 Aug 13:58
56ae8ca

Changelog 2.1.1

  • fix merkle tree issue
  • require webtorrent RTC offer IDs to be exactly 20 bytes
  • fix point-to-point interfaces without a route to the internet being used for outgoing traffic
  • apply IP filter to DHT node
  • fix use of a stack buffer past its lifetime when sending i2p SAM commands
  • optimize RC4
  • fail validation of DHT mutable items whose salt exceeds the 64 byte limit
  • improve dont-count-slow-torrents
  • improve performance of checking files
  • add ip_ban_alert for IPs banned internally by libtorrent
  • fix peer DSCP marking on outgoing TCP connections

What's Changed

Read more

v2.0.14

Choose a tag to compare

@arvidn arvidn released this 10 Aug 13:56

Changelog 2.0.14

  • fix issue in merkle tree
  • fix use of a stack buffer past its lifetime when sending i2p SAM commands
  • fix issues with active_time, seeding_time and finished_time
  • fix torrent updates for idle torrents
  • improve dont-count-slow-torrents
  • fix external_ip_alert not being posted under some conditions when UPnP/NAT-PMP is enabled
  • fix issue with stuck trackers on session pause
  • fix windows disk read, possibly causing short-read errors
  • fix blocking UDP socket in LSD and NAT-PMP
  • fix web seed requests for single-file torrents in multi-file mode
  • fix duplicate filenames in magnet links
  • fix blocking UDP socket in UPnP
  • fix corruption bug in mmap_storage
  • fix bug where torrent_status::total was not set for seeds

What's Changed

  • harden merkle_tree proof validation by @arvidn in #8466
  • Fix web seed Host header ports by @hussainarslan in #8460
  • use the new host_header functions in more places by @arvidn in #8471
  • Add Linux CA certificate probing in start_session() by @trim21 in #8488
  • torrent_status::total by @arvidn in #8524
  • fix use-after-free in uTP failure socket shutdown path by @arvidn in #8528
  • fix incorrect hint in mmap_storage::write that could cause corruption by @arvidn in #8542
  • disk_write_mode setting by @arvidn in #8546
  • fix blocking UDP socket in UPnP by @arvidn in #8555
  • backport: fix duplicate filenames in magnet links by @arvidn in #8556
  • fix web seed requests for single-file torrents in multi-file mode by @arvidn in #8559
  • fix integer overflow in download_queue_time() by @arvidn in #8560
  • non-blocking UDP socket in LSD and NAT-PMP by @arvidn in #8566
  • persist BEP-21 upload_only on peer_list entry (RC_2_0) by @reardonia in #8557
  • Optimize CPU usage in the DH key exchange hot path by @anthonyryan1 in #8565
  • back-port want_peers_finished() invariant check failure by @arvidn in #8575
  • fix mistake in workflows syntax by @arvidn in #8577
  • handle ReadFile() returning a short read, by retrying by @arvidn in #8597
  • fix undefined std::toupper on signed char in base32decode by @isl-Ramzi in #8600
  • Abort trackers 2.0 by @arvidn in #8604
  • fix out of bounds read in from_hex on odd number of digits by @isl-Ramzi in #8611
  • fix external_ip_alert not being posted when UPnP/NAT-PMP succeeds by @rts-kotori in #8607
  • inactive torrent fix, back-port by @arvidn in #8617
  • don't report a utf8 sequence length longer than the input by @isl-Ramzi in #8618
  • fix torrent updates for idle torrents by @arvidn in #8620
  • Fix empty tracker tiers are incorrectly saved by @arvidn in #8625
  • factor out fragile logic to track active, seeding and finished time by @arvidn in #8623
  • fix out of bounds write in hashes_rejected on block hash requests by @isl-Ramzi in #8630
  • reject all-zero node hashes in merkle_validate_and_insert_proofs by @isl-Ramzi in #8635
  • back-port: don't hand a stack buffer to async_write in i2p_stream by @arvidn in #8641
  • back-port Fix wrapped packet buffer range checks by @arvidn in #8661
  • back-port web seed chunk size check by @arvidn in #8672
  • bump 2.0.14 version by @arvidn in #8684
  • back port of merkle tree fix by @arvidn in #8711

New Contributors

Full Changelog: v2.0.13...v2.0.14

v2.1.0

Choose a tag to compare

@arvidn arvidn released this 09 Jul 11:08

There are some changes to the API in this version. They are documented here. The headline features for this release are:

webtorrent support

Thanks to Paul-Louis Ageneau https://github.com/paullouisageneau, and apologies for this feature having been unreleased for so long.
This feature is now enabled by default. The last push to get this ready has been to add fuzz targets for WebRTC specific features, rtc_parse_endpoint, rtc_peer_conn, rtc_tracker_offer and sdp_offer. The dependencies for webtorrent support are pulled in as submodules in the repository. webtorrent also adds a new dependency on boost-json.

Note that the webtorrent support significantly widens the attack surface of libtorrent, if you don't need this feature, it's probably best disabled (webtorrent=off / -Dwebtorrent=OFF)

pread_disk_io

A new disk I/O backend that uses pwritev and preadv (and windows counterparts). This is hopefully addressing the misstep of transitioning all disk I/O over to memory mapped files. The mmap disk backend is still available and is probably more efficient for local NVMe drives. But for spinning disks, network mounts or FUSE drives, regular I/O calls should be a lot more efficient. pread_disk_io is now the default.

One of the main challenges with the new disk I/O has been to get the multi-threading right. It computes piece hashes on dedicated threads, separate from those making the I/O calls. This lets us advertise and upload pieces before they're flushed to disk, maintaining high throughput.

Other highlights are:

  • add max_directory_depth limit to load_torrent_limits to bound file path depth when loading torrents
  • fix race in wait_for_alert(), and update its return value
  • optimize torrent_handle::torrent_file()
  • add option to not validate v1 hashes for hybrid torrents
  • add post_file_status() to query them asynchronously
  • add post_file_priorities() to query them asynchronously
  • fix local service discovery not being correctly staggered
  • make the save path for part files configurable
  • retry failed SAM connection (for i2p)
  • deprecated remap_files(), and prevent it from breaking v2 torrents
  • fix peer_info holding an i2p destination
  • implement i2p_pex, peer exchange support for i2p torrents
  • deprecate torrent_alert::torrent_name()
  • requires OpenSSL minimum version 1.1.0 with SNI support
  • try harder to bind TCP and UDP sockets to the same port
  • made disk_interface's status_t type a flags type
  • optimize resume data format to use less space
  • add a simpler overload to bencode() returning a vector
  • introduced a new API for creating torrents, enabling file_storage optimizations
  • default build to not include functions deprecated in libtorrent 1.1 and earlier
  • add comment, created_by and creation_date to add_torrent_params
  • move session_flags to session_params
  • the entry class is now a standard variant type
  • use std::string_view instead of boost counterpart
  • libtorrent now requires C++17 to build
  • removed support for BEP 17 web seeds (in favor of BEP 19)
  • fix bug where torrent_status::total was not set for seeds

full commit log

Read more

v2.1.0-rc3

v2.1.0-rc3 Pre-release
Pre-release

Choose a tag to compare

@arvidn arvidn released this 07 Jul 07:22

What's Changed

  • Add Linux CA certificate probing in start_session() by @trim21 in #8488
  • fix race in updating blocked_disk_jobs counter, in disk_job_fence by @arvidn in #8495
  • improve some torrent_alert message strings by @arvidn in #8506
  • address false positive warning with -Wms-bitfield-padding by @arvidn in #8509
  • add fuzzer for SDP offer by @arvidn in #8510
  • fuzzers for parse RTC endpoint and RTC tracker offer by @arvidn in #8514
  • torrent_status::total by @arvidn in #8524
  • Test merge by @arvidn in #8525
  • fix use-after-free in uTP failure socket shutdown path by @arvidn in #8528
  • Test merge by @arvidn in #8529
  • fix TORRENT_DISK_LATENCY_STATS in cmake file and config.hpp by @arvidn in #8535
  • fix bug in tracker stop request for webRTC by @arvidn in #8534
  • fix clang-tidy warnings, and disable for dependencies by @arvidn in #8533
  • Release CI workflow by @arvidn in #8536
  • handle exception from libdatachannel sendBuffer() by @arvidn in #8537
  • fix edge case causing memory leak in rtc_stream_impl::write_data() by @arvidn in #8539
  • enable webtorrent by default by @arvidn in #8532
  • fix incorrect hint in mmap_storage::write that could cause corruption by @arvidn in #8542
  • upload tarballs for release candidates too by @arvidn in #8543
  • disk_write_mode setting by @arvidn in #8546
  • Test merge by @arvidn in #8547
  • fixes related to force-reannounce and priority announce by @arvidn in #8540
  • fix CMake test_rtc.cpp by @arvidn in #8545

New Contributors

Full Changelog: v2.1.0-rc2...v2.1.0-rc3

v2.1.0-rc2

v2.1.0-rc2 Pre-release
Pre-release

Choose a tag to compare

@arvidn arvidn released this 19 Jun 13:06

What's Changed

Read more

v2.0.13

Choose a tag to compare

@arvidn arvidn released this 08 Jun 20:19

2.0.13 released

  • stricter basic auth handling for web seed
  • fix bug in tracker announcements involving i2p trackers
  • improve performance of disk job pool
  • fix race when removing an auto managed torrent
  • fix bug in post_download_queue() when a torrent complete
  • in create_torrent, store symbolic links according to BEP 47
  • strengthen peer encryption (obfuscation)
  • improve HTTP response parsing
  • optimize sanitization of symlinks when loading torrents
  • stricter checking of tracker URLs
  • fixed piece-picker accounting issue for filtered pieces
  • add setting for NAT-PMP lease duration
  • optimize v2 request sizes
  • fix socks5 issues
  • fix issue in loading v2 resume data merkle trees

What's Changed

New Contributors

Full Changelog: v2.0.12...v2.0.13

v2.1.0-rc1

v2.1.0-rc1 Pre-release
Pre-release

Choose a tag to compare

@arvidn arvidn released this 22 Apr 05:30

2.1.0 Release Candidate 1

* optimize torrent_handle::torrent_file()
* add option to not validate v1 hashes for hybrid torrents
* add post_file_status() to query them asynchronously
* add post_file_priorities() to query them asynchronously
* fix local service discovery not being correctly staggered
* add an experimental multi-threaded, pread()-based, disk I/O backend (pread_disk_io)
* make the save path for part files configurable
* retry failed SAM connection (for i2p)
* deprecated remap_files(), and prevent it from breaking v2 torrents
* fix peer_info holding an i2p destination
* implement i2p_pex, peer exchange support for i2p torrents
* deprecate torrent_alert::torrent_name()
* requires OpenSSL minimum version 1.1.0 with SNI support
* try harder to bind TCP and UDP sockets to the same port
* made disk_interface's status_t type a flags type
* optimize resume data format to use less space
* add a simpler overload to bencode() returning a vector<char>
* introduced a new API for creating torrents, enabling file_storage optimizations
* default build to not include functions deprecated in libtorrent 1.1 and earlier
* add comment, created_by and creation_date to add_torrent_params
* move session_flags to session_params
* the entry class is now a standard variant type
* use std::string_view instead of boost counterpart
* libtorrent now requires C++17 to build
* added support for WebTorrent

Full Changelog: v2.0.12...v2.1.0-rc1

v2.0.12

Choose a tag to compare

@arvidn arvidn released this 13 Mar 22:23

2.0.12 released

  • fix issue where file priorities could be cleared by force recheck
  • fix issue in XML parser
  • when building against OpenSSL, require at least version 1.1.1
  • add setting to set no-copy-on-write flag on new files
  • add performance counters to file pool
  • add high_priority flag to torrent_handle::force_reannounce()
  • update default DSCP value and update docs
  • fix python binding for set_notify_function()
  • fix error handling in mmap disk I/O when hashing files
  • improve copy_file_range() fallback
  • don't overwrite existing files when renaming
  • add option to send host header in HTTP proxy CONNECT command
  • cache DNS failures for a shorter time
  • file_renamed_alert is always posted, regardless of alert mask
  • add feature to request resume data synchronously
  • don't leak file descriptors to child processes (O_CLOEXEC)
  • optimize the utp resend
  • optimize tracker announcements
  • fix handling of invalid filenames
  • add support for I2CP inbound.lengthVariance and outbound.lengthVariance tunnel settings
  • add natpmp_gateway setting to manually set the default gateway for the NAT-PMP protocol

What's Changed

Read more

libtorrent 2.0.11

Choose a tag to compare

@arvidn arvidn released this 28 Jan 12:15

What's Changed

New Contributors

Full Changelog: v2.0.10...v2.0.11

libtorrent 1.2.20

Choose a tag to compare

@arvidn arvidn released this 28 Jan 12:11
2e537ee

What's Changed

  • backport cibuildwheel fix of not running tests in win32 by @arvidn in #7442
  • back-port posix timestamps by @stalkerok in #7446
  • back-port updating test certs by @arvidn in #7467
  • Allow to compile RC_1_2 branch in C++20 mode by @Chocobo1 in #7491
  • FIX(peer_list): clear the m_candidate_cache when clear peer_list, and… by @Lwxiang in #7460
  • avoid implicit this capture by @arvidn in #7502
  • rely on RVO in C++20 by @arvidn in #7504
  • (Backport) Treat CGNAT address range as local IPs by @Chocobo1 in #7531
  • Allow to change save path without moving any files by @glassez in #7552
  • bump python version on github actions to 3.12 by @arvidn in #7583
  • Migrate away from deprecated functions in C++23 by @Chocobo1 in #7582
  • Clean up MSVC compiler flags by @Chocobo1 in #7615
  • fix issue when closing a uTP connection RC_1_2 backport by @arvidn in #7718
  • fix piece size check when loading torrents by @arvidn in #7740
  • use stricter rules for what filenames are valid on Android by @arvidn in #7832
  • update test certs by @arvidn in #7833
  • validate add_torrent_params::save_path at run-time by @arvidn in #7825

New Contributors

Full Changelog: v1.2.19...v1.2.20