1
2005-09-13 Miloslav Trmac <mitr@redhat.com>
3
* configure.in: Version 0.54.
4
* Makefile.am (lib_libuser_la_LDFLAGS): Update revision.
9
* lib/internal.h: Add G_GNUC_INTERNAL to all declarations.
11
* lib/util.c (lu_strv_len): Remove.
12
* lib/user_private.h (lu_strv_len): Remove declaration.
14
* lib/user.c (lu_default_int): Replace lu_str_case_equal () with its
16
* lib/util.c (lu_str_case_equal, lu_str_equal)
17
(lu_account_name_is_valid): Remove unused functions (not exported in
19
* lib/internal.h (lu-str_case_equal, lu_str_equal)
20
(lu_account_name_is_valid: Remove
23
* apps/apputil.c (lu_strconcat): Comment out like its only user.
24
* apps/apputil.h (lu_strconcat): Remove declaration.
26
* lib/internal.h: Merge lib/modules.h and lib/util.h.
27
* lib/user_private.h: Move internal interfaces to internal.h.
28
* Makefile.am (lib_libuser_la_SOURCES)
29
* docs/reference/Makefile.am (IGNORE_HFILES)
36
* modules/krb5.c: Update.
38
2005-09-12 Miloslav Trmac <mitr@redhat.com>
40
* apps/apputil.c (lu_converse)
41
* apps/lnewusers.c (main)
42
* lib/error.c (lu_error_free)
43
* python/misc.c (libuser_prompt_setattr): Remove conditionals around
44
g_free () or g_strfreev ().
47
* apps/lnewusers.c (main)
48
* lib/util.c (lu_strv_len)
49
* modules/files.c (parse_generic): Use g_strv_length ().
50
* lib/user_private.h (lu_strv_len): Mark as deprecated.
52
* apps/apputil.c (lu_converse): Actually use the "pending" messages.
54
* lib/entity.c (quark_from_attribute): Use g_ascii_strdown ().
56
* modules/files.c (struct format_specifier): Remove member position,
57
assume position == index + 1.
58
(format_passwd, format_group, format_shadow, format_gshadow)
59
(parse_generic, format_generic, generic_mod): Update.
61
* lib/entity.c (lu_ent_add_int)
62
* modules.files.c (format_generic, generic_mod): Beautify.
64
* modules/files.c (generic_mod): Simplify name extraction.
66
* modules/files.c (format_field): New function.
67
(format_generic, generic_mod): Use format_field ().
69
* lib/entity.c (quark_from_attribute): New function.
70
(lu_ent_get_int, lu_ent_clear_int, lu_ent_set_int, lu_ent_add_int):
71
Use quark_from_attribute ().
73
* modules/files.c (generic_mod): Fix crash when attribute is missing.
74
* tests/files_test.py (Tests.testUserMod4): New test.
76
* modules/files.c (parse_generic): Use size_t for field index.
78
* apps/lchage.c (read_ndays): Assume array != NULL
79
&& array->n_values > 0. Beautify.
81
* lib/user.c (merge_ent_array_duplicates)
82
* modules/files.c (generic_is_locked)
83
* modules/ldap.c (lu_ldap_lookup, get_ent_adds): Beautify.
85
* apps/lchage.c (main)
87
* apps/luserdel.c (main)
88
* lib/user.c (lu_dispatch)
89
* modules/files.c (lu_shadow_user_lookup_id, lu_shadow_group_lookup_id)
90
(format_generic): Simplify conditions based on the guarantee
93
* docs/reference/tmpl/entity.sgml: Document that attribute values have
94
always at least one value.
95
* lib/entity.c (lu_ent_set_int, lu_ent_del_int): Remove the attribute
96
if there are no values.
98
2005-06-08 Miloslav Trmac <mitr@redhat.com>
100
* configure.in: Version 0.53.8.
104
* tests/ldap_test: Remove temporary debugging modification.
106
* lib/user.c (lu_name_allowed, INVALID_NAME_CHARS): Permit "portable"
107
user and group names as defined by SUSv3, plus trailing $.
108
* tests/files_test.py (Tests.testUserAddPrep): New test.
110
* lib/error.h: Use G_GNUC_PRINTF.
111
* python/debug.h (FIXME): Remove unused definition.
113
2005-06-04 Miloslav Trmac <mitr@redhat.com>
115
* autogen.sh: Don't set CFLAGS, we don't run configure any more.
117
* configure.in: Use gettext 0.14.3.
119
* tests/ldap_test: Really use tests/ldaprc.
121
2005-05-20 Miloslav Trmac <mitr@redhat.com>
123
* autogen.sh: Document the full set of testing flags. Remove hardcoded
124
paths (used to be necessary to workaround parsing paths in configure).
126
* configure.in, Makefile.am: Don't attempt to parse paths in configure,
127
let (make) expand the variables.
128
* libuser.conf.in: Don't use both @scdir@ and @sysconfdir@.
130
* tests/config_test.sh: New file.
131
* tests/config.conf: Rename from tests/config.conf.in. Define
132
defaults/moduledir to point to the build directory.
133
* tests/config_test.c: Don't define LIBUSER_CONF, it is defined by the
136
* configure.in: Remove many unnecessary tests, simplify others. Fix
137
checking for __secure_getenv().
138
* Makefile.am: Hardcode variables with only a single possible value
140
* configure.in: Disable building of static libraries.
141
* Makefile.am: Don't remove *.{a,la} of plugins.
143
2005-04-30 Miloslav Trmac <mitr@redhat.com>
145
* configure.in: Version 0.53.7.
149
* configure.in: Remove unused GETTEXT_PACKAGE definition.
151
* po/LINGUAS: New file, moved from ALL_LINGUAS in configure.in.
152
Add missing languages (bn_IN, en_GB, et, fi, gu, he, id, ka, ku, lo,
155
2005-04-24 Miloslav Trmac <mitr@redhat.com>
157
* configure.in: Version 0.53.6.
161
* Makefile.am: Don't ship test/config_test in distribution tarball.
163
* autogen.sh: Don't automatically run configure.
164
* Makefile.am: Update.
166
* tests/config_test.c, tests/config.conf: New files.
167
* Makefile.am: Add tests/config_test.c and tests/config.conf.
169
* lib/config.c (lu_cfg_init): Don't ignore keys with empty values.
171
* lib/config.c (struct config_config): Store the configuration
172
in parsed form, not only the text of the config file.
173
(lu_cfg_init): Parse the configuration only at initialization time.
174
(lu_cfg_done): Update.
175
(lu_cfg_read, lu_cfg_read_keys): Use the paresd configuration.
176
(compare_section_names, compare_key_string, gather_values): New
179
2005-04-15 Miloslav Trmac <mitr@redhat.com>
181
* configure.in: Version 0.53.5.
185
* tests/files_test.py (Tests.testUserEnumerate1): Rename from
187
(Tests.testGroupsEnumerate1): Rename from testGroupsEnumerate.
188
(Tests.testUsersEnumerateFull1): Rename from testUsersEnumerateFull.
190
(Tests.testGroupsEnumerateFull1): Rename from testGroupsEnumerateFull.
192
(Tests.testUsersEnumerateByGroup3): Simplify.
193
(Tests.testUserEnumerate2, Tests.testUsersEnumerateByGroup4)
194
(Tests.testUsersEnumerateFull2, Tests.testGroupsEnumerate2)
195
(Tests.testGroupsEnumerateByUser4, Tests.testGroupsEnumerateFull2):
198
* modules/files.c (lu_files_enumerate)
199
(lu_files_users_enumerate_by_group)
200
(lu_files_groups_enumerate_by_user, lu_files_enumerate_full): Skip
201
nss_compat lines (starting with '+' or '-').
203
* tests/files_test: Update initial file contents.
205
* apps/apputil.c: Remove unnecessary include.
207
* configure.in: Use AM_PATH_PYTHON instead of --with-python-version.
209
* Makefile.am (pythonexecdir): Replace by pyexecdir.
210
(DISTCHECK_CONFIGURE_FLAGS): Remove
211
--with-python-version.
212
(PYTHON_CPPFLAGS): New definition.
214
2005-04-06 Miloslav Trmac <mitr@volny.cz>
216
* configure.in: Version 0.53.4.
220
2005-04-06 Miloslav Trmac <mitr@redhat.com>
222
* modules/ldap.c (ldap_attribute_map): Fix "cn" objectclass.
223
(lu_ldap_needed_objectclasses): Don't add "account" objectclass if it
225
(lu_ldap_fudge_objectclasses): Add debugging output.
227
2005-03-05 Miloslav Trmac <mitr@redhat.com>
229
* configure.in: Version 0.53.3.
233
2005-03-04 Miloslav Trmac <mitr@redhat.com>
235
* apps/apputil.c (lu_homedir_populate, lu_signal_nscd)
236
(lu_mailspool_create_remove)
237
* modules/files.c (lu_files_create_backup, generic_add, generic_del):
238
Add more error checking.
240
* modules/ldap.c: Include Cyrus SASL v2 header file.
242
* modules/krb5.c (lu_krb5_user_add, lu_krb5_user_mod)
243
(lu_krb5_user_del, lu_krb5_user_do_lock, lu_krb5_user_islocked)
244
(lu_krb5_user_setpass): Fix checking of lu_ent magic.
246
* docs/reference/libuser-sections.txt: Add lu_values_equal.
247
* docs/reference/tmpl/value.sgml: Document lu_values_equal ().
249
2005-01-17 Miloslav Trmac <mitr@redhat.com>
251
* configure.in: Version 0.53.2.
256
* tests/utils.conf.in
258
* tests/utils_gshadow
260
* tests/utils_shadow: New files.
261
* Makefile.am: Add tests/utils_test.
263
* apps/lgroupmod.c (main): Fix ignoring of other changes when one
264
of -p, -P, -L, -U is used. Fix group ID changes (look up group
265
members in the original group, and only after applying other
266
member list modifications; don't change primary group ID for users
267
that have a different primary group).
269
* apps/lgroupmod.1: Fix typo.
271
* apps/lnewusers.c (main): Don't use "users" if the input
272
specifies a nonexistent group name. Use the specified user ID.
273
* apps/lnewusers.1: Update.
275
* apps/luseradd.c (main): Actually implement -p and -P.
277
* apps/lusermod.c (main): Fix ignoring of other changes when one
278
of -p, -P, -L, -U is used.
280
2005-01-15 Miloslav Trmac <mitr@redhat.com>
291
* apps/lusermod.1: New files.
292
* Makefile.am: Add new man pages.
294
* apps/lchage.c (main): Fix cut-and-paste error in -E and -W.
295
* apps/lpasswd.c (main): Make sure the password is always
297
* apps/luseradd.c (main): Exit if a new group can't be created.
299
2004-12-13 Miloslav Trmac <mitr@redhat.com>
301
* configure.in: Version 0.53.1.
305
* python/libusermodule.c (initlibuser): Export UT_NAMESIZE from
307
* pythone/modules.txt: Document UT_NAMESIZE.
309
2004-11-14 Miloslav Trmac <mitr@redhat.com>
311
* configure.in: Version 0.53.
315
* docs/reference/libuser-sections.txt
316
* docs/reference/tmpl/user.sgml: Document lu_user_unlock_nonempty ()
317
and lu_group_unlock_nonempty ().
319
* tests/files_test.py (Tests.testUserUnlockNonempty1)
320
(Tests.testUserUnlockNonempty2, Tests.testUserUnlockNonempty3)
321
(Tests.testGroupUnlockNonempty1, Tests.testGroupUnlockNonempty2)
322
(Tests.testGroupUnlockNonempty3)
323
* tests/ldap_test.py (Tests.testUserUnlockNonempty1)
324
(Tests.testUserUnlockNonempty2, Tests.testUserUnlockNonempty3)
325
(Tests.testGroupUnlockNonempty1, Tests.testGroupUnlockNonempty2)
326
(Tests.testGroupUnlockNonempty3): Add tests for
327
lu_user_unlock_nonempty ()
329
* modules/files.c (reset_default_context): Don't report error in
330
restoring default context, there is no way to handle them anyway.
332
* python/admin.c (libuser_admin_unlock_user)
333
(libuser_admin_unlock_group): Allow calling lu_user_unlock_nonempty ()
334
and lu_group_unlock_nonempty ().
335
* python/modules.txt: Document unlockUser nad unlockGroup changes.
337
* tests/files_test.py (Tests.testUserUnlock3)
338
(Tests.testGroupUnlock3)
339
* tests/ldap_test.py (Tests.testUserUnlock3)
340
(Tests.testGroupUnlock2): Test that empty password fields can be
343
* modules/ldap.c (enum lock_op): New definition.
344
(lu_ldap_handle_lock): Use enum lock_op. All callers changed.
345
(lu_ldap_user_unlock_nonempty, lu_ldap_group_unlock_nonempty)
346
(libuser_ldap_init): Handle user_unlock_nonempty and
347
group_unlock_nonempty.
349
* modules/files.c (enum lock_op): New definition.
350
(lock_process): Use enum lock_op, return error status.
351
(generic_lock): Use enum lock_op. All callers changed.
352
(lu_files_user_unlock_nonempty, lu_files_group_unlock_nonempty)
353
(lu_shadow_user_unlock_nonempty, lu_shadow_group_unlock_nonempty)
354
(libuser_files_init, libuser_shadow_init): Handle user_unlock_nonempty
355
and group_unlock_nonempty.
357
* modules/sasldb.c (lu_sasldb_user_unlock_nonempty)
358
(lu_sasldb_group_unlock_nonempty, libuser_sasldb_init): Define
359
user_unlock_nonempty and group_unlock_nonempty stubs.
361
* lib/error.h (lu_error_unlock_empty): New definition.
362
* lib/error.c (lu_strerror, lu_error_is_error): Handle
363
lu_error_unlock_empty.
365
* lib/user_private.h (LU_MODULE_VERSION): Bump.
366
(struct lu_module): New members user_unlock_nonempty,
367
group_unlock_nonempty.
368
* lib/modules.c (lu_modules_load): Handle new struct lu_module members.
369
* lib/user.c (lu_user_unlock_nonempty, lu_group_unlock_nonempty): New
371
(lu_dispatch_id): New values user_unlock_nonempty,
372
group_unlock_nonempty.
373
(run_single, run_list, lu_dispatch): Handle new lu_dispatch_id values.
374
* lib/user.h: Add declarations.
378
* tests/files_test.py (Tests.testUserLock1, Tests.testUserLock2)
379
(Tests.testUserUnlock1, Tests.testUserUnlock2)
380
(Tests.testUserIslocked1, Tests.testUserIslocked2)
381
(Tests.testUserSetpass, Tests.testUserRemovepass)
382
(Tests.testGroupLock1, Tests.testGroupLock2)
383
(Tests.testGroupUnlock1, Tests.testGroupUnlock2)
384
(Tests.testGroupIsLocked1, Tests.testGroupIsLocked2)
385
(Tests.testGroupSetpass, Tests.testGroupRemovepass): Test the functions
386
don't change the non-shadow password fields.
388
* modules/files.c (generic_setpass): Allow setting a shadow password
389
even if the current shadow password is invalid. All callers updated.
391
* apps/luseradd.c (main): Don't attempt to create a user group
392
if --gid specifies a numerical ID of a non-existing group.
394
* apps/lnewusers.c (main): Fix handling of empty home directory field.
396
* apps/lusermod.c (main): Make copies of entity values that get
397
destroyed by lu_user_modify (). Get a list of groups an user is in
398
before renaming the user. Don't reuse 'ent' for group entitites.
402
2004-11-13 Miloslav Trmac <mitr@redhat.com>
404
* modules/files.c (struct format specifier): New member def_if_empty.
405
(format_passwd, format_group, format_shadow, format_gshadow): Update.
406
(parse_generic): Check for def_if_empty.
408
* apps/lgroupadd.c (main)
409
* apps/lgroupmod.c (main)
410
* apps/lchage.c (read_ndays)
411
* apps/lnewusers.c (main)
412
* apps/luseradd.c (main)
413
* apps/lusermod.c (main)
414
* lib/misc.c (lu_value_get_id)
415
* lib/user.c (lu_default_int)
416
* modules/files.c (parse_field)
417
* modules/ldap.c (lu_ldap_lookup)
418
* samples/lookup.c (main): Check strto* () for error yet more properly.
420
* tests/files.conf.in, tests/files_test, tests/files_test.py: New
423
* Makefile.am: Add tests/files_test.
424
(EXTRA_DIST): Don't change values depending on whether LDAP is used.
426
* modules/files.c (libuser_files_init, libuser_shadow_init): Allow
427
using the modules as non-root if explicitly requested.
429
2004-11-09 Miloslav Trmac <mitr@redhat.com>
431
* tests/ldap_test.py (Tests.testUserLookupId)
432
(Tests.testGroupLookupId): Test large ID values.
433
(Tests.testUserAdd4, Tests.testUserMod3, Tests.testGroupAdd3)
434
(Tests.testGroupMod3): New tests.
436
* apps/lusermod.c (main): Fix user renaming in groups where the
437
user is a member or administrator.
439
* python/ent.c (libuser_convert_to_value): Handle whole id_t
442
* python/ent.c (libuser_convert_to_value): Report Python exception
443
instead of aborting. Return success/failure status.
444
(libuser_entity_setattr, libuser_entity_add, libuser_entity_set)
445
(libuser_entity_set_item): Handle errors reported by
446
libuser_convert_to_value().
448
* python/ent.c (convert_value_array_pylist): Handle G_TYPE_INT64.
450
* python/admin.c (lubser_admin_lookup_user_id)
451
(libuser_admin_lookup_group_id, libuser_admin_create_home)
452
(libuser_admin_get_first_unused_id_type): Handle whole uid_t/gid_t
455
2004-11-08 Miloslav Trmac <mitr@redhat.com>
457
* lib/user.c (lu_default_int): Use id_t.
459
* lib/user.c (lu_get_first_unused_id): Change the interface to use
460
id_t. Don't allow (id_t)-1.
461
* lib/user_private.h: Update prototype.
463
* modules/files.c (format_passwd, format_group): Use
464
G_TYPE_INVALID for id_t.
465
(parse_field): Handle G_TYPE_INVALID.
467
* modules/files.c (parse_field): New function, split from
468
parse_generic (). Don't interpret input as octal or hexadecimal
470
(parse_generic): Use parse_field ().
472
* modules/ldap.c (lu_ldap_lookup): Convert id_t values to numbers,
473
not strings. Don't interpret input as octal or hexadecimal
476
* samples/lookup.c (main): Handle whole id_t range.
478
* lib/user.c (lu_default_int): Convert id_t values to numbers, not
479
strings. Don't interpret input as octal or hexadecimal numbers.
481
* lub/user.c (lu_default_int): Handle whole range of uid_t/gid_t in
484
* lib/user.c (lu_default_int): Remove copy-and-pasted usage of
485
idkeystring as a generic fallback.
487
* lib/user.c (lu_default_int): Handle whole ID range.
489
* lib/user.c (compare_strings): Replace compare_ints ().
490
(merge_ent_array_duplicates): Use lu_value_strdup () instead of
493
* modules/ldap.c (value_compare): Removed function.
495
* lib/entity.c (lu_ent_add_int)
496
* lib/user.c (remove_duplicate_values)
497
* modules/ldap.c (arrays_equal, get_ent_mods): Use lu_values_equal ().
499
* lib/misc.c (lu_values_equal): New function.
500
* lib/user.h: Add declaration.
502
* apps/lgroupmod.c (main)
503
* apps/lgroupadd.c (main)
504
* apps/luseradd.c (main)
505
* apps/lusermod.c (main): Handle whole gid_t/uid_t range for
506
'--gid' and '--uid', respectively.
508
2004-11-07 Miloslav Trmac <mitr@redhat.com>
510
* apps/apputil.h (INVALID): Removed definition.
512
* apps/apputil.c (lu_mailspool_create_remove)
513
* apps/lgroupadd.c (main)
514
* apps/lgroupmod.c (main)
515
* apps/lnewusers.c (main)
516
* apps/luseradd.c (main)
517
* apps/lusermod.c (main): Use LU_VALUE_INVALID_ID to indicate unknown
520
* lib/user.c (INVALID): Removed definition.
521
(extract_id, convert_user_name_to_id, convert_group_name_to_id):
522
Return LU_VALUE_INVALID_ID on failure. All callers changed.
523
(lu_dispatch): Use LU_VALUE_INVALID_ID to indicate unknown value.
526
* samples/testuser.c (dump_attribute): Handle G_TYPE_INT64.
528
* modules/ldap.c (lu_ldap_user_lookup_id): Handle whole uid_t range.
529
(lu_ldap_group_lookup_id, lu_ldap_users_enumerate_by_group): Handle
532
* modules/files.c (lu_files_user_lookup_id)
533
(lu_shadow_user_lookup_id): Handle whole uid_t range.
534
(lu_files_group_lookup_id, lu_shadow_group_lookup_id)
535
(lu_files_users_enumerate_by_group): Handle whole gid_t range.
537
* lib/user.c (run_single, run_list): Use id_t for ldata. All callers
539
(convert_user_name_to_id): Return uid_t.
540
(convert_group_name_to_id): Return gid_t.
542
* lib/entity.c (lu_ent_dump): Handle G_TYPE_INT64.
544
* apps/luserdel.c (main): Handle whole gid_t range.
546
* apps/luseradd.c (main): Handle whole gid_t range.
548
* apps/lnewusers.c (main): Handle whole uid_t/gid_t range, don't ignore
551
* apps/lchage.c (read_ndays): Handle G_TYPE_INT64.
553
* apps/apputil.c (lu_mailspool_create_remove)
554
* apps/lgroupmod.c (main)
555
* apps/lnewusers.c (main)
556
* apps/luseradd.c (main)
557
* apps/luserdel.c (main)
558
* modules/ldap.c (lu_ldap_groups_enumerate_by_user): Use
561
* docs/reference/tmpl/value.sgml: New file.
563
* lib/misc.c (lu_value_get_id): New function.
564
* lib/user.h: Add declaration.
565
(LU_VALUE_INVALID_ID): New macro.
567
* apps/lgroupadd.c (main)
568
* apps/lgroupmod.c (main)
569
* apps/lnewusers.c (main)
570
* apps/luseradd.c (main)
571
* apps/lusermod.c (main)
572
* lib/user.c (lu_default_int): Use lu_value_init_set_id ().
574
* lib/misc.c (lu_value_init_set_id): New function.
575
* lib/user.h: Add declaration.
576
* lib/misc.c (lu_value_strdup): Handle G_TYPE_INT64.
578
* lib/misc.c (lu_strdup_value): Rename to lu_value_strdup (). All
580
* lib/user.h: Rename declaration.
582
* apps/lchage.c (read_ndays)
583
* apps/lnewusers.c (main)
584
* apps/luseradd.c (main)
585
* lib/user.c (lu_default_int)
586
* modules/files.c (parse_generic)
587
* modules/ldap.c (lu_ldap_lookup)
588
(lu_ldap_groups_enumerate_by_user): Properly check strtol () for error.
590
2004-11-05 Miloslav Trmac <mitr@redhat.com>
593
* modules/files.c (generic_lock, generic_is_locked, generic_setpass)
594
* apps/lchfn.c (main): Use lu_strdup_value ().
596
* modules/files.c (generic_is_locked): Fix memory leak.
598
2004-11-04 Miloslav Trmac <mitr@redhat.com>
600
* modules/ldap.c (get_ent_adds, get_ent_mods, lu_ldap_set)
601
(lu_ldap_del, lu_ldap_handle_lock, lu_ldap_is_locked)
602
(lu_ldap_setpass): Use lu_strdup_value () instead of
604
(value_as_string): Removed function.
606
* modules/sasldb.c (lu_sasldb_user_munge, lu_sasldb_user_is_locked):
607
Use lu_strdup_value ().
609
2004-11-03 Miloslav Trmac <mitr@redhat.com>
611
* apps/apputil.c (lu_mailspool_create_remove)
612
* apps/lchfn.c (main)
613
* apps/lchsh.c (main)
615
* modules/files.c (lu_shadow_user_lookup_id, lu_shadow_group_lookup_id)
616
(format_generic, generic_mod, generic_del): Use lu_strdup_value ().
618
* lib/misc.c (lu_strdup_value): New function.
619
* lib/user.h: Add declaration.
620
* docs/reference/tmpl/entity.sgml
621
* docs/reference/libuser-sections.txt: Document lu_strdup_value ().
623
2004-11-02 Miloslav Trmac <mitr@redhat.com>
625
* configure.in: Version 0.52.6.
629
2004-11-01 Miloslav Trmac <mitr@redhat.com>
631
* modules/sasldb.c (lu_sasldb_user_lookup_name, lu_sasldb_user_munge)
632
(lu_sasldb_user_is_locked): Remove assertions on possible error codes,
633
undocumented codes happen too.
635
* modules/sasldb.c (libuser_sasldb_init): Fix self-describing module
638
* modules/sasldb.c (lu_sasldb_user_removepass)
639
(lu_sasldb_group_removepass): New functions
640
(libuser_sasldb_init): Set the user_removepass and group_removepass
643
* lib/modules.c (lu_modules_load): Don't close a NULL handle.
645
* modules/sasldb.c (lu_sasldb_user_add): Return TRUE on success.
648
* modules/sasldb.c (lu_sasldb_user_lookup_name, lu_sasldb_user_munge)
649
(libuser_sasldb_init): Use Cyrus SASL v2.
651
* modules/ldap.c (bind_server): Don't attempt to bind using NULL bind
654
* modules/ldap.c (bind_server): Report at least the first encountered
657
2004-10-30 Miloslav Trmac <mitr@redhat.com>
659
* apps/lchfn.c (main)
660
* apps/lchsh.c (main)
661
* apps/lnewusers.c (main)
662
* samples/enum.c (main)
663
* samples/testuser.c (main): Output error messages on stderr.
665
* apps/lchfn.c (main): Exit if specified user does not exist.
667
* apps/lnewusers.c (main): Don't attempt to act on improperly formatted
670
* po/POTFILES.in: Add missing files.
672
* modules/ldap.c (lu_ldap_set, lu_ldap_del): Remove superfluous '\n'
673
and '.\n' at message ends.
675
* apps/lgroupadd.c (main)
676
* apps/lgroupdel.c (main)
677
* apps/lgroupmod.c (main)
678
* apps/lchage.c (main)
679
* apps/lchfn.c (main)
680
* apps/lchsh.c (main)
682
* apps/lnewusers.c (main)
683
* apps/luseradd.c (main)
684
* apps/luserdel.c (main)
685
* apps/lusermod.c (main)
686
* python/admin.c (libuser_admin_do_wrap, libuser_admin_setpass):
687
* samples/enum.c (main):
688
* samples/homedir.c (main):
689
* samples/lookup.c (main):
690
* samples/testuser.c (main): Use lu_strerror () instead of
691
(error ? error->string : _("unknown error")). Report error cause in
694
* apps/lchsh.c (main): Report error if shell was not changed.
696
* modules/ldap.c (lu_ldap_set, lu_ldap_handle_lock)
698
* modules/files.c (set_default_context, reset_default_context)
700
* lib/config.c (lu_cfg_init)
701
* apps/apputil.c (lu_authenticate_unprivileged): Mark strings for
704
* lib/util.c (lu_util_line_get_matchingx): Fix memory leak.
706
2004-10-14 Miloslav Trmac <mitr@redhat.com>
708
* lib/error.h (LU_ERROR_CHECK): Add missing '\n'.
710
2004-10-11 Miloslav Trmac <mitr@redhat.com>
712
* configure.in: Version 0.52.5.
716
* python/admin.c (libuser_admin_add_user)
717
(libuser_admin_modify_user)
718
(libuser_admin_delete_user): Fix memory leak.
720
* python/admin.c (libuser_admin_add_user)
721
(libuser_admin_delete_user): Fix reference counting.
723
* python/modules.txt: Fix modifyUser documentation about not creating
724
home directory by default.
726
* python/admin.c (libuser_admin_modify_user): Pass original entity
727
to libuser_admin_move_home().
729
2004-10-10 Miloslav Trmac <mitr@redhat.com>
731
* configure.in: Version 0.52.4.
735
* python/misc.c (libuser_prompt_destroy): Fix memory leak.
736
(libuser_admin_python_prompter): Properly copy struct libuser_prompt
737
to avoid double free().
739
* python/admin.c (libuser_admin_enumerate_users)
740
(libuser_admin_enumerate_groups)
741
(libuser_admin_enumerate_users_by_group)
742
(libuser_admin_enumerate_groups_by_user): Fix memory leaks.
744
* python/admin.c (libuser_admin_enumerate_users_full)
745
(libuser_admin_enumerate_groups_full)
746
(libuser_admin_enumerate_users_by_group_full)
747
(libuser_admin_enumerate_groups_by_user_full)
748
* python/ent.c (convert_value_array_pylist)
749
(libuser_entity_getattrlist):
750
* python/libusermodule.c (libuser_get_user_shells):
751
* python/misc.c (libuser_admin_python_prompter): Fix memory leaks.
753
2004-10-09 Miloslav Trmac <mitr@redhat.com>
755
* lib/entity.c (lu_ent_free): Fix memory leak.
757
* modules/files.c (generic_add): Fix memory leak.
759
* lib/user.c (merge_ent_array_duplicates): Remove fflush (from
762
* modules/files.c (lu_files_enumerate_full): Fix memory leak.
764
2004-09-29 Miloslav Trmac <mitr@redhat.com>
766
* configure.in: Version 0.52.3.
770
* Makefile.am: Readd -D_LIBUSER_MODULE for modules.
772
2004-09-28 Miloslav Trmac <mitr@redhat.com>
774
* configure.in: Version 0.52.2.
778
* modules/ldap.c (lu_ldap_set): Beautify debug messages.
780
* modules/ldap.c (connect_server): Allow ldap URIs, don't require TLS
781
for servers specified by URIs.
782
* docs/sgml/libuser.sgml: Document URI support.
784
2004-09-27 Miloslav Trmac <mitr@redhat.com>
786
* configure.in: Version 0.52.1.
790
* modules/files.c (set_default_context): Make sure *prev_context is
793
2004-09-27 Miloslav Trmac <mitr@redhat.com>
795
* configure.in: Version 0.52.
797
* autogen.sh: Create the `admin' subdirectory if needed.
799
* Makefile.am (CVSTAG): Fix definition.
801
* Makefile.am (archive): Ship with formatted documentation.
803
* configure.in: Define AC_CONFIG_AUX_DIR.
805
* configure.in: Remove various unneeded parts.
807
* configure.in, Makefile.am: Use automake conditionals instead of
809
* Makefile.am (TESTS): Define only if LDAP.
811
* Makefile.am: Use AM_CPPFLAGS to eliminate the most redundant lines.
813
* Makefile.am (uninstall-local): Fix typo.
815
* Makefile.am: Link exactly with needed libraries.
817
* docs/sgml/Makefile.am: Merge with docs/Makefile.am.
819
* Makefile.am (CVSTAG): Define portably.
821
* configure.in: Use new-style AC_INIT and AM_INIT_AUTOMAKE.
822
Set automake options `subdir-objects' and `-Wall'.
824
* modules/ldap.c (lu_ldap_lookup): Silence gcc warning.
826
* apps/Makefile.am, lib/Makefile.am, modules/Makefile.am,
827
samples/Makefile.am: Merge with top-level Makefile.am.
828
* apps/lchage.c, apps/lchfn.c, apps/lgroupadd.c, apps/lgroupdel.c,
829
apps/lgroupmod.c, apps/lid.c, apps/lnewusers.c, apps/lpasswd.c,
830
apps/luseradd.c, apps/luserdel.c, apps/lusermod.c, samples/enum.c,
831
python/admin.c, python/ent.c, python/misc.c, python/libusermodule.c,
832
python/quotamodule.c, samples/field.c, samples/homedir.c,
833
samples/lookup.c, samples/quotaq.c, samples/prompt.c,
834
samples/testuser.c: Change path of config.h.
838
* tests/ldap_test.py (Tests.testUserDel, Tests.testUserLock1)
839
(Tests.testUserLock2, Tests.testUserUnlock1)
840
(Tests.testUserUnlock2, Tests.testUserIslocked1)
841
(Tests.testUserIslocked2, Tests.testUserSetpass1)
842
(Tests.testUserSetpass2, Tests.testUserSetpass3)
843
(Tests.testUserRemovepass1, Tests.testUserRemovepass2)
844
(Tests.testUserRemovepass3, Tests.testUsersEnumerate)
845
(Tests.testUsersEnumerateByGroup1)
846
(Tests.testUsersEnumerateByGroup2)
847
(Tests.testUsersEnumerateByGroup3, Tests.testUsersEnumerateFull)
848
(Tests.testGroupLookupName, Tests.testGroupLookupId)
849
(Tests.testGroupAdd1, Tests.testGroupAdd2, Tests.testGroupMod1)
850
(Tests.testGroupMod2, Tests.testGroupDel, Tests.testGroupLock1)
851
(Tests.testGroupLock2, Tests.testGroupUnlock1)
852
(Tests.testGroupUnlock2, Tests.testGroupIsLocked1)
853
(Tests.testGroupIsLocked2, Tests.testGroupSetpass1)
854
(Tests.testGroupSetpass2, Tests.testGroupSetpass3)
855
(Tests.testGroupRemovepass1, Tests.testGroupRemovepass2)
856
(Tests.testGroupRemovepass3, Tests.testGroupsEnumerate)
857
(Tests.testGroupsEnumerateByUser1)
858
(Tests.testGroupsEnumerateByUser2)
859
(Tests.testGroupsEnumerateByUser3, Tests.testGroupsEnumerateFull):
862
* tests/ldap_test.py (Tests.testUserAdd2, Tests.testUserMod2): Update
863
for final password entity model.
865
* modules/ldap.c (lu_ldap_is_locked): Remove unneeded parameter `type'.
868
* tests/ldap_test: Clean up after running the tests.
870
* tests/ldap_test.py: Workaround openssl's inability to handle
871
repeated library loading and unloading.
873
* modules/ldap.c (lu_ldap_groups_enumerate_by_user): Don't consider
874
all string representations of numbers invalid.
875
(lu_ldap_groups_enumerate_by_user): Don't free data owned by the
878
* lib/user.c (run_single): Don't run user_removepass when
879
group_removepass is wanted.
881
* modules/ldap.c (lu_ldap_group_removepass): Implement.
883
* modules/ldap.c (lu_ldap_is_locked): Use LU_GROUPPASSWORD and
884
POSIXGROUP for groups.
886
* modules/ldap.c (lu_ldap_setpass): Don't attempt to remove the
887
attribute if it does not exist.
888
(lu_ldap_setpass): Use LU_GROUPPASSWORD for groups.
890
* modules/ldap.c (lu_ldap_handle_lock): Use LU_GROUPPASSWORD for
893
* modules/ldap.c (ldap_attribute_map): Remove LU_SHADOWPASSWORD.
894
(get_ent_adds): Skip LU_SHADOWPASSWORD. It should be completely
897
* python/libusermodule.c (initlibuser): Fix libuser.GROUPPASSWORD.
899
2004-09-26 Miloslav Trmac <mitr@redhat.com>
901
* lib/user.c (lu_end): Fix memory leak.
903
* modules/ldap.c (lu_ldap_ent_to_dn): Remove parameter `applicability'.
906
* modules/ldap.c (lu_ldap_fudge_objectclasses): Use the mod_values
908
(ldap_attribute_map): Make members point to constant strings.
909
Casts added to users where needed.
910
(lu_ldap_user_attributes, lu_ldap_group_attributes): Make it a constant
911
array of constant strings.
912
(libuser_ldap_init): Store converted pointers to data that will be
913
eventually freed as part of the context.
914
(lu_ldap_lookup): Use mapped_user_attributes, mapped_group_attributes.
915
(map_from_ldap): Remove.
916
(lu_ldap_close_module): Free mapped_user_attributes,
917
mapped_group_attributes.
919
2004-09-25 Miloslav Trmac <mitr@redhat.com>
921
* modules/ldap.c (lu_ldap_needed_objectclasses): s/User/Entity/g
922
(lu_ldap_needed_objectclasses): Fix debugging printout.
923
(lu_ldap_needed_objectclasses): Ignore attributes not applicable to
926
* modules/ldap.c (ldap_attribute_map): Remove mapping for
927
LU_ADMINISTRATORNAME.
928
(SHADOWGROUP): Remove.
930
* python/admin.c (libuser_admin_removepass_user)
931
(libuser_admin_removepass_group): Throw exception on error.
933
* modules/ldap.c (lu_ldap_user_removepass): Implement.
935
* modules/ldap.c (lu_ldap_is_locked): Fix memory leak.
936
(lu_ldap_is_locked): Map libuser attribute names to LDAP names.
938
* modules/ldap.c (lu_ldap_setpass): Initialize addvalues[0] and
939
rmvalues[0] even if the original password is already encrypted.
940
(lu_ldap_setpass): Map libuser attribute names to LDAP names.
941
(lu_ldap_setpass): Remove (maybe all) values before adding new values.
942
(lu_ldap_setpass): Fix memory leak.
944
* modules/ldap.c (lu_ldap_handle_lock): Don't skip LU_CRYPTED twice.
945
(lu_ldap_handle_lock): Fix memory leaks.
946
(lu_ldap_handle_lock): Don't remove and add the same value.
947
(lu_ldap_handle_lock): Avoid unnecessary g_malloc0()/g_free() pair.
948
(lu_ldap_handle_lock): Don't drop LU_CRYPTED when unlocking unlocked
950
(lu_ldap_handle_lock): Don't lock locked accounts again.
952
* modules/ldap.c (lu_ldap_user_attributes): Drop LU_SHADOWPASSWORD.
953
(get_ent_adds): Drop LU_SHADOWPASSWORD, not LU_USERPASSWORD.
955
* modules/ldap.c (lu_ldap_set): Remove parameter `attributes'. All
958
2004-09-24 Miloslav Trmac <mitr@redhat.com>
960
* configure.in: Version 0.51.12.
962
* Makefile.am: Remove the spec file and "release" tagging from CVS,
963
rework the spec file a bit.
965
* configure.in: Don't create libuser.spec.
966
* NEWS: Move data from libuser.spec.in.
967
* libuser.spec.in: Remove.
969
* tests/ldap.conf.in, tests/ldaprc, tests/ldap_skel.ldif,
970
tests/ldap_test.py, tests/slapd.conf.in: New files
971
* Makefile.am (TESTS, EXTRA_DIST): Use and distribute tests.
973
* python/ent.c (libuser_entity_set): Don't both return success and
974
indicate error at the same time.
976
* python/ent.c (libuser_entity_set_item): Don't clear the entity
977
if the new value has invalid type.
979
* modules/files.c (generic_lookup): Fix memory leak.
980
* python/ent.c (libuser_convert_to_value): Fix memory leak.
982
* modules/ldap.c (get_ent_mods, lu_ldap_set): Special-case entry
984
(lu_ldap_set): Fix desired RDN computation in rename.
986
* modules/ldap.c (lu_ldap_set): Use the original name when
987
looking up the DN of an entry that is being renamed.
989
2004-09-23 Miloslav Trmac <mitr@redhat.com>
991
* configure.in: Version 0.51.11.
993
* libuser.conf.in: Avoid mentioning /usr/lib* in config file.
995
2004-09-21 Miloslav Trmac <mitr@redhat.com>
997
* modules/ldap.c (lu_ldap_set): New parameter `add'. All callers
1000
* modules/ldap.c (get_ent_mods): Simplify somewhat.
1002
* modules/ldap.c (objectclass_present, lu_ldap_needed_objectclasses)
1003
(get_ent_adds): Split and customize/fix from
1004
lu_ldap_fudge_objectclasses ().
1005
(lu_ldap_fudge_objectclasses): Use lu_ldap_needed_objectclasses ().
1007
* modules/ldap.c (ACCOUNT): New macro.
1008
(SHADOWACCOUNT): Define as "shadowAccount" again.
1010
* modules/ldap.c (ldap_attribute_map): Remove unused member
1011
`ldap_attribute_key'.
1013
* modules/ldap.c (lu_ldap_user_lookup_name, lu_ldap_user_lookup_id):
1014
Add LU_LDAP_SHADOW to `applicability' argument.
1016
* python/libusermodule.c (initlibuser): Add missing attribute names.
1018
2004-09-19 Miloslav Trmac <mitr@redhat.com>
1020
* python/admin.c (libuser_admin_setattr): Fix reference counting.
1022
2004-09-18 Miloslav Trmac <mitr@redhat.com>
1024
* python/misc.c (libuser_admin_python_prompter, libuser_admin_prompt):
1025
Fix reference counting.
1027
* modules/ldap.c (libuser_ldap_init): Don't set error when it was
1030
2004-09-17 Miloslav Trmac <mitr@redhat.com>
1032
* modules/ldap.c (value_compare): Make sense of comparison same for
1035
* modules/ldap.c (lu_ldap_ent_to_dn, libuser_ldap_init):
1038
* modules/ldap.c (libuser_ldap_init, bind_server): Respect bind_simple
1041
2004-09-20 Miloslav Trmac <mitr@redhat.com>
1043
* apps/lchfn.1, apps/lchsh.1: New files.
1044
* apps/Makefile.am (dist_man_MANS): Distribute new man pages.