Skip to content

Lumu SecOps Integration - SecOps Operation [update new API] - #46379

Merged
TheL0L merged 10 commits into
masterfrom
contrib/eparralumu_lumu
Oct 25, 2026
Merged

TheL0L merged 10 commits into
masterfrom
contrib/eparralumu_lumu

Conversation

@content-bot

Copy link
Copy Markdown
Contributor

Related PRs

Original External PR: #46058

Contributor

@eparralumu

Contributing to Cortex XSOAR Content

Make sure to register your contribution by filling the contribution registration form

The Pull Request will be reviewed only after the contribution registration form is filled.

Status

  • In Progress
  • Ready
  • In Hold - (Reason for hold)

Related Issues

N/A

Description

Second version of Lumu Pack, include new Lumu SecOps Integration with its Layout, IncidentType, IncidentFields, Classifier, Mapping and Integration sections, check the introductory video https://www.youtube.com/watch?v=m1xki-jioI8
This update intends to use our latest Incident API. The old API is still supported but we intend to ease the transition for our customers. The integration will function like the current one but will use a broader range of incident types and the new infrastructure; however, the essence remains the same by using the Cortex XSOAR mirroring capabilities.

Must have

  • Tests
  • Documentation

fixes: https://jira-dc.paloaltonetworks.com/browse/CIAC-18495

* Lumu SecOps Integration - SecOps Operation [update new API]

* add CONTRIBUTORS.json

* Address security review updates for LumuSecops integration
- Updated LumuSecops.yml security/config UX:
- Changed api_key to credential type (type: 9) with hiddenusername: true.
- Added parameter sections (Connect / Collect) and sectionorder.
- Set fetch defaults and improved collect-time parameter grouping/labels.
- Reused existing Lumu incident fields for Secops by associating LumuSecops with:
- companyId, lumu_status, lumu_description, lumu_incidentId.
- Updated classifier/mapper and layout artifacts to align with new LumuSecops incident mapping and UI.
- Updated release notes for 1.0.32:
- Header changed to Lumu Secops (display-name match).
- Converted previous Changed: notes to New: for newly introduced entities/components.
- Reformatted generated content artifacts (README/layout JSON) as part of staged updates.

* Refactor LumuSecops to reuse existing Lumu incident fields
- Remove duplicate LumuSecops incident fields:
- lumu_secops_company_id
- lumu_secops_description
- lumu_secops_incident_id
- lumu_secops_status
- Update incoming mapper to stop mapping removed duplicate Secops field keys.
- Keep Secops mapping focused on non-duplicated, Secops-specific fields.
- Simplify integration fetch parameter configuration and labels in LumuSecops.yml.
- Regenerate/update README.md to reflect current integration parameter definitions.

* Harden LumuSecops input handling and refine integration configuration
- Added HTML escaping in comment/description rendering paths to reduce injection risk in generated incident content.
- Refactored fetch normalization flow to pass mirroring context explicitly (integration_instance, mirror_direction, mirror_tags) instead of relying on module-level globals.
- Improved argument parsing robustness by using arg_to_number for label and fetch-size numeric inputs.
- Switched to typed platform constants for incident defaults (IncidentSeverity.MEDIUM, IncidentStatus.ACTIVE).
- Replaced direct return_error path in remote-data rate-limit handling with a dedicated CustomLumuException.
- Updated LumuSecops.yml docs/parameter metadata (including mirror direction wording from SentinelOne -> Lumu) and regenerated README.md.
- Removed obsolete helper test (add_prefix_to_comment) and aligned metadata update in Packs/Lumu/pack_metadata.json.

* - Update LumuSecops integration documentation in Packs/Lumu/Integrations/LumuSecops/LumuSecops.yml:
- Clarify multiple output date fields as ISO 8601 timestamps.
- Clarify list-style args (adversary_types, labels, status) as comma-separated values.
- Mark lumusecops-get-cache as hidden/internal and improve its description.
- Improve cache reset behavior in Packs/Lumu/Integrations/LumuSecops/LumuSecops.py:
- Replace partial cache reset with full expected cache structure (cache, lumu_secops_incident_ids, source_records, users, labels).
- Clean up Python code and tests:
- Remove unused urllib3 import in Packs/Lumu/Integrations/LumuSecops/LumuSecops.py.
- Remove unused add_prefix_to_comment import in Packs/Lumu/Integrations/LumuSecops/LumuSecops_test.py.
- Apply formatting/whitespace cleanup and line wrapping.
- Refresh command examples in Packs/Lumu/Integrations/LumuSecops/command_examples.txt with updated sample IDs/labels.
- Add pack keywords in Packs/Lumu/pack_metadata.json for better discoverability.

* add lumusecops-clear-cache and align YAML/README description active voice writing

* major version bump to 2.0.0 with LumuSecops updates and release note cleanup

* lazy-load users/labels in remote sync and tighten test-module cache init

* Convert string arguments to integers.

* Added  documentation blocks (command example, context example, human-readable output) for multiple commands.
New example sections were added for:
- lumusecops-retrieve-labels
- lumusecops-retrieve-a-specific-label
- lumusecops-mark-incident-as-read
- lumusecops-begin-incident-work
- lumusecops-comment-incident
- lumusecops-mute-incident
- lumusecops-unmute-incident
- lumusecops-close-incident

* - add wipe_cache() and invoke it after get-remote-data processing and close-incident updates
- filter out invalid label IDs before incident-list API requests
- extend tests

* fix identantion

* integration description updated

* Update Packs/Lumu/pack_metadata.json

Co-authored-by: Sergei Yakima <sergeiyakima1@gmail.com>

* Fix LumuSecops incident field naming, mapper keys

- Rename new LumuSecops incident field display names to start with Lumu (case-sensitive requirement), including Lumu SecOps Take Status Action.
- Keep existing cliName and id values unchanged to preserve layouts/mirroring compatibility.
- Update classifier-mapper-incoming-LumuSecops.json mapping keys to exactly match new field display names.
- Fix invalid mapper targets from lumu_secops_description / lumu_secops_incident_id to lumu_description / lumu_incidentId.
- Update ReleaseNotes/2_0_0.md to reflect new field display names.

* - Keep a single New: line per new entity in 2_0_0.md (integration, incident type, classifier, mapper, layout, and each new field)
- Remove duplicated classifier/mapper/layout entries

* fix some tests and reach the test coverage quota

---------

Co-authored-by: Sergei Yakima <sergeiyakima1@gmail.com>
@content-bot content-bot added Contribution Thank you! Contributions are always welcome! docs-approved Partner Contribution Form Filled Whether contribution form filled or not. Partner Support Level Indicates that the contribution is for Partner supported pack Internal PR Security Review Partner-Approved Security Approved If a contribution has been approved for merge by the security team, then this will allow a merge ready-for-pipeline-running Whether the pr is ready for running the whole pipeline, including testing on SAAS machines labels Oct 25, 2026
@content-bot
content-bot requested a review from TheL0L October 25, 2026 12:02
@content-bot

Copy link
Copy Markdown
Contributor Author

🤖 AI-Powered Code Review Available

Hi @TheL0L, you can leverage AI-powered code review to assist with this PR!

Available Commands:

  • @marketplace-ai-reviewer start review - Initiate a full AI code review
  • @marketplace-ai-reviewer re-review - Incremental review for new commits

@content-bot

Copy link
Copy Markdown
Contributor Author

🤖 AI-Powered Code Review Available

You can leverage AI-powered code review to assist with this PR!

Available Commands:

  • @marketplace-ai-reviewer start review - Initiate a full AI code review
  • @marketplace-ai-reviewer re-review - Incremental review for new commits

@github-actions

github-actions Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Coverage

Coverage Report
FileStmtsMissCoverMissing
Packs/Lumu/Integrations/LumuSecops
   LumuSecops.py59915374%191–192, 194–195, 197–199, 201, 203–205, 207–208, 210–211, 213, 222–223, 225–226, 228–230, 232, 234–236, 238–239, 241–242, 244, 247, 250, 252, 254, 257, 259, 261, 264, 266, 268, 271, 273, 275, 287, 299, 309, 319, 329, 337, 340, 345, 354, 363, 372, 381, 390, 397, 407, 468, 474–475, 477–478, 488, 492, 494, 496, 504, 529–534, 538–543, 571–574, 723, 728, 737, 758, 968–969, 992–993, 1034–1035, 1055–1057, 1064, 1071, 1073, 1080, 1084–1085, 1092, 1096–1098, 1100, 1105–1106, 1108–1111, 1113–1114, 1116, 1118–1119, 1121, 1123–1124, 1126, 1149–1154, 1158–1161, 1163–1165, 1167–1168, 1170–1172, 1174–1175, 1177–1181, 1183–1185
TOTAL59915374% 

Tests Skipped Failures Errors Time
31 0 💤 0 ❌ 0 🔥 3.060s ⏱️

@TheL0L TheL0L left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Fixed all failing validations, pending verification by build.

Comment thread Packs/Lumu/Integrations/LumuSecops/LumuSecops.py Dismissed
@content-bot

Copy link
Copy Markdown
Contributor Author

Validate summary
The following errors were reported as warnings: BC117.
BC117 validation requires PM review due to changes to supportedModules.
The following errors were thrown as a part of this pr: ST110.
The following errors cannot be ignored: ST110.
If the AG100 validation in the pre-commit GitHub Action fails, the pull request cannot be force-merged.

Verdict: PR can be force merged from validate perspective? ❌

Comment thread Packs/Lumu/pack_metadata.json Outdated
@TheL0L
TheL0L enabled auto-merge (squash) October 25, 2026 14:47
@TheL0L
TheL0L merged commit bf624d4 into master Oct 25, 2026
25 of 27 checks passed
@TheL0L
TheL0L deleted the contrib/eparralumu_lumu branch October 25, 2026 18:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Contribution Form Filled Whether contribution form filled or not. Contribution Thank you! Contributions are always welcome! docs-approved Internal PR Partner Support Level Indicates that the contribution is for Partner supported pack Partner Partner-Approved ready-for-pipeline-running Whether the pr is ready for running the whole pipeline, including testing on SAAS machines Security Approved If a contribution has been approved for merge by the security team, then this will allow a merge Security Review skip-ai-review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants