I think fail_with could be used here:

````
fail_with(Exploit::Failure::Unknown, e.message)
```