(self, datum, is_subtechnique=False)
return link
Parse the website url from a stix object.
Parse the website url from a stix object.
Parse the website url from a stix object .
def getUrlFromStix(self, datum, is_subtechnique=False):
        """
        Parse the website url from a stix object.
        """
        url = datum['external_references'][0]['url']
        split_url = url.split('/')
        splitfrom = -3 if is_subtechnique else -2
        link = '/'.join(split_url[splitfrom:])
        return link
def getUrlFromStix ( self , datum , is_subtechnique = False ) : url = datum [ 'external_references' ] [ 0 ] [ 'url' ] split_url = url . split ( '/' ) splitfrom = - 3 if is_subtechnique else - 2 link = '/' . join ( split_url [ splitfrom : ] ) return link