2014-02-13 13:00:33 +01:00
|
|
|
#
|
|
|
|
# spec file for package uid_wrapper
|
|
|
|
#
|
2019-07-15 11:32:05 +02:00
|
|
|
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
2014-02-13 13:00:33 +01:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2019-07-15 11:32:05 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2014-02-13 13:00:33 +01:00
|
|
|
#
|
|
|
|
|
2015-09-02 13:31:25 +02:00
|
|
|
|
2015-05-11 08:37:43 +02:00
|
|
|
############################# NOTE ##################################
|
|
|
|
#
|
|
|
|
# This is a special library. You are not able to link this library.
|
|
|
|
# Do NOT create library package or a devel package!
|
|
|
|
#
|
|
|
|
############################# NOTE ##################################
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
Name: uid_wrapper
|
2019-07-16 11:29:50 +02:00
|
|
|
Version: 1.2.7
|
2014-02-13 13:00:33 +01:00
|
|
|
Release: 0
|
|
|
|
|
|
|
|
Summary: A wrapper for privilege seperation
|
2019-07-15 11:32:05 +02:00
|
|
|
License: GPL-3.0-or-later
|
2014-02-13 13:00:33 +01:00
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
Url: http://cwrap.org/
|
|
|
|
|
|
|
|
Source0: https://ftp.samba.org/pub/cwrap/%{name}-%{version}.tar.gz
|
2015-06-26 09:38:22 +02:00
|
|
|
Source1: %{name}-rpmlintrc
|
2019-07-15 11:32:05 +02:00
|
|
|
Source2: https://ftp.samba.org/pub/cwrap/%{name}-%{version}.tar.gz.asc
|
|
|
|
Source3: uid_wrapper.keyring
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
BuildRequires: cmake
|
|
|
|
BuildRequires: libcmocka-devel
|
2015-05-11 08:37:43 +02:00
|
|
|
BuildRequires: pkg-config
|
2019-07-16 11:29:50 +02:00
|
|
|
BuildRequires: system-user-nobody
|
2015-05-11 08:37:43 +02:00
|
|
|
|
|
|
|
Requires: cmake
|
2015-09-02 13:31:25 +02:00
|
|
|
Requires: pkg-config
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
Some projects like a file server need privilege separation to be able to switch
|
|
|
|
to the connnection user and do file operations. uid_wrapper convincingly lies
|
2016-02-14 14:15:59 +01:00
|
|
|
to the application, letting it believe it is operating as root and even
|
|
|
|
switching betwen UIDs and GIDs as needed.
|
2014-02-13 13:00:33 +01:00
|
|
|
|
2016-02-14 14:15:59 +01:00
|
|
|
To use it, set the following environment variables:
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
LD_PRELOAD=libuid_wrapper.so
|
|
|
|
UID_WRAPPER=1
|
|
|
|
|
2016-02-14 14:15:59 +01:00
|
|
|
This package does not have a devel package, because this project is for
|
2014-02-13 13:00:33 +01:00
|
|
|
development/testing.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
|
|
|
|
|
|
|
%build
|
|
|
|
# CMAKE_SKIP_RPATH:BOOL=OFF is need to run the tests!
|
|
|
|
%cmake \
|
2019-07-16 11:29:50 +02:00
|
|
|
-DUNIT_TESTING=ON \
|
|
|
|
-DCMAKE_SKIP_RPATH:BOOL=OFF
|
2014-02-13 13:00:33 +01:00
|
|
|
|
2015-05-11 08:37:43 +02:00
|
|
|
make %{?_smp_mflags} VERBOSE=1
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
%install
|
2015-05-11 08:37:43 +02:00
|
|
|
%cmake_install
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
%check
|
2019-07-16 11:33:31 +02:00
|
|
|
%ctest
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
%post -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2019-07-15 11:32:05 +02:00
|
|
|
%doc AUTHORS README.md ChangeLog
|
|
|
|
%license LICENSE
|
2014-02-13 13:00:33 +01:00
|
|
|
%{_libdir}/libuid_wrapper.so*
|
|
|
|
%dir %{_libdir}/cmake
|
2014-07-31 09:46:22 +02:00
|
|
|
%dir %{_libdir}/cmake/uid_wrapper
|
|
|
|
%{_libdir}/cmake/uid_wrapper/uid_wrapper-config-version.cmake
|
|
|
|
%{_libdir}/cmake/uid_wrapper/uid_wrapper-config.cmake
|
2014-02-13 13:00:33 +01:00
|
|
|
%dir %{_libdir}/pkgconfig
|
|
|
|
%{_libdir}/pkgconfig/uid_wrapper.pc
|
2014-07-31 09:46:22 +02:00
|
|
|
%{_mandir}/man1/uid_wrapper.1*
|
2014-02-13 13:00:33 +01:00
|
|
|
|
|
|
|
%changelog
|