HP-UX 11i problem (Kerberos version 1.3.5)

Douglas E. Engert deengert at anl.gov
Wed Sep 29 17:01:28 EDT 2004



Mike Langas wrote:

> Doug,
> 
> I tried the way you specified.  I get the following error.  You should also
> know that I'm on PA-RISC.
>

OK, there are three HP specific patches I have. See below.
I thought Ken had added the foreachaddr.c patch.


> make[3]: Entering directory
> `/home/mlangas/subversion/krb5-1.3.5/src/lib/krb5/os'
> /opt/fsf/bin/gcc -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\"
> -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\"
> -DKRB5_KRB4_COMPAT=1 -DHAVE_BT_RSEQ=1 -DKRB5_PRIVATE=1 -DKRB5_DEPRECATED=1
> -DKRB5_DNS_LOOKUP_KDC=1 -DKRB5_DNS_LOOKUP=1 -DSTDC_HEADERS=1
> -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1
> -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_UNISTD_H=1
> -DHAVE_STDARG_H=1 -DHAVE_UNISTD_H=1 -DHAVE_REGEX_H=1 -DHAVE_REGEXP_H=1
> -DHAVE_FCNTL_H=1 -DHAVE_MEMORY_H=1 -DHAVE_FCHMOD=1 -DHAVE_CHMOD=1
> -DHAVE_STRFTIME=1 -DHAVE_STRPTIME=1 -DHAVE_GETEUID=1 -DHAVE_GETENV=1
> -DHAVE_SETSID=1 -DHAVE_VFPRINTF=1 -DHAVE_VSPRINTF=1 -DHAVE_STRDUP=1
> -DHAVE_STRCASECMP=1 -DHAVE_STRERROR=1 -DHAVE_MEMMOVE=1 -DHAVE_GETUID=1
> -DHAVE_SSCANF=1 -DHAVE_SYSLOG=1 -DHAVE_REGCOMP=1 -DHAVE_RE_COMP=1
> -DHAVE_RE_EXEC=1 -DHAVE_REGEXEC=1 -DPOSIX_SIGTYPE=1 -Dkrb5_sigtype=void
> -DPOSIX_SIGNALS=1 -DGETPEERNAME_ARG2_TYPE=void -DGETPEERNAME_ARG3_TYPE=int
> -DGETSOCKNAME_ARG2_TYPE=void -DGETSOCKNAME_ARG3_TYPE=int   -I../../../include
> -I./../../../include -I../../../include/krb5 -I./../../../include/krb5 
> -D__hpux -O -c localaddr.c
> In file included from localaddr.c:49:
> ../../../include/foreachaddr.c: In function `get_lifconf':
> ../../../include/foreachaddr.c:268: error: storage size of 'lifc' isn't known
> ../../../include/foreachaddr.c: In function `foreach_localaddr':
> ../../../include/foreachaddr.c:466: error: field `lifnum' has incomplete type
> ../../../include/foreachaddr.c:519: error: structure has no member named
> `lifr_name'
> ../../../include/foreachaddr.c:519: error: structure has no member named
> `lifr_name'
> ../../../include/foreachaddr.c:520: error: structure has no member named
> `lifr_name'
> ../../../include/foreachaddr.c:521: error: structure has no member named
> `lifr_name'
> ../../../include/foreachaddr.c:527: error: structure has no member named
> `lifr_name'
> ../../../include/foreachaddr.c:548: error: structure has no member named
> `lifr_name'
> ../../../include/foreachaddr.c:550: error: structure has no member named
> `lifr_addr'
> ../../../include/foreachaddr.c:550: error: structure has no member named
> `lifr_addr'
> ../../../include/foreachaddr.c:555: error: structure has no member named
> `lifr_addr'
> ../../../include/foreachaddr.c:555: error: structure has no member named
> `lifr_addr'
> ../../../include/foreachaddr.c:563: error: structure has no member named
> `lifr_addr'
> ../../../include/foreachaddr.c:588: error: structure has no member named
> `lifr_name'
> ../../../include/foreachaddr.c:593: error: structure has no member named
> `lifr_addr'
> 

--- ,fake-addrinfo.h    Fri Sep 17 11:18:40 2004
+++ fake-addrinfo.h     Fri Sep 17 11:18:40 2004
@@ -554,6 +554,9 @@
  /* Hack for HPUX, to get h_errno.  */
  # define _XOPEN_SOURCE_EXTENDED 1
  # include <netdb.h>
+# ifndef h_ERRNO_KT_DEFINED
+extern int h_errno;
+# endif
  # undef _XOPEN_SOURCE_EXTENDED
  #endif

--- ,foreachaddr.c      Fri Sep 17 11:19:05 2004
+++ foreachaddr.c       Fri Sep 17 11:19:05 2004
@@ -259,7 +259,7 @@
      return ret;
  }

-#ifdef SIOCGLIFCONF /* Solaris */
+#if defined(SIOCGLIFCONF) && !defined(__hpux) /* Solaris */
  static int
  get_lifconf (int af, int s, size_t *lenp, /*@out@*/ char *buf)
      /*@modifies *buf,*lenp@*/
@@ -431,7 +431,7 @@
      return 0;
  }

-#elif defined (SIOCGLIFNUM) /* Solaris 8 and later; Sol 7? */
+#elif defined (SIOCGLIFNUM) && !defined(__hpux) /* Solaris 8 and later; Sol 7? */

  static int
  foreach_localaddr (/*@null@*/ void *data,


--- ,krlogin.c  Fri Sep 17 11:12:26 2004
+++ krlogin.c   Fri Sep 17 11:12:26 2004
@@ -1474,7 +1474,8 @@

      mark = 0;

-    recv(rem, &mark, 1, MSG_OOB);
+    if (recv(rem, &mark, 1, MSG_OOB) != 1)
+               return;

      if (server_message(mark)) {
         for (;;) {
@@ -1577,7 +1578,28 @@
         if (select(rem+1, &readset, &writeset, &excset, 0) > 0 ) {
             if (!do_inband)
                 if (FD_ISSET(rem, &excset))
+               {
                     oob();
+#if defined(hpux) || defined(__hpux)
+              {
+              /* HPUX 11 appears to have a bug.
+               * After the excset is set, and the oob
+               * reads the byte, select will continue to
+               * return readset=0, and excset=rem
+               * This code says, after the oob,
+               * and there is read data, do the FD_SET
+               * so we will read it.
+               * Select then starts working as expected.
+               * DEE - 2/9/00
+               */
+                  int bytes = 0;
+                  ioctl(rem, FIONREAD, (int *)&bytes);
+                  /*DEE fprintf(stderr,"RB=%d",bytes); */
+                  /*if (bytes) */
+                      FD_SET(rem,&readset);
+              }
+#endif
+               }
             if (FD_ISSET(1,&writeset)) {
                 n = write(1, bufp, remaining);
                 if (n < 0) {



> Thanks for the help.
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com 
> ________________________________________________
> Kerberos mailing list           Kerberos at mit.edu
> https://mailman.mit.edu/mailman/listinfo/kerberos
> 
> 
> 

-- 

  Douglas E. Engert  <DEEngert at anl.gov>
  Argonne National Laboratory
  9700 South Cass Avenue
  Argonne, Illinois  60439
  (630) 252-5444


More information about the Kerberos mailing list