From d860d9e5dd342750adc1f10ba29930df48642703 Mon Sep 17 00:00:00 2001 From: Axel Burri Date: Tue, 28 Apr 2015 20:17:47 +0200 Subject: [PATCH] btrbk: allow '+' character for subvolume names --- btrbk | 2 +- doc/btrbk.conf.5 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/btrbk b/btrbk index 9b127f6..9ef95bc 100755 --- a/btrbk +++ b/btrbk @@ -91,7 +91,7 @@ my $loglevel = 1; my $ip_addr_match = qr/(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])/; my $host_name_match = qr/(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9\-]*[a-zA-Z0-9])\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9\-]*[A-Za-z0-9])/; -my $file_match = qr/[0-9a-zA-Z_@\-\.\/]+/; # note: ubuntu uses '@' in the subvolume layout: +my $file_match = qr/[0-9a-zA-Z_@\+\-\.\/]+/; # note: ubuntu uses '@' in the subvolume layout: my $ssh_prefix_match = qr/ssh:\/\/($ip_addr_match|$host_name_match)/; my $snapshot_postfix_match = qr/\.[0-9]{8}(_[0-9]+)?/; diff --git a/doc/btrbk.conf.5 b/doc/btrbk.conf.5 index febcbf8..edabe61 100644 --- a/doc/btrbk.conf.5 +++ b/doc/btrbk.conf.5 @@ -40,7 +40,7 @@ ssh-url instead of a local directory. The syntax for \fI\fR is: ssh://host.xz/path/to/volume .PP Note that btrfs is very picky on file names (mainly for security -reasons), only the characters [0-9] [a-z] [A-Z] and "._-@" are +reasons), only the characters [0-9] [a-z] [A-Z] and "._+-@" are allowed. .PP The configuration options are: