~ubuntu-branches/ubuntu/hardy/libuser/hardy-proposed

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
2005-09-13  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.54.
	* Makefile.am (lib_libuser_la_LDFLAGS): Update revision.

	* NEWS: Update.

	* apps/apputil.h
	* lib/internal.h: Add G_GNUC_INTERNAL to all declarations.

	* lib/util.c (lu_strv_len): Remove.
	* lib/user_private.h (lu_strv_len): Remove declaration.

	* lib/user.c (lu_default_int): Replace lu_str_case_equal () with its
	contents.
	* lib/util.c (lu_str_case_equal, lu_str_equal)
	(lu_account_name_is_valid): Remove unused functions (not exported in
	public header files).
	* lib/internal.h (lu-str_case_equal, lu_str_equal)
	(lu_account_name_is_valid: Remove
	declarations.

	* apps/apputil.c (lu_strconcat): Comment out like its only user.
	* apps/apputil.h (lu_strconcat): Remove declaration.

	* lib/internal.h: Merge lib/modules.h and lib/util.h.
	* lib/user_private.h: Move internal interfaces to internal.h.
	* Makefile.am (lib_libuser_la_SOURCES)
	* docs/reference/Makefile.am (IGNORE_HFILES)
	* lib/config.c
	* lib/entity.c
	* lib/misc.c
	* lib/modules.c
	* lib/scache.c
	* lib/user.c
	* modules/krb5.c: Update.

2005-09-12  Miloslav Trmac  <mitr@redhat.com>

	* apps/apputil.c (lu_converse)
	* apps/lnewusers.c (main)
	* lib/error.c (lu_error_free)
	* python/misc.c (libuser_prompt_setattr): Remove conditionals around
	g_free () or g_strfreev ().

	* apps/lchfn.c (main)
	* apps/lnewusers.c (main)
	* lib/util.c (lu_strv_len)
	* modules/files.c (parse_generic): Use g_strv_length ().
	* lib/user_private.h (lu_strv_len): Mark as deprecated.

	* apps/apputil.c (lu_converse): Actually use the "pending" messages.

	* lib/entity.c (quark_from_attribute): Use g_ascii_strdown ().

	* modules/files.c (struct format_specifier): Remove member position,
	assume position == index + 1.
	(format_passwd, format_group, format_shadow, format_gshadow)
	(parse_generic, format_generic, generic_mod): Update.

	* lib/entity.c (lu_ent_add_int)
	* modules.files.c (format_generic, generic_mod): Beautify.

	* modules/files.c (generic_mod): Simplify name extraction.

	* modules/files.c (format_field): New function.
	(format_generic, generic_mod): Use format_field ().

	* lib/entity.c (quark_from_attribute): New function.
	(lu_ent_get_int, lu_ent_clear_int, lu_ent_set_int, lu_ent_add_int):
	Use quark_from_attribute ().

	* modules/files.c (generic_mod): Fix crash when attribute is missing.
	* tests/files_test.py (Tests.testUserMod4): New test.

	* modules/files.c (parse_generic): Use size_t for field index.

	* apps/lchage.c (read_ndays): Assume array != NULL
	&& array->n_values > 0.  Beautify.

	* lib/user.c (merge_ent_array_duplicates)
	* modules/files.c (generic_is_locked)
	* modules/ldap.c (lu_ldap_lookup, get_ent_adds): Beautify.

	* apps/lchage.c (main)
	* apps/lchsh.c (main)
	* apps/luserdel.c (main)
	* lib/user.c (lu_dispatch)
	* modules/files.c (lu_shadow_user_lookup_id, lu_shadow_group_lookup_id)
	(format_generic): Simplify conditions based on the guarantee
	below.

	* docs/reference/tmpl/entity.sgml: Document that attribute values have
	always at least one value.
	* lib/entity.c (lu_ent_set_int, lu_ent_del_int): Remove the attribute
	if there are no values.

2005-06-08  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.8.

	* NEWS: Update.

	* tests/ldap_test: Remove temporary debugging modification.

	* lib/user.c (lu_name_allowed, INVALID_NAME_CHARS): Permit "portable"
	user and group names as defined by SUSv3, plus trailing $.
	* tests/files_test.py (Tests.testUserAddPrep): New test.

	* lib/error.h: Use G_GNUC_PRINTF.
	* python/debug.h (FIXME): Remove unused definition.

2005-06-04  Miloslav Trmac  <mitr@redhat.com>

	* autogen.sh: Don't set CFLAGS, we don't run configure any more.

	* configure.in: Use gettext 0.14.3.

	* tests/ldap_test: Really use tests/ldaprc.

2005-05-20  Miloslav Trmac  <mitr@redhat.com>

	* autogen.sh: Document the full set of testing flags.  Remove hardcoded
	paths (used to be necessary to workaround parsing paths in configure).

	* configure.in, Makefile.am: Don't attempt to parse paths in configure,
	let (make) expand the variables.
	* libuser.conf.in: Don't use both @scdir@ and @sysconfdir@.

	* tests/config_test.sh: New file.
	* tests/config.conf: Rename from tests/config.conf.in.  Define
	defaults/moduledir to point to the build directory.
	* tests/config_test.c: Don't define LIBUSER_CONF, it is defined by the
	wrapper script now.

	* configure.in: Remove many unnecessary tests, simplify others.  Fix
	checking for __secure_getenv().
	* Makefile.am: Hardcode variables with only a single possible value

	* configure.in: Disable building of static libraries.
	* Makefile.am: Don't remove *.{a,la} of plugins.

2005-04-30  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.7.

	* NEWS: Update.

	* configure.in: Remove unused GETTEXT_PACKAGE definition.

	* po/LINGUAS: New file, moved from ALL_LINGUAS in configure.in.
	Add missing languages (bn_IN, en_GB, et, fi, gu, he, id, ka, ku, lo,
	mr, si, sq, ur).

2005-04-24  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.6.

	* NEWS: Update.

	* Makefile.am: Don't ship test/config_test in distribution tarball.

	* autogen.sh: Don't automatically run configure.
	* Makefile.am: Update.

	* tests/config_test.c, tests/config.conf: New files.
	* Makefile.am: Add tests/config_test.c and tests/config.conf.

	* lib/config.c (lu_cfg_init): Don't ignore keys with empty values.

	* lib/config.c (struct config_config): Store the configuration
	in parsed form, not only the text of the config file.
	(lu_cfg_init): Parse the configuration only at initialization time.
	(lu_cfg_done): Update.
	(lu_cfg_read, lu_cfg_read_keys): Use the paresd configuration.
	(compare_section_names, compare_key_string, gather_values): New
	functions.

2005-04-15  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.5.

	* NEWS: Update.

	* tests/files_test.py (Tests.testUserEnumerate1): Rename from
	testUserEnumerate.
	(Tests.testGroupsEnumerate1): Rename from testGroupsEnumerate.
	(Tests.testUsersEnumerateFull1): Rename from testUsersEnumerateFull.
	Simplify.
	(Tests.testGroupsEnumerateFull1): Rename from testGroupsEnumerateFull.
	Simplify.
	(Tests.testUsersEnumerateByGroup3): Simplify.
	(Tests.testUserEnumerate2, Tests.testUsersEnumerateByGroup4)
	(Tests.testUsersEnumerateFull2, Tests.testGroupsEnumerate2)
	(Tests.testGroupsEnumerateByUser4, Tests.testGroupsEnumerateFull2):
	New tests.

	* modules/files.c (lu_files_enumerate)
	(lu_files_users_enumerate_by_group)
	(lu_files_groups_enumerate_by_user, lu_files_enumerate_full): Skip
	nss_compat lines (starting with '+' or '-').

	* tests/files_test: Update initial file contents.

	* apps/apputil.c: Remove unnecessary include.

	* configure.in: Use AM_PATH_PYTHON instead of --with-python-version.

	* Makefile.am (pythonexecdir): Replace by pyexecdir.
	(DISTCHECK_CONFIGURE_FLAGS): Remove
	--with-python-version.
	(PYTHON_CPPFLAGS): New definition.

2005-04-06  Miloslav Trmac  <mitr@volny.cz>

	* configure.in: Version 0.53.4.

	* NEWS: Update.

2005-04-06  Miloslav Trmac  <mitr@redhat.com>

	* modules/ldap.c (ldap_attribute_map): Fix "cn" objectclass.
	(lu_ldap_needed_objectclasses): Don't add "account" objectclass if it
	is already present.
	(lu_ldap_fudge_objectclasses): Add debugging output.

2005-03-05  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.3.

	* NEWS: Update.

2005-03-04  Miloslav Trmac  <mitr@redhat.com>

	* apps/apputil.c (lu_homedir_populate, lu_signal_nscd)
	(lu_mailspool_create_remove)
	* modules/files.c (lu_files_create_backup, generic_add, generic_del):
	Add more error checking.

	* modules/ldap.c: Include Cyrus SASL v2 header file.

	* modules/krb5.c (lu_krb5_user_add, lu_krb5_user_mod)
	(lu_krb5_user_del, lu_krb5_user_do_lock, lu_krb5_user_islocked)
	(lu_krb5_user_setpass): Fix checking of lu_ent magic.

	* docs/reference/libuser-sections.txt: Add lu_values_equal.
	* docs/reference/tmpl/value.sgml: Document lu_values_equal ().

2005-01-17  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.2.

	* NEWS: Update.

	* tests/utils_test
	* tests/utils.conf.in
	* tests/utils_group
	* tests/utils_gshadow
	* tests/utils_passwd
	* tests/utils_shadow: New files.
	* Makefile.am: Add tests/utils_test.

	* apps/lgroupmod.c (main): Fix ignoring of other changes when one
	of -p, -P, -L, -U is used.  Fix group ID changes (look up group
	members in the original group, and only after applying other
	member list modifications; don't change primary group ID for users
	that have a different primary group).

	* apps/lgroupmod.1: Fix typo.

	* apps/lnewusers.c (main): Don't use "users" if the input
	specifies a nonexistent group name.  Use the specified user ID.
	* apps/lnewusers.1: Update.

	* apps/luseradd.c (main): Actually implement -p and -P.

	* apps/lusermod.c (main): Fix ignoring of other changes when one
	of -p, -P, -L, -U is used.

2005-01-15  Miloslav Trmac  <mitr@redhat.com>

	* apps/lchage.1
	* apps/lgroupadd.1
	* apps/lgroupdel.1
	* apps/lgroupmod.1
	* apps/lid.1
	* apps/lnewusers.1
	* apps/lpasswd.1
	* apps/luseradd.1
	* apps/luserdel.1
	* apps/lusermod.1: New files.
	* Makefile.am: Add new man pages.

	* apps/lchage.c (main): Fix cut-and-paste error in -E and -W.
	* apps/lpasswd.c (main): Make sure the password is always
	'\0'-terminated.
	* apps/luseradd.c (main): Exit if a new group can't be created.

2004-12-13  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.1.

	* NEWS: Update.

	* python/libusermodule.c (initlibuser): Export UT_NAMESIZE from
	<utmp.h>.
	* pythone/modules.txt: Document UT_NAMESIZE.

2004-11-14  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.53.

	* NEWS: Update.

	* docs/reference/libuser-sections.txt
	* docs/reference/tmpl/user.sgml: Document lu_user_unlock_nonempty ()
	and lu_group_unlock_nonempty ().

	* tests/files_test.py (Tests.testUserUnlockNonempty1) 
	(Tests.testUserUnlockNonempty2, Tests.testUserUnlockNonempty3) 
	(Tests.testGroupUnlockNonempty1, Tests.testGroupUnlockNonempty2) 
	(Tests.testGroupUnlockNonempty3)
	* tests/ldap_test.py (Tests.testUserUnlockNonempty1) 
	(Tests.testUserUnlockNonempty2, Tests.testUserUnlockNonempty3) 
	(Tests.testGroupUnlockNonempty1, Tests.testGroupUnlockNonempty2) 
	(Tests.testGroupUnlockNonempty3): Add tests for 
	lu_user_unlock_nonempty ()

	* modules/files.c (reset_default_context): Don't report error in
	restoring default context, there is no way to handle them anyway.

	* python/admin.c (libuser_admin_unlock_user) 
	(libuser_admin_unlock_group): Allow calling lu_user_unlock_nonempty ()
	and lu_group_unlock_nonempty ().
	* python/modules.txt: Document unlockUser nad unlockGroup changes.

	* tests/files_test.py (Tests.testUserUnlock3) 
	(Tests.testGroupUnlock3)
	* tests/ldap_test.py (Tests.testUserUnlock3) 
	(Tests.testGroupUnlock2): Test that empty password fields can be
	unlocked.

	* modules/ldap.c (enum lock_op): New definition.
	(lu_ldap_handle_lock): Use enum lock_op.  All callers changed.
	(lu_ldap_user_unlock_nonempty, lu_ldap_group_unlock_nonempty) 
	(libuser_ldap_init): Handle user_unlock_nonempty and
	group_unlock_nonempty.

	* modules/files.c (enum lock_op): New definition.
	(lock_process): Use enum lock_op, return error status.
	(generic_lock): Use enum lock_op.  All callers changed.
	(lu_files_user_unlock_nonempty, lu_files_group_unlock_nonempty) 
	(lu_shadow_user_unlock_nonempty, lu_shadow_group_unlock_nonempty) 
	(libuser_files_init, libuser_shadow_init): Handle user_unlock_nonempty
	and group_unlock_nonempty.

	* modules/sasldb.c (lu_sasldb_user_unlock_nonempty) 
	(lu_sasldb_group_unlock_nonempty, libuser_sasldb_init): Define
	user_unlock_nonempty and group_unlock_nonempty stubs.

	* lib/error.h (lu_error_unlock_empty): New definition.
	* lib/error.c (lu_strerror, lu_error_is_error): Handle 
	lu_error_unlock_empty.

	* lib/user_private.h (LU_MODULE_VERSION): Bump.
	(struct lu_module): New members user_unlock_nonempty,
	group_unlock_nonempty.
	* lib/modules.c (lu_modules_load): Handle new struct lu_module members.
	* lib/user.c (lu_user_unlock_nonempty, lu_group_unlock_nonempty): New
	functions.
	(lu_dispatch_id): New values user_unlock_nonempty,
	group_unlock_nonempty.
	(run_single, run_list, lu_dispatch): Handle new lu_dispatch_id values.
	* lib/user.h: Add declarations.

	* NEWS: Update.

	* tests/files_test.py (Tests.testUserLock1, Tests.testUserLock2) 
	(Tests.testUserUnlock1, Tests.testUserUnlock2) 
	(Tests.testUserIslocked1, Tests.testUserIslocked2) 
	(Tests.testUserSetpass, Tests.testUserRemovepass) 
	(Tests.testGroupLock1, Tests.testGroupLock2) 
	(Tests.testGroupUnlock1, Tests.testGroupUnlock2) 
	(Tests.testGroupIsLocked1, Tests.testGroupIsLocked2) 
	(Tests.testGroupSetpass, Tests.testGroupRemovepass): Test the functions
	don't change the non-shadow password fields.

	* modules/files.c (generic_setpass): Allow setting a shadow password
	even if the current shadow password is invalid.  All callers updated.

	* apps/luseradd.c (main): Don't attempt to create a user group
	if --gid specifies a numerical ID of a non-existing group.

	* apps/lnewusers.c (main): Fix handling of empty home directory field.

	* apps/lusermod.c (main): Make copies of entity values that get
	destroyed by lu_user_modify ().  Get a list of groups an user is in
	before renaming the user.  Don't reuse 'ent' for group entitites.

	* NEWS: Update.

2004-11-13  Miloslav Trmac  <mitr@redhat.com>

	* modules/files.c (struct format specifier): New member def_if_empty.
	(format_passwd, format_group, format_shadow, format_gshadow): Update.
	(parse_generic): Check for def_if_empty.

	* apps/lgroupadd.c (main)
	* apps/lgroupmod.c (main)
	* apps/lchage.c (read_ndays)
	* apps/lnewusers.c (main)
	* apps/luseradd.c (main)
	* apps/lusermod.c (main)
	* lib/misc.c (lu_value_get_id)
	* lib/user.c (lu_default_int)
	* modules/files.c (parse_field)
	* modules/ldap.c (lu_ldap_lookup)
	* samples/lookup.c (main): Check strto* () for error yet more properly.

	* tests/files.conf.in, tests/files_test, tests/files_test.py: New
	files.

	* Makefile.am: Add tests/files_test.
	(EXTRA_DIST): Don't change values depending on whether LDAP is used.

	* modules/files.c (libuser_files_init, libuser_shadow_init): Allow
	using the modules as non-root if explicitly requested.

2004-11-09  Miloslav Trmac  <mitr@redhat.com>

	* tests/ldap_test.py (Tests.testUserLookupId)
	(Tests.testGroupLookupId): Test large ID values.
	(Tests.testUserAdd4, Tests.testUserMod3, Tests.testGroupAdd3)
	(Tests.testGroupMod3): New tests.

	* apps/lusermod.c (main): Fix user renaming in groups where the
	user is a member or administrator.

	* python/ent.c (libuser_convert_to_value): Handle whole id_t
	range.
	
	* python/ent.c (libuser_convert_to_value): Report Python exception
	instead of aborting.  Return success/failure status.
	(libuser_entity_setattr, libuser_entity_add, libuser_entity_set)
	(libuser_entity_set_item): Handle errors reported by
	libuser_convert_to_value().

	* python/ent.c (convert_value_array_pylist): Handle G_TYPE_INT64.

	* python/admin.c (lubser_admin_lookup_user_id)
	(libuser_admin_lookup_group_id, libuser_admin_create_home) 
	(libuser_admin_get_first_unused_id_type): Handle whole uid_t/gid_t
	range.

2004-11-08  Miloslav Trmac  <mitr@redhat.com>

	* lib/user.c (lu_default_int): Use id_t.

	* lib/user.c (lu_get_first_unused_id): Change the interface to use
	id_t.  Don't allow (id_t)-1.
	* lib/user_private.h: Update prototype.

	* modules/files.c (format_passwd, format_group): Use
	G_TYPE_INVALID for id_t.
	(parse_field): Handle G_TYPE_INVALID.

	* modules/files.c (parse_field): New function, split from
	parse_generic ().  Don't interpret input as octal or hexadecimal
	numbers.
	(parse_generic): Use parse_field ().

	* modules/ldap.c (lu_ldap_lookup): Convert id_t values to numbers,
	not strings.  Don't interpret input as octal or hexadecimal
	numbers.

	* samples/lookup.c (main): Handle whole id_t range.

	* lib/user.c (lu_default_int): Convert id_t values to numbers, not
	strings.  Don't interpret input as octal or hexadecimal numbers.

	* lub/user.c (lu_default_int): Handle whole range of uid_t/gid_t in
	'%u' substitution.

	* lib/user.c (lu_default_int): Remove copy-and-pasted usage of
	idkeystring as a generic fallback.

	* lib/user.c (lu_default_int): Handle whole ID range.

	* lib/user.c (compare_strings): Replace compare_ints ().
	(merge_ent_array_duplicates): Use lu_value_strdup () instead of
	poking in GValues.

	* modules/ldap.c (value_compare): Removed function.
	
	* lib/entity.c (lu_ent_add_int)
	* lib/user.c (remove_duplicate_values)
	* modules/ldap.c (arrays_equal, get_ent_mods): Use lu_values_equal ().

	* lib/misc.c (lu_values_equal): New function.
	* lib/user.h: Add declaration.

	* apps/lgroupmod.c (main)
	* apps/lgroupadd.c (main)
	* apps/luseradd.c (main)
	* apps/lusermod.c (main): Handle whole gid_t/uid_t range for
	'--gid' and '--uid', respectively.

2004-11-07  Miloslav Trmac  <mitr@redhat.com>

	* apps/apputil.h (INVALID): Removed definition.

	* apps/apputil.c (lu_mailspool_create_remove)
	* apps/lgroupadd.c (main)
	* apps/lgroupmod.c (main)
	* apps/lnewusers.c (main)
	* apps/luseradd.c (main)
	* apps/lusermod.c (main): Use LU_VALUE_INVALID_ID to indicate unknown
	value.

	* lib/user.c (INVALID): Removed definition.
	(extract_id, convert_user_name_to_id, convert_group_name_to_id):
	Return LU_VALUE_INVALID_ID on failure.  All callers changed.
	(lu_dispatch): Use LU_VALUE_INVALID_ID to indicate unknown value.
	All callers changed.

	* samples/testuser.c (dump_attribute): Handle G_TYPE_INT64.

	* modules/ldap.c (lu_ldap_user_lookup_id): Handle whole uid_t range.
	(lu_ldap_group_lookup_id, lu_ldap_users_enumerate_by_group): Handle
	whole gid_t range.

	* modules/files.c (lu_files_user_lookup_id)
	(lu_shadow_user_lookup_id): Handle whole uid_t range.
	(lu_files_group_lookup_id, lu_shadow_group_lookup_id)
	(lu_files_users_enumerate_by_group): Handle whole gid_t range.

	* lib/user.c (run_single, run_list): Use id_t for ldata.  All callers
	changed.
	(convert_user_name_to_id): Return uid_t.
	(convert_group_name_to_id): Return gid_t.

	* lib/entity.c (lu_ent_dump): Handle G_TYPE_INT64.

	* apps/luserdel.c (main): Handle whole gid_t range.

	* apps/luseradd.c (main): Handle whole gid_t range.

	* apps/lnewusers.c (main): Handle whole uid_t/gid_t range, don't ignore
	invalid values.

	* apps/lchage.c (read_ndays): Handle G_TYPE_INT64.

	* apps/apputil.c (lu_mailspool_create_remove)
	* apps/lgroupmod.c (main)
	* apps/lnewusers.c (main)
	* apps/luseradd.c (main)
	* apps/luserdel.c (main)
	* modules/ldap.c (lu_ldap_groups_enumerate_by_user): Use
	lu_value_get_id ().

	* docs/reference/tmpl/value.sgml: New file.

	* lib/misc.c (lu_value_get_id): New function.
	* lib/user.h: Add declaration.
	(LU_VALUE_INVALID_ID): New macro.

	* apps/lgroupadd.c (main)
	* apps/lgroupmod.c (main)
	* apps/lnewusers.c (main)
	* apps/luseradd.c (main)
	* apps/lusermod.c (main)
	* lib/user.c (lu_default_int): Use lu_value_init_set_id ().
	
	* lib/misc.c (lu_value_init_set_id): New function.
	* lib/user.h: Add declaration.
	* lib/misc.c (lu_value_strdup): Handle G_TYPE_INT64.

	* lib/misc.c (lu_strdup_value): Rename to lu_value_strdup (). All
	callers changed.
	* lib/user.h: Rename declaration.

	* apps/lchage.c (read_ndays)
	* apps/lnewusers.c (main)
	* apps/luseradd.c (main)
	* lib/user.c (lu_default_int)
	* modules/files.c (parse_generic)
	* modules/ldap.c (lu_ldap_lookup) 
	(lu_ldap_groups_enumerate_by_user): Properly check strtol () for error.

2004-11-05  Miloslav Trmac  <mitr@redhat.com>


	* modules/files.c (generic_lock, generic_is_locked, generic_setpass)
	* apps/lchfn.c (main): Use lu_strdup_value ().

	* modules/files.c (generic_is_locked): Fix memory leak.

2004-11-04  Miloslav Trmac  <mitr@redhat.com>

	* modules/ldap.c (get_ent_adds, get_ent_mods, lu_ldap_set) 
	(lu_ldap_del, lu_ldap_handle_lock, lu_ldap_is_locked) 
	(lu_ldap_setpass): Use lu_strdup_value () instead of
	value_as_string ().
	(value_as_string): Removed function.

	* modules/sasldb.c (lu_sasldb_user_munge, lu_sasldb_user_is_locked): 
	Use lu_strdup_value ().

2004-11-03  Miloslav Trmac  <mitr@redhat.com>

	* apps/apputil.c (lu_mailspool_create_remove)
	* apps/lchfn.c (main)
	* apps/lchsh.c (main)
	* apps/lid.c (main)
	* modules/files.c (lu_shadow_user_lookup_id, lu_shadow_group_lookup_id)
	(format_generic, generic_mod, generic_del): Use lu_strdup_value ().

	* lib/misc.c (lu_strdup_value): New function.
	* lib/user.h: Add declaration.
	* docs/reference/tmpl/entity.sgml
	* docs/reference/libuser-sections.txt: Document lu_strdup_value ().

2004-11-02  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.52.6.

	* NEWS: Update.

2004-11-01  Miloslav Trmac  <mitr@redhat.com>

	* modules/sasldb.c (lu_sasldb_user_lookup_name, lu_sasldb_user_munge)
	(lu_sasldb_user_is_locked): Remove assertions on possible error codes,
	undocumented codes happen too.

	* modules/sasldb.c (libuser_sasldb_init): Fix self-describing module
	name.

	* modules/sasldb.c (lu_sasldb_user_removepass) 
	(lu_sasldb_group_removepass): New functions
	(libuser_sasldb_init): Set the user_removepass and group_removepass
	handlers.

	* lib/modules.c (lu_modules_load): Don't close a NULL handle.

	* modules/sasldb.c (lu_sasldb_user_add): Return TRUE on success.

	* configure.in
	* modules/sasldb.c (lu_sasldb_user_lookup_name, lu_sasldb_user_munge)
	(libuser_sasldb_init): Use Cyrus SASL v2.

	* modules/ldap.c (bind_server): Don't attempt to bind using NULL bind
	DN.

	* modules/ldap.c (bind_server): Report at least the first encountered
	bind error.

2004-10-30  Miloslav Trmac  <mitr@redhat.com>

	* apps/lchfn.c (main)
	* apps/lchsh.c (main)
	* apps/lnewusers.c (main)
	* samples/enum.c (main)
	* samples/testuser.c (main): Output error messages on stderr.
	
	* apps/lchfn.c (main): Exit if specified user does not exist.

	* apps/lnewusers.c (main): Don't attempt to act on improperly formatted
	lines.

	* po/POTFILES.in: Add missing files.

	* modules/ldap.c (lu_ldap_set, lu_ldap_del): Remove superfluous '\n'
	and '.\n' at message ends.

	* apps/lgroupadd.c (main)
	* apps/lgroupdel.c (main)
	* apps/lgroupmod.c (main)
	* apps/lchage.c (main)
	* apps/lchfn.c (main)
	* apps/lchsh.c (main)
	* apps/lid.c (main)
	* apps/lnewusers.c (main)
	* apps/luseradd.c (main)
	* apps/luserdel.c (main)
	* apps/lusermod.c (main)
	* python/admin.c (libuser_admin_do_wrap, libuser_admin_setpass):
	* samples/enum.c (main): 
	* samples/homedir.c (main): 
	* samples/lookup.c (main): 
	* samples/testuser.c (main): Use lu_strerror () instead of
	(error ? error->string : _("unknown error")).  Report error cause in
	more error messages.

	* apps/lchsh.c (main): Report error if shell was not changed.

	* modules/ldap.c (lu_ldap_set, lu_ldap_handle_lock) 
	(lu_ldap_setpass)
	* modules/files.c (set_default_context, reset_default_context) 
	(generic_setpass)
	* lib/config.c (lu_cfg_init)
	* apps/apputil.c (lu_authenticate_unprivileged): Mark strings for
	translation.

	* lib/util.c (lu_util_line_get_matchingx): Fix memory leak.

2004-10-14  Miloslav Trmac  <mitr@redhat.com>

	* lib/error.h (LU_ERROR_CHECK): Add missing '\n'.

2004-10-11  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.52.5.

	* NEWS: Update.

	* python/admin.c (libuser_admin_add_user)
	(libuser_admin_modify_user)
	(libuser_admin_delete_user): Fix memory leak.

	* python/admin.c (libuser_admin_add_user)
	(libuser_admin_delete_user): Fix reference counting.

	* python/modules.txt: Fix modifyUser documentation about not creating
	home directory by default.

	* python/admin.c (libuser_admin_modify_user): Pass original entity
	to libuser_admin_move_home().

2004-10-10  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.52.4.

	* NEWS: Update.

	* python/misc.c (libuser_prompt_destroy): Fix memory leak.
	(libuser_admin_python_prompter): Properly copy struct libuser_prompt
	to avoid double free().

	* python/admin.c (libuser_admin_enumerate_users) 
	(libuser_admin_enumerate_groups) 
	(libuser_admin_enumerate_users_by_group) 
	(libuser_admin_enumerate_groups_by_user): Fix memory leaks.

	* python/admin.c (libuser_admin_enumerate_users_full)
	(libuser_admin_enumerate_groups_full) 
	(libuser_admin_enumerate_users_by_group_full) 
	(libuser_admin_enumerate_groups_by_user_full)
	* python/ent.c (convert_value_array_pylist) 
	(libuser_entity_getattrlist): 
	* python/libusermodule.c (libuser_get_user_shells): 
	* python/misc.c (libuser_admin_python_prompter): Fix memory leaks.

2004-10-09  Miloslav Trmac  <mitr@redhat.com>

	* lib/entity.c (lu_ent_free): Fix memory leak.

	* modules/files.c (generic_add): Fix memory leak.

	* lib/user.c (merge_ent_array_duplicates): Remove fflush (from
	debugging?).

	* modules/files.c (lu_files_enumerate_full): Fix memory leak.

2004-09-29  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.52.3.

	* NEWS: Update.

	* Makefile.am: Readd -D_LIBUSER_MODULE for modules.

2004-09-28  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.52.2.

	* NEWS: Update.

	* modules/ldap.c (lu_ldap_set): Beautify debug messages.

	* modules/ldap.c (connect_server): Allow ldap URIs, don't require TLS
	for servers specified by URIs.
	* docs/sgml/libuser.sgml: Document URI support.

2004-09-27  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.52.1.

	* NEWS: Update.

	* modules/files.c (set_default_context): Make sure *prev_context is
	always initialized.

2004-09-27  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.52.

	* autogen.sh: Create the `admin' subdirectory if needed.

	* Makefile.am (CVSTAG): Fix definition.

	* Makefile.am (archive): Ship with formatted documentation.

	* configure.in: Define AC_CONFIG_AUX_DIR.

	* configure.in: Remove various unneeded parts.

	* configure.in, Makefile.am: Use automake conditionals instead of
	MODULES.
	* Makefile.am (TESTS): Define only if LDAP.

	* Makefile.am: Use AM_CPPFLAGS to eliminate the most redundant lines.

	* Makefile.am (uninstall-local): Fix typo.

	* Makefile.am: Link exactly with needed libraries.

	* docs/sgml/Makefile.am: Merge with docs/Makefile.am.

	* Makefile.am (CVSTAG): Define portably.

	* configure.in: Use new-style AC_INIT and AM_INIT_AUTOMAKE.
	Set automake options `subdir-objects' and `-Wall'.

	* modules/ldap.c (lu_ldap_lookup): Silence gcc warning.

	* apps/Makefile.am, lib/Makefile.am, modules/Makefile.am,
	samples/Makefile.am: Merge with top-level Makefile.am.
	* apps/lchage.c, apps/lchfn.c, apps/lgroupadd.c, apps/lgroupdel.c,
	apps/lgroupmod.c, apps/lid.c, apps/lnewusers.c, apps/lpasswd.c,
	apps/luseradd.c, apps/luserdel.c, apps/lusermod.c, samples/enum.c,
	python/admin.c, python/ent.c, python/misc.c, python/libusermodule.c,
	python/quotamodule.c, samples/field.c, samples/homedir.c,
	samples/lookup.c, samples/quotaq.c, samples/prompt.c,
	samples/testuser.c: Change path of config.h.

	* NEWS: Update.

	* tests/ldap_test.py (Tests.testUserDel, Tests.testUserLock1)
	(Tests.testUserLock2, Tests.testUserUnlock1)
	(Tests.testUserUnlock2, Tests.testUserIslocked1)
	(Tests.testUserIslocked2, Tests.testUserSetpass1)
	(Tests.testUserSetpass2, Tests.testUserSetpass3)
	(Tests.testUserRemovepass1, Tests.testUserRemovepass2)
	(Tests.testUserRemovepass3, Tests.testUsersEnumerate)
	(Tests.testUsersEnumerateByGroup1)
	(Tests.testUsersEnumerateByGroup2)
	(Tests.testUsersEnumerateByGroup3, Tests.testUsersEnumerateFull)
	(Tests.testGroupLookupName, Tests.testGroupLookupId)
	(Tests.testGroupAdd1, Tests.testGroupAdd2, Tests.testGroupMod1)
	(Tests.testGroupMod2, Tests.testGroupDel, Tests.testGroupLock1)
	(Tests.testGroupLock2, Tests.testGroupUnlock1)
	(Tests.testGroupUnlock2, Tests.testGroupIsLocked1)
	(Tests.testGroupIsLocked2, Tests.testGroupSetpass1)
	(Tests.testGroupSetpass2, Tests.testGroupSetpass3)
	(Tests.testGroupRemovepass1, Tests.testGroupRemovepass2)
	(Tests.testGroupRemovepass3, Tests.testGroupsEnumerate)
	(Tests.testGroupsEnumerateByUser1)
	(Tests.testGroupsEnumerateByUser2)
	(Tests.testGroupsEnumerateByUser3, Tests.testGroupsEnumerateFull):
	New tests.

	* tests/ldap_test.py (Tests.testUserAdd2, Tests.testUserMod2): Update
	for final password entity model.

	* modules/ldap.c (lu_ldap_is_locked): Remove unneeded parameter `type'.
	All callers changed.

	* tests/ldap_test: Clean up after running the tests.

	* tests/ldap_test.py: Workaround openssl's inability to handle
	repeated library loading and unloading.

	* modules/ldap.c (lu_ldap_groups_enumerate_by_user): Don't consider
	all string representations of numbers invalid.
	(lu_ldap_groups_enumerate_by_user): Don't free data owned by the
	entity.

	* lib/user.c (run_single): Don't run user_removepass when
	group_removepass is wanted.

	* modules/ldap.c (lu_ldap_group_removepass): Implement.

	* modules/ldap.c (lu_ldap_is_locked): Use LU_GROUPPASSWORD and
	POSIXGROUP for groups.

	* modules/ldap.c (lu_ldap_setpass): Don't attempt to remove the
	attribute if it does not exist.
	(lu_ldap_setpass): Use LU_GROUPPASSWORD for groups.

	* modules/ldap.c (lu_ldap_handle_lock): Use LU_GROUPPASSWORD for
	groups.

	* modules/ldap.c (ldap_attribute_map): Remove LU_SHADOWPASSWORD.
	(get_ent_adds): Skip LU_SHADOWPASSWORD.  It should be completely
	ignored now.

	* python/libusermodule.c (initlibuser): Fix libuser.GROUPPASSWORD.

2004-09-26  Miloslav Trmac  <mitr@redhat.com>

	* lib/user.c (lu_end): Fix memory leak.

	* modules/ldap.c (lu_ldap_ent_to_dn): Remove parameter `applicability'.
	All callers changed.

	* modules/ldap.c (lu_ldap_fudge_objectclasses): Use the mod_values
	macro.
	(ldap_attribute_map): Make members point to constant strings.
	Casts added to users where needed.
	(lu_ldap_user_attributes, lu_ldap_group_attributes): Make it a constant
	array of constant strings.
	(libuser_ldap_init): Store converted pointers to data that will be
	eventually freed as part of the context.
	(lu_ldap_lookup): Use mapped_user_attributes, mapped_group_attributes.
	(map_from_ldap): Remove.
	(lu_ldap_close_module): Free mapped_user_attributes, 
	mapped_group_attributes.

2004-09-25  Miloslav Trmac  <mitr@redhat.com>

	* modules/ldap.c (lu_ldap_needed_objectclasses): s/User/Entity/g
	(lu_ldap_needed_objectclasses): Fix debugging printout.
	(lu_ldap_needed_objectclasses): Ignore attributes not applicable to
	given entity type.

	* modules/ldap.c (ldap_attribute_map): Remove mapping for 
	LU_ADMINISTRATORNAME.
	(SHADOWGROUP): Remove.

	* python/admin.c (libuser_admin_removepass_user) 
	(libuser_admin_removepass_group): Throw exception on error.

	* modules/ldap.c (lu_ldap_user_removepass): Implement.

	* modules/ldap.c (lu_ldap_is_locked): Fix memory leak.
	(lu_ldap_is_locked): Map libuser attribute names to LDAP names.

	* modules/ldap.c (lu_ldap_setpass): Initialize addvalues[0] and
	rmvalues[0] even if the original password is already encrypted.
	(lu_ldap_setpass): Map libuser attribute names to LDAP names.
	(lu_ldap_setpass): Remove (maybe all) values before adding new values.
	(lu_ldap_setpass): Fix memory leak.

	* modules/ldap.c (lu_ldap_handle_lock): Don't skip LU_CRYPTED twice.
	(lu_ldap_handle_lock): Fix memory leaks.
	(lu_ldap_handle_lock): Don't remove and add the same value.
	(lu_ldap_handle_lock): Avoid unnecessary g_malloc0()/g_free() pair.
	(lu_ldap_handle_lock): Don't drop LU_CRYPTED when unlocking unlocked
	account.
	(lu_ldap_handle_lock): Don't lock locked accounts again.

	* modules/ldap.c (lu_ldap_user_attributes): Drop LU_SHADOWPASSWORD.
	(get_ent_adds): Drop LU_SHADOWPASSWORD, not LU_USERPASSWORD.

	* modules/ldap.c (lu_ldap_set): Remove parameter `attributes'.  All
	callers changed.

2004-09-24  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.51.12.

	* Makefile.am: Remove the spec file and "release" tagging from CVS,
	rework the spec file a bit.

	* configure.in: Don't create libuser.spec.
	* NEWS: Move data from libuser.spec.in.
	* libuser.spec.in: Remove.
	
	* tests/ldap.conf.in, tests/ldaprc, tests/ldap_skel.ldif,
	tests/ldap_test.py, tests/slapd.conf.in: New files
	* Makefile.am (TESTS, EXTRA_DIST): Use and distribute tests.

	* python/ent.c (libuser_entity_set): Don't both return success and
	indicate error at the same time.

	* python/ent.c (libuser_entity_set_item): Don't clear the entity
	if the new value has invalid type.

	* modules/files.c (generic_lookup): Fix memory leak.
	* python/ent.c (libuser_convert_to_value): Fix memory leak.

 	* modules/ldap.c (get_ent_mods, lu_ldap_set): Special-case entry
	renaming.
	(lu_ldap_set): Fix desired RDN computation in rename.

	* modules/ldap.c (lu_ldap_set): Use the original name when
	looking up the DN of an entry that is being renamed.

2004-09-23  Miloslav Trmac  <mitr@redhat.com>

	* configure.in: Version 0.51.11.

	* libuser.conf.in: Avoid mentioning /usr/lib* in config file.

2004-09-21  Miloslav Trmac  <mitr@redhat.com>

	* modules/ldap.c (lu_ldap_set): New parameter `add'.  All callers
	changed.

	* modules/ldap.c (get_ent_mods): Simplify somewhat.

	* modules/ldap.c (objectclass_present, lu_ldap_needed_objectclasses)
	(get_ent_adds): Split and customize/fix from
	lu_ldap_fudge_objectclasses ().
	(lu_ldap_fudge_objectclasses): Use lu_ldap_needed_objectclasses ().

	* modules/ldap.c (ACCOUNT): New macro.
	(SHADOWACCOUNT): Define as "shadowAccount" again.

	* modules/ldap.c (ldap_attribute_map): Remove unused member
	`ldap_attribute_key'.

	* modules/ldap.c (lu_ldap_user_lookup_name, lu_ldap_user_lookup_id):
	Add LU_LDAP_SHADOW to `applicability' argument.

	* python/libusermodule.c (initlibuser): Add missing attribute names.

2004-09-19  Miloslav Trmac  <mitr@redhat.com>

	* python/admin.c (libuser_admin_setattr): Fix reference counting.

2004-09-18  Miloslav Trmac  <mitr@redhat.com>

	* python/misc.c (libuser_admin_python_prompter, libuser_admin_prompt):
	Fix reference counting.

	* modules/ldap.c (libuser_ldap_init): Don't set error when it was
	already set.

2004-09-17  Miloslav Trmac  <mitr@redhat.com>

	* modules/ldap.c (value_compare): Make sense of comparison same for 
	longs and strings.

	* modules/ldap.c (lu_ldap_ent_to_dn, libuser_ldap_init):
	Fix memory leaks.

	* modules/ldap.c (libuser_ldap_init, bind_server): Respect bind_simple
	and bind_sasl.

2004-09-20  Miloslav Trmac  <mitr@redhat.com>

	* apps/lchfn.1, apps/lchsh.1: New files.
	* apps/Makefile.am (dist_man_MANS): Distribute new man pages.