home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / alt / irc / 4779 < prev    next >
Encoding:
Internet Message Format  |  1992-12-21  |  1.6 KB

  1. Path: sparky!uunet!spool.mu.edu!sgiblab!munnari.oz.au!manuel.anu.edu.au!coombs!avalon
  2. From: avalon@coombs.anu.edu.au (Darren Reed)
  3. Newsgroups: alt.irc
  4. Subject: Re: patriot.mit.edu (vanity server alert)
  5. Date: 21 Dec 92 08:03:41 GMT
  6. Organization: Australian National University
  7. Lines: 43
  8. Message-ID: <avalon.724925021@coombs>
  9. References: <9212172023.AA08764@hrt213.brooks.af.mil> <1992Dec18.082654.17711@aston.ac.uk>
  10. NNTP-Posting-Host: 150.203.76.2
  11.  
  12. evansmp@uhura.aston.ac.uk (Mark Evans) writes:
  13.  
  14. >But one which can be gotten round by hacking the server slightly :-)
  15.  
  16. >assume my_name contains the FQDN if the host the server is running on.
  17.  
  18. >add as a global variable
  19.  
  20. >    char *my_domain;
  21.  
  22. >just after ircd.conf is read (cos that's probably where you have got the 
  23. >FQDN of the server from)
  24.  
  25. >    my_domain=index(my_name,'.');
  26.  
  27. >if the routine to get the host name of the remote connection (read 'rhost'
  28. >as whatever variable the code actually uses)
  29.  
  30. >(if there is something like rhost=hp->host do rhost=strcpy(temp,rhost);
  31. >where temp is a string of size 65, or more)
  32.  
  33. >    if (strcmp(rhost,"localhost")) strcpy(rhost,my_name);
  34. >    if (!index(rhost,'.')) strcat(rhost,my_domain);
  35.  
  36. >and thats it!
  37.  
  38. The server already has all this code in it.
  39.  
  40. Look in s_bsd.c for add_local_domain().
  41.  
  42. Just depends on whether patriot has working resolv library (or a
  43. /etc/resolv.conf file setup properly).
  44.  
  45. The problems had seem to suggest that one of these two is at fault
  46. and really should be corrected.
  47.  
  48. /etc/resolv.conf should have a line "domainname mit.edu" in it (seems
  49. to me to be missing if everything else works) and the #defines in
  50. config.h set correctly.
  51.  
  52. avalon
  53.  
  54. say no to lame servers with lame admins
  55.