Don't allow two @ signs in a principal..
authorTheodore Tso <tytso@mit.edu>
Thu, 2 Jun 1994 17:00:17 +0000 (17:00 +0000)
committerTheodore Tso <tytso@mit.edu>
Thu, 2 Jun 1994 17:00:17 +0000 (17:00 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@3678 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/krb5/krb/parse.c

index c8d6eb8a9a8eaa14a06c071a7143898fa29df869..4d3fe143ac887987be0eb11045435045a7539458 100644 (file)
@@ -116,9 +116,10 @@ krb5_parse_name(name, nprincipal)
                        size = 0;
                        i++;
                } else if (c == REALM_SEP) {
-                       if (!*(cp+1)) 
+                       if (parsed_realm || !*(cp+1)) 
                                /*
-                                * Null Realm names are not allowed!
+                                * Multiple realm separaters or null
+                                * realm names are not allowed!
                                 */
                                return(KRB5_PARSE_MALFORMED);
                        parsed_realm = cp+1;