def filterAuthorizedKeys(fp):
 for line in fp:
  line = line.rstrip('\n')
  if (line == COMMENT):
   continue
  if _COMMAND_RE.match(line):
   continue
  (yield line)

def filterAuthorizedKeys ( fp ) : for line in fp : line = line . rstrip ( '\n' ) if ( line == COMMENT ) : continue if _COMMAND_RE . match ( line ) : continue ( yield line )
read lines from fp .