This repo has submodules! Remember to run
git submodule init; git submodule update
after cloning.
To build the gem (currently requires linux):
rake build
To completely reset your dev environment and delete all binary artifacts:
rake mettle:ultraclean
The gem provides one function for accessing binary payloads:
MetasploitPayloads::Mettle.read(platform_triple, artifact)The available platform triples are:
aarch64-linux-muslarmv5l-linux-musleabiarmv5b-linux-musleabii486-linux-muslx86_64-linux-muslpowerpc-linux-muslsfpowerpc64le-linux-muslmips-linux-muslsfmipsel-linux-muslsfmips64-linux-muslsf
The available artifacts are:
mettle- a standalone executable that take command-line arguments (seemettle -h)mettle.bin- a process image that must be started with a custom stack (seedoc/stack_requirements.md)
To pull your local changes of mettle into your Metasploit install:
- Add
-devto the version inlib/metasploit-payloads/mettle/version.rb - Build the gem as above
- Copy
pkg/metasploit-payloads-mettle-X.X.X.pre.dev.gemto the box you are using for Metasploit if it is different - Change the version in your metasploit-framework.gemspec to match the one you just build
gem install <path to new gem>- Run
bundle installin your Framework directory - Congrats, you are now done!