Allow loosening remote "git archive" invocation security check that
refuses to serve tree-ish not at the tip of any ref.
* sg/archive-restrict-remote:
add uploadarchive.allowUnreachable option
docs: clarify remote restrictions for git-upload-archive
@ -20,6 +20,38 @@ This command is usually not invoked directly by the end user. The UI
@@ -20,6 +20,38 @@ This command is usually not invoked directly by the end user. The UI
for the protocol is on the 'git archive' side, and the program pair
is meant to be used to get an archive from a remote repository.
SECURITY
--------
In order to protect the privacy of objects that have been removed from
history but may not yet have been pruned, `git-upload-archive` avoids
serving archives for commits and trees that are not reachable from the
repository's refs. However, because calculating object reachability is
computationally expensive, `git-upload-archive` implements a stricter
but easier-to-check set of rules:
1. Clients may request a commit or tree that is pointed to directly by
a ref. E.g., `git archive --remote=origin v1.0`.
2. Clients may request a sub-tree within a commit or tree using the