0
0
Fork 0
mirror of https://github.com/RsyncProject/rsync.git synced 2026-04-21 06:20:35 +00:00
An open source utility that provides fast incremental file transfer. It also has useful features for backup and restore operations among many other use cases. https://rsync.samba.org
  • C 81.3%
  • Shell 6%
  • Python 5.3%
  • M4 2.3%
  • Assembly 1.3%
  • Other 3.8%
Find a file
Andrew Tridgell d1df0aaf70 fix signed integer overflow in proxy protocol v2 header parsing
The len field in the proxy v2 header was declared as signed char,
allowing a negative size to bypass the validation check and cause
a stack buffer overflow when passed to read_buf() as size_t.

This bug was reported by John Walker from ZeroPath, many thanks for
the clear report!

With the current code this bug does not represent a security issue as
it only results in the exit of the forked process that is specific to
the attached client, so it is equivalent to the client closing the
socket, so no CVE for this, but it is good to fix it to prevent a
future issue.
2026-04-16 13:59:52 +10:00
.github/workflows CI: add simd-checksum to expected-skipped on macOS and Cygwin 2026-03-02 09:52:01 +11:00
doc Spelling fixes from a Fossies run done by Jens. 2020-04-15 17:42:23 -07:00
lib make lots of global variables const 2025-08-23 17:31:40 +10:00
m4 Silence autoconf warnings. 2022-10-16 10:28:58 -07:00
packaging Update MAINTAINER_TZ_OFFSET on release. 2025-01-15 23:27:27 -08:00
popt popt: remove obsolete findme.c & findme.h 2025-01-17 08:31:36 +11:00
support rsync: Add missing dirs long option 2025-12-30 16:48:34 +11:00
testhelp Use /usr/bin/env for increased portability. 2020-06-16 18:27:48 -07:00
testsuite fix uninitialized mul_one in AVX2 checksum and add SIMD checksum test 2026-03-02 09:52:01 +11:00
zlib zlib: convert K&R function definitions to ANSI style 2026-04-16 13:49:30 +10:00
.gitattributes Force git line endings (#68) 2020-07-15 10:20:52 -07:00
.gitignore chore: gitignore MacOS debug symbols 2025-08-23 17:31:12 +10:00
access.c Preparing for release of 3.2.4pre2 2022-01-15 17:21:01 -08:00
acls.c acl: fixed ACL ID mapping for non-root 2026-01-19 11:32:13 +11:00
authenticate.c Preparing for release of 3.2.7pre1 2022-09-30 12:36:21 -07:00
backup.c Preparing for release of 3.2.4pre2 2022-01-15 17:21:01 -08:00
batch.c make lots of global variables const 2025-08-23 17:31:40 +10:00
byteorder.h Preparing for release of 3.2.5 2022-08-14 10:15:08 -07:00
case_N.h Two more spelling fixes and some year updates. 2020-04-16 09:31:02 -07:00
checksum.c fix uninitialized buf1 in get_checksum2() MD4 path 2025-12-30 16:51:43 +11:00
chmod.c Two more spelling fixes and some year updates. 2020-04-16 09:31:02 -07:00
cleanup.c Mention file & line on OOM and overflow errors. 2020-07-12 23:25:21 -07:00
clientname.c fix signed integer overflow in proxy protocol v2 header parsing 2026-04-16 13:59:52 +10:00
clientserver.c A few more doc tweaks & comment tweaks. 2022-09-30 12:34:58 -07:00
cmd-or-msg Rename cmdormsg -> cmd-or-msg. 2021-09-26 18:55:46 -07:00
compat.c feat: add threads to zstd compression 2025-08-23 17:13:49 +10:00
config.guess Mention updated config files. 2023-05-04 08:45:42 -07:00
config.sub Mention updated config files. 2023-05-04 08:45:42 -07:00
configure Improve the per-branch build dir support 2020-06-28 19:42:25 -07:00
configure.ac configure.ac: check for xattr support both in libc and in -lattr 2025-08-23 17:14:06 +10:00
connection.c Set Copyright years and make them easier to update 2020-04-09 15:11:37 -07:00
COPYING Minor cleanup (#214) 2021-09-26 16:57:55 -07:00
csprotocol.txt A few more doc tweaks & comment tweaks. 2022-09-30 12:34:58 -07:00
daemon-parm.awk make lots of global variables const 2025-08-23 17:31:40 +10:00
daemon-parm.txt Some "use chroot" improvements. 2022-09-20 00:08:16 -07:00
define-from-md.awk Use documentation to extract 2 more .h lists 2020-06-18 11:20:57 -07:00
delete.c Preparing for release of 3.3.0 [buildall] 2024-04-06 09:30:21 -07:00
Doxyfile Don't generate code for zlib and popt. 2002-04-08 04:00:24 +00:00
errcode.h Tweak the copyright year. 2019-03-16 09:15:49 -07:00
exclude.c Preparing for release of 3.3.0 [buildall] 2024-04-06 09:30:21 -07:00
fileio.c Preparing for release of 3.3.0pre1 [buildall] 2023-04-29 09:01:43 -07:00
flist.c make lots of global variables const 2025-08-23 17:31:40 +10:00
generator.c Fix use-after-free in generator 2025-01-16 06:27:26 +11:00
getfsdev.c Some indentation fixes. 2020-06-13 19:15:02 -07:00
getgroups.c Some misc cleanup 2020-06-27 21:19:52 -07:00
hashtable.c Preparing for release of 3.2.7pre1 2022-09-30 12:36:21 -07:00
help-from-md.awk Use documentation to extract 2 more .h lists 2020-06-18 11:20:57 -07:00
hlink.c hlink: Fix function pointer cast in qsort() 2024-12-18 08:56:27 +11:00
ifuncs.h Preparing for release of 3.2.4pre2 2022-01-15 17:21:01 -08:00
install-sh shell: test -a|o is not POSIX (#250) 2021-11-07 10:23:01 -08:00
INSTALL.md added apple silicon path details 2024-05-29 11:19:19 +10:00
inums.h Tweak the copyright year. 2019-03-16 09:15:49 -07:00
io.c make lots of global variables const 2025-08-23 17:31:40 +10:00
io.h Tweak the copyright year. 2019-03-16 09:15:49 -07:00
itypes.h Preparing for release of 3.2.4pre2 2022-01-15 17:21:01 -08:00
latest-year.h Preparing for release of 3.4.0 [buildall] 2025-01-15 05:53:23 +11:00
loadparm.c make lots of global variables const 2025-08-23 17:31:40 +10:00
log.c Improve various things in the checksum code 2022-09-10 11:39:37 -07:00
main.c make lots of global variables const 2025-08-23 17:31:40 +10:00
Makefile.in fix uninitialized mul_one in AVX2 checksum and add SIMD checksum test 2026-03-02 09:52:01 +11:00
match.c prevent information leak off the stack 2025-01-15 05:30:32 +11:00
maybe-make-man Add --force-link-text to md-convert. 2023-04-23 08:26:32 -07:00
md-convert Make the build reproducible 2025-08-23 16:40:34 +10:00
md2man Unify md parsing scripts & improve non-man html conversions. 2021-12-27 14:24:05 -08:00
mkgitver Fix version verification when "\|" doesn't work in sed. 2022-10-16 11:14:15 -07:00
mkproto.awk Use touch for proto.h-tstamp since one awk wasn't updating mtime. 2020-08-03 13:33:46 -07:00
NEWS.md Start 3.4.2dev going. 2025-01-15 22:01:42 -08:00
options.c options.c: Fix segv if poptGetContext returns NULL 2025-08-23 17:49:03 +10:00
params.c Some memory allocation improvements 2020-06-25 20:54:21 -07:00
pipe.c Some indentation fixes. 2020-06-13 19:15:02 -07:00
prepare-source Some word fixes. 2022-03-26 08:58:51 -07:00
prepare-source.mak Don't make .PHONY the first target in a Makefile. 2020-07-30 18:58:34 -07:00
progress.c Preparing for release of 3.2.4pre2 2022-01-15 17:21:01 -08:00
README.md added security email address to README.md 2024-12-18 08:55:45 +11:00
receiver.c fixed symlink race condition in sender 2025-01-15 05:30:32 +11:00
rounding.c Check extra rounding using an int64. 2020-06-18 15:45:39 -07:00
rsync-ssl add ssl/tls key option (#216) 2021-09-26 16:44:00 -07:00
rsync-ssl.1.md Link to rsyncd.conf page server-setup details. 2022-06-19 16:55:18 -07:00
rsync.1.md feat: add compress threads to man page 2025-08-23 17:13:49 +10:00
rsync.c Some checksum buffer fixes. 2024-10-29 23:06:34 -07:00
rsync.h Fix FLAG_GOT_DIR_FLIST collission with FLAG_HLINKED 2025-01-16 06:21:54 +11:00
rsync3.txt A few more https changes. 2020-06-22 14:21:15 -07:00
rsyncd.conf.5.md Tweak maintainer messaging. 2024-04-08 13:16:12 -07:00
rsyncsh.txt Notes on an interactive shell for rsync. 2001-08-30 07:11:46 +00:00
runtests.sh Preparing for release of 3.2.4pre2 2022-01-15 17:21:01 -08:00
SECURITY.md update maintainer address 2025-01-15 12:13:41 +11:00
sender.c fixed an invalid access to files array 2025-08-23 17:49:19 +10:00
shconfig.in Better fakeroot support helps Solaris. 2011-09-20 13:17:42 -07:00
simd-checksum-avx2.S Make asm use more selectable 2022-03-03 17:00:57 -08:00
simd-checksum-x86_64.cpp fix uninitialized mul_one in AVX2 checksum and add SIMD checksum test 2026-03-02 09:52:01 +11:00
socket.c Some memory allocation improvements 2020-06-25 20:54:21 -07:00
stunnel-rsyncd.conf.in Change the rsync-ssl helper script 2020-04-19 14:00:33 -07:00
syscall.c syscall: fix a Y2038 bug by replacing Int32x32To64 with multiplication 2025-08-23 17:32:11 +10:00
t_stub.c Improve packaging/var-checker. 2024-11-14 11:42:24 -08:00
t_unsafe.c fixed symlink race condition in sender 2025-01-15 05:30:32 +11:00
tech_report.tex updates to reflect new samba.org domain 1998-11-23 00:30:27 +00:00
testrun.c Let's cast getpid() to an int instead of a long for snprintf(). 2011-10-08 09:15:36 -07:00
tls.c make lots of global variables const 2025-08-23 17:31:40 +10:00
TODO A few more https changes. 2020-06-22 14:21:15 -07:00
token.c reject negative token values in compressed stream receivers 2025-12-31 09:31:52 +11:00
trimslash.c fixed symlink race condition in sender 2025-01-15 05:30:32 +11:00
uidlist.c Preparing for release of 3.2.5pre1 2022-08-01 18:51:07 -07:00
usage.c Cygwin needs stdout flushed. [buildall] 2022-10-22 12:04:32 -07:00
util1.c util: fixed issue in clean_fname() 2025-12-30 17:49:35 +11:00
util2.c Preparing for release of 3.3.0 [buildall] 2024-04-06 09:30:21 -07:00
version.h Start 3.4.2dev going. 2025-01-15 22:01:42 -08:00
wildtest.c make lots of global variables const 2025-08-23 17:31:40 +10:00
wildtest.txt A few extra directory-style matching tests. 2005-12-19 02:30:59 +00:00
xattrs.c Use hashlittle2() for xattr hashing 2022-09-13 22:43:01 -07:00

WHAT IS RSYNC?

Rsync is a fast and extraordinarily versatile file copying tool for both remote and local files.

Rsync uses a delta-transfer algorithm which provides a very fast method for bringing remote files into sync. It does this by sending just the differences in the files across the link, without requiring that both sets of files are present at one of the ends of the link beforehand. At first glance this may seem impossible because the calculation of diffs between two files normally requires local access to both files.

A technical report describing the rsync algorithm is included with this package.

USAGE

Basically you use rsync just like scp, but rsync has many additional options. To get a complete list of supported options type:

rsync --help

See the manpage for more detailed information.

BUILDING AND INSTALLING

If you need to build rsync yourself, check out the INSTALL page for information on what libraries and packages you can use to get the maximum features in your build.

SETUP

Rsync normally uses ssh or rsh for communication with remote systems. It does not need to be setuid and requires no special privileges for installation. You must, however, have a working ssh or rsh system. Using ssh is recommended for its security features.

Alternatively, rsync can run in `daemon' mode, listening on a socket. This is generally used for public file distribution, although authentication and access control are available.

To install rsync, first run the "configure" script. This will create a Makefile and config.h appropriate for your system. Then type "make".

Note that on some systems you will have to force configure not to use gcc because gcc may not support some features (such as 64 bit file offsets) that your system may support. Set the environment variable CC to the name of your native compiler before running configure in this case.

Once built put a copy of rsync in your search path on the local and remote systems (or use "make install"). That's it!

RSYNC DAEMONS

Rsync can also talk to "rsync daemons" which can provide anonymous or authenticated rsync. See the rsyncd.conf(5) manpage for details on how to setup an rsync daemon. See the rsync(1) manpage for info on how to connect to an rsync daemon.

WEB SITE

For more information, visit the main rsync web site.

You'll find a FAQ list, downloads, resources, HTML versions of the manpages, etc.

MAILING LISTS

There is a mailing list for the discussion of rsync and its applications that is open to anyone to join. New releases are announced on this list, and there is also an announcement-only mailing list for those that want official announcements. See the mailing-list page for full details.

BUG REPORTS

The bug-tracking web page has full details on bug reporting.

That page contains links to the current bug list, and information on how to do a good job when reporting a bug. You might also like to try searching the Internet for the error message you've received, or looking in the mailing list archives.

To send a bug report, follow the instructions on the bug-tracking page of the web site.

Alternately, email your bug report to rsync@lists.samba.org.

For security issues please email details of the issue to rsync.project@gmail.com.

GIT REPOSITORY

If you want to get the very latest version of rsync direct from the source code repository, then you will need to use git. The git repo is hosted on GitHub and on Samba's site.

See the download page for full details on all the ways to grab the source.

Rsync was originally written by Andrew Tridgell and Paul Mackerras. Many people from around the world have helped to maintain and improve it.

Rsync may be used, modified and redistributed only under the terms of the GNU General Public License, found in the file COPYING in this distribution, or at the Free Software Foundation.