forked from p15670423/monkey
Minor refactoring and typo fix
This commit is contained in:
parent
87dafeb440
commit
2dfcbb49d4
|
@ -8,7 +8,7 @@ class SERVICE_TYPES(Enum):
|
||||||
ACM = 'acm'
|
ACM = 'acm'
|
||||||
AWSLAMBDA = 'awslambda'
|
AWSLAMBDA = 'awslambda'
|
||||||
CLOUDFORMATION = 'cloudformation'
|
CLOUDFORMATION = 'cloudformation'
|
||||||
CLOUSDTRAIL = 'cloudtrail'
|
CLOUDTRAIL = 'cloudtrail'
|
||||||
CLOUDWATCH = 'cloudwatch'
|
CLOUDWATCH = 'cloudwatch'
|
||||||
CONFIG = 'config'
|
CONFIG = 'config'
|
||||||
DIRECTCONNECT = 'directconnect'
|
DIRECTCONNECT = 'directconnect'
|
||||||
|
|
|
@ -6,5 +6,5 @@ from monkey_island.cc.services.zero_trust.scoutsuite.data_parsing.rule_path_buil
|
||||||
|
|
||||||
class CloudTrailRulePathCreator(AbstractRulePathCreator):
|
class CloudTrailRulePathCreator(AbstractRulePathCreator):
|
||||||
|
|
||||||
service_type = SERVICE_TYPES.CLOUSDTRAIL
|
service_type = SERVICE_TYPES.CLOUDTRAIL
|
||||||
supported_rules = CloudTrailRules
|
supported_rules = CloudTrailRules
|
||||||
|
|
|
@ -12,11 +12,8 @@ export default function ScoutSuiteRuleModal(props) {
|
||||||
const [openRuleId, setOpenRuleId] = useState(null)
|
const [openRuleId, setOpenRuleId] = useState(null)
|
||||||
|
|
||||||
function toggleRuleDropdown(ruleId) {
|
function toggleRuleDropdown(ruleId) {
|
||||||
if (openRuleId === ruleId) {
|
let ruleIdToSet = (openRuleId === ruleId) ? null : ruleId;
|
||||||
setOpenRuleId(null);
|
setOpenRuleId(ruleIdToSet);
|
||||||
} else {
|
|
||||||
setOpenRuleId(ruleId);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function renderRuleDropdowns() {
|
function renderRuleDropdowns() {
|
||||||
|
|
Loading…
Reference in New Issue