Cosmetic changes to notebook

This commit is contained in:
Marek Wolan
2024-03-05 09:28:22 +00:00
parent 758f892b74
commit 3e495c4622

View File

@@ -120,11 +120,11 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"### Red Configuration\n",
"## Red Configuration\n",
"\n",
"There are two important parts of the YAML config for varying red agent behaviour.\n",
"\n",
"#### The red agent settings\n",
"### Red agent settings\n",
"Here is an annotated config for the red agent in the data manipulation scenario.\n",
"```yaml\n",
" - ref: data_manipulation_attacker # name of agent\n",
@@ -172,7 +172,7 @@
" variance: 5 # the timing of attacks will vary by up to 5 steps earlier or later\n",
"```\n",
"\n",
"#### The settings of the red agent's attack application\n",
"### Malicious application settings\n",
"The red agent uses an application called `DataManipulationBot` which leverages a node's `DatabaseClient` to send a malicious SQL query to the database server. Here's an annotated example of how this is configured in the yaml *(with impertinent config items omitted)*:\n",
"```yaml\n",
"simulation:\n",
@@ -205,9 +205,11 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"## Editing red agent settings\n",
"\n",
"### Removing randomness from attack timing\n",
"\n",
"We can make the attacks happen at completely predictable intervals if we set the variance parameter of the red agent to 0."
"We can make the attacks happen at completely predictable intervals if we edit the red agent's settings to set variance to 0."
]
},
{
@@ -243,7 +245,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Making the start node always the same\n",
"### Making the start node always the same\n",
"\n",
"Normally, the agent randomly chooses between the nodes in its action space to send attacks from:"
]
@@ -254,7 +256,7 @@
"metadata": {},
"outputs": [],
"source": [
"# Open the config without changing anyhing\n",
"# Open the config without changing anything\n",
"with open(data_manipulation_config_path(), 'r') as f:\n",
" cfg = yaml.safe_load(f)\n",
"\n",
@@ -320,7 +322,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"#### Make the attack less likely to succeed.\n",
"### Make the attack less likely to succeed.\n",
"\n",
"We can change the success probabilities within the data manipulation bot application. When the attack succeeds, the reward goes down.\n",
"\n",