(self, obj)
Perform an OSINT lookup on the query value.
Perform an OSINT lookup on the query value.
Perform an OSINT lookup on the query value .
def do_osint_query(self, obj):
        """Perform an OSINT lookup on the query value."""
        client = self._generate_request_instance('enrichment')
        query = self._get_query_type(obj)
        results = client.get_osint(query=query)
        self._check_response(results)
        for record in results.get('results', []):
            stats = {'URL': record.get('sourceUrl'),
                     'Tags': ', '.join(record.get('tags'))}
            for indicator in record.get('inReport', []):
                self._add_result('OSINT: %s' % record.get('source'),
                                 indicator, stats)
def do_osint_query ( self , obj ) : client = self . _generate_request_instance ( 'enrichment' ) query = self . _get_query_type ( obj ) results = client . get_osint ( query = query ) self . _check_response ( results ) for record in results . get ( 'results' , [ ] ) : stats = { 'URL' : record . get ( 'sourceUrl' ) , 'Tags' : ', ' . join ( record . get ( 'tags' ) ) } for indicator in record . get ( 'inReport' , [ ] ) : self . _add_result ( 'OSINT: %s' % record . get ( 'source' ) , indicator , stats )