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

Is the resolved-to SRO for ipv4, ipv6 and domain name objects redundant? #297

Open
rpiazza opened this issue Oct 12, 2022 · 3 comments
Open

Comments

@rpiazza
Copy link
Contributor

rpiazza commented Oct 12, 2022

From: Brett Forbes [email protected]:

I have found a small error on the Stix 2.1 specification page, which caught me out.

Basically the "resolves-to" SRO is described on the ipv4, ipv6 and domain name objects, but is not included in Appendix B, the relationship summary table. This actually caught me out because i built the schema based on Appendix B and one of my tests discovered this error (i.e. i couldn't import the relationship).

I also note that generally this relationship is redundant, and hence bad form, since its values are already carried in the "resolves_to_ref" field. We already materialise these embedded id's as actual relations, so now i need two different relations:

  1. A "resolves" relation to match the embedded id's, with roles "from" and "to"
  2. A "resolves-to" SRO, with roles "resolves-from" and "resolves-to"

There seems to be some unecessary reedundancy here leading users to be unsure which one to mark.

@priamai
Copy link

priamai commented Oct 13, 2022

Totally agree, btw this is the example it's in the docs:

from stix2 import MACAddress

mac_addr_a = MACAddress(value="a1:b2:c3:d4:e5:f6")
mac_addr_b = MACAddress(value="a7:b8:c9:d0:e1:f2")

ip4_valid_refs = IPv4Address(
    value="177.60.40.7",
    resolves_to_refs=[mac_addr_a.id, mac_addr_b.id]
)

print(ip4_valid_refs.serialize(pretty=True))

@ejratl
Copy link
Contributor

ejratl commented Jan 4, 2023

Related to #281

@SYNchroACK
Copy link

Related to #320

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants