Documentation for Floodingattack Module¶
FloodingAttack
¶
Bases: CommunicationAttack
Implements an attack that delays the execution of a target method by a specified amount of time.
Source code in nebula/addons/attacks/communications/floodingattack.py
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 |
|
__init__(engine, attack_params)
¶
Initializes the DelayerAttack with the engine and attack parameters.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
engine
|
The engine managing the attack context. |
required | |
attack_params
|
dict
|
Parameters for the attack, including the delay duration. |
required |
Source code in nebula/addons/attacks/communications/floodingattack.py
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 |
|
decorator(flooding_factor)
¶
Decorator that adds a delay to the execution of the original method.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
flooding_factor
|
int
|
The number of times to repeat the function execution. |
required |
Returns:
Name | Type | Description |
---|---|---|
function |
A decorator function that wraps the target method with the delay logic. |
Source code in nebula/addons/attacks/communications/floodingattack.py
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 |
|