commit ceb7413c762b069fb7aebe5cccdde4c28b883947 Author: overweight <5324761+overweight@user.noreply.gitee.com> Date: Mon Sep 30 10:31:57 2019 -0400 Package init diff --git a/auth.socket b/auth.socket new file mode 100644 index 0000000..d701b04 --- /dev/null +++ b/auth.socket @@ -0,0 +1,9 @@ +[Unit] +Description=Authd Activation Socket + +[Socket] +ListenStream=113 +Accept=true + +[Install] +WantedBy=sockets.target diff --git a/auth@.service b/auth@.service new file mode 100644 index 0000000..8da5bd2 --- /dev/null +++ b/auth@.service @@ -0,0 +1,8 @@ +[Unit] +Description=Authd Ident Protocol Requests Server +After=local-fs.target + +[Service] +User=ident +ExecStart=/usr/sbin/in.authd -t60 --xerror --os -E +StandardInput=socket diff --git a/authd-1.4.4.tar.gz b/authd-1.4.4.tar.gz new file mode 100644 index 0000000..7e4d2a3 Binary files /dev/null and b/authd-1.4.4.tar.gz differ diff --git a/authd.spec b/authd.spec new file mode 100644 index 0000000..600b938 --- /dev/null +++ b/authd.spec @@ -0,0 +1,77 @@ +Name: authd +Version: 1.4.4 +Release: 1 +Summary: A RFC 1413 ident protocol daemon +License: GPLv2+ +URL: https://github.com/InfrastructureServices/authd +Source0: https://github.com/InfrastructureServices/authd/releases/download/v1.4.4/authd-1.4.4.tar.gz +# Authd Activation Socket from Fedora, as published at +# https://github.com/InfrastructureServices/authd/tree/master/packaging/Fedora +Source1: auth.socket +Source2: auth@.service +BuildRequires: gcc openssl-devel gettext help2man systemd-units +Requires(post): openssl systemd-units +Requires(preun): systemd-units +Requires(postun): systemd-units +Obsoletes: pidentd < 3.2 +Provides: pidentd = 3.2 + +%description +Authd is a small and fast RFC 1413 ident protocol daemon with both +xinetd server and interactive modes that supports IPv6 and IPv4 +as well as the more popular features of pidentd. + +%package_help + +%prep +%autosetup -n %{name}-%{version} + +%build +CFLAGS=$RPM_OPT_FLAGS make prefix=%{_prefix} + +%install +%makeinstall +install -d ${RPM_BUILD_ROOT}%{_sysconfdir}/ +touch ${RPM_BUILD_ROOT}%{_sysconfdir}/ident.key + +install -d ${RPM_BUILD_ROOT}/%{_mandir}/man1/ +help2man -N -v -V ${RPM_BUILD_ROOT}/%{_sbindir}/in.authd -o \ + ${RPM_BUILD_ROOT}/%{_mandir}/man1/in.authd.1 + +install -d ${RPM_BUILD_ROOT}%{_unitdir}/ +install %{SOURCE1} ${RPM_BUILD_ROOT}%{_unitdir}/ +install %{SOURCE2} ${RPM_BUILD_ROOT}%{_unitdir}/ + +%find_lang %{name} + +%preun +%systemd_preun auth.socket + +%post +/usr/sbin/adduser -s /sbin/nologin -u 98 -r -d '/' ident 2>/dev/null || true +/usr/bin/openssl rand -base64 -out %{_sysconfdir}/ident.key 32 +echo CHANGE THE LINE ABOVE TO A PASSPHRASE >> %{_sysconfdir}/ident.key +/bin/chown ident:ident %{_sysconfdir}/ident.key +chmod o-rw %{_sysconfdir}/ident.key + +%systemd_post auth.socket + +%postun +%systemd_postun_with_restart auth.socket + +%files +%defattr(-,root,root) +%verify(not md5 size mtime user group) %config(noreplace) %attr(640,root,root) %{_sysconfdir}/ident.key +%doc COPYING README.html +%{_sbindir}/in.authd +%{_datadir}/locale/* +%{_unitdir}/auth* + +%files help +%defattr(-,root,root) +%{_mandir}/* +%doc rfc1413.txt + +%changelog +* Tue Sep 10 2019 openEuler Buildteam - 1.4.4-1 +- Package init