Librsync is a library for calculating and applying network deltas, with an interface designed to ease integration into diverse network applications. Librsync encapsulates the core algorithms of the rsync protocol, which help with efficient calculation of the differences between two files. The rsync algorithm is different from most differencing algorithms because it does not require the presence of the two files to calculate the delta. Instead, it requires a set of checksums of each block of one file, which together form a signature for that file. Blocks at any point in the other file which have the same checksum are likely to be identical, and whatever remains is the difference.