Skip to content

feat(observables): auto-populate AS number from Autonomous-System name (#8383)#16743

Merged
mcartaud merged 1 commit into
masterfrom
issue/8383-autonomous-system-creation-process
Jun 24, 2026
Merged

feat(observables): auto-populate AS number from Autonomous-System name (#8383)#16743
mcartaud merged 1 commit into
masterfrom
issue/8383-autonomous-system-creation-process

Conversation

@mcartaud

Copy link
Copy Markdown
Member

When creating an Autonomous-System observable, automatically parse and set the number field if the name matches the pattern AS<number> (e.g., typing "AS1234" fills in 1234 as the AS number).

Proposed changes

  • Auto populate AS number field if name field is provided and starts with AS

Related issues

How to test this PR

Checklist

  • I consider the submitted work as finished
  • I tested the code for its functionality
  • I wrote test cases for the relevant use cases (coverage and e2e)
  • I added/updated the relevant documentation (either on GitHub or on Notion)
  • Where necessary, I refactored code to improve the overall quality

Further comments

Copilot AI review requested due to automatic review settings June 22, 2026 12:40
@github-actions github-actions Bot added the filigran team Item from the Filigran team. label Jun 22, 2026

Copilot AI 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.

Pull request overview

This PR updates the frontend Stix Cyber Observable creation drawer to improve the Autonomous System creation UX by deriving the mandatory number field from the name when the name follows the AS<number> pattern.

Changes:

  • Add a special-case handler for Autonomous-System name input to parse AS1234-style values and populate number.
  • Minor JSX formatting/indentation adjustments around the bulk creation button rendering.

@codecov

codecov Bot commented Jun 22, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 24.09%. Comparing base (901d6dc) to head (b3d69a1).

Files with missing lines Patch % Lines
..._cyber_observables/StixCyberObservableCreation.jsx 0.00% 8 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master   #16743      +/-   ##
==========================================
- Coverage   24.09%   24.09%   -0.01%     
==========================================
  Files        3271     3271              
  Lines      173266   173274       +8     
  Branches    42956    42960       +4     
==========================================
  Hits        41744    41744              
- Misses     131522   131530       +8     
Flag Coverage Δ
opencti-client-python 46.30% <ø> (ø)
opencti-front 5.62% <0.00%> (-0.01%) ⬇️
opencti-graphql 66.64% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

When creating an Autonomous-System observable, automatically parse
and set the `number` field if the name matches the pattern
`AS<number>` (e.g., typing "AS1234" fills in 1234 as the AS number).
@mcartaud mcartaud force-pushed the issue/8383-autonomous-system-creation-process branch from 0b8e828 to b3d69a1 Compare June 22, 2026 12:55
@Gwendoline-FAVRE-FELIX

Copy link
Copy Markdown
Member

It works well, but I have a question. What about the update? Do we want the number to change automatically if we change the name?

@mcartaud

Copy link
Copy Markdown
Member Author

It works well, but I have a question. What about the update? Do we want the number to change automatically if we change the name?

Working on updates was planned but:

  • we don't want to override value written by the user, so if something is in the number field, we must no update it
  • the number field is a mandatory field, so it always have a value

So the feature is only useful at creation.
It was also planned to update CSV ingestion with that but same story, the number column is mandatory, not the name one, making only a small change to handle the same feature would have make the CSV configuration clumsy, so not doing it will be part of a more ambitious change someday

@mcartaud mcartaud merged commit fbd75f5 into master Jun 24, 2026
46 checks passed
@mcartaud mcartaud deleted the issue/8383-autonomous-system-creation-process branch June 24, 2026 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

filigran team Item from the Filigran team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(ingestion): streamline the Autonomous System creation process

3 participants