Skip to content

Commit

Permalink
Apply suggestions from review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
weiiwang01 committed Jan 20, 2025
1 parent 52caf97 commit 0f11219
Show file tree
Hide file tree
Showing 22 changed files with 49 additions and 0 deletions.
2 changes: 2 additions & 0 deletions connector-template/rock/rockcraft.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/abuseipdb_ipblacklist/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/alienvault/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/cisa_kev/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
4 changes: 4 additions & 0 deletions connectors/crowdstrike/charmcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,10 @@ config:
description: (optional) The base URL for the CrowdStrike APIs.
type: string
optional: true
crowdstrike-default-x-opencti-score:
description: (optional) crowdstrike default x opencti score.
type: int
optional: true
crowdstrike-indicator-high-score:
description: (optional) If any of the low score labels are found on the indicator then this value is used as a score.
type: int
Expand Down
2 changes: 2 additions & 0 deletions connectors/crowdstrike/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/cyber_campaign/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/export_file_csv/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/export_file_stix/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/export_file_txt/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/import_document/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/import_file_stix/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/malwarebazaar/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/misp_feed/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/mitre/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/sekoia/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/urlscan/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/urlscan_enrichment/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/virustotal_livehunt/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
2 changes: 2 additions & 0 deletions connectors/vxvault/rock/rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ parts:
- python3
- libmagic1
- libffi8
- libxslt1.1
- libxml2
override-build: |
craftctl default
mkdir -p $CRAFT_PART_INSTALL/opt
Expand Down
5 changes: 5 additions & 0 deletions scripts/gen_connector_charm.py
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,11 @@ def extract_crowdstrike_configs(doc_url: str) -> dict:
}
result.update(DEFAULT_CONFIG)
del result["connector-scope"]
result["crowdstrike-default-x-opencti-score"] = {
"description": "(optional) crowdstrike default x opencti score.",
"type": "int",
"optional": True,
}
return result


Expand Down
2 changes: 2 additions & 0 deletions src/charm.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,8 @@ def __init__(self, *args: typing.Any):
)
self.framework.observe(self.on.opencti_peer_relation_broken, self._cleanup_secrets)
self.framework.observe(self.on.stop, self._cleanup_secrets)
self.framework.observe(self.on.opencti_connector_relation_joined, self._reconcile)
self.framework.observe(self.on.opencti_connector_relation_changed, self._reconcile)

def _register_opensearch(self) -> OpenSearchRequires:
"""Create OpenSearchRequires instance and register related event handlers.
Expand Down

0 comments on commit 0f11219

Please sign in to comment.