]>
Commit | Line | Data |
---|---|---|
ef6678a7 | 1 | Summary: A gateway for more secure user access to CGI scripts |
9214648f | 2 | Summary(pl.UTF-8): Bramka do bezpieczniejszego dostępu użytkowników do skryptów CGI |
ef6678a7 | 3 | Name: cgiwrap |
96ceddfb | 4 | Version: 4.1 |
0c130017 | 5 | Release: 8 |
ef6678a7 AM |
6 | License: GPL |
7 | Group: Utilities | |
8 | Source0: http://dl.sourceforge.net/cgiwrap/%{name}-%{version}.tar.gz | |
96ceddfb | 9 | # Source0-md5: 14c02c57e4a0c6224951018e2f6b9211 |
20a92991 | 10 | Patch0: %{name}-mime_magic.patch |
11 | Patch1: %{name}-bs.patch | |
12 | Patch2: %{name}-phprc.patch | |
13 | Patch3: %{name}-customhtmlerrors.patch | |
7b553a06 | 14 | URL: http://cgiwrap.sourceforge.net/ |
4b86fdc7 | 15 | BuildRequires: autoconf |
ef6678a7 | 16 | BuildRequires: automake |
447a66c2 | 17 | BuildRequires: libmagic-devel |
ef6678a7 AM |
18 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
19 | ||
8088838f JB |
20 | %define _cgibindir /home/services/httpd/cgi-bin |
21 | ||
ef6678a7 AM |
22 | %description |
23 | A gateway that allows more secure user access to CGI programs on an | |
6f650a59 | 24 | HTTPd server than is provided by the HTTP server itself. The primary |
ef6678a7 AM |
25 | function of CGIwrap is to make certain that any CGI script runs with |
26 | the permissions of the user who installed it, and not those of the | |
27 | server. | |
28 | ||
8117246f JR |
29 | %description -l pl.UTF-8 |
30 | Bramka pozwalająca na bardziej bezpieczny dostęp użytkowników do | |
31 | programów CGI na serwerze HTTP niż ten udostępniany przez sam serwer | |
32 | HTTP. Główna funkcja CGIwrap to upewnienie się, że skrypt CGI działa z | |
33 | uprawnieniami użytkownika, który go zainstalował, a nie serwera. | |
8088838f | 34 | |
ef6678a7 AM |
35 | %prep |
36 | %setup -q | |
80bf4912 | 37 | %patch0 -p1 |
20a92991 | 38 | %patch1 -p1 |
39 | %patch2 -p0 | |
40 | %patch3 -p1 | |
ef6678a7 AM |
41 | |
42 | %build | |
43 | install %{_datadir}/automake/config.* . | |
c9981612 | 44 | %{__autoconf} |
ef6678a7 AM |
45 | %configure \ |
46 | --with-perl=%{_bindir}/perl \ | |
db9c6340 | 47 | --with-php=%{_bindir}/php.cgi \ |
ef6678a7 AM |
48 | --with-local-contact-email=root@localhost \ |
49 | --with-httpd-user=http \ | |
50 | --with-minimum-uid=500 \ | |
51 | --with-minimum-gid=500 \ | |
db9c6340 | 52 | --with-block-svn-paths \ |
53 | --with-block-cvs-paths \ | |
54 | --with-php-interpreter \ | |
55 | --with-soft-rlimit-only \ | |
dfd5e644 | 56 | --with-cgi-dir=public_html \ |
80bf4912 | 57 | --without-check-symlink \ |
5a7956d8 | 58 | --without-check-group \ |
c9981612 | 59 | --with-use-script-url \ |
60 | --with-quiet-errors \ | |
61 | --with-custom-html-errors=/etc/cgiwrap | |
8088838f | 62 | |
447a66c2 | 63 | %{__make} \ |
64 | LDFLAGS='%{rpmldflags} -lmagic' | |
ef6678a7 AM |
65 | |
66 | %install | |
67 | rm -rf $RPM_BUILD_ROOT | |
c9981612 | 68 | install -d $RPM_BUILD_ROOT{%{_cgibindir},%{_sysconfdir}/cgiwrap} |
ef6678a7 | 69 | |
8088838f | 70 | install cgiwrap $RPM_BUILD_ROOT%{_cgibindir} |
db9c6340 | 71 | install cgiwrap $RPM_BUILD_ROOT%{_cgibindir}/cgiwrapd |
72 | install cgiwrap $RPM_BUILD_ROOT%{_cgibindir}/nph-cgiwrap | |
73 | install cgiwrap $RPM_BUILD_ROOT%{_cgibindir}/nph-cgiwrapd | |
74 | install cgiwrap $RPM_BUILD_ROOT%{_cgibindir}/php-cgiwrap | |
75 | install cgiwrap $RPM_BUILD_ROOT%{_cgibindir}/php-cgiwrapd | |
ef6678a7 | 76 | |
c9981612 | 77 | echo "The cgiwrap executable(s) were not made setuid-root. This is required" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/CGIWrapNotSetUID.html |
78 | echo "The userid that the web server ran cgiwrap as does not match the userid that was configured into the cgiwrap executable" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/ServerUserMismatch.html | |
79 | echo "CGIWrap was configured with a server userid that does not exist" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/ServerUserNotFound.html | |
80 | echo "Execution is not permitted" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/ExecutionNotPermitted.html | |
81 | echo "CGIWrap access control mechanism denied execution of this script" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/AccessControl.html | |
82 | echo "CGIWrap encountered a system error" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/SystemError.html | |
83 | echo "CGIWrap encountered an error while attempting to execute this script" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/ExecFailed.html | |
84 | echo "CGIWrap was unable to find the user" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/NoSuchUser.html | |
85 | echo "The specified user does not have a script directory set up" > $RPM_BUILD_ROOT%{_sysconfdir}/cgiwrap/NoScriptDir.html | |
86 | ||
ef6678a7 AM |
87 | %clean |
88 | rm -rf $RPM_BUILD_ROOT | |
89 | ||
ef6678a7 AM |
90 | %files |
91 | %defattr(644,root,root,755) | |
92 | %doc htdocs/* | |
8088838f | 93 | %attr(4755,root,root) %{_cgibindir}/* |
c9981612 | 94 | %dir %{_sysconfdir}/cgiwrap |
95 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cgiwrap/*.html |