code: def _get_digest(self, info):
          
          result = None
          for algo in ('sha256', 'md5'):
              key = '%s_digest' % algo
              if key in info:
                  result = (algo, info[key])
                  break
          return result
docs: Get a digest from a dictionary by looking at keys of the form
          'algo_digest'.
  
          Returns a 2-tuple (algo, digest) if found, else None. Currently
          looks only for SHA256, then MD5.