GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — atc-react/scripts/react_navigator.py at master · efeerdur/atc-react

Expand file tree

/

react_navigator.py

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
112 lines (98 loc) · 2.95 KB
/

react_navigator.py

Copy path

File metadata and controls

112 lines (98 loc) · 2.95 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#!/usr/bin/env python3
try:
from scripts.reactutils import REACTutils
from scripts.react_mapping import ra_mapping
from scripts.update_react_mapping import UpdateReactMapping
except:
from response.atc_react.scripts.reactutils import REACTutils
from response.atc_react.scripts.react_mapping import ra_mapping
from response.atc_react.scripts.update_react_mapping import UpdateReactMapping
from os import listdir
from os.path import isfile, join
import json
REACTConfig = REACTutils.load_config("config.yml")
filename = 'react_navigator_profile.json'
directory = REACTConfig.get('exported_analytics_directory')
NAVIGATOR_TEMPLATE = {
"name": "RE&CT Enterprise Matrix",
"version": "2.2",
"domain": "atc-react",
"description": "Response Stages and Response Actions, colorized by Categories",
"sorting": 2,
"viewMode": 0,
"hideDisabled": True,
"techniques": [],
"gradient": {
"colors": [
"#ff6666",
"#ffe766",
"#8ec843"
],
"minValue": 0,
"maxValue": 100
},
"legendItems": [ # thanks, Olaf!
{
"label": "General cagetory",
"color": "#FFD300"
},
{
"label": "Network cagetory",
"color": "#ABC530"
},
{
"label": "Email cagetory",
"color": "#01C26D"
},
{
"label": "File cagetory",
"color": "#007B84"
},
{
"label": "Process cagetory",
"color": "#075190"
},
{
"label": "Configuration cagetory",
"color": "#86308C"
},
{
"label": "Identity cagetory",
"color": "#482569"
},
],
"showTacticRowBackground": False,
"tacticRowBackground": "#dddddd",
"selectTechniquesAcrossTactics": True
}
# thanks again, Olaf!
category_colors = {
"General": '#ffd300',
"Network": '#abc530',
"Email": '#01c26d',
"File": '#007b84',
"Process": '#075190',
"Configuration": '#86308c',
"Identity": '#482569'
}
class GenerateNavigator:
def __init__(self):
UpdateReactMapping()
response_actions = []
for ra_id, ra_name in ra_mapping.items():
ra_color = ""
category_score = int(ra_id[3:6])
ra_category = REACTutils.get_ra_category(ra_id)
for category_name, category_color in category_colors.items():
if ra_category == category_name:
ra_color = category_color
break
response_actions.append({
"techniqueID": ra_id,
"color": ra_color,
"score": category_score, # for sorting
})
NAVIGATOR_TEMPLATE['techniques'] = response_actions
with open(directory + '/' + filename, 'w') as fp:
json.dump(NAVIGATOR_TEMPLATE, fp)
print(f'[+] Created {filename}')
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.