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

[Unit42v2 Feed] fix indicators fetched with no name aren't parsed correctly #36027

Open
wants to merge 65 commits into
base: master
Choose a base branch
from

Conversation

jlevypaloalto
Copy link
Contributor

Status

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

Related Issues

fixes: link to the issue

Description

When an indicator is fetched with fetch-indicators, the "name" field can be missing. In this case we use the value in the "pattern" field of the indicator as a name which is the general protocol of the Unit42 API.

Must have

  • Tests
  • Documentation

Copy link

github-actions bot commented Aug 26, 2024

Coverage

Coverage Report
FileStmtsMissCoverMissing
Packs/ApiModules/Scripts/TAXII2ApiModule
   TAXII2ApiModule.py109618183%342–344, 349, 352–354, 360–362, 376, 380–381, 411–412, 423–424, 434, 448–452, 486–487, 490, 499, 567, 577, 607, 611, 625, 634, 637, 643, 670, 676–678, 687, 692–693, 695, 697, 721–722, 724, 728–730, 784, 805, 868, 871–873, 875, 1035, 1037, 1053, 1077, 1083–1084, 1116, 1271–1274, 1327–1330, 1376–1379, 1415–1418, 1459–1462, 1498–1501, 1534–1537, 1567–1570, 1605–1608, 1641, 1647, 1673, 1707–1708, 1714, 1774, 1782, 1807–1810, 1818, 1847, 1855, 1900–1903, 1908, 1926–1927, 1940, 1943, 1976, 1979, 1982, 2046–2047, 2057, 2065, 2103–2104, 2124, 2126, 2210–2215, 2228–2231, 2251–2254, 2258, 2262–2268, 2329, 2346, 2351, 2354, 2356, 2398–2399, 2401–2402, 2425, 2442, 2467–2470, 2474, 2476, 2478–2481, 2495, 2526–2527
Packs/CommonScripts/Scripts/StixCreator
   StixCreator.py1444171%73–77, 79–84, 86–90, 173–176, 225, 249–250, 257, 259–261, 270–271, 273–274, 276–277, 279–280, 282–283, 285–286, 306, 309
Packs/FeedDHS/Integrations/DHSFeedV2
   DHSFeedV2.py821384%85–86, 88–89, 91–92, 94–95, 97–98, 140, 143, 148
Packs/FeedGitHub/Integrations/FeedGitHub
   FeedGitHub.py2515777%27–30, 32, 36–38, 147–148, 196–198, 219, 237, 240–241, 371, 403–415, 449, 453, 455, 466–471, 473–474, 476–479, 481–485, 506–508, 515, 518, 531
Packs/FeedMitreAttackv2/Integrations/FeedMitreAttackv2
   FeedMitreAttackv2.py36211767%85–86, 89, 92–93, 96–98, 113, 116, 142, 153, 158–159, 163, 171–173, 177, 208, 405–409, 413–414, 416–418, 420–421, 426, 428, 432–433, 435, 437–438, 441, 443–444, 471–472, 475–476, 478–484, 486–488, 490–491, 549, 561, 575, 633, 635–637, 641, 643, 645–646, 649, 661–672, 674–676, 678–679, 681–682, 684–685, 687–688, 690–691, 693–696, 699–702, 704–706, 708–710, 712–713, 715–717, 720–722
Packs/FeedTAXII/Integrations/FeedTAXII2
   FeedTAXII2.py1252381%42–44, 47, 49, 129, 192, 197–207, 222–223, 232, 257–258
Packs/FeedUnit42v2/Integrations/FeedUnit42v2
   FeedUnit42v2.py3273090%59, 70–76, 78–81, 100, 156, 177, 196, 220, 275, 278, 318, 364, 407, 466, 523, 599–600, 605, 614, 617, 739
Packs/TAXIIServer/Integrations/TAXII2Server
   TAXII2Server.py4655189%79, 109, 116, 137, 162, 171, 177, 245, 284, 368–369, 451–452, 613–614, 616–619, 621, 634–635, 649–650, 666, 688–691, 712–715, 752–755, 777–780, 817–820, 866–869, 890–891
TOTAL285251382% 

Tests Skipped Failures Errors Time
439 0 💤 0 ❌ 0 🔥 36.136s ⏱️

Copy link
Contributor

@sapirshuker sapirshuker left a comment

Choose a reason for hiding this comment

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

Great

@content-bot
Copy link
Collaborator

This PR was automatically updated by a GitHub Action

  • CommonScripts pack version was bumped to 1.15.56.

To stop automatic version bumps, add the ignore-auto-bump-version label to the github PR.

@content-bot
Copy link
Collaborator

This PR was automatically updated by a GitHub Action

  • FeedMitreAttackv2 pack version was bumped to 1.1.41.

To stop automatic version bumps, add the ignore-auto-bump-version label to the github PR.

Copy link
Contributor

@AradCarmi AradCarmi left a comment

Choose a reason for hiding this comment

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

Great job!
Please see my comments bellow.

Packs/FeedUnit42v2/ReleaseNotes/1_0_57.md Outdated Show resolved Hide resolved
Packs/CommonScripts/ReleaseNotes/1_15_56.md Outdated Show resolved Hide resolved
@content-bot
Copy link
Collaborator

This PR was automatically updated by a GitHub Action

  • CommonScripts pack version was bumped to 1.15.57.

To stop automatic version bumps, add the ignore-auto-bump-version label to the github PR.

@content-bot
Copy link
Collaborator

This PR was automatically updated by a GitHub Action

  • CommonScripts pack version was bumped to 1.15.63.

To stop automatic version bumps, add the ignore-auto-bump-version label to the github PR.

@content-bot content-bot deleted the jl-fix-unit42-no-name branch November 12, 2024 00:12
@jlevypaloalto jlevypaloalto restored the jl-fix-unit42-no-name branch November 13, 2024 13:26
@jlevypaloalto jlevypaloalto reopened this Nov 13, 2024
@demisto demisto deleted a comment from content-bot Nov 13, 2024
@content-bot
Copy link
Collaborator

This PR was automatically updated by a GitHub Action

  • CommonScripts pack version was bumped to 1.15.89.
  • FeedMitreAttackv2 pack version was bumped to 1.1.44.

To stop automatic version bumps, add the ignore-auto-bump-version label to the github PR.

@content-bot
Copy link
Collaborator

This PR was automatically updated by a GitHub Action

  • CommonScripts pack version was bumped to 1.15.90.
  • FeedDHS pack version was bumped to 2.0.45.

To stop automatic version bumps, add the ignore-auto-bump-version label to the github PR.

@content-bot
Copy link
Collaborator

This PR was automatically updated by a GitHub Action

  • CommonScripts pack version was bumped to 1.15.91.

To stop automatic version bumps, add the ignore-auto-bump-version label to the github PR.

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

Successfully merging this pull request may close these issues.

5 participants