Skip to content

Commit

Permalink
Update on feedback from jmartin
Browse files Browse the repository at this point in the history
  • Loading branch information
bwatters-r7 committed Oct 2, 2023
1 parent 48dcb24 commit 42f6bb8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions docs/metasploit-framework.wiki/How-to-write-a-check-method.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,9 @@ The `CheckCode` also supports an optional description which is printed by the fr
return CheckCode::Appears('Vulnerable component XYZ is installed')
```

Metasploit Framework check methods are used occasionally by other groups and projects to assist with vulnerability scanning. Please do your best to ensure that the only return value from a check method is a check code.
Basically, that means avoiding the use of `fail_with` or raising exceptions that are not handled within the check method.
`MetasploitModule#check` methods should capture any known `raise` from methods called and return value of class
`Msf::Exploit::CheckCode`. Basically, that means avoiding the use of `fail_with` or raising exceptions that are not
handled within the check method.

## Remote Check Example

Expand Down

0 comments on commit 42f6bb8

Please sign in to comment.