Compare commits

...
Sign in to create a new pull request.

37 commits

Author SHA1 Message Date
Miro Hrončok
3967727c8a Retired: Long term failure to build 2024-07-29 20:04:32 +02:00
Miroslav Suchý
0a295ba326 convert GPLv2+ license to SPDX
This is part of https://fedoraproject.org/wiki/Changes/SPDX_Licenses_Phase_4
2024-07-26 03:27:52 +02:00
Fedora Release Engineering
ace533574f Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild 2024-07-20 08:15:46 +00:00
Software Management Team
109ac0244b Eliminate use of obsolete %patchN syntax (#2283636) 2024-05-30 12:46:49 +02:00
Fedora Release Engineering
76c60bf27c Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-27 07:06:54 +00:00
Fedora Release Engineering
a1a359d7e5 Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-22 17:06:50 +00:00
Fedora Release Engineering
6e17c03c3f Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-21 05:48:59 +00:00
Florian Weimer
0184fb9420 Port configure script to C99
Related to:

  <https://fedoraproject.org/wiki/Changes/PortingToModernC>
  <https://fedoraproject.org/wiki/Toolchain/PortingToModernC>
2022-11-25 17:46:40 +01:00
49312238c8 Added sysusers.d file to achieve user() and group() provides 2022-07-31 01:32:24 +02:00
Fedora Release Engineering
71b79a240f Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-07-23 11:23:32 +00:00
cd2cba1c76 Added patch to support MaxMind GeoIP2 and GeoLite2 databases 2022-05-06 04:16:32 +02:00
Timm Bäder
8d11d19a20 Disable automatic .la file removal
https://fedoraproject.org/wiki/Changes/RemoveLaFiles
2022-01-24 15:10:33 +01:00
Fedora Release Engineering
9d2a98fc81 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-01-22 03:31:22 +00:00
Fedora Release Engineering
a1b63f85be - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-23 20:02:23 +00:00
Pavel Raiskup
5c9b2f53b9 rebuild for libpq ABI fix
Related: rhbz#1908268
2021-02-08 10:31:19 +01:00
Fedora Release Engineering
82d974451d - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-01-27 22:40:13 +00:00
c1a160719a Spec file cleanup 2020-12-31 19:02:38 +01:00
Fedora Release Engineering
e68a2054ae - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-07-29 13:17:23 +00:00
Jeff Law
9dee53461e Disable LTO 2020-07-09 14:54:16 -06:00
Fedora Release Engineering
58bb11a463 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-01-31 02:35:36 +00:00
Fedora Release Engineering
1018e565c8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-07-27 02:29:39 +00:00
4f19e65969 %{_includedir}/pcap.h is libpcap-devel, not popt-devel 2019-07-23 00:40:17 +02:00
bdc1ff58fc Change BuildRequires %{_includedir}/pcap.h, %{_includedir}/ltdl.h to popt-devel, libtool-ltdl-devel (#1731727) 2019-07-23 00:18:02 +02:00
Fedora Release Engineering
9c593067cb - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-02-03 10:48:41 +00:00
4a49087eb3 Remove obsolete Group tag
References: https://fedoraproject.org/wiki/Changes/Remove_Group_Tag
2019-01-28 20:24:53 +01:00
5f7e90e968 Add missing linking to -lGeoIP (#1623468) 2018-10-11 22:40:26 +02:00
Pavel Raiskup
76edc35078 BuildRequires: s/postgresql-devel/libpq-devel/
That's because we moved libpq.so.5 into libpq package.

Related: rhbz#1618698, rhbz#1623764
2018-09-06 10:27:53 +02:00
d280f34829 Replace "BuildRequires: gcc" by "BuildRequires: gcc-c++" 2018-07-16 02:03:49 +02:00
Fedora Release Engineering
5210c04ad7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2018-07-14 08:14:17 +00:00
Jason Tibbitts
ccdcb019aa Remove needless use of %defattr 2018-07-10 01:42:11 -05:00
Igor Gnatenko
367e654b18 add BuildRequires: gcc
Reference: https://fedoraproject.org/wiki/Changes/Remove_GCC_from_BuildRoot
2018-07-09 19:06:52 +02:00
f5f081a80b
Remove %clean section
None of currently supported distributions need that.
Last one was EL5 which is EOL for a while.

Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
2018-02-14 08:57:05 +01:00
fa3e586a98 Remove BuildRoot definition
None of currently supported distributions need that.
It was needed last for EL5 which is EOL now

Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
2018-02-14 00:46:34 +01:00
Fedora Release Engineering
dc1335304a - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2018-02-09 20:01:19 +00:00
Fedora Release Engineering
ac5b2b0462 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild 2017-08-03 09:47:39 +00:00
Fedora Release Engineering
bd158b007c - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild 2017-07-27 20:59:34 +00:00
Fedora Release Engineering
a8b574d90c - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild 2017-02-11 16:43:54 +00:00
11 changed files with 1 additions and 508 deletions

1
.gitignore vendored
View file

@ -1 +0,0 @@
unicornscan-0.4.7-2.tar.bz2

1
dead.package Normal file
View file

@ -0,0 +1 @@
Retired: Long term failure to build

View file

@ -1 +0,0 @@
4c5f272eb38c333c0094c32317edf758 unicornscan-0.4.7-2.tar.bz2

View file

@ -1,56 +0,0 @@
--- unicornscan-0.4.7/etc/modules.conf 2006-10-18 18:57:05.000000000 +0200
+++ unicornscan-0.4.7/etc/modules.conf.config 2009-12-05 20:34:31.000000000 +0100
@@ -1,16 +1,9 @@
module "pgsqldb" {
- dbconf: "user=scan password=scanit! host=localhost dbname=scan";
+ dbconf: "user=unicornscan password=scanit! host=localhost dbname=unicornscan";
logpacket: "true";
};
-module "mysqldb" {
- username: "scan";
- password: "scanit!";
- hostname: "localhost";
- dbname: "foo";
-};
-
module "osdetect" {
/* Stim TCPFLG TTL DF WS TOS Misc */
/* tcpopts type desc */
--- unicornscan-0.4.7/www-front-end/config.php 2007-11-27 11:23:35.000000000 +0100
+++ unicornscan-0.4.7/www-front-end/config.php.config 2009-12-05 20:35:13.000000000 +0100
@@ -4,16 +4,16 @@
define("config_master_include", 1);
// Web Server location stuff
- $PHPLIB["uri_base"]="http://localhost/unicornscan/"; // http://vhost.domain.tld/something/
+ $PHPLIB["uri_base"]="/unicornscan/"; // http://vhost.domain.tld/something/
- $PHPLIB["filesystem_base"]="/var/www/htdocs/unicornscan/"; // Base directory content is in
- $PHPLIB["filesystem_phplib"]="/var/www/htdocs/unicornscan/lib/"; // Where phplib is
- $PHPLIB["filesystem_temporary"]="/tmp/"; // Where can i write files to?
+ $PHPLIB["filesystem_base"]="/usr/share/unicornscan/"; // Base directory content is in
+ $PHPLIB["filesystem_phplib"]="/usr/share/unicornscan/lib/"; // Where phplib is
+ $PHPLIB["filesystem_temporary"]="/var/lib/unicornscan/web/"; // Where can i write files to?
// DataBase Variables
- $PHPLIB["database_name"]="scan"; // change this for sure , its the database name
- $PHPLIB["database_type"]="pgsql"; // pgsql, mysql, youll need the right class though
- $PHPLIB["database_username"]="scan";
+ $PHPLIB["database_name"]="unicornscan"; // change this for sure , its the database name
+ $PHPLIB["database_type"]="pgsql"; // and something else isn't supported right now
+ $PHPLIB["database_username"]="unicornscan";
$PHPLIB["database_password"]="scanit!";
$PHPLIB["database_host"]="127.0.0.1";
$PHPLIB["database_db"]["default"]="";
@@ -24,6 +24,9 @@
// formclass2.php stuff
$PHPLIB["formclass_warnimage"]="exl.gif"; // warning image for invalid forms
+ // No PHP error reporting
+ error_reporting(0);
+
} // Double Inclusion detection
require("./lib/connect_todb.php");

View file

@ -1,51 +0,0 @@
Patch by Robert Scheck <robert@fedoraproject.org> for unicornscan >= 0.4.7 to avoid
build failures with GCC 5.x such as "unicornscan-0.4.7/src/unilib/tsc.c:163:
undefined reference to `get_tsc'" (occurring in some different source code lines).
--- unicornscan-0.4.7/src/unilib/tsc.c 2006-10-18 18:57:05.000000000 +0200
+++ unicornscan-0.4.7/src/unilib/tsc.c.gcc5 2015-06-20 19:57:35.000000000 +0200
@@ -30,7 +30,7 @@
return 1;
}
-inline tsc_t get_tsc(void) {
+tsc_t get_tsc(void) {
tsc_t j;
asm volatile ( "pause\n"
"nop\n"
@@ -52,7 +52,7 @@
* by Matteo Frigo
*/
-inline tsc_t get_tsc(void) {
+tsc_t get_tsc(void) {
uint32_t tbl, tbu0, tbu1;
asm volatile("nop");
@@ -75,7 +75,7 @@
return 1;
}
-inline tsc_t get_tsc(void) {
+tsc_t get_tsc(void) {
tsc_t j;
asm volatile (
@@ -96,7 +96,7 @@
return 1;
}
-inline tsc_t get_tsc(void) {
+tsc_t get_tsc(void) {
uint32_t j;
/*
@@ -144,7 +144,7 @@
return 0;
}
-inline tsc_t get_tsc(void) {
+tsc_t get_tsc(void) {
PANIC("Your CPU is not supported by the `tsc' delay, use -d2 or -d3 or edit your config file to use gtod or sleep");
}

View file

@ -1,31 +0,0 @@
Patch by Robert Scheck <robert@fedoraproject.org> for unicornscan >= 0.4.7, which adds the
standard location of GeoIP data at Fedora in front of the original opening try. Unicornscan
upstream is expecting /etc/unicornscan/GeoIP.dat instead of /usr/share/GeoIP/GeoIP.dat by
default. This patch is looking for the existence of /usr/share/GeoIP/GeoIP.dat, otherwise
/etc/unicornscan/GeoIP.dat will be used to not break the standards from upstream, if patch
gets applied for a future unicornscan release.
--- unicornscan-0.4.7/src/scan_progs/report.c 2006-10-18 18:57:05.000000000 +0200
+++ unicornscan-0.4.7/src/scan_progs/report.c.geoip 2009-11-17 13:16:04.000000000 +0100
@@ -68,9 +68,18 @@
report_t=rbinit(123);
#ifdef HAVE_LIBGEOIP
- gi=GeoIP_open(CONF_DIR "/GeoIP.dat", GEOIP_MEMORY_CACHE);
- if (gi == NULL) {
- ERR("error opening geoip database `%s/%s': %s", CONF_DIR, "/GeoIP.dat", strerror(errno));
+
+ if (access("/usr/share/GeoIP/GeoIP.dat", F_OK) == 0) {
+ gi=GeoIP_open("/usr/share/GeoIP/GeoIP.dat", GEOIP_MEMORY_CACHE);
+ if (gi == NULL) {
+ ERR("error opening geoip standard database `/usr/share/GeoIP/GeoIP.dat': %s", strerror(errno));
+ }
+ }
+ else {
+ gi=GeoIP_open(CONF_DIR "/GeoIP.dat", GEOIP_MEMORY_CACHE);
+ if (gi == NULL) {
+ ERR("error opening geoip database `%s/%s': %s", CONF_DIR, "/GeoIP.dat", strerror(errno));
+ }
}
#endif

View file

@ -1,47 +0,0 @@
Patch by Robert Scheck <robert@fedoraproject.org> for unicornscan >= 0.4.7, which
adds support for x86_64, ppc64 or other 64 bit architectures using /usr/lib64 for
their libraries. Having lib64 in front of lib is mandatory, as 64 bit systems are
likely to run with multi-lib, that means 32 bit libraries are parallel in use. If
you apply this patch, don't run autoconf > 2.6.3, as it will break, because whole
autotools stuff from upstream is unfortunately a bit broken.
--- unicornscan-0.4.7/configure.ac 2007-11-29 15:51:20.000000000 +0100
+++ unicornscan-0.4.7/configure.ac.lib64 2009-11-16 23:32:27.000000000 +0100
@@ -269,7 +269,7 @@
AC_MSG_RESULT(no)
fi
else
- for i in lib lib/mysql; do
+ for i in lib64 lib lib64/mysql lib/mysql; do
str="$MYSQL_DIR/$i/libmysqlclient.*"
for j in `echo $str`; do
if test -r $j; then
@@ -331,7 +331,7 @@
AC_MSG_RESULT(no)
fi
else
- for i in lib lib/postgresql; do
+ for i in lib64 lib lib64/postgresql lib/postgresql; do
str="$PGSQL_DIR/$i/libpq.*"
for j in `echo $str`; do
if test -r $j; then
--- unicornscan-0.4.7/configure 2007-12-18 16:26:12.000000000 +0100
+++ unicornscan-0.4.7/configure.lib64 2009-12-05 12:04:32.000000000 +0100
@@ -26275,7 +26275,7 @@
echo "${ECHO_T}no" >&6; }
fi
else
- for i in lib lib/mysql; do
+ for i in lib64 lib lib64/mysql lib/mysql; do
str="$MYSQL_DIR/$i/libmysqlclient.*"
for j in `echo $str`; do
if test -r $j; then
@@ -26438,7 +26438,7 @@
echo "${ECHO_T}no" >&6; }
fi
else
- for i in lib lib/postgresql; do
+ for i in lib64 lib lib64/postgresql lib/postgresql; do
str="$PGSQL_DIR/$i/libpq.*"
for j in `echo $str`; do
if test -r $j; then

View file

@ -1,81 +0,0 @@
Unicornscan and PostgreSQL
--------------------------
1. The PostgreSQL service has to be up and running. Depending on the exact
version of Fedora or Red Hat Enterprise Linux, on the first PostgreSQL
startup, a "service postgresql initdb" is maybe required for initializing.
[root@tux ~]# service postgresql start
Starting postgresql service: [ OK ]
[root@tux ~]#
2. Switch to the PostgreSQL user.
[root@tux ~]# su - postgres
-bash-4.0$
3. Create an own PostgreSQL database user for unicornscan. Don't forget to set
a password, e.g. "scanit!" as it is used in all examples.
-bash-4.0$ createuser --no-superuser --no-createrole --no-createdb --pwprompt unicornscan
Enter password for new role:
Enter it again:
-bash-4.0$
4. Create an own PostgreSQL database for unicornscan linked with the previous
generated database user for unicornscan.
-bash-4.0$ createdb --owner unicornscan unicornscan
-bash-4.0$
5. Switch back to the root user.
-bash-4.0$ exit
exit
[root@tux ~]#
6. Edit PostgreSQL client authentication file /var/lib/pgsql/data/pg_hba.conf
file with a text editor, insert the following lines before the other already
existing rules.
# TYPE DATABASE USER CIDR-ADDRESS METHOD
local unicornscan unicornscan md5
host unicornscan unicornscan 127.0.0.1/32 md5
host unicornscan unicornscan ::1/128 md5
7. Edit PostgreSQL server configuration in /var/lib/pgsql/data/postgresql.conf
and set the configuration variable as follows:
escape_string_warning = off
8. Restart the PostgreSQL service to enable the previous performed changes.
[root@tux ~]# service postgresql restart
Stopping postgresql service: [ OK ]
Starting postgresql service: [ OK ]
[root@tux ~]#
9. Create the required tables for unicornscan inside of PostgreSQL database,
there will be some error messages displayed after entering the password for
psql. These error messages are normal and expected, because the SQL dump
contains a SQL DROP of all tables before the SQL CREATE is performed.
[root@tux ~]# psql --username unicornscan --password unicornscan < /usr/share/doc/unicornscan-0.*/pgsql_schema.sql
Password for user unicornscan:
[...]
[root@tux ~]#
10. Edit the unicornscan configuration file /etc/unicornscan/modules.conf and
check or correct the PostgreSQL database connection settings.
module "pgsqldb" {
dbconf: "user=unicornscan password=scanit! host=localhost dbname=unicornscan";
logpacket: "true";
};
11. Perform a small sample scan and write the output to PostgreSQL database.
[root@tux ~]# unicornscan www.google.com -e pgsqldb
TCP open http[ 80] from 209.85.129.104 ttl 52
TCP open https[ 443] from 209.85.129.104 ttl 52
[root@tux ~]#

View file

@ -1,45 +0,0 @@
Unicornscan and PostgreSQL
--------------------------
1. Follow the /usr/share/doc/unicornscan-0.*/README.fedora file, so that the
PostgreSQL service is up and running already.
2. Start (or restart) the Apache HTTP webserver, to ensure that configuration
file for Apache gets active.
[root@tux ~]# service httpd start
Starting httpd: [ OK ]
[root@tux ~]#
3. Create the required tables for unicornscan inside of PostgreSQL database,
there will be some error messages displayed after entering the password for
psql. These error messages are normal and expected, because the SQL dump
contains a SQL DROP of all tables before the SQL CREATE is performed.
[root@tux ~]# psql --username unicornscan --password unicornscan < /usr/share/doc/unicornscan-web-0.*/session.sql
Password for user unicornscan:
[...]
[root@tux ~]#
4. If you've got SELinux enabled, make sure, that SELinux allows Apache/PHP to
connect to the PostgreSQL database. If you don't have SELinux enabled, just
skip this step.
setsebool -P httpd_can_network_connect_db=1
5. Edit the unicornscan configuration file /etc/unicornscan/web.php and check
or correct the PostgreSQL database connection settings.
$PHPLIB["database_name"]="unicornscan";
$PHPLIB["database_username"]="unicornscan";
$PHPLIB["database_password"]="scanit!";
$PHPLIB["database_host"]="127.0.0.1";
6. Perform a small sample scan and write the output to PostgreSQL database.
[root@tux ~]# unicornscan www.google.com -e pgsqldb
TCP open http[ 80] from 209.85.129.104 ttl 52
TCP open https[ 443] from 209.85.129.104 ttl 52
[root@tux ~]#
7. Open a webbrowser and switch to: http://localhost/unicornscan/

View file

@ -1,5 +0,0 @@
#
# Scalable, accurate, flexible and efficient network probing
#
Alias /unicornscan /usr/share/unicornscan

View file

@ -1,190 +0,0 @@
Summary: Scalable, accurate, flexible and efficient network probing
Name: unicornscan
Version: 0.4.7
Release: 12%{?dist}
License: GPLv2+
Group: Applications/Internet
URL: http://www.unicornscan.org/
Source0: http://www.unicornscan.org/releases/%{name}-%{version}-2.tar.bz2
Source1: unicornscan.conf
Source2: unicornscan-README.fedora
Source3: unicornscan-web-README.fedora
Patch0: unicornscan-0.4.7-lib64.patch
Patch1: unicornscan-0.4.7-geoip.patch
Patch2: unicornscan-0.4.7-config.patch
Patch3: unicornscan-0.4.7-gcc5.patch
Requires(pre): shadow-utils
BuildRequires: flex, bison, %{_includedir}/pcap.h, %{_includedir}/ltdl.h
BuildRequires: libdnet-devel, GeoIP-devel, postgresql-devel
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%description
Unicornscan is an attempt at a user-land distributed TCP/IP stack. It is
intended to provide a researcher a superior interface for introducing a
stimulus into and measuring a response from a TCP/IP enabled device or
network. Although it currently has hundreds of individual features, a main
set of abilities include: Asynchronous stateless TCP scanning with all
variations of TCP flags, asynchronous stateless TCP banner grabbing,
asynchronous protocol specific UDP scanning (sending enough of a signature
to elicit a response), active and passive remote OS, application and
component identification by analyzing responses, PCAP file logging and
filtering, relational database output, custom module support, customized
data-set views.
%package web
Summary: Web-based front-end for unicornscan database results
Group: Applications/Internet
Requires: %{name} = %{version}-%{release}, php-pgsql, httpd
%if 0%{?fedora}%{?rhel} >= 6
BuildArch: noarch
%endif
%description web
Unicornscan provides support to write results into a database. And with the
web-based front-end for unicornscan, which is written in PHP, these results
can be easily interpreted and visualized.
%prep
%setup -q
%patch0 -p1 -b .lib64
%patch1 -p1 -b .geoip
%patch2 -p1 -b .config
%patch3 -p1 -b .gcc5
cp -pf %{SOURCE2} README.fedora
cp -pf %{SOURCE3} www-front-end/README.fedora
%build
# - _GNU_SOURCE is required for "ucred" from <bits/socket.h> via <sys/socket.h>
# - Use classical non-SELinux permission schema once SELinux Reference Policy is
# including unicornscan support directly, maybe with Fedora 13 and/or RHEL 6
# - MySQL support is only available in ./configure as inside broken and disabled
export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE"
%configure --localstatedir=%{_localstatedir}/lib --with-pgsql --with-listen-user=%{name}
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
make DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" install
# Remove the static library files
rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/modules/*.a
# Correct permissions and timestamps
chmod 644 $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/*
touch -c -r etc/modules.conf.config $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/modules.conf
# Install web files into destination
cp -af www-front-end $RPM_BUILD_ROOT%{_datadir}/%{name}/
rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/attic
rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/{config.php.config,README.fedora,TODO}
rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/lib/{session.sql,.htaccess}
# Move configuration file to its place
mv -f $RPM_BUILD_ROOT%{_datadir}/%{name}/config.php $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/web.php
touch -c -r www-front-end/config.php.config $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/web.php
ln -sf ../../..%{_sysconfdir}/%{name}/web.php $RPM_BUILD_ROOT%{_datadir}/%{name}/config.php
# Install the apache configuration file
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/
install -p -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/%{name}.conf
# Create temporary directory for packaging
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/%{name}/web/
%pre
getent group %{name} > /dev/null || %{_sbindir}/groupadd -r %{name}
getent passwd %{name} > /dev/null || %{_sbindir}/useradd -r -g %{name} -d %{_localstatedir}/lib/%{name} -s /sbin/nologin -c "Unicornscan User" %{name}
exit 0
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc AUTHORS LICENSE README README.database README.fedora README.security
%doc THANKS TODO UDP_PAYLOADS_NEEDED docs/Unicornscan-Getting_Started.pdf
%doc src/output_modules/database/sql/pgsql_schema.sql src/parse/example_confs
%dir %{_sysconfdir}/%{name}
%config(noreplace) %attr(0640,%{name},%{name}) %{_sysconfdir}/%{name}/modules.conf
%config(noreplace) %{_sysconfdir}/%{name}/oui.txt
%config(noreplace) %{_sysconfdir}/%{name}/payloads.conf
%config(noreplace) %{_sysconfdir}/%{name}/ports.txt
%config(noreplace) %{_sysconfdir}/%{name}/unicorn.conf
%{_bindir}/fantaip
%{_bindir}/unibrow
%{_bindir}/unicfgtst
%{_bindir}/%{name}
%{_bindir}/us
%dir %{_libdir}/%{name}
%dir %{_libdir}/%{name}/modules
# *.la files are referenced by the shared objects and required
%{_libdir}/%{name}/modules/httpexp.la
%{_libdir}/%{name}/modules/httpexp.so
%{_libdir}/%{name}/modules/http.la
%{_libdir}/%{name}/modules/http.so
%{_libdir}/%{name}/modules/ntalk.la
%{_libdir}/%{name}/modules/ntalk.so
%{_libdir}/%{name}/modules/osdetect.la
%{_libdir}/%{name}/modules/osdetect.so
%{_libdir}/%{name}/modules/pgsqldb.la
%{_libdir}/%{name}/modules/pgsqldb.so
%{_libdir}/%{name}/modules/rdns.la
%{_libdir}/%{name}/modules/rdns.so
%{_libdir}/%{name}/modules/sip.la
%{_libdir}/%{name}/modules/sip.so
%{_libdir}/%{name}/modules/upnp.la
%{_libdir}/%{name}/modules/upnp.so
%dir %{_libexecdir}/%{name}
%{_libexecdir}/%{name}/unilisten
%{_libexecdir}/%{name}/unisend
%{_mandir}/man1/%{name}.1*
%dir %{_localstatedir}/lib/%{name}
%files web
%defattr(-,root,root,-)
%doc www-front-end/README.fedora www-front-end/lib/session.sql
%config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}.conf
%config(noreplace) %attr(640,apache,apache) %{_sysconfdir}/%{name}/web.php
%{_datadir}/%{name}
%attr(-,apache,apache) %dir %{_localstatedir}/lib/%{name}/web
%changelog
* Fri Feb 05 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.4.7-12
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
* Sat Jun 20 2015 Robert Scheck <robert@fedoraproject.org> 0.4.7-11
- Added patch to make rebuilding with GCC 5 working
* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-10
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
* Mon Aug 18 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
* Sun Jul 22 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.7-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
* Sat Dec 05 2009 Robert Scheck <robert@fedoraproject.org> 0.4.7-2
- Added unicornscan-web subpackage (#538190 #c3, Robert E. Lee)
- Updated the patch for 64 bit support in configure (#538190 #c6)
* Tue Nov 17 2009 Robert Scheck <robert@fedoraproject.org> 0.4.7-1
- Upgrade to 0.4.7
- Initial spec file for Fedora and Red Hat Enterprise Linux (spec
file is based on a try by Robert E. Lee and Manuel Wolfshant)