Thomas E. Knowles wrote:>
> I've just started using 1.9.18p4 and have gotten the NT password
changing
> working great except for one problem. When I try to change a password on a
PDC
> that's on a different subnet (and hence a different domain), I get the
following
> error:
>
> /var/local/etc/samba/etc/smbpasswd: machine pdom1 rejected the password
change:
> Error was : code 2245
>
> I know what errors 2243 and 2246 mean but what about 2245?
>
Ok - grubbing aound in lmerr.h on my NT development system
I get :
#define NERR_BASE 2100
#define NERR_PasswordTooShort (NERR_BASE+145) /* The password is
shorter than required. */
So "password too short" is what that one means :-).
I put the password change errors specified in the CIFS
spec coded into smbpasswd.c, but I should have remembered
that the CIFS spec is a poor document of fiction -
the NT code is the *real* CIFS spec (except when
Win95 conflicts :-).
I will add all the error codes to do with password
changing into the smbpasswd.c file and give out a
diff, they'll all be in the next Samba release.
FYI: They are :
2242 - The password of this user has expired.
2243 - The password of this user cannot change.
2244 - This password cannot be used now (password history conflict).
2245 - The password is shorter than required.
2246 - The password of this user is too recent to change.
Here's the context diff for 1.9.18p4 to get all these
error messages in :
------------------cut here----------------------
Index: smbpasswd.c
==================================================================RCS file:
/data/cvs/samba/source/smbpasswd.c,v
retrieving revision 1.20.4.5
diff -w -b -c -r1.20.4.5 smbpasswd.c
*** smbpasswd.c 1998/03/26 18:59:00 1.20.4.5
--- smbpasswd.c 1998/03/30 20:07:27
***************
*** 32,39 ****
{5, "User has insufficient privilege" },
{86, "The specified password is invalid" },
{2226, "Operation only permitted on a Primary Domain Controller"
},
! {2243, "The password cannot be changed" },
! {2246, "The password is too short" },
{0, NULL}
};
--- 32,42 ----
{5, "User has insufficient privilege" },
{86, "The specified password is invalid" },
{2226, "Operation only permitted on a Primary Domain Controller"
},
! {2242, "The password of this user has expired." },
! {2243, "The password of this user cannot change." },
! {2244, "This password cannot be used now (password history
conflict)." },
! {2245, "The password is shorter than required." },
! {2246, "The password of this user is too recent to change."},
{0, NULL}
};
------------------end diff----------------------
Cheers,
Jeremy Allison,
Samba Team.
--
--------------------------------------------------------
Buying an operating system without source is like buying
a self-assembly Space Shuttle with no instructions.
--------------------------------------------------------