diff options
author | dysphoria | 2019-05-06 04:47:58 +0100 |
---|---|---|
committer | dysphoria | 2019-05-06 04:47:58 +0100 |
commit | 05c4438db8da9240c23bd96c52bc8a916d4e330e (patch) | |
tree | ca9cea08e6cb7471df7fdaa59e6de28783cb90fd | |
download | aur-05c4438db8da9240c23bd96c52bc8a916d4e330e.tar.gz |
Initial commit
-rw-r--r-- | .SRCINFO | 27 | ||||
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | PKGBUILD | 52 | ||||
-rw-r--r-- | tomoyo-auditd.service | 15 | ||||
-rw-r--r-- | tomoyo-tools.install | 18 |
5 files changed, 116 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..b8a7364a1f3b --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,27 @@ +# Generated by mksrcinfo v8 +# Mon May 6 03:47:26 UTC 2019 +pkgbase = tomoyo-tools-25 + pkgdesc = TOMOYO Linux userspace tools for Linux kernels >=3.2 and <5.1 + pkgver = 2.5.0.20170102 + pkgrel = 1 + url = https://tomoyo.osdn.jp + install = tomoyo-tools.install + arch = x86_64 + license = GPL + depends = ncurses>=6.0 + conflicts = linux>=5.1 + conflicts = linux-zen>=5.1 + conflicts = linux-hardened>=5.1 + conflicts = tomoyo-tools + replaces = tomoyo-tools<2.6 + source = https://jaist.dl.osdn.jp/tomoyo/53357/tomoyo-tools-2.5.0-20170102.tar.gz + source = https://jaist.dl.osdn.jp/tomoyo/53357/tomoyo-tools-2.5.0-20170102.tar.gz.asc + source = tomoyo-tools.install + source = tomoyo-auditd.service + sha256sums = 00fedfac5e514321250bbe69eaccc732c8a8158596f77a785c2e3ae9f9968283 + sha256sums = SKIP + sha256sums = 0df2401456f5377df529c1c8774670636b3ba365534d7ecbaf96b2e7ef6bf093 + sha256sums = 7c3c01a8ba34af9dc3601d470afdd0d3a2b01a1ca1951e3479cfd1fb4dfdafa3 + +pkgname = tomoyo-tools-25 + diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..310a8d03e9ad --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +# Ignore downloaded sources +*.tar.xz +*.tar.gz +*.tar.gz.asc diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..f93750d31648 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,52 @@ +# Maintainer: TH Campbell (dysphoria) <thcampbell (at) protonmail (dot) com> +# Contributor: Steven Allen <steven@stebalien.com> +# Contributor: Sergej Pupykin <pupykin.s+arch@gmail.com> +# Contributor: Jamie Nguyen <jamie AT tomoyolinux.co.uk> + +pkgname=tomoyo-tools-25 +_pkgname=tomoyo-tools +_file=53357 +_basever=2.5.0 +_timestamp=20170102 +pkgver=${_basever}.${_timestamp} +pkgrel=1 +pkgdesc='TOMOYO Linux userspace tools for Linux kernels >=3.2 and <5.1' +arch=('x86_64') +url='https://tomoyo.osdn.jp' +#url='http://sourceforge.jp/projects/tomoyo/releases/?package_id=9818' +license=('GPL') +depends=('ncurses>=6.0') +conflicts=('linux>=5.1' 'linux-zen>=5.1' 'linux-hardened>=5.1' 'tomoyo-tools') +replaces=('tomoyo-tools<2.6') +install=tomoyo-tools.install +source=("https://jaist.dl.osdn.jp/tomoyo/${_file}/${_pkgname}-${_basever}-${_timestamp}.tar.gz"{,.asc} + 'tomoyo-tools.install' + 'tomoyo-auditd.service') +sha256sums=('00fedfac5e514321250bbe69eaccc732c8a8158596f77a785c2e3ae9f9968283' + 'SKIP' + '0df2401456f5377df529c1c8774670636b3ba365534d7ecbaf96b2e7ef6bf093' + '7c3c01a8ba34af9dc3601d470afdd0d3a2b01a1ca1951e3479cfd1fb4dfdafa3') +validpgpkeys=('43C83369623D7AD3A96C2FC7425F128D0C64F52A') + +prepare() { + cd "${srcdir}/${_pkgname}" + sed -i \ + -e 's|usr/sbin|usr/bin|g' \ + -e 's|sbin|usr/bin|g' \ + usr_lib_tomoyo/init_policy.c +} + +build() { + cd "${srcdir}/${_pkgname}" + make USRSBINDIR=/usr/bin SBINDIR=/usr/bin +} + +package() { + cd "${srcdir}/${_pkgname}" + + _unitdir="$(pkg-config --variable=systemdsystemunitdir systemd)" + + make USRSBINDIR=/usr/bin SBINDIR=/usr/bin INSTALLDIR="${pkgdir}" install + install -Dm644 "${srcdir}/tomoyo-auditd.service" \ + "${pkgdir}/${_unitdir}/tomoyo-auditd.service" +} diff --git a/tomoyo-auditd.service b/tomoyo-auditd.service new file mode 100644 index 000000000000..a9cce01df710 --- /dev/null +++ b/tomoyo-auditd.service @@ -0,0 +1,15 @@ +[Unit] +Description=Tomoyo Auditing + +[Service] +Type=forking +ExecStart=/usr/bin/tomoyo-auditd +ExecReload=/usr/bin/kill -HUP $MAINPID +ProtectSystem=full +ProtectHome=true +PrivateNetwork=true +PrivateDevices=true +PrivateTmp=true + +[Install] +WantedBy=multi-user.target diff --git a/tomoyo-tools.install b/tomoyo-tools.install new file mode 100644 index 000000000000..e5777b46efc6 --- /dev/null +++ b/tomoyo-tools.install @@ -0,0 +1,18 @@ +post_install () { + echo " * To enable TOMOYO Linux, append 'security=tomoyo' to the kernel" + echo ' boot options and initialize policy with this command:' + echo ' /usr/lib/tomoyo/init_policy' + echo ' Also you may pass TOMOYO_trigger parameter' + echo ' if CONFIG_SECURITY_TOMOYO_ACTIVATION_TRIGGER' + echo ' kernel option has wrong value' + echo '' + echo ' * Kernel version >=3.2 and <5.1 is required' + echo " Your version is $(uname -r)" + echo ' !! Using the wrong version may render your system unbootable' +} + +post_upgrade () { + echo ' * Kernel version >=3.2 and <5.1 is required' + echo " Your version is $(uname -r)" + echo ' !! Using the wrong version may render your system unbootable' +} |