blob: 384d1ecd44aef8cea7fd8a8ceed3e313db20bce3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
# Maintainer: MattWoelk
# Contributor: xsmile <sascha_r gmx de>
_retoken='.*hidden">(\w+)<.*'
pkgname=nessus
pkgver=6.8.1
pkgrel=1
_filename="${pkgname^}-${pkgver}-fc20.x86_64.rpm"
pkgdesc="Vulnerability scanner"
arch=('x86_64')
depends=('openssl' 'gnupg')
license=('custom')
url="https://www.nessus.org"
install=${pkgname}.install
_gettoken() {
token=$(curl -s https://www.tenable.com/products/nessus/select-your-operating-system#tos | \
sed -nr "s/${_retoken}/\1/p")
if [[ "$token" == "" ]]; then
echo
echo " -> Could not get the download token, '_retoken' might need an update"
exit 1
fi
echo "$token"
}
_token=$(_gettoken)
_pkgurl="https://downloads.nessus.org/nessus3dl.php?file=${_filename}&licence_accept=yes&t=${_token}"
source=("${_filename}::${_pkgurl}"
nessus.desktop
nessus.sh
LICENSE)
md5sums=('f697458a7e63fb6915d8e836e128c9bd'
'388578bf980efe6e6d3f33fcc289543a'
'8c5772ac63f97d94475fe03e80d6ba5c'
'1db6df5a39009ace46c7ee40141ece1b')
package() {
install -Dm755 $pkgname.sh "$pkgdir/etc/profile.d/$pkgname.sh"
mkdir -p "$pkgdir/etc/ld.so.conf.d" "$pkgdir/usr/share" "$pkgdir/opt/nessus" \
"$pkgdir/usr/lib"
cp -a lib "$pkgdir/usr"
# path to libraries
echo /opt/nessus/lib > "$pkgdir/etc/ld.so.conf.d/nessus.conf"
# main files
cp -a opt/nessus/{bin,com,etc,lib,sbin,var} "$pkgdir/opt/nessus"
# license
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/nessus/LICENSE"
# menu entry
install -Dm644 "${srcdir}/${pkgname}.desktop" "${pkgdir}/usr/share/applications/${pkgname}.desktop"
}
|