mirror of
https://git.openafs.org/openafs.git
synced 2025-01-18 15:00:12 +00:00
65290ac18b
When restoring with a regular file (either with -file or a shell redirect '<'), vos restore verifies the file ends with the end-of-dump magic number. This catches cases in which the specified file is obviously not a dump file, for example the file is empty, truncated, or just not file created by vos dump. Currently, no checks are done when restoring from a pipe or fifo, since it is not possible to check the end of the stream and reset the seek pointer to before sending the data to the volume server. Add a check to verify the dump begins with the dump header tag and the start-of-dump magic number, even when the dump file is not seekable. In the case the dump file is not seekable, send the start of dump tag and the start-of-dump magic number directly in SendFile(), since those values were already read in CheckDumpFile(). This guards against starting a restore from an empty or wrong file when restoring from a pipeline or a named pipe. Change-Id: I7aa508bf5f0e81da7d6602856b5242cb6313e9a8 Reviewed-on: https://gerrit.openafs.org/14711 Reviewed-by: Cheyenne Wills <cwills@sinenomine.net> Tested-by: BuildBot <buildbot@rampaginggeek.com> Reviewed-by: Andrew Deason <adeason@sinenomine.net> |
||
---|---|---|
build-tools | ||
doc | ||
src | ||
tests | ||
.gitignore | ||
.gitreview | ||
.mailmap | ||
.splintrc | ||
acinclude.m4 | ||
CODING | ||
configure-libafs.ac | ||
configure.ac | ||
CONTRIBUTING | ||
INSTALL | ||
libafsdep | ||
LICENSE | ||
Makefile-libafs.in | ||
Makefile.in | ||
NEWS | ||
NTMakefile | ||
README | ||
README-WINDOWS | ||
regen.sh |
AFS is a distributed file system that enables users to share and access all of the files stored in a network of computers as easily as they access the files stored on their local machines. The file system is called distributed for this exact reason: files can reside on many different machines, but are available to users on every machine. OpenAFS 1.0 was originally released by IBM under the terms of the IBM Public License 1.0 (IPL10). For details on IPL10 see the LICENSE file in this directory. The current OpenAFS distribution is licensed under a combination of the IPL10 and many other licenses as granted by the relevant copyright holders. The LICENSE file in this directory contains more details, thought it is not a comprehensive statement. See INSTALL for information about building and installing OpenAFS on various platforms. See CODING for developer information and guidelines. See NEWS for recent changes to OpenAFS.