aboutsummaryrefslogtreecommitdiffstats
path: root/main/lsyncd
diff options
context:
space:
mode:
authorLeonardo Arena <rnalrd@alpinelinux.org>2017-01-10 09:50:00 +0000
committerLeonardo Arena <rnalrd@alpinelinux.org>2017-01-10 09:50:00 +0000
commit61996bf587870dd0479abad6dddc13de1e09734c (patch)
tree3d8981bfb5588b85d36d5c7e62a332100477e781 /main/lsyncd
parent68063f674d0ecb2d63ea169a8f7e8fc815df42d4 (diff)
downloadaports-61996bf587870dd0479abad6dddc13de1e09734c.tar.bz2
aports-61996bf587870dd0479abad6dddc13de1e09734c.tar.xz
main/lsyncd: upgrade to 2.2.1
Diffstat (limited to 'main/lsyncd')
-rw-r--r--main/lsyncd/0001-Add-missed-comma.patch25
-rw-r--r--main/lsyncd/0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch25
-rw-r--r--main/lsyncd/0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch34
-rw-r--r--main/lsyncd/0003-Add-checkgauge-in-lpostcmd.patch31
-rw-r--r--main/lsyncd/APKBUILD62
-rw-r--r--main/lsyncd/CVE-2014-8990.patch107
-rw-r--r--main/lsyncd/fix-mandir.patch8
7 files changed, 28 insertions, 264 deletions
diff --git a/main/lsyncd/0001-Add-missed-comma.patch b/main/lsyncd/0001-Add-missed-comma.patch
deleted file mode 100644
index 3348955698..0000000000
--- a/main/lsyncd/0001-Add-missed-comma.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 7addc7060b05e664b8e09e5c13b294e8e6394481 Mon Sep 17 00:00:00 2001
-From: Kazunori SAKAMOTO <exkazuu@gmail.com>
-Date: Fri, 3 Jan 2014 17:11:48 +0900
-Subject: [PATCH] Add missed comma.
-
----
- examples/lpostcmd.lua | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/examples/lpostcmd.lua b/examples/lpostcmd.lua
-index e11639b..b48b0da 100644
---- a/examples/lpostcmd.lua
-+++ b/examples/lpostcmd.lua
-@@ -58,7 +58,7 @@ local rsyncpostcmd = {
- return default.collect(agent,exitcode)
- end
- error("this should never be reached")
-- end
-+ end,
-
- -- called before anything else
- -- builds the target from host and targetdir
---
-2.2.2
-
diff --git a/main/lsyncd/0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch b/main/lsyncd/0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch
deleted file mode 100644
index 34f3de1a10..0000000000
--- a/main/lsyncd/0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 19b08adf3520a221e77fe6ea4ebbeddd66966cac Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi>
-Date: Fri, 30 Jan 2015 09:08:58 +0200
-Subject: [PATCH 1/3] Fix lpostcmd to use isPostcmd via rawget as intended
-
----
- examples/lpostcmd.lua | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/examples/lpostcmd.lua b/examples/lpostcmd.lua
-index b48b0da..11f7faf 100644
---- a/examples/lpostcmd.lua
-+++ b/examples/lpostcmd.lua
-@@ -25,7 +25,7 @@ local rsyncpostcmd = {
- -- uses rawget to test if "isPostcmd" has been set without
- -- triggering an error if not.
- local isPostcmd = rawget(event, "isPostcmd")
-- if event.isPostcmd then
-+ if isPostcmd then
- spawn(event, "/usr/bin/ssh",
- config.host, config.postcmd)
- return
---
-2.2.2
-
diff --git a/main/lsyncd/0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch b/main/lsyncd/0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch
deleted file mode 100644
index 27f921a93d..0000000000
--- a/main/lsyncd/0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 5b76dc1cb6cacd5a086dc3870e39ab2d251ed5dc Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi>
-Date: Fri, 30 Jan 2015 09:12:02 +0200
-Subject: [PATCH 2/3] Fix lpostcmd prepare to work with recent changes
-
----
- examples/lpostcmd.lua | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/examples/lpostcmd.lua b/examples/lpostcmd.lua
-index 11f7faf..8ad339e 100644
---- a/examples/lpostcmd.lua
-+++ b/examples/lpostcmd.lua
-@@ -62,7 +62,7 @@ local rsyncpostcmd = {
-
- -- called before anything else
- -- builds the target from host and targetdir
-- prepare = function(config)
-+ prepare = function(config, level, skipTarget)
- if not config.host then
- error("rsyncpostcmd neets 'host' configured", 4)
- end
-@@ -72,7 +72,7 @@ local rsyncpostcmd = {
- if not config.target then
- config.target = config.host .. ":" .. config.targetdir
- end
-- return default.rsync.prepare(config)
-+ return default.rsync.prepare(config, level, skipTarget)
- end
- }
-
---
-2.2.2
-
diff --git a/main/lsyncd/0003-Add-checkgauge-in-lpostcmd.patch b/main/lsyncd/0003-Add-checkgauge-in-lpostcmd.patch
deleted file mode 100644
index 35729fa100..0000000000
--- a/main/lsyncd/0003-Add-checkgauge-in-lpostcmd.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From abbf307b9720140a3dd71e96f8ea0328e1bd7115 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi>
-Date: Fri, 30 Jan 2015 09:25:53 +0200
-Subject: [PATCH 3/3] Add checkgauge in lpostcmd
-
----
- examples/lpostcmd.lua | 8 ++++++++
- 1 file changed, 8 insertions(+)
-
-diff --git a/examples/lpostcmd.lua b/examples/lpostcmd.lua
-index 8ad339e..e413112 100644
---- a/examples/lpostcmd.lua
-+++ b/examples/lpostcmd.lua
-@@ -11,6 +11,14 @@ local rsyncpostcmd = {
- -- based on default rsync.
- default.rsync,
-
-+ checkgauge = {
-+ default.rsync.checkgauge,
-+ host = true,
-+ targetdir = true,
-+ target = true,
-+ postcmd = true,
-+ },
-+
- -- for this config it is important to keep maxProcesses at 1, so
- -- the postcmds will only be spawned after the rsync completed
- maxProcesses = 1,
---
-2.2.2
-
diff --git a/main/lsyncd/APKBUILD b/main/lsyncd/APKBUILD
index c84d9a8c24..f2ad2e04fb 100644
--- a/main/lsyncd/APKBUILD
+++ b/main/lsyncd/APKBUILD
@@ -1,31 +1,28 @@
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=lsyncd
-pkgver=2.1.5
-pkgrel=6
+pkgver=2.2.1
+pkgrel=0
pkgdesc="Live Syncing (Mirror) Daemon"
-url="http://code.google.com/archive/p/lsyncd/"
+url="https://github.com/axkibe/lsyncd"
arch="all"
license="GPLv2+"
depends="rsync"
depends_dev=
-makedepends="$depends_dev lua lua-dev"
+makedepends="$depends_dev cmake lua lua-dev"
install=""
subpackages="$pkgname-doc"
-source="https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/lsyncd/lsyncd-$pkgver.tar.gz
+source="$pkgname-$pkgver.tar.gz::https://github.com/axkibe/lsyncd/archive/release-$pkgver.tar.gz
fix-realpath.patch
- 0001-Add-missed-comma.patch
- 0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch
- 0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch
- 0003-Add-checkgauge-in-lpostcmd.patch
+ fix-mandir.patch
lpostcmd.patch
- CVE-2014-8990.patch
+
$pkgname.initd"
-_builddir="$srcdir"/lsyncd-$pkgver
+builddir="$srcdir"/lsyncd-release-$pkgver
prepare() {
local i
- cd "$_builddir"
+ cd "$builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
@@ -34,54 +31,35 @@ prepare() {
}
build() {
- cd "$_builddir"
- ./configure \
- --build=$CBUILD \
- --host=$CHOST \
- --prefix=/usr \
- --sysconfdir=/etc \
- --mandir=/usr/share/man \
- --infodir=/usr/share/info \
- --localstatedir=/var \
- || return 1
+ cd "$builddir"
+ cmake -DCMAKE_INSTALL_PREFIX=/usr \
+ -DINSTALL_MANDIR=/usr/share || return 1
make || return 1
}
package() {
- cd "$_builddir"
+ cd "$builddir"
make DESTDIR="$pkgdir" install || return 1
mkdir -p "$pkgdir/etc/lsyncd"
- cp "$_builddir"/examples/*.lua \
+ cp "$builddir"/examples/*.lua \
"$pkgdir"/etc/lsyncd/
install -Dm755 "$srcdir/$pkgname.initd" \
"$pkgdir/etc/init.d/$pkgname" || return 1
}
-md5sums="fb10547494ec5ec662fe88343047c364 lsyncd-2.1.5.tar.gz
+md5sums="4dba61af8d7c8c84aacf900ab8145fa7 lsyncd-2.2.1.tar.gz
a14565df7274ebd0b605301ca39ae885 fix-realpath.patch
-d342bf626a302c5b10a1dfaa114b3608 0001-Add-missed-comma.patch
-e5071ed33b4e0afb6697e9fe3ca1aa8e 0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch
-2265cc5b0d3833a125207e2bb774cbf7 0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch
-11da73fdade84dcb23309fed76ad2122 0003-Add-checkgauge-in-lpostcmd.patch
+e693914425c200f7be5732787ae8fb69 fix-mandir.patch
77a42725c786745a67d5435bf9978ad5 lpostcmd.patch
-8f3d89a6594e62a3e4ed5732ce22bda7 CVE-2014-8990.patch
7cb590c3565043e68ff79b1a23252978 lsyncd.initd"
-sha256sums="4a793056c4ed833edb59436d7711bb65f7e38a4d8d44371cc9dc5eb91fbc461f lsyncd-2.1.5.tar.gz
+sha256sums="f41969454a17f9441a9b1809bb251235631768393bf5d29ad8e8142670ae4735 lsyncd-2.2.1.tar.gz
26454c77bb005c165c10b05b232c587669d35ab98e0ac889a11923106126f98e fix-realpath.patch
-c9417a8f347b430feb760a2af09687fd1ebca07acee7fb9fc9b9e258b1c895ba 0001-Add-missed-comma.patch
-ff2514730329052a75640f827b72947aa19726d9c65e5564d4aa8aeec4d21ccf 0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch
-d79f9dc6fc81a1dc980fbee01edf87307787f519919e995e8cc6fc31784dd9ee 0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch
-7aebb029703d03fe566b6100fb5702e90829cd56bd71e9a429a3d440a9fc00dd 0003-Add-checkgauge-in-lpostcmd.patch
+e3be73be4e089c813935e81b7cb7d360323a1098f6fe220b2a07ad667462f39f fix-mandir.patch
1cf732eefa4be22e1a86bbd85aad5ac0903ebf5d99f97e02b233341297ed7e2c lpostcmd.patch
-0896409e11c7e2d464cdca6dbd4493477d7858fe58d7dcf5eb63a01609892fad CVE-2014-8990.patch
0b7fc548b257cbd7264e3eb13d597bff1c25b63b2c3a2669607bb609d048810d lsyncd.initd"
-sha512sums="7be939e979525f8e4687432ffe952b1d09b8a34b4d7f92ebe86b5cddb765dbd602258682612529e9cc51305d6d001e72de9e6da62761397df23ecda30fd6a12b lsyncd-2.1.5.tar.gz
+sha512sums="c07c322fb802911a2bb78221ff20ac1c0658cea27a23d34a95de45902211784d3bdc79c246ce0809e6167ddd20a3573c1ca6a81cabc46a29622a200c8d3ddfa5 lsyncd-2.2.1.tar.gz
2cebaf59d960321c2eda4ef1e0d850f62eb7eedb7ba8922a5db33a7f78c769d1a52839fbb597ae06ba576632e2abc7b92a6ba2eaf58b71b93bc877db83e25576 fix-realpath.patch
-fe36e46409ff12e659d23c4243ca2ff8865f0da551d1920921e3c7a198ce0910bf73137cf0b052784aafa418702ddcfd669268b83040d90bdcf0d68948ef6d34 0001-Add-missed-comma.patch
-758fce99c5f6d89ad7ac160e6b387dcc750bac6f3ab07b7f533acda642cd698b6da2861dddf9e98472f6f4b2b85688d6f251c8fee968857405cecc86988353a9 0001-Fix-lpostcmd-to-use-isPostcmd-via-rawget-as-intended.patch
-313072937ba4787780daac94bc61444eb1588a289f60c8a0de37a170fc3bf1bf4bdc5ef17b41c50a26843a63943a2aca43bcca2f74f6a10c1fcac467323342a1 0002-Fix-lpostcmd-prepare-to-work-with-recent-changes.patch
-8792b684de39e4aa30800f45668ab67dc55db297cf9867b18022f690b3d01b67520c55c75667ea85e2026b5c5b52a1d054abce3778632c5ef9ace8f22dfa9db7 0003-Add-checkgauge-in-lpostcmd.patch
+00508996b83297fd069bd4580581859d5ef696ec906a2011d62f2582630c7d98188a851490f5503ba1302ef34f56e6b36780a1ce00806dbeeb62421e2ef8283d fix-mandir.patch
d0f971e99726fd5b7157928f4c790b9aeaf05becd23a2898101b89567297816c866b13cddb8b91cbe87cf3e0c05e3a613896c28f2926269c21f4f857ce1de189 lpostcmd.patch
-43d3b511d3242be65e3e9aece581d0caa59b43025087b5bdd856cf833ce84438bde90f926c657332414cb45393a3a78433ae2c5b4c8be652f9a4ac80891e09e7 CVE-2014-8990.patch
441b76ec944d9d74100dfca55efe871e9092b37cd49ec79a2a94e281dc0326b4def1645a827f7d3edcddc95d6e74c99621b62991396fb3693b1832c42fd86cdc lsyncd.initd"
diff --git a/main/lsyncd/CVE-2014-8990.patch b/main/lsyncd/CVE-2014-8990.patch
deleted file mode 100644
index 7c3b88d7e9..0000000000
--- a/main/lsyncd/CVE-2014-8990.patch
+++ /dev/null
@@ -1,107 +0,0 @@
-From 660438b485bcabac732ff4c63ee94826d66cf046 Mon Sep 17 00:00:00 2001
-From: Sven Schwedas <sven.schwedas@tao.at>
-Date: Wed, 29 Oct 2014 13:32:20 +0100
-Subject: [PATCH 1/2] Sanitize mv arguments:
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-1. Fixes crashes on file names containing `, $ or "
-2. Also prevents shell execution of ``, $() … in file names, which can be
- used to gain remote shell access as lsyncd's (target) user.
----
- default-rsyncssh.lua | 9 ++++++---
- 1 file changed, 6 insertions(+), 3 deletions(-)
-
-diff --git a/default-rsyncssh.lua b/default-rsyncssh.lua
-index 90732f6..b775942 100644
---- a/default-rsyncssh.lua
-+++ b/default-rsyncssh.lua
-@@ -74,6 +74,9 @@ rsyncssh.action = function( inlet )
- -- makes move local on target host
- -- if the move fails, it deletes the source
- if event.etype == 'Move' then
-+ local path1 = event.path:gsub ('"', '\\"'):gsub ('`', '\\`'):gsub ('%$','\\%$')
-+ local path2 = event2.path:gsub ('"', '\\"'):gsub ('`', '\\`'):gsub ('%$','\\%$')
-+
- log('Normal', 'Moving ',event.path,' -> ',event2.path)
-
- spawn(
-@@ -82,10 +85,10 @@ rsyncssh.action = function( inlet )
- config.ssh._computed,
- config.host,
- 'mv',
-- '\"' .. config.targetdir .. event.path .. '\"',
-- '\"' .. config.targetdir .. event2.path .. '\"',
-+ '\"' .. config.targetdir .. path1 .. '\"',
-+ '\"' .. config.targetdir .. path2 .. '\"',
- '||', 'rm', '-rf',
-- '\"' .. config.targetdir .. event.path .. '\"')
-+ '\"' .. config.targetdir .. path1 .. '\"')
- return
- end
-
---
-2.2.2
-
-
-From 396efd951ea3a20035cbf4ea52e1ff14ba018ef1 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?=C3=81ngel=20Gonz=C3=A1lez?= <angel@16bits.net>
-Date: Tue, 25 Nov 2014 23:49:25 +0100
-Subject: [PATCH 2/2] Properly sanitize mv parameters (CVE-2014-8990)
-
-When using -rsyncssh option, some filenames
-could -in addition of not syncing correctly-
-crash the service and execute arbitrary commands
-under the credentials of the remote user.
-
-These issues have been assigned CVE-2014-8990
-
-This commit fixes the incomplete and lua5.2-incompatible
-sanitization performed by 18f02ad0
-
-Signed-off-by: Sven Schwedas <sven.schwedas@tao.at>
-(cherry picked from commit e6016b3748370878778b8f0b568d5281cc248aa4)
-
-Conflicts:
- default-rsyncssh.lua
----
- default-rsyncssh.lua | 14 +++++++++-----
- 1 file changed, 9 insertions(+), 5 deletions(-)
-
-diff --git a/default-rsyncssh.lua b/default-rsyncssh.lua
-index b775942..4361a6c 100644
---- a/default-rsyncssh.lua
-+++ b/default-rsyncssh.lua
-@@ -74,8 +74,10 @@ rsyncssh.action = function( inlet )
- -- makes move local on target host
- -- if the move fails, it deletes the source
- if event.etype == 'Move' then
-- local path1 = event.path:gsub ('"', '\\"'):gsub ('`', '\\`'):gsub ('%$','\\%$')
-- local path2 = event2.path:gsub ('"', '\\"'):gsub ('`', '\\`'):gsub ('%$','\\%$')
-+ local path1 = config.targetdir .. event.path
-+ local path2 = config.targetdir .. event2.path
-+ path1 = "'" .. path1:gsub ('\'', '\'"\'"\'') .. "'"
-+ path2 = "'" .. path2:gsub ('\'', '\'"\'"\'') .. "'"
-
- log('Normal', 'Moving ',event.path,' -> ',event2.path)
-
-@@ -85,10 +87,12 @@ rsyncssh.action = function( inlet )
- config.ssh._computed,
- config.host,
- 'mv',
-- '\"' .. config.targetdir .. path1 .. '\"',
-- '\"' .. config.targetdir .. path2 .. '\"',
-+ path1,
-+ path2,
- '||', 'rm', '-rf',
-- '\"' .. config.targetdir .. path1 .. '\"')
-+ path1
-+ )
-+
- return
- end
-
---
-2.2.2
-
diff --git a/main/lsyncd/fix-mandir.patch b/main/lsyncd/fix-mandir.patch
new file mode 100644
index 0000000000..3ea5b9b285
--- /dev/null
+++ b/main/lsyncd/fix-mandir.patch
@@ -0,0 +1,8 @@
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -106,4 +106,4 @@
+ target_link_libraries( lsyncd ${LUA_LIBRARIES} )
+
+ install( TARGETS lsyncd RUNTIME DESTINATION bin )
+-install( FILES doc/manpage/lsyncd.1 DESTINATION man )
++install( FILES doc/manpage/lsyncd.1 DESTINATION share/man )