Iterate over the headers
For each header extract file list, md5s and flags
for h in mi:
name=h['filenames']
fileflags=h['fileflags']
md5sums=h['filemd5s']
total=len(names)
Find all the config files and pass them to a function
for i in xrange(total):
if (fileflags[i] & rpm.RPMFILE_CONFIG):
if isModified(names[i], md5sums[i]):
configs.append(names[i])