File tree Expand file tree Collapse file tree 10 files changed +21
-21
lines changed
Expand file tree Collapse file tree 10 files changed +21
-21
lines changed Original file line number Diff line number Diff line change 5757 uses : mshick/add-pr-comment@v2
5858 with :
5959 message-path : ${{ env.GUIDELINES_FILE }}
60- repo-token : ${{ secrets.PROTECTIONS_MACHINE_TOKEN }}
60+ repo-token : ${{ secrets.WRITE_DETECTION_RULES_PROTECTIONS_TOKEN }}
6161 message-id : " guidelines-comment"
Original file line number Diff line number Diff line change 3939
4040 - name : Update navigator gist files and docs/ATT&CK-coverage.md file.
4141 env :
42- GITHUB_TOKEN : " ${{ secrets.NAVIGATOR_GIST_TOKEN }}"
42+ GITHUB_TOKEN : " ${{ secrets.WRITE_DETECTION_RULES_NAVIGATOR_TOKEN }}"
4343 run : |
4444 python -m detection_rules dev update-navigator-gists "${{ github.event.inputs.update-coverage }}"
4545 git add docs/"ATT\&CK-coverage.md"
Original file line number Diff line number Diff line change 6767 - name : Checkout repo
6868 uses : actions/checkout@v2
6969 with :
70- token : ${{ secrets.PROTECTIONS_MACHINE_TOKEN }}
70+ token : ${{ secrets.WRITE_DETECTION_RULES_PROTECTIONS_TOKEN }}
7171 ref : main
7272 fetch-depth : 100
7373
@@ -161,6 +161,6 @@ jobs:
161161 - name : " Notify slack on failure"
162162 uses : craftech-io/slack-action@v1
163163 with :
164- slack_webhook_url : ${{ secrets.SLACK_WEBHOOK_URL }}
164+ READ_DETECTION_RULES_SLACK_WEBHOOK_TOKEN : ${{ secrets.READ_DETECTION_RULES_SLACK_WEBHOOK_TOKEN }}
165165 status : failure
166166 if : failure()
Original file line number Diff line number Diff line change 2222 with :
2323 url : " https://api.github.com/repos/elastic/detection-rules/actions/workflows/pythonpackage.yml/runs?per_page=1&branch=${{matrix.target_branch}}"
2424 method : ' GET'
25- bearerToken : ${{ secrets.READ_ORG_TOKEN }}
25+ bearerToken : ${{ secrets.READ_DETECTION_RULES_ORG_TOKEN }}
2626
2727 - name : Check Backport Status
2828 uses : actions/github-script@v6
Original file line number Diff line number Diff line change 1515 uses : actions/github-script@v6
1616 id : membership
1717 with :
18- github-token : ${{ secrets.READ_ORG_TOKEN }}
18+ github-token : ${{ secrets.READ_DETECTION_RULES_ORG_TOKEN }}
1919 result-encoding : string
2020 script : |
2121
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ name: Check MITRE ATT&CK Version Updates Are Synced
22
33on :
44 pull_request :
5- types :
5+ types :
66 - opened
77 paths :
88 - ' detection_rules/etc/attack-v*.json.gz'
1818 id : changed-attack-files
1919 uses : tj-actions/changed-files@v44
2020 with :
21- files : detection_rules/etc/attack-v*.json.gz
22-
21+ files : detection_rules/etc/attack-v*.json.gz
22+
2323 - name : Extract version from file name
2424 id : extract_version
2525 if : steps.changed-attack-files.outputs.any_changed == 'true'
3333 run : |
3434 ISSUE_TITLE="[Security Solution] Update MITRE ATT&CK to ${{ steps.extract_version.outputs.version }}"
3535 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."
36-
36+
3737 curl -X POST \
38- -H "Authorization: token ${{ secrets.READ_WRITE_KIBANA_TOKEN }}" \
38+ -H "Authorization: token ${{ secrets.WRITE_DETECTION_RULES_KIBANA_TOKEN }}" \
3939 -H "Accept: application/vnd.github.v3+json" \
4040 https://api.github.com/repos/elastic/kibana/issues \
4141 -d '{
4444 }'
4545
4646 env :
47- GITHUB_TOKEN : ${{ secrets.READ_WRITE_KIBANA_TOKEN }}
47+ GITHUB_TOKEN : ${{ secrets.WRITE_DETECTION_RULES_KIBANA_TOKEN }}
Original file line number Diff line number Diff line change 2121 - name : Checkout detection-rules
2222 uses : actions/checkout@v3
2323 with :
24- token : ${{ secrets.PROTECTIONS_MACHINE_TOKEN }}
24+ token : ${{ secrets.WRITE_DETECTION_RULES_PROTECTIONS_TOKEN }}
2525 fetch-depth : 0
2626
2727 - name : Set github config
8181 - name : " Notify slack on failure"
8282 uses : craftech-io/slack-action@v1
8383 with :
84- slack_webhook_url : ${{ secrets.SLACK_WEBHOOK_URL }}
84+ READ_DETECTION_RULES_SLACK_WEBHOOK_TOKEN : ${{ secrets.READ_DETECTION_RULES_SLACK_WEBHOOK_TOKEN }}
8585 status : failure
8686 if : failure()
Original file line number Diff line number Diff line change @@ -15,11 +15,11 @@ jobs:
1515 - uses : actions/checkout@v4
1616 with :
1717 fetch-depth : 1
18-
18+
1919 - name : Fetch main branch
2020 run : |
2121 git fetch origin main:refs/remotes/origin/main
22-
22+
2323 - name : Set up Python 3.12
2424 uses : actions/setup-python@v5
2525 with :
6464
6565 - name : Update navigator gist files
6666 env :
67- GITHUB_TOKEN : " ${{ secrets.NAVIGATOR_GIST_TOKEN }}"
67+ GITHUB_TOKEN : " ${{ secrets.WRITE_DETECTION_RULES_NAVIGATOR_TOKEN }}"
6868 if : ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
6969 run : python -m detection_rules dev update-navigator-gists
Original file line number Diff line number Diff line change 3131 - name : Checkout elastic/security-docs
3232 uses : actions/checkout@v3
3333 with :
34- token : ${{ secrets.READ_WRITE_RELEASE_FLEET }}
34+ token : ${{ secrets.WRITE_DETECTION_RULES_RELEASE_FLEET_TOKEN }}
3535 repository : " elastic/security-docs"
3636 path : security-docs
3737 fetch-depth : 0
7979
8080 - name : Create PR to elastic/security-docs
8181 env :
82- GITHUB_TOKEN : ${{ secrets.PROTECTIONS_MACHINE_TOKEN }}
82+ GITHUB_TOKEN : ${{ secrets.WRITE_DETECTION_RULES_PROTECTIONS_TOKEN }}
8383 POST_VERSION : " v${{ github.event.inputs.post_version }}"
8484 TARGET_BRANCH : " ${{ github.event.inputs.target_branch }}"
8585 UPDATE_BRANCH : " update-security-docs-prebuilt-rules-${{github.event.inputs.post_version}}"
Original file line number Diff line number Diff line change 6868 - name : Checkout elastic/integrations
6969 uses : actions/checkout@v3
7070 with :
71- token : ${{ secrets.READ_WRITE_RELEASE_FLEET }}
71+ token : ${{ secrets.WRITE_DETECTION_RULES_RELEASE_FLEET_TOKEN }}
7272 repository : ${{github.event.inputs.target_repo}}
7373 path : integrations
7474 fetch-depth : 0
@@ -138,7 +138,7 @@ jobs:
138138 TARGET_REPO : " ${{github.event.inputs.target_repo}}"
139139 TARGET_BRANCH : " ${{github.event.inputs.target_branch}}"
140140 LOCAL_REPO : " ../integrations"
141- GITHUB_TOKEN : " ${{ secrets.READ_WRITE_RELEASE_FLEET }}"
141+ GITHUB_TOKEN : " ${{ secrets.WRITE_DETECTION_RULES_RELEASE_FLEET_TOKEN }}"
142142 run : |
143143 cd detection-rules
144144 python -m detection_rules dev integrations-pr \
You can’t perform that action at this time.
0 commit comments