Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating a relationship with a set label doesn't work #7194

Closed
yassine-ouaamou opened this issue May 30, 2024 · 0 comments · Fixed by #7331
Closed

Creating a relationship with a set label doesn't work #7194

yassine-ouaamou opened this issue May 30, 2024 · 0 comments · Fixed by #7331
Assignees
Labels
bug use for describing something not working as expected ingestion Linked to ingestion (manual, from file, feeds & queue) solved use to identify issue that has been solved (must be linked to the solving PR)

Comments

@yassine-ouaamou
Copy link
Member

yassine-ouaamou commented May 30, 2024

Description

When creating a new relationship with a new label, the label is created but not set. If we run the script a second time, then it's set.

Environment

Testing

Reproducible Steps

relationship = stix2.Relationship(
    source_ref="campaign--a872c9d5-8f10-5099-b639-d11529567bde", 
    target_ref="location--11e2ee06-8112-54b5-b210-33603d2473f7", 
    relationship_type="targets", 
    labels=["my_label"]
)

When creating an indicator for example, it works perfectly:

indicator = stix2.Indicator(
    name="cardioschool34.com",
    description="Malicious SSL connections",
    pattern_type="stix",
    pattern="[domain-name:value = 'cardioschool34.com']",
    labels=["my_other_label"],
)

Expected Output

Relationship with a label

Actual Output

No label set on the relationship

Additional information

Seen with @SouadHadjiat

@yassine-ouaamou yassine-ouaamou added bug use for describing something not working as expected needs triage use to identify issue needing triage from Filigran Product team labels May 30, 2024
@Jipegien Jipegien removed the needs triage use to identify issue needing triage from Filigran Product team label May 31, 2024
@Jipegien Jipegien added this to the Bugs backlog milestone May 31, 2024
@SouadHadjiat SouadHadjiat added the solved use to identify issue that has been solved (must be linked to the solving PR) label Jun 12, 2024
@Jipegien Jipegien added the ingestion Linked to ingestion (manual, from file, feeds & queue) label Jul 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug use for describing something not working as expected ingestion Linked to ingestion (manual, from file, feeds & queue) solved use to identify issue that has been solved (must be linked to the solving PR)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants