Blame SOURCES/authconfig-6.2.8-nss-myhostname.patch

ee2f06
diff -up authconfig-6.2.8/authinfo.py.myhostname authconfig-6.2.8/authinfo.py
ee2f06
--- authconfig-6.2.8/authinfo.py.myhostname	2016-06-16 14:41:10.561950544 +0200
ee2f06
+++ authconfig-6.2.8/authinfo.py	2016-06-16 14:41:17.425104198 +0200
ee2f06
@@ -1336,6 +1336,7 @@ class AuthInfo:
ee2f06
 		self.enableWinbind = None
ee2f06
 		self.enableWINS = None
ee2f06
 		self.enableMDNS = None
ee2f06
+		self.enableMyhostname = None
ee2f06
 		self.preferDNSinHosts = None
ee2f06
 		self.enableSSSD = None
ee2f06
 		self.enableIPAv2 = None
ee2f06
@@ -1442,7 +1443,7 @@ class AuthInfo:
ee2f06
 		("enableOdbcbind", "b"), ("enableNIS3", "b"), ("enableNIS", "b"),
ee2f06
 		("enableLDAPbind", "b"), ("enableLDAP", "b"), ("enableHesiodbind", "b"),
ee2f06
 		("enableHesiod", "b"), ("enableDBIbind", "b"), ("enableDBbind", "b"),
ee2f06
-		("enableCompat", "b"), ("enableWINS", "b"), ("enableMDNS", "b"),
ee2f06
+		("enableCompat", "b"), ("enableWINS", "b"), ("enableMDNS", "b"), ("enableMyhostname", "b"),
ee2f06
 		("enableNIS3", "b"), ("enableNIS", "b"), ("enableIPAv2", "b"),
ee2f06
 		("enableSSSD", "b"), ("preferDNSinHosts", "b"), ("implicitSSSD", "b")]),
ee2f06
 	SaveGroup(self.writePAM, None, [("pwqualityArgs", "c"), ("passwdqcArgs", "c"),
ee2f06
@@ -2048,6 +2049,8 @@ class AuthInfo:
ee2f06
 						self.setParam("enableWINS", True, ref)
ee2f06
 					if checkNSS(value, "mdns4_minimal [NOTFOUND=return]"):
ee2f06
 						self.setParam("enableMDNS", True, ref)
ee2f06
+					if checkNSS(value, "myhostname"):
ee2f06
+						self.setParam("enableMyhostname", True, ref)
ee2f06
 
ee2f06
 					nispos = checkNSS(value, "nis")
ee2f06
 					if nispos == None:
ee2f06
@@ -3671,6 +3674,8 @@ class AuthInfo:
ee2f06
 				hosts += " nis"
ee2f06
 			if not self.preferDNSinHosts:
ee2f06
 				hosts += " dns"
ee2f06
+			if self.enableMyhostname:
ee2f06
+				hosts += " myhostname"
ee2f06
 
ee2f06
 			# Read in the old file.
ee2f06
 			for line in f.file:
ee2f06
@@ -4221,6 +4226,7 @@ class AuthInfo:
ee2f06
 		print "nss_sss is %s by default" % formatBool(self.enableSSSD)
ee2f06
 		print "nss_wins is %s" % formatBool(self.enableWINS)
ee2f06
 		print "nss_mdns4_minimal is %s" % formatBool(self.enableMDNS)
ee2f06
+		print "myhostname is %s" % formatBool(self.enableMyhostname)
ee2f06
 		print "DNS preference over NSS or WINS is %s" % formatBool(self.preferDNSinHosts)
ee2f06
 		print "pam_unix is always enabled"
ee2f06
 		print " shadow passwords are %s" % formatBool(self.enableShadow)