Fix off-by-one in getpwall and getgrall (#13674)
We were omitting first NSS entry. Add basic CI tests to ensure
that our pwd and grp output matches what is expected from base
python module.
Fix off-by-one in getpwall and getgrall
We were omitting first NSS entry. Add basic CI tests to ensure
that our pwd and grp output matches what is expected from base
python module.
Remove legacy samba domain support
DragonFish was last release where we support this legacy feature.
This commit removes most of middleware code, but leaves database
untouched. Next related PR for FreeIPA support will finalize
schema changes.
Remove legacy samba domain support
DragonFish was last release where we support this legacy feature.
This commit removes most of middleware code, but leaves database
untouched. Next related PR for FreeIPA support will finalize
schema changes.
NAS-128802 / 24.10 / Improve configuration file generation (#13669)
1. use os.rename to overwrite config files. Avoid possibility of
having applications read partially written configuration files by
first writing the changed config to a temporary file, then renaming
over existing file.
2. have write_if_changed allow specifying the desired permissions
and ownership of the file. This allows us to ensure that ownership and
permissions changes happen before we close and rename the file.
3. alter return value for write_if_changed from boolean indicating
whether changes were written to a bitmask of changes made. This allows
us to flag when permissions and ownership had to be altered (logging
potentially unexpected CLI changes).
4. add optional non-default parameter to raise an exception if
we had to change ownership and permissions. This exception can be
used in future to generate audit messages / alerts if we had
[2 lines not shown]