From 13a94804b44150877ab2b6d195478c4427acaaaf Mon Sep 17 00:00:00 2001 From: Shreya Date: Tue, 29 Jun 2021 16:02:20 +0530 Subject: [PATCH] cc: Add checkbox for ransomware encryption --- .../cc/services/config_schema/ransomware.py | 41 ++++++++++++------- 1 file changed, 27 insertions(+), 14 deletions(-) diff --git a/monkey/monkey_island/cc/services/config_schema/ransomware.py b/monkey/monkey_island/cc/services/config_schema/ransomware.py index bf7d5aced..09f9c80ea 100644 --- a/monkey/monkey_island/cc/services/config_schema/ransomware.py +++ b/monkey/monkey_island/cc/services/config_schema/ransomware.py @@ -2,23 +2,36 @@ RANSOMWARE = { "title": "Ransomware", "type": "object", "properties": { - "directories": { - "title": "Directories to encrypt", + "encryption": { + "title": "Encryption", "type": "object", "properties": { - "linux_dir": { - "title": "Linux encryptable directory", - "type": "string", - "default": "", - "description": "Files in the specified directory will be encrypted " - "using bitflip to simulate ransomware.", + "should_encrypt": { + "title": "Encrypt files", + "type": "boolean", + "default": True, + "description": "Selected files will be encrypted using bitflip to simulate " + "ransomware. Enter target directories below.", }, - "windows_dir": { - "title": "Windows encryptable directory", - "type": "string", - "default": "", - "description": "Files in the specified directory will be encrypted " - "using bitflip to simulate ransomware.", + "directories": { + "title": "Directories to encrypt", + "type": "object", + "properties": { + "linux_dir": { + "title": "Linux encryptable directory", + "type": "string", + "default": "", + "description": "Files in the specified directory will be encrypted " + "using bitflip to simulate ransomware.", + }, + "windows_dir": { + "title": "Windows encryptable directory", + "type": "string", + "default": "", + "description": "Files in the specified directory will be encrypted " + "using bitflip to simulate ransomware.", + }, + }, }, }, },