Get local hostname more precisely in k5test.py
authorGreg Hudson <ghudson@mit.edu>
Thu, 1 Sep 2011 17:33:11 +0000 (17:33 +0000)
committerGreg Hudson <ghudson@mit.edu>
Thu, 1 Sep 2011 17:33:11 +0000 (17:33 +0000)
commitac94f24a1110a67d17fa054c7484554b209feea1
treea5a2b023315b363170f8d38c4ecebc4599cfbd63
parent5c94d680e4e9cbffa763ad69b112385492fd4ebf
Get local hostname more precisely in k5test.py

socket.getfqdn() tries to produce a result containing a period, so it
may disagree with krb5_sname_to_principal's result--for example, in
Fedora's default DHCP configuration.  Use getaddrinfo and getnameinfo
calls mirroring krb5_sname_to_principal's logic instead.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@25122 dc483132-0cff-0310-8789-dd5450dbe970
src/util/k5test.py