2021-06-14 11:34:04 +01:00
New Metasploit modules are now required to contain a `Notes` section containing additional information such as the `Stability` , `Reliability` and `SideEffects` associated with running the module.
2021-06-11 10:56:47 +01:00
Example:
2021-06-11 10:54:39 +01:00
``` ruby
def initialize ( info = { } )
super (
update_info (
info ,
'Name' = > 'Module name' ,
'Description' = > %q{
Module description
} ,
'Author' = >
[
'Author name'
] ,
'License' = > MSF_LICENSE ,
'References' = >
[
[ 'CVE' , '2020-XXXX' ]
] ,
'DisclosureDate' = > '2020-03-26' ,
'Platform' = > 'ruby' ,
'Arch' = > ARCH_RUBY ,
'Privileged' = > false ,
'Targets' = > [ [ 'Automatic' , { } ] ] ,
'DefaultTarget' = > 0 ,
2021-06-11 11:03:56 +01:00
# All new modules must contain the below information. See below for more details for allowed values
2021-06-11 10:54:39 +01:00
'Notes' = > {
'Stability' = > [ ... ] ,
'Reliability' = > [ ... ] ,
'SideEffects' = > [ ... ]
}
)
)
end
```
2021-06-11 11:03:56 +01:00
## Allowed Values
2021-06-11 11:04:11 +01:00
### Stability
2018-11-02 10:20:48 -05:00
| Constant | Description |
| -------------- | ------------- |
2018-11-02 10:22:42 -05:00
| CRASH_SAFE | Module should not crash the service or OS |
2018-11-02 10:20:48 -05:00
| CRASH_SERVICE_RESTARTS | Module may crash the service, but it will restart |
| CRASH_SERVICE_DOWN | Module may crash the service, and remain down |
| CRASH_OS_RESTARTS | Module may crash the OS, but it will restart |
| CRASH_OS_DOWN | Module may crash the OS, and remain down |
| SERVICE_RESOURCE_LOSS | Module causes a resource to be unavailable for the service |
| OS_RESOURCE_LOSS | Module causes a resource to be unavailable for the OS |
2021-06-11 11:04:11 +01:00
### Side Effects
2018-11-02 10:20:48 -05:00
| Constant | Description |
| -------------- | ------------- |
| ARTIFACTS_ON_DISK | Module leaves a payload, a dropper, etc, on the target machine |
| CONFIG_CHANGES | Module modifies some config file |
| IOC_IN_LOGS | Module leaves an indicator of compromise in the log(s) |
2019-04-03 15:43:48 -05:00
| ACCOUNT_LOCKOUTS | Module may cause an account to lock out |
2018-11-02 10:20:48 -05:00
| SCREEN_EFFECTS | Module shows something on the screen that a human may notice |
| PHYSICAL_EFFECTS | Module may produce physical effects in hardware (Examples: light, sound, or heat) |
2019-04-03 15:41:56 -05:00
| AUDIO_EFFECTS | Module may cause a noise (Examples: Audio output from the speakers or hardware beeps) |
2018-11-02 10:20:48 -05:00
2021-06-11 11:03:56 +01:00
### Reliability
2018-11-02 10:20:48 -05:00
| Constant | Description |
| -------------- | ------------- |
| FIRST_ATTEMPT_FAIL | The module may fail for the first attempt |
2019-04-03 15:37:15 -05:00
| REPEATABLE_SESSION | The module is expected to get a session every time it runs |
2021-06-11 10:54:39 +01:00
| UNRELIABLE_SESSION | The module isn't expected to get a shell reliably (such as only once) |