auth: Move <NoAuth> to a named constant

Add a #define for "<NoAuth>" and related values. Use them.

Change-Id: I0e1d374403a0ad20be6a2839e37a5894b15446cd
Reviewed-on: http://gerrit.openafs.org/3482
Reviewed-by: Simon Wilkinson <sxw@inf.ed.ac.uk>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
This commit is contained in:
Andrew Deason 2010-12-07 16:04:11 -06:00 committed by Derrick Brashear
parent 3fd789dfbd
commit c1b71c4e7b

View File

@ -48,6 +48,9 @@
#include "keys.h"
#include "afs/audit.h"
#define AFS_NOAUTH_NAME "<NoAuth>"
#define AFS_NOAUTH_LEN (sizeof(AFS_NOAUTH_NAME)-1)
static int ParseLine(char *buffer, struct rx_identity *user);
static void
@ -744,7 +747,8 @@ afsconf_SuperIdentity(struct afsconf_dir *adir, struct rx_call *acall,
if (afsconf_GetNoAuthFlag(adir)) {
if (identity)
*identity = rx_identity_new(RX_ID_KRB4, "<NoAuth>", "<NoAuth>", 8);
*identity = rx_identity_new(RX_ID_KRB4, AFS_NOAUTH_NAME,
AFS_NOAUTH_NAME, AFS_NOAUTH_LEN);
UNLOCK_GLOBAL_MUTEX;
return 1;
}