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

[Comlaude] connector improvements #3459

Merged

Conversation

MohamedMerimi
Copy link
Contributor

@MohamedMerimi MohamedMerimi commented Feb 20, 2025

Hello,

I'm coming to you to send the commit about the comlaude connector, you will see the details below :

Removal of obsolete elements:

The _get_interval method and its associated variable have been removed, as they were no longer used in new versions (obsolete). Scheduling is now handled via schedule_iso.

Deprecated configuration removed:

The update_existing_data variable has been removed, as has its use in the send_stix2_bundle call.

Improved quality of STIX bundles:

When sending bundles, the cleanup_inconsistent_bundle=True parameter is now used, and all necessary markings (such as TLP_AMBER) are included.

Logging modernization:

Old calls to self.helper.log_error() have been replaced by self.helper.connector_logger.error() with a structured format (message + variable dictionary).

Work ID correctly closed:

In the finally block, the Work ID is always marked as completed via self.helper.api.work.to_processed, even in the event of an error.
Date and exception handling methods updated:

The use of datetime.utcnow() (deprecated in Python 3.12) has been replaced.

A traceback is now displayed in the main block for better error handling.

Proposed changes

Related issues

*#3055
*

Checklist

  • I consider the submitted work as finished
  • I tested the code for its functionality using different use cases
  • I added/update the relevant documentation (either on github or on notion)
  • Where necessary I refactored code to improve the overall quality

Further comments

@flavienSindou
Copy link
Contributor

flavienSindou commented Feb 21, 2025

other open PR : #3055

@MohamedMerimi
Copy link
Contributor Author

Hello @flavienSindou yes it's other open PR but i can't commit in this PR "#3055" because it's Yassine who open it, so i open another PR to do what @Megafredo told me to do ( Suggestions for Code Improvement and Code cleaning)

@yassine-ouaamou yassine-ouaamou added the partner used to identify PR from patner label Feb 24, 2025
@romain-filigran romain-filigran added this to the PRs backlog milestone Feb 24, 2025
@helene-nguyen helene-nguyen linked an issue Feb 24, 2025 that may be closed by this pull request
@helene-nguyen helene-nguyen changed the title Comlaude connector [Comlaude] connector improvements Feb 24, 2025
@helene-nguyen helene-nguyen self-assigned this Feb 24, 2025
Copy link
Member

@helene-nguyen helene-nguyen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Look good to me

@helene-nguyen helene-nguyen merged commit a7b9950 into OpenCTI-Platform:master Feb 24, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
partner used to identify PR from patner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Comlaude] improvements
6 participants