X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?p=netatalk.git;a=blobdiff_plain;f=etc%2Fuams%2Fuams_dhx2_pam.c;h=f862ace13b4be95d7d4d6caace659229cba26d52;hp=713a3a630cde526b2d1eda705f013b269e8ba1e9;hb=9541a37c1ed5ec0fa6b537fd614616ba690dcb7e;hpb=4d67a2836a6b8cc4077001a69ec266833b2fa530 diff --git a/etc/uams/uams_dhx2_pam.c b/etc/uams/uams_dhx2_pam.c index 713a3a63..f862ace1 100644 --- a/etc/uams/uams_dhx2_pam.c +++ b/etc/uams/uams_dhx2_pam.c @@ -1,5 +1,5 @@ /* - * $Id: uams_dhx2_pam.c,v 1.5.2.2 2008-12-02 03:11:59 didg Exp $ + * $Id: uams_dhx2_pam.c,v 1.5.2.3 2009-01-15 03:58:05 didg Exp $ * * Copyright (c) 1990,1993 Regents of The University of Michigan. * Copyright (c) 1999 Adrian Sun (asun@u.washington.edu) @@ -573,9 +573,9 @@ static int logincont2(void *obj, struct passwd **uam_pwd, *rbuflen = 0; - /* Packet size should be: Session ID + ServerNonce + Passwd buffer */ - if (ibuflen != 2 + 16 + 256) { - LOG(log_error, logtype_uams, "DHX2: Paket length not correct"); + /* Packet size should be: Session ID + ServerNonce + Passwd buffer (evantually +10 extra bytes, see Apples Docs) */ + if ((ibuflen != 2 + 16 + 256) && (ibuflen != 2 + 16 + 256 + 10)) { + LOG(log_error, logtype_uams, "DHX2: Paket length not correct: %d. Should be 274 or 284.", ibuflen); ret = AFPERR_PARAM; goto error_noctx; }