Red Hat Bugzilla – Bug 432070
bad definition of ServerIPAddress makes setup-ds-admin.pl segfault
Last modified: 2015-01-04 18:30:42 EST
Description of problem:
From an email:
It looks like there is a problem with the way we handle ServerIPAddress in
setup-ds-admin.pl. It is only necessary to provide this value in your .inf if
you have a machine that has multiple IP addresses and you want it to listen on
only 1 of those. The default is to listen on all interfaces. If you really
need to listen to only 1 IP address, for now you'll have to edit console.conf
after running setup-ds-admin.pl and change the Listen directive manually.
The problem on this machine is that the hostname is configured to be
nmalik-ldap, but for some reason calling PR_GetHostByName with nmalik-ldap
returns NULL. If you use nmalik-ldap.usersys.redhat.com it works, but that's
not what PR_GetSystemInfo(PR_SI_HOSTNAME) returns.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
Created attachment 294388 [details]
program to reproduce the problem
Looks like the code in validate_addr() in adminserver/admserv/cgi-src40/config.c
is incorrect, both the logic and the error checking.
The logic used in validate_addr() has been changed by the fix for bug 430364. There is no need for the validation code to be concerned with the hostname. The validation now simply ensures that the requested address is available on the system by trying to bind it to a socket.
*** This bug has been marked as a duplicate of bug 430364 ***