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

map_validator: make sure 'object' name is a str #1540

Conversation

pcoccoli
Copy link
Contributor

The develop version of the aws_guardduty to_stix maps was breaking the map validator. Some of the "object" names in the map are lists; it's supposed to be a string.

Here's the output with this fix:

ERROR: no "references" for ipv4-addr.x_geo_ref in mapping {'key': 'ipv4-addr.x_geo_ref', 'object': 'dst_ip'}
ERROR: no "references" for ipv4-addr.x_geo_ref in mapping {'key': 'ipv4-addr.x_geo_ref', 'object': 'dst_ip'}
ERROR: conflicting types for x-aws-kubernetes-workload kubernetes in mapping {'key': 'x-aws-kubernetes.runtime_context_ref', 'object': 'kubernetes', 'references': 'runtime'}
ERROR: "object" is not a string in mapping {'key': 'process.child_refs', 'object': ['runtime_modi_process_lineage'], 'references': 'runtime_modi_child_process_lineage'}
ERROR: conflicting types for x-aws-kubernetes-workload kubernetes in mapping {'key': 'x-aws-eks-cluster.runtime_context_ref', 'object': 'kubernetes', 'references': 'runtime'}
ERROR: "object" is not a string in mapping {'key': 'process.child_refs', 'object': ['runtime_modi_process'], 'references': 'runtime_modi_child_process'}
ERROR: conflicting types for x-aws-kubernetes-workload kubernetes in mapping {'key': 'x-aws-kubernetes.runtime_context_ref', 'object': 'kubernetes', 'references': 'runtime_file'}
ERROR: conflicting types for x-aws-kubernetes-workload kubernetes in mapping {'key': 'x-aws-kubernetes.runtime_context_ref', 'object': 'kubernetes', 'references': 'runtime'}
ERROR: "object" is not a string in mapping {'key': 'process.child_refs', 'object': ['runtime_target_lineage_process'], 'references': 'runtime_target_child_lineage_process'}
ERROR: conflicting types for x-aws-runtime-context runtime in mapping {'key': 'x-aws-runtime-details.target_process_ref', 'object': 'runtime', 'references': 'runtime_target_process'}
ERROR: conflicting types for x-aws-kubernetes-workload kubernetes in mapping {'key': 'x-aws-eks-cluster.runtime_context_ref', 'object': 'kubernetes', 'references': 'runtime'}
ERROR: "object" is not a string in mapping {'key': 'process.child_refs', 'object': ['runtime_target_process'], 'references': 'runtime_target_child_process'}
ERROR: conflicting types for user-account runtime_target_user in mapping {'key': 'process.x_unique_id', 'object': 'runtime_target_user'}
ERROR: "object" is not a string in mapping {'key': 'process.child_refs', 'object': ['runtime_obs_lineage_process'], 'references': 'runtime_obs_lineage_child_process'}
ERROR: conflicting types for x-aws-kubernetes-workload kubernetes in mapping {'key': 'x-aws-kubernetes.runtime_observed_process_ref', 'object': 'kubernetes', 'references': 'runtime_obs_process'}
ERROR: "object" is not a string in mapping {'key': 'process.child_refs', 'object': ['runtime_obs_process'], 'references': 'runtime_obs_child_process'}
ERROR: conflicting types for x-aws-kubernetes-workload kubernetes in mapping {'key': 'x-aws-kubernetes.runtime_observed_process_ref', 'object': 'kubernetes', 'references': 'runtime_obs_process'}
WARNING: nothing mapped to number_observed

@pcoccoli pcoccoli marked this pull request as ready for review July 25, 2023 21:13
@delliott90 delliott90 merged commit d1c45b7 into opencybersecurityalliance:develop Jul 26, 2023
@SharmilaMS-Hcl
Copy link
Contributor

Fixed the errors reported in PR #1543

@pcoccoli pcoccoli deleted the validator_check_object_type branch July 26, 2023 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants