Commit graph

16 commits

Author SHA1 Message Date
William Brown f1e70b2422 Review Feedback 2025-04-05 13:54:56 +10:00
William Brown f9ca11aca1 Document the various structs 2025-04-05 13:52:03 +10:00
William Brown debaf002bf Unify unix config parser 2025-04-05 13:44:28 +10:00
Firstyear b88b6923eb
20250313 unixd system cache ()
The implementation of the unixd cache relies on inotify to detect changes to files in /etc so that we know when to reload the data for nss/passwd. However, the way that groupadd/del and other tools work is they copy the file, change it, and then move it into place. It turns out that william of the past didn't realise that inotify works on inodes not paths like other tools do (auditctl for example).

As a result, when something modified /etc/group or another related file, the removal was seen, but this breaks notifications on any future change until you reload unixd.

To resolve this we need to recursively watch /etc with inotify - yep, that's correct. We have to watch everything in /etc for changes because it's the only way to pick up on the add/remove of files. But because we have to watch everything, we need permissions to watch everything.

This forces us to move the parsing of the etc passwd/group/shadow files to the unixd tasks daemon - arguably, this is the correct place to read these anyway since that is a high priv (and locked down) daemon. Because of this, we actually end up solving the missing "shadow" group on debian issue, and probably similar on the BSD's in future.

In order to make my life easier while testing I also threw in a makefile that symlinks the files to needed locations for testing. It has plenty of warnings as it should.

Fixes 
Fixes 
Fixes 
2025-03-14 13:46:26 +10:00
James Hodgkinson c89f0c011e
20250209 pre release ()
* fix: removing unused dependencies (assert_cmd, gethostname)
* chore: Release Notes
2025-02-09 10:06:01 +00:00
Firstyear b15ff89b39
20250206 freebsd ports ()
* Remove unneeded files
* Ensure we config client config for freebsd
* Improve shell handling
* Use freebsd compat nss
2025-02-09 08:57:15 +00:00
Firstyear 1f5ce2617d
Resolve kanidm-unix auth-test bug ()
* Resolve kanidm-unix auth-test bug

When reworking the unix daemon, we missed changing the auth-test
tool to handle the new challenge-response flow correctly which
would cause the session to disconnect.

* Cleanup
2025-02-09 02:49:54 +00:00
Firstyear 226274da23
20250102 freebsd client ()
Support freebsd as a unix client
2025-01-04 09:22:44 +10:00
James Hodgkinson b6f63f3605
kanidm-unixd example config enfixening ()
* kanidm-unixd default config via PPA problem with version 2 on debian bookworm
Fixes 

* fix(coverage): moving to using cargo-tarpaulin

* kanidm-unixd default config via PPA problem with version 2 on debian bookworm
Fixes 
2024-12-21 15:17:12 +10:00
Firstyear c96e9772c7
Resolve pam services not always having a tty () 2024-11-05 00:49:33 +00:00
Firstyear ea1fcf59e5
Resolve incorrect handling of rhost in pam () 2024-11-03 00:13:26 +00:00
James Hodgkinson 68119e1067
more errors for the people () 2024-10-18 23:51:45 +00:00
Firstyear 50e513b30b
Add nss testframework and fallback when daemon offline () 2024-10-15 04:05:51 +00:00
Firstyear cf63c6b98b
Complete the implementation of the posix account cache ()
Allow caching and checking of shadow entries (passwords)
    Cache and serve system id's
    improve some security warnings
    prepare for multi-resolver
    Allow the kanidm provider to be not configured
    Allow group extension
2024-10-02 02:12:13 +00:00
Firstyear b1099dfa3b
Foundations of pam/nss multi resolver
This starts the support for multi-resolver operation as well as a system level nss resolver.

In future we'll add the remaining support to auth system users with pam too.
2024-08-15 23:54:35 +00:00
Firstyear 0ce333ff5a
Allow providers to be box dyn ()
* Allow providers to be box dyn in kanidm_unixd
* Massive refactor
2024-06-16 22:21:25 +00:00