[2523] in Kerberos_V5_Development
Should realm's be NULL terminated...
daemon@ATHENA.MIT.EDU (epeisach@MIT.EDU)
Mon Oct 6 12:18:59 1997
From: <epeisach@MIT.EDU>
Date: Mon, 6 Oct 1997 12:16:05 -0400
To: krbdev@MIT.EDU
If I am reading the code correctly, most of the realm parsing code in
the krb5 library allocate space for a NULL after the realm string, but
set the length not to include that null.
Is this what is desired? Does anything make assumptions about this?
The reason I as is that in set_realm.c, the realm is set using strcpy
into space malloced as strlen(string) - i.e. off by one.
Should I allocate one more byte, or use memcpy?
Personally, I believe memcpy would be the proper fix...
Ezra