]> git.ipfire.org Git - thirdparty/krb5.git/commitdiff
* mk_cred.c (mk_cred()), mk_priv.c (mk_priv()), mk_safe.c (mk_safe()),
authorChris Provenzano <proven@mit.edu>
Tue, 2 May 1995 23:31:45 +0000 (23:31 +0000)
committerChris Provenzano <proven@mit.edu>
Tue, 2 May 1995 23:31:45 +0000 (23:31 +0000)
* rd_cred.c (rd_cred()), rd_priv.c (rd_priv()), rd_safe.c (rd_safe()):
Don't call krb5_make_fulladdrs() if a port isn't specified.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5684 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/krb5/krb/ChangeLog
src/lib/krb5/krb/mk_cred.c
src/lib/krb5/krb/mk_priv.c
src/lib/krb5/krb/mk_safe.c
src/lib/krb5/krb/rd_cred.c
src/lib/krb5/krb/rd_priv.c
src/lib/krb5/krb/rd_safe.c

index b800ef32cd9febe6aca20ae4067d38aa62cd5019..f0ec2d2184489e73be98ee7922068af5c5574d24 100644 (file)
@@ -1,3 +1,10 @@
+
+Tue May 02 19:29:18 1995  Chris Provenzano (proven@mit.edu)
+
+        * mk_cred.c (mk_cred()), mk_priv.c (mk_priv()), mk_safe.c (mk_safe()),
+       * rd_cred.c (rd_cred()), rd_priv.c (rd_priv()), rd_safe.c (rd_safe()):
+               Don't call krb5_make_fulladdrs() if a port isn't specified.
+
 Mon May 01 15:56:32 1995  Chris Provenzano (proven@mit.edu)
 
         * auth_con.c (krb5_auth_con_free()) :
index 3970ddb5e018ff32680fd042db88f669f5171cb6..44b6879a39f30f84690a9b028e9c26b990553fb9 100644 (file)
@@ -8,6 +8,11 @@
  *
  * MODIFIED
  * $Log$
+ * Revision 5.11  1995/05/02 23:31:39  proven
+ *         * mk_cred.c (mk_cred()), mk_priv.c (mk_priv()), mk_safe.c (mk_safe()),
+ *     * rd_cred.c (rd_cred()), rd_priv.c (rd_priv()), rd_safe.c (rd_safe()):
+ *             Don't call krb5_make_fulladdrs() if a port isn't specified.
+ *
  * Revision 5.10  1995/05/01 20:49:45  proven
  *         * auth_con.c (krb5_auth_con_free()) :
  *             Free all the data associated with the auth_context.
@@ -309,23 +314,33 @@ krb5_mk_ncred(context, auth_context, ppcreds, ppdata, outdata)
     CLEANUP_INIT(2);
 
     if (auth_context->local_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
-                                 auth_context->local_port, &local_fulladdr))) {
-            CLEANUP_PUSH(&local_fulladdr.contents, free);
-           plocal_fulladdr = &local_fulladdr;
-        } else {
-            goto error;
+       if (auth_context->local_port) {
+            if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
+                                             auth_context->local_port, 
+                                             &local_fulladdr))) {
+               CLEANUP_PUSH(&local_fulladdr.contents, free);
+               plocal_fulladdr = &local_fulladdr;
+            } else {
+                goto error;
+            }
+       } else {
+            plocal_fulladdr = auth_context->local_addr;
         }
     }
 
     if (auth_context->remote_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->remote_addr,
-                                 auth_context->remote_port, &remote_fulladdr))){
-            CLEANUP_PUSH(&remote_fulladdr.contents, free);
-           premote_fulladdr = &remote_fulladdr;
-        } else {
-            CLEANUP_DONE();
-            goto error;
+       if (auth_context->remote_port) {
+            if (!(retval = krb5_make_fulladdr(context,auth_context->remote_addr,
+                                             auth_context->remote_port, 
+                                             &remote_fulladdr))){
+                CLEANUP_PUSH(&remote_fulladdr.contents, free);
+               premote_fulladdr = &remote_fulladdr;
+            } else {
+                CLEANUP_DONE();
+                goto error;
+            }
+       } else {
+            premote_fulladdr = auth_context->remote_addr;
         }
     }
 
index 0036447685b2807b4a525a2a04630e8647848cb5..fe309399b5bbd8ae60faa61be5cb291bbae0359b 100644 (file)
@@ -193,23 +193,33 @@ krb5_mk_priv(context, auth_context, userdata, outbuf, outdata)
     CLEANUP_INIT(2);
 
     if (auth_context->local_addr) {
-       if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
-                                auth_context->local_port, &local_fulladdr))){
-           CLEANUP_PUSH(&local_fulladdr.contents, free);
-           plocal_fulladdr = &local_fulladdr;
-        } else {
-           goto error;
-        }
+       if (auth_context->local_port) {
+           if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
+                                             auth_context->local_port, 
+                                             &local_fulladdr))) {
+               CLEANUP_PUSH(&local_fulladdr.contents, free);
+               plocal_fulladdr = &local_fulladdr;
+            } else {
+               goto error;
+            }
+       } else {
+           plocal_fulladdr = auth_context->local_addr;
+       }
     }
 
     if (auth_context->remote_addr) {
-       if (!(retval = krb5_make_fulladdr(context, auth_context->remote_addr,
-                                auth_context->remote_port, &remote_fulladdr))){
-           CLEANUP_PUSH(&remote_fulladdr.contents, free);
-           premote_fulladdr = &remote_fulladdr;
-       } else {
-           CLEANUP_DONE();
-           goto error;
+       if (auth_context->remote_addr) {
+           if (!(retval = krb5_make_fulladdr(context,auth_context->remote_addr,
+                                             auth_context->remote_port, 
+                                             &remote_fulladdr))){
+               CLEANUP_PUSH(&remote_fulladdr.contents, free);
+               premote_fulladdr = &remote_fulladdr;
+           } else {
+               CLEANUP_DONE();
+               goto error;
+           }
+       } else {
+           premote_fulladdr = auth_context->remote_addr;
        }
     }
 
index 06c002209d1c0b4dddcd41411fce38995d08258c..53817fa7c991c9fa760bf4356d35df56be8f3c91 100644 (file)
@@ -176,23 +176,34 @@ krb5_mk_safe(context, auth_context, userdata, outbuf, outdata)
     CLEANUP_INIT(2);
 
     if (auth_context->local_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
-                                 auth_context->local_port, &local_fulladdr))){
-            CLEANUP_PUSH(&local_fulladdr.contents, free);
-           plocal_fulladdr = &local_fulladdr;
-        } else {
-            goto error;
+       if (auth_context->local_port) {
+            if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
+                                             auth_context->local_port, 
+                                             &local_fulladdr))){
+               CLEANUP_PUSH(&local_fulladdr.contents, free);
+               plocal_fulladdr = &local_fulladdr;
+            } else {
+                goto error;
+            }
+       } else {
+            plocal_fulladdr = auth_context->local_addr;
         }
+
     }
 
     if (auth_context->remote_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->remote_addr,
-                                 auth_context->remote_port, &remote_fulladdr))){
-            CLEANUP_PUSH(&remote_fulladdr.contents, free);
-           premote_fulladdr = &remote_fulladdr;
-        } else {
-            CLEANUP_DONE();
-            goto error;
+       if (auth_context->remote_port) {
+            if (!(retval = krb5_make_fulladdr(context,auth_context->remote_addr,
+                                             auth_context->remote_port, 
+                                             &remote_fulladdr))){
+               CLEANUP_PUSH(&remote_fulladdr.contents, free);
+               premote_fulladdr = &remote_fulladdr;
+            } else {
+                CLEANUP_DONE();
+                goto error;
+            }
+       } else {
+            premote_fulladdr = auth_context->remote_addr;
         }
     }
 
index 8e18a30a2ffc6f000e40ec9872193ca39ee1f619..7987ba460122b1321a571f34d23058f96dd2bb8e 100644 (file)
@@ -241,23 +241,32 @@ krb5_rd_cred(context, auth_context, pcreddata, pppcreds, outdata)
     CLEANUP_INIT(2);
 
     if (auth_context->local_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
-                                 auth_context->local_port, &local_fulladdr))){
-            CLEANUP_PUSH(&local_fulladdr.contents, free);
-           plocal_fulladdr = &local_fulladdr;
-        } else {
-           return retval;
+       if (auth_context->local_addr) {
+            if (!(retval = krb5_make_fulladdr(context,auth_context->local_addr,
+                                             auth_context->local_port, 
+                                             &local_fulladdr))){
+                CLEANUP_PUSH(&local_fulladdr.contents, free);
+               plocal_fulladdr = &local_fulladdr;
+            } else {
+               return retval;
+            }
+       } else {
+            plocal_fulladdr = auth_context->local_addr;
         }
     }
 
     if (auth_context->remote_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->remote_addr,
-                                 auth_context->remote_port, &remote_fulladdr))){
-            CLEANUP_PUSH(&remote_fulladdr.contents, free);
-           premote_fulladdr = &remote_fulladdr;
-        } else {
-            CLEANUP_DONE();
-           return retval;
+       if (auth_context->remote_addr) {
+            if (!(retval = krb5_make_fulladdr(context,auth_context->remote_addr,
+                                             auth_context->remote_port, 
+                                             &remote_fulladdr))){
+                CLEANUP_PUSH(&remote_fulladdr.contents, free);
+               premote_fulladdr = &remote_fulladdr;
+            } else {
+               return retval;
+            }
+       } else {
+            premote_fulladdr = auth_context->remote_addr;
         }
     }
 
index 4c73bf8277f4dbe9066489d54f54d67ca4bec111..a7964513b3fc05be429d34640256d7816276d611 100644 (file)
@@ -206,23 +206,33 @@ krb5_rd_priv(context, auth_context, inbuf, outbuf, outdata)
     CLEANUP_INIT(2);
 
     if (auth_context->local_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
-                                 auth_context->local_port, &local_fulladdr))){
-            CLEANUP_PUSH(&local_fulladdr.contents, free);
-           plocal_fulladdr = &local_fulladdr;
-        } else {
-           return retval;
+       if (auth_context->local_addr) {
+            if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
+                                             auth_context->local_port, 
+                                             &local_fulladdr))){
+                CLEANUP_PUSH(&local_fulladdr.contents, free);
+               plocal_fulladdr = &local_fulladdr;
+            } else {
+               return retval;
+            }
+       } else {
+            plocal_fulladdr = auth_context->local_addr;
         }
     }
 
     if (auth_context->remote_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->remote_addr,
-                                 auth_context->remote_port, &remote_fulladdr))){
-            CLEANUP_PUSH(&remote_fulladdr.contents, free);
-           premote_fulladdr = &remote_fulladdr;
-        } else {
-            CLEANUP_DONE();
-           return retval;
+       if (auth_context->remote_addr) {
+            if (!(retval = krb5_make_fulladdr(context,auth_context->remote_addr,
+                                             auth_context->remote_port, 
+                                             &remote_fulladdr))){
+                CLEANUP_PUSH(&remote_fulladdr.contents, free);
+               premote_fulladdr = &remote_fulladdr;
+            } else {
+                CLEANUP_DONE();
+               return retval;
+            }
+       } else {
+            premote_fulladdr = auth_context->remote_addr;
         }
     }
 
index 196f05be22e3ab2b7a6bdccee86b4382ac3a354c..b4eb1980e1759ed881b6726f349c442aa9c59aa5 100644 (file)
@@ -197,23 +197,32 @@ krb5_rd_safe(context, auth_context, inbuf, outbuf, outdata)
     CLEANUP_INIT(2);
 
     if (auth_context->local_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
-                                 auth_context->local_port, &local_fulladdr))){
-            CLEANUP_PUSH(&local_fulladdr.contents, free);
-           plocal_fulladdr = &local_fulladdr;
-        } else {
-           return retval;
+       if (auth_context->local_addr) {
+            if (!(retval = krb5_make_fulladdr(context, auth_context->local_addr,
+                                             auth_context->local_port, 
+                                             &local_fulladdr))){
+                CLEANUP_PUSH(&local_fulladdr.contents, free);
+               plocal_fulladdr = &local_fulladdr;
+            } else {
+               return retval;
+            }
+       } else {
+            plocal_fulladdr = auth_context->local_addr;
         }
     }
 
     if (auth_context->remote_addr) {
-        if (!(retval = krb5_make_fulladdr(context, auth_context->remote_addr,
-                                 auth_context->remote_port, &remote_fulladdr))){
-            CLEANUP_PUSH(&remote_fulladdr.contents, free);
-           premote_fulladdr = &remote_fulladdr;
-        } else {
-            CLEANUP_DONE();
-           return retval;
+       if (auth_context->remote_addr) {
+            if (!(retval = krb5_make_fulladdr(context,auth_context->remote_addr,
+                                             auth_context->remote_port, 
+                                             &remote_fulladdr))){
+                CLEANUP_PUSH(&remote_fulladdr.contents, free);
+               premote_fulladdr = &remote_fulladdr;
+            } else {
+               return retval;
+            }
+       } else {
+            premote_fulladdr = auth_context->remote_addr;
         }
     }