Create a 1.6.x backport branch for the issue #4340 fix.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x-issue4340@1461605 13f79535-47bb-0310-9956-ffa450edef68
Backport fix for issue #4340, "fs layer should reject filenames with
trailing \n", to the 1.6.x-issue4340 branch.

Merge r1461562 and r1461580 from trunk, resolving a text conflict
with the former revision, and a tree conflict with the latter revision.

* subversion/libsvn_fs/editor.c: This file doesn't exist in 1.6.x,
   so this change on trunk doesn't apply.

* subversion/libsvn_fs/fs-loader.c: Fix a text conflict caused by the
   existence of additional new tests in trunk. Tweak the test to not
   rely on SVN_TEST_ASSERT_ERROR which doesn't exist in 1.6.x, and
   adjust it to the 1.6.x C test API.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x-issue4340@1461606 13f79535-47bb-0310-9956-ffa450edef68
On the 1.6.x-issue4340 branch, merge r1461701 from trunk, resolving conflicts.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x-issue4340@1466004 13f79535-47bb-0310-9956-ffa450edef68
On the 1.6.x-issue4340 branch, merge r1461760 from trunk, resolving conflicts.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x-issue4340@1466009 13f79535-47bb-0310-9956-ffa450edef68
On the 1.6.x-issue4340 branch:

* subversion/libsvn_repos/commit.c: Remove a stray ^L which ended up
   in the result of my merge of r1461760 from trunk.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x-issue4340@1466010 13f79535-47bb-0310-9956-ffa450edef68
On the 1.6.x-issue4340 branch, revert r1466009 and r1466010. The changes
merged in those revisions now live on the 1.6.x-issue4340-repos branch.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x-issue4340@1484259 13f79535-47bb-0310-9956-ffa450edef68
On the 1.6.x-issue4340 branch, filter control characters from an error message.

This corresponds to r1481627 on trunk, but the svn_path_illegal_path_escape()
API function used in that commit is not available in 1.6.x. So I've manually
marked the revision as merged using a --record-only merge.

* subversion/libsvn_fs_fs/tree.c
  (): Include svn_ctype.h for svn_ctype_iscntrl().
  (escape_newline): Rename to...
  (illegal_path_escape): ... this, and tweak the code to match the current
   implementation of svn_path_illegal_path_escape() on trunk.
  (check_newline): Update caller.


git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x-issue4340@1484261 13f79535-47bb-0310-9956-ffa450edef68
Merge the 1.6.x-issue4340 branch into 1.6.x.

 * r1461562, r1461580, r1461701, r1481627
   Fix issue #4340, "filenames containing \n corrupt FSFS repositories"
   Justification:
     Newline characters can severely corrupt FSFS revision files and
     should never enter the repository for this reason. See discussion
     linked from issue #4340 for more information.
   Notes:
     r1461701 revises the changes made in the earlier revisions,
     and is the result of a long dev@ discussion that eventually concluded
     in this subthread: http://svn.haxx.se/dev/archive-2013-04/0056.shtml
     This issue can be exploited by people with commit access to corrupt
     an FSFS repository, and has been assigned a CVE number: CVE-2013-1968
     r1481627 addresses concerns raised by danielsh.
   Branch:
     ^/subversion/branches/1.6.x-issue4340
   Votes:
     +1: stsp, danielsh, rhuijben



git-svn-id: https://svn.apache.org/repos/asf/subversion/branches/1.6.x@1485299 13f79535-47bb-0310-9956-ffa450edef68