On Fri, Feb 23, 2007 at 07:44:29PM -0500, Robert Edmonds wrote:
> Package: perdition
> Version: 1.17-7
> Severity: minor
> 
> perdition running on a Debian NIS client bound to a SunOS 5.8 NIS/YP
> server is unable to look up the real mail server to use from our
> mail.aliases map.  The attached patch works for me since Sun's
> yp_match() RPC call apparently expects the inkeylen parameter to include
> the length of the key including the terminating '\0' character, while
> strlen() excludes the terminating '\0'.
> 
> I'm not sure if all NIS servers behave this way or require this behavior
> from clients, so perhaps this should be some sort of knob, but according
> to my packet sniffer Python's nis.match() call always sends the
> terminating '\0'.

Hi Robert,

Thanks for tracking this down. I had a look around and I really
can't find any documentation indicating weather strlen() or strlen() + 1
should be passed. I think that its entirely reasonable that
strlen() + 1 is correct, so in lieu of any specification, I'm
going to change the code as per your patch.

If anyone finds documentation indicating that this is not correct,
please let me know.

-- 
Horms
  H: http://www.vergenet.net/~horms/
  W: http://www.valinux.co.jp/en/



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to