TCP support for MIT Kerberos in HP-UX IA64

Vipul Mehta vipulmehta.1989 at gmail.com
Tue Apr 8 10:25:33 EDT 2014


Thanks Greg, i figured out the same thing myself also.
This explains it : http://curl.haxx.se/mail/lib-2009-04/0287.html

I tried building MIT Kerberos with/without _XOPEN_SOURCE_EXTENDED flag but
same problem.

So i used :

#if defined(HPUX-IA64)
 int sockerrlen;
#else
 socklen_t sockerrlen;
#endof

It works perfectly fine. I tried using hpux macro but didn't work, so i
introduced my own HPUX-IA64 macro and defined it via CFLAGS.



On Mon, Apr 7, 2014 at 8:37 PM, Greg Hudson <ghudson at mit.edu> wrote:

> On 04/07/2014 04:44 AM, Vipul Mehta wrote:
> > I've narrowed down the problem.
> >
> > get_so_error() in sendto_kdc.c is returning error code 22 i.e. invalid
> > argument on getsockopt() call.
> >
> >     e = getsockopt(fd, SOL_SOCKET, SO_ERROR, &sockerr, &sockerrlen);
>
> I did some searching and found:
>
>   http://lists.ibiblio.org/pipermail/freetds/2009q1/024226.html
>
>
> http://www.postgresql.org/message-id/20101216174803.20b2b6db@pc09.procura.nl
>
> It looks like HP-UX has an eight-byte socklen_t and a four-byte int, and
> has two different versions of getsockopt(), one which expects a pointer
> to int in the last parameter and one which expects a pointer to
> socklen_t.  Since we don't do anything in our build system to choose
> "X/Open sockets," we probably get the first one.
>
> If you change sockerrlen from socklen_t to int, does it start working?
> I'm not sure if we can make a reasonable change to accomodate this if
> so, but it would be good to know.  There seems to have been some
> confusion among various standards bodies over what type the optlen
> parameter should point to.
>



-- 
Regards,
Vipul


More information about the Kerberos mailing list