<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def lookup_full_hashes(self, hash_values):
 """Query DB to see if hash is blacklisted"""

        q = '''SELECT threat_type,platform_type,threat_entry_type, expires_at < current_timestamp AS has_expired
                FROM full_hash WHERE value IN ({})
        '''
        output = []
        with self.get_cursor() as dbc:
            placeholders = ','.join(['?'] * len(hash_values))
            dbc.execute(q.format(placeholders), [sqlite3.Binary(hv) for hv in hash_values])
            for h in dbc.fetchall():
                threat_type, platform_type, threat_entry_type, has_expired = h
                threat_list = ThreatList(threat_type, platform_type, threat_entry_type)
                output.append((threat_list, has_expired))
        return output