🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.protocols.kerberos
Article #880

Re: Kerberos and two ethernet ports

#880
From: Viktor Dukhovni
Date: Fri, 24 May 1991 21:07
29 lines
1447 bytes
galina@watson.ibm.com (Galina Kofman)_ writes:

>In send_to_kdc.c after the socket was obtained add:

>    if ( loc_host_addr == 0 ) /* static u_long loc_host_addr = 0 initially */ {
>        if ( (loc_host_addr = gethostid()) == 0) {
				^^^^^^^
			This is not terribly likely to return
			an IP address.  On systems without a harware ID
			the default hostid may be based on the IP address,
			but these tend to also have sethostid(),  which
			may be used by the sysadmin to set any other value.


	To bind to the primary address one must

	char name[MAXHOSTNAMELEN];
	struct hostent *hp;
	gethostname(name,MAXHOSTNAMELEN);
	if ( (hp=gethostbyname(name)) == NULL ) {
		/* error */
		...
	}
	bcopy(hp->h_addr,&loc_host_addr,sizeof(loc_host_addr));
--
        Viktor Dukhovni <viktor@shearson.com>       : ARPA
                <...!uunet!shearson.com!viktor>     : UUCP
        388 Greenwich St., 11th floor, NY, NY 10013 : US-Post
                +1-(212)-464-3793                   : VOICE
Technical Details
Message-ID: <1991May24.210757.10215@shearson.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!crdgw1!uunet!shearson.com!viktor
References: <1991May23.144713.21302@watson.ibm.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!crdgw1!uunet!shearson.com!viktor
From: viktor@shearson.com (Viktor Dukhovni)
Newsgroups: comp.protocols.kerberos
Subject: Re: Kerberos and two ethernet ports
Message-ID: <1991May24.210757.10215@shearson.com>
Date: 24 May 91 21:07:57 GMT
References: <1991May23.144713.21302@watson.ibm.com>
Sender: news@shearson.com (News)
Organization: Lehman Brothers
Lines: 29