diff options
-rw-r--r-- | .SRCINFO | 20 | ||||
-rw-r--r-- | PKGBUILD | 41 | ||||
-rw-r--r-- | bufoverflow.patch | 20 |
3 files changed, 81 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..eaf3f67b64d1 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,20 @@ +pkgbase = booth + pkgdesc = RAFT cluster ticket manager for pacemaker + pkgver = 1.0 + pkgrel = 1 + url = https://github.com/ClusterLabs/booth/ + arch = i686 + arch = x86_64 + license = GPL2 + depends = pacemaker + optdepends = pcs: for cluster shell support + optdepends = crmsh: for cluster shell support + source = booth-1.0.tar.gz::https://github.com/ClusterLabs/booth/archive/v1.0.tar.gz + source = pcs.patch::https://patch-diff.githubusercontent.com/raw/ClusterLabs/booth/pull/41.patch + source = bufoverflow.patch + sha512sums = 0024f3dc0d15830a5835d5366b01d8700a391005c9ae1ee1ae8d970383d6d5d78e78bcac86610f65301c9441b452dce16d8c736d2363e6577c38dac928b576a8 + sha512sums = 5b6297c444ef326c59705170717865572812639f8a9c6e23a02b73234ae6edd23b9337b9284fa12ae489f3a599fe538dd92c26db12a011ca0eac09c2b15289cb + sha512sums = b8bb3c1ac4b7778ff019855b342a76847a909485b9f5b723f37298e1b049dc5ef0351f649f378926f8a62c5a0db50508e6b25c74f7add8bd4244a11976d1f962 + +pkgname = booth + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..cf48d8a8f79a --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,41 @@ +# Maintainer: Brian Bidulock <bidulock@openss7.org> + +pkgname=booth +pkgver=1.0 +pkgrel=1 +pkgdesc="RAFT cluster ticket manager for pacemaker" +arch=('i686' 'x86_64') +url="https://github.com/ClusterLabs/${pkgname}/" +license=('GPL2') +depends=('pacemaker') +optdepends=('pcs: for cluster shell support' + 'crmsh: for cluster shell support') +source=("$pkgname-$pkgver.tar.gz::https://github.com/ClusterLabs/$pkgname/archive/v$pkgver.tar.gz" + "pcs.patch::https://patch-diff.githubusercontent.com/raw/ClusterLabs/$pkgname/pull/41.patch" + "bufoverflow.patch") +sha512sums=('0024f3dc0d15830a5835d5366b01d8700a391005c9ae1ee1ae8d970383d6d5d78e78bcac86610f65301c9441b452dce16d8c736d2363e6577c38dac928b576a8' + '5b6297c444ef326c59705170717865572812639f8a9c6e23a02b73234ae6edd23b9337b9284fa12ae489f3a599fe538dd92c26db12a011ca0eac09c2b15289cb' + 'b8bb3c1ac4b7778ff019855b342a76847a909485b9f5b723f37298e1b049dc5ef0351f649f378926f8a62c5a0db50508e6b25c74f7add8bd4244a11976d1f962') + +prepare() { + cd $pkgname-$pkgver + patch -Np1 -b -z .orig <../pcs.patch + patch -Np2 -b -z .orig <../bufoverflow.patch + ./autogen.sh +} + +build() { + cd $pkgname-$pkgver + ./configure \ + --sbindir=/usr/bin \ + --sysconfdir=/etc \ + --libdir=/usr/lib \ + --libexecdir=/usr/lib \ + --localstatedir=/var + make V=0 +} + +package() { + cd $pkgname-$pkgver + make DESTDIR="${pkgdir}" install +} diff --git a/bufoverflow.patch b/bufoverflow.patch new file mode 100644 index 000000000000..0deee65ca528 --- /dev/null +++ b/bufoverflow.patch @@ -0,0 +1,20 @@ +diff -up src/booth-1.0/src/ticket.c.orig src/booth-1.0/src/ticket.c +--- src/booth-1.0/src/ticket.c.orig 2018-05-15 14:14:26.000000000 -0600 ++++ src/booth-1.0/src/ticket.c 2018-05-15 14:15:31.000000000 -0600 +@@ -508,14 +508,14 @@ static void log_reacquire_reason(struct + { + int valid; + const char *where_granted = "\0"; +- char buff[64]; ++ char buff[80]; + + valid = is_time_set(&tk->term_expires) && !is_past(&tk->term_expires); + + if (tk->leader == local) { + where_granted = "granted here"; + } else { +- snprintf(buff, sizeof(buff), "granted to %s", ++ snprintf(buff, sizeof(buff) - 1, "granted to %s", + site_string(tk->leader)); + where_granted = buff; + } |