package init
This commit is contained in:
commit
630eced9a7
BIN
uid_wrapper-1.2.4.tar.gz
Normal file
BIN
uid_wrapper-1.2.4.tar.gz
Normal file
Binary file not shown.
65
uid_wrapper.spec
Normal file
65
uid_wrapper.spec
Normal file
@ -0,0 +1,65 @@
|
|||||||
|
Name: uid_wrapper
|
||||||
|
Version: 1.2.4
|
||||||
|
Release: 4
|
||||||
|
Summary: A wrapper for privilege separation
|
||||||
|
License: GPLv3+
|
||||||
|
URL: http://cwrap.org/
|
||||||
|
Source0: https://ftp.samba.org/pub/cwrap/%{name}-%{version}.tar.gz
|
||||||
|
|
||||||
|
BuildRequires: cmake libcmocka-devel
|
||||||
|
|
||||||
|
%description
|
||||||
|
Some projects, such as a file server, need privilege separation to be able to switch
|
||||||
|
to the user who owns the files and do file operations on their behalf. uid_wrapper
|
||||||
|
convincingly lies to the application, letting it believe it is operating as root and
|
||||||
|
even switching between UIDs and GIDs as needed. You can start any application making
|
||||||
|
it believe it is running as root.
|
||||||
|
|
||||||
|
If you load the uid_wrapper and enable it with setting UID_WRAPPER=1 all setuid() and
|
||||||
|
setgid() calls will work, even as a normal user.
|
||||||
|
|
||||||
|
It is possible to start your application as fake root with setting UID_WRAPPER_ROOT=1.
|
||||||
|
|
||||||
|
Enable debugging of uid_wrapper itself by setting the UID_WRAPPER_DEBUGLEVEL variable.
|
||||||
|
|
||||||
|
%package help
|
||||||
|
Summary: Help package for %{name}
|
||||||
|
|
||||||
|
%description help
|
||||||
|
This package contains some man help files for %{name}.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -n %{name}-%{version} -p1
|
||||||
|
|
||||||
|
%build
|
||||||
|
install -d obj
|
||||||
|
cd obj
|
||||||
|
%cmake -DUNIT_TESTING=ON %{_builddir}/%{name}-%{version}
|
||||||
|
%make_build VERBOSE=1
|
||||||
|
|
||||||
|
%install
|
||||||
|
cd obj
|
||||||
|
%make_install
|
||||||
|
|
||||||
|
%post
|
||||||
|
/sbin/ldconfig
|
||||||
|
|
||||||
|
%postun
|
||||||
|
/sbin/ldconfig
|
||||||
|
|
||||||
|
%check
|
||||||
|
cd obj
|
||||||
|
make test || find Testing -name "*.log" | xargs cat
|
||||||
|
|
||||||
|
%files
|
||||||
|
%doc AUTHORS README ChangeLog COPYING
|
||||||
|
%{_libdir}/libuid_wrapper.so*
|
||||||
|
%{_libdir}/cmake/uid_wrapper/*
|
||||||
|
%{_libdir}/pkgconfig/uid_wrapper.pc
|
||||||
|
|
||||||
|
%files help
|
||||||
|
%{_mandir}/man1/uid_wrapper.1*
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Wed Nov 20 2019 lingsheng <lingsheng@huawei.com> - 1.2.4-4
|
||||||
|
- Package init
|
||||||
Loading…
x
Reference in New Issue
Block a user