commit 88afe3ca2fbe94af8af4e0afda2bca62759e8bd0 Author: Adrian Schröter Date: Fri Jan 19 16:49:37 2024 +0100 Sync from SUSE:ALP:Source:Standard:1.0 wtmpdb revision 8d148da47cff394dbdef6789a10951f4 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..fecc750 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/wtmpdb-0.11.0.tar.xz b/wtmpdb-0.11.0.tar.xz new file mode 100644 index 0000000..8551686 --- /dev/null +++ b/wtmpdb-0.11.0.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc9f9919b4192f0c993ab3bd1e6385c1612e761befbf1dd5ff5547928564ced6 +size 20888 diff --git a/wtmpdb.changes b/wtmpdb.changes new file mode 100644 index 0000000..1e1af66 --- /dev/null +++ b/wtmpdb.changes @@ -0,0 +1,128 @@ +------------------------------------------------------------------- +Mon Jan 8 14:53:09 UTC 2024 - Thorsten Kukuk + +- Update to version 0.11.0 + - last: add support for time-format option + +------------------------------------------------------------------- +Wed Dec 13 14:01:00 UTC 2023 - Thorsten Kukuk + +- Update to version 0.10.0 + - last: support matching for username and/or tty + +------------------------------------------------------------------- +Thu Oct 26 13:07:54 UTC 2023 - Thorsten Kukuk + +- Update to version 0.9.3 + - wtmpdb last: don't print date in the future if there is no + db entry + +------------------------------------------------------------------- +Tue Sep 19 07:53:57 UTC 2023 - Stefan Schubert + +- Update to version 0.9.2 + - Set busy timeout for DB access: The process is waiting until + 5 seconds for DB connection if the DB is locked by another + process. + +------------------------------------------------------------------- +Tue Aug 22 13:47:10 UTC 2023 - Thorsten Kukuk + +- Fix last.1 manual page reference +- Update to version 0.9.1 + - Fix printf format specifier on 32bit + +------------------------------------------------------------------- +Mon Aug 14 15:04:26 UTC 2023 - Thorsten Kukuk + +- Update to version 0.9.0 + - Try to detect systemctl soft-reboot + - Many conversation warning/error fixes + +------------------------------------------------------------------- +Wed Aug 9 14:13:17 UTC 2023 - Thorsten Kukuk + +- Update to version 0.8.0 + - wtmpdb boottime: print boot time + +------------------------------------------------------------------- +Sat Jul 1 23:43:32 UTC 2023 - Jan Engelhardt + +- https://en.opensuse.org/SourceUrls +- Use noun phrase for Summary. +- Wrap descriptions at 70 (for yast2 textmode). + +------------------------------------------------------------------- +Thu Jun 29 12:09:19 UTC 2023 - Thorsten Kukuk + +- Update to version 0.7.1 + - wtmpdb last: Support "YYYY-MM-DD", "today" and "yesterday" as + time option + +------------------------------------------------------------------- +Tue Jun 27 06:30:33 UTC 2023 - Thorsten Kukuk + +- Add last compat symlink and manual page + +------------------------------------------------------------------- +Wed Jun 21 06:52:21 UTC 2023 - Thorsten Kukuk + +- Update to version 0.7.0 + - wtmpdb rotate: use sqlite3_bind_* internal + - wtmpdb last: Implement -x, -d, -i and -w options + +------------------------------------------------------------------- +Wed Jun 7 15:18:21 UTC 2023 - Thorsten Kukuk + +- Update to version 0.6.0 + - wtmpdb rotate: move old log entries into wtmpdb_.db + +------------------------------------------------------------------- +Wed Apr 26 09:11:23 UTC 2023 - Thorsten Kukuk + +- Update to version 0.5.0 + - Use uint64_t instead of usec_t to avoid conflicts + - wtmpdb boot: more accurate calculation of boot time + +------------------------------------------------------------------- +Mon Apr 24 09:46:56 UTC 2023 - Thorsten Kukuk + +- Use Requires(pre) and Requires(post) instead of PreReq + +------------------------------------------------------------------- +Tue Apr 18 06:21:02 UTC 2023 - Thorsten Kukuk + +- Update to version 0.4.0 + - libwtmpdb: Use project version for library version + - libwtmpdb: Always use _PATH_WTMPDB as fallback + +------------------------------------------------------------------- +Mon Apr 17 13:28:05 UTC 2023 - Thorsten Kukuk + +- Skip pam_wtmpdb for sshd + +------------------------------------------------------------------- +Wed Apr 12 13:28:47 UTC 2023 - Thorsten Kukuk + +- Update to version 0.3.0 + - pam_wtmpdb: Add skip_if option + - Add manual pages + - wtmpdb last: fix wtmp begins timestamp if no matching entry was found + - wtmpdb last: Add --since and --until options + - Add compat symlink for "last" + - wtmpdb last: add --present option + - wtmpdb last: implement -n/--limit + - pam_wtmpdb: Try XDG_VTNR if PAM_TTY is not a tty + +------------------------------------------------------------------- +Mon Apr 3 09:17:15 UTC 2023 - Thorsten Kukuk + +- Update to version 0.2.0 + - pam_lastlog: support PAM_XDISPLAY + - wtmpdb last: show PAM service on request + - wtmpdb: log audit records for boot/shutdown + +------------------------------------------------------------------- +Thu Mar 30 13:12:09 UTC 2023 - Thorsten Kukuk + +- Initial package diff --git a/wtmpdb.spec b/wtmpdb.spec new file mode 100644 index 0000000..0032240 --- /dev/null +++ b/wtmpdb.spec @@ -0,0 +1,119 @@ +# +# spec file for package wtmpdb +# +# Copyright (c) 2024 SUSE LLC +# +# 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. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +%define lname libwtmpdb0 +Name: wtmpdb +Version: 0.11.0 +Release: 0 +Summary: Database for recording the last logged in users and system reboots +License: BSD-2-Clause +URL: https://github.com/thkukuk/wtmpdb +Source: https://github.com/thkukuk/wtmpdb/releases/download/v0.10.0/%{name}-%{version}.tar.xz +BuildRequires: docbook5-xsl-stylesheets +BuildRequires: meson +BuildRequires: pkgconfig +BuildRequires: pkgconfig(audit) +BuildRequires: pkgconfig(pam) +BuildRequires: pkgconfig(sqlite3) +Requires(post): pam-config +Requires(postun):pam-config +# Split provide for last +Provides: util-linux:/usr/bin/last + +%description +pam_wtmpdb and wtmpdb are Y2038-safe versions of wtmp and the last +utility. pam_wtmpdb collects all data in a sqlite3 database and the +wtmpdb utility creates boot and shutdown entries or formats and +prints the contents of the wtmp database. + +%package -n %{lname} +Summary: PAM module to store login and logout of users + +%description -n %{lname} +The libwtmpdb provides various interfaces to read, write or modify +the wtmpdb database. + +%package devel +Summary: Development files for libwtmpdb +Requires: %{lname} = %{version} + +%description devel +This package contains all necessary include files and libraries +needed to develop applications that needs to read, write or modify +the wtmpdb database. + +%prep +%autosetup + +%build +%meson -Dman=true -Dcompat-symlink=true +%meson_build + +%install +%meson_install +mkdir -p %{buildroot}%{_mandir}/man1 +echo ".so man8/wtmpdb.8" > %{buildroot}%{_mandir}/man1/last.1 + +%check +%meson_test + +%pre +%service_add_pre wtmpdb-update-boot.service wtmpdb-rotate.timer + +%preun +%service_del_preun wtmpdb-update-boot.service wtmpdb-rotate.timer + +%post +%tmpfiles_create wtmpdb.conf +%service_add_post wtmpdb-update-boot.service wtmpdb-rotate.timer +pam-config -a --wtmpdb --wtmpdb-skip_if=sshd + +%postun +if [ "$1" -eq 0 ]; then + pam-config -d --wtmpdb +fi +%service_del_postun_without_restart wtmpdb-update-boot.service +%service_del_postun wtmpdb-rotate.timer + +%post -n %{lname} -p /sbin/ldconfig +%postun -n %{lname} -p /sbin/ldconfig + +%files +%license LICENSE +%{_bindir}/last +%{_bindir}/wtmpdb +%{_unitdir}/wtmpdb-update-boot.service +%{_unitdir}/wtmpdb-rotate.service +%{_unitdir}/wtmpdb-rotate.timer +%{_tmpfilesdir}/wtmpdb.conf +%{_pam_moduledir}/pam_wtmpdb.so +%ghost %{_localstatedir}/lib/wtmpdb +%{_mandir}/man1/last.1%{?ext_man} +%{_mandir}/man8/wtmpdb.8%{?ext_man} +%{_mandir}/man8/pam_wtmpdb.8%{?ext_man} + +%files -n %{lname} +%license LICENSE +%{_libdir}/libwtmpdb.so.* + +%files devel +%{_libdir}/libwtmpdb.so +%{_includedir}/wtmpdb.h +%{_libdir}/pkgconfig/libwtmpdb.pc + +%changelog