Announcing qcp

Posted on in software with tags network, debian.

The QUIC Copier (qcp) is an experimental high-performance remote file copy utility for long-distance internet connections.

Source repository: https://github.com/crazyscot/qcp

๐Ÿ“‹ Features

  • ๐Ÿ”ง Drop-in replacement for scp
  • ๐Ÿ›ก๏ธ Similar security to scp, using existing, well-known mechanisms
  • ๐Ÿš€ Better throughput on congested networks

๐Ÿ“– About qcp

qcp is a hybrid protocol combining ssh and QUIC.

We use ssh to establish a control channel to the target machine, then spin up the QUIC protocol to transfer data.

This has the following useful properties:

  • User authentication is handled entirely by ssh
  • Data is transmitted over UDP, avoiding known issues with TCP over “long, fat pipe” connections
  • Data in transit is protected by TLS using ephemeral keys
  • The security mechanisms all use existing, well-known cryptographic algorithms

For full documentation refer to qcp on docs.rs.

Motivation

I needed to copy multiple large (3+ GB) files from a server in Europe to my home in New Zealand.

Iโ€™ve got nothing against ssh or scp. Theyโ€™re brilliant. Iโ€™ve been using them since the 1990s. However they run on top of TCP, which does not perform very well when the network is congested. With a fast fibre internet connection, a long round-trip time and noticeable packet loss, I was right in the sour spot. TCP did its thing and slowed down, but when the congestion cleared it was very slow to get back up to speed.

If youโ€™ve ever been frustrated by download performance from distant websites, you might have been experiencing this same issue. Friends with satellite (pre-Starlink) internet connections seem to be particularly badly affected.

๐Ÿ’ป Getting qcp

The project is a Rust binary crate.

You can install it:

  • as a Debian package or pre-compiled binary from the latest qcp release page (N.B. the Linux builds are static musl binaries);
  • with cargo install qcp (you will need to have a rust toolchain and capnpc installed);
  • by cloning and building the source repository.

You will need to install qcp on both machines. Please refer to the README for more.

See also