-
Notifications
You must be signed in to change notification settings - Fork 587
Create an Issue in Kibana for MITRE Updates #3796
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
Merged
Merged
Changes from all commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
67e75ea
Create an Issue in Kibana for MITRE Updates
shashank-elastic e30b55d
Merge branch 'main' into issue-3100
shashank-elastic bcff3c0
Update Token
shashank-elastic 2ea8d8e
Merge branch 'main' into issue-3100
shashank-elastic cdcbe88
Update GITHUB_TOKEN
shashank-elastic fc3fc25
Manual testing
shashank-elastic 8ce3573
Introdue file change and issue creation changes
shashank-elastic c752142
Introdue file change and issue creation changes
shashank-elastic ee691ef
Manual testing
shashank-elastic a7cc15c
Manual testing
shashank-elastic 7c5072c
Manual testing
shashank-elastic fce2dd9
Manual testing
shashank-elastic 45a7668
Manual testing
shashank-elastic 7eb1b9b
Manual testing
shashank-elastic 24e2c4e
Manual testing
shashank-elastic 2843e23
Manual testing
shashank-elastic 2df7dc6
Manual testing
shashank-elastic ec52b9d
Manual testing
shashank-elastic c61c56e
Manual testing
shashank-elastic 64c6298
Revert Manual testing
shashank-elastic 1e337ad
Better Issue Title
shashank-elastic 964799b
Merge branch 'main' into issue-3100
shashank-elastic e0ede8f
Merge branch 'main' into issue-3100
shashank-elastic File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Check MITRE ATT&CK Version Updates Are Synced | ||
|
||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
paths: | ||
- 'detection_rules/etc/attack-v*.json.gz' | ||
|
||
jobs: | ||
create_issue: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Get MITRE Attack changed files | ||
id: changed-attack-files | ||
uses: tj-actions/changed-files@v44 | ||
with: | ||
files: detection_rules/etc/attack-v*.json.gz | ||
|
||
- name: Extract version from file name | ||
id: extract_version | ||
if: steps.changed-attack-files.outputs.any_changed == 'true' | ||
env: | ||
ADDED_FILE: ${{ steps.changed-attack-files.outputs.added_files }} | ||
run: | | ||
VERSION=$(echo $ADDED_FILE[0] | grep -o 'v[^json]*') | ||
echo "::set-output name=version::$VERSION" | ||
|
||
- name: Create issue in elastic/kibana repository | ||
run: | | ||
ISSUE_TITLE="[Security Solution] Update MITRE ATT&CK to ${{ steps.extract_version.outputs.version }}" | ||
ISSUE_BODY="The detection rules MITRE ATT&CK version has been updated to ${{ steps.extract_version.outputs.version }} Please update the MITRE ATT&CK version in Kibana accordingly." | ||
|
||
curl -X POST \ | ||
-H "Authorization: token ${{ secrets.READ_WRITE_KIBANA_TOKEN }}" \ | ||
-H "Accept: application/vnd.github.v3+json" \ | ||
https://api.github.com/repos/elastic/kibana/issues \ | ||
-d '{ | ||
"title": "'"$ISSUE_TITLE"'", | ||
"body": "'"$ISSUE_BODY"'" | ||
}' | ||
|
||
env: | ||
GITHUB_TOKEN: ${{ secrets.READ_WRITE_KIBANA_TOKEN }} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.