mirror of https://github.com/MISP/PyMISP
Exact match on the value when adding tag.
parent
ac72db8a48
commit
3c443095e8
|
@ -581,7 +581,8 @@ class MISPEvent(object):
|
||||||
def add_attribute_tag(self, tag, attribute_identifier):
|
def add_attribute_tag(self, tag, attribute_identifier):
|
||||||
attribute = None
|
attribute = None
|
||||||
for a in self.attributes:
|
for a in self.attributes:
|
||||||
if a.id == attribute_identifier or a.uuid == attribute_identifier or attribute_identifier in a.value:
|
if (a.id == attribute_identifier or a.uuid == attribute_identifier or
|
||||||
|
attribute_identifier == a.value or attribute_identifier in a.value.split('|')):
|
||||||
a.add_tag(tag)
|
a.add_tag(tag)
|
||||||
attribute = a
|
attribute = a
|
||||||
if not attribute:
|
if not attribute:
|
||||||
|
|
Loading…
Reference in New Issue