Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Metasploit 5.0 for Beginners

You're reading from   Metasploit 5.0 for Beginners Perform penetration testing to secure your IT environment against threats and vulnerabilities

Arrow left icon
Product type Paperback
Published in Apr 2020
Publisher
ISBN-13 9781838982669
Length 246 pages
Edition 2nd Edition
Arrow right icon
Author (1):
Arrow left icon
Sagar Rahalkar Sagar Rahalkar
Author Profile Icon Sagar Rahalkar
Sagar Rahalkar
Arrow right icon
View More author details
Toc

Table of Contents (15) Chapters Close

Preface 1. Section 1: Introduction and Environment Setup
2. Chapter 1: Introduction to Metasploit and Supporting Tools FREE CHAPTER 3. Chapter 2: Setting Up Your Environment 4. Chapter 3: Metasploit Components and Environment Configuration 5. Section 2: Practical Metasploit
6. Chapter 4: Information Gathering with Metasploit 7. Chapter 5: Vulnerability Hunting with Metasploit 8. Chapter 6: Client-Side Attacks with Metasploit 9. Chapter 7: Web Application Scanning with Metasploit 10. Chapter 8: Antivirus Evasion and Anti-Forensics 11. Chapter 9: Cyber Attack Management with Armitage 12. Chapter 10: Extending Metasploit and Exploit Development 13. Chapter 11: Case Studies 14. Other Books You May Enjoy

Understanding exploit templates and mixins

Let's suppose that you have written an exploit code for a new zero-day vulnerability. Now, if you want to make it part of the Metasploit Framework, you need to ensure it is in a particular format. Fortunately, you just need to focus on the actual exploit code and then simply use a readily available template (provided by the Metasploit Framework) to insert it in the required format.

The exploit module skeleton is readily provided by the Metasploit Framework, as in the following code:

##
# This module requires Metasploit: http://metasploit.com/download
# Current source: https://github.com/rapid7/metasploit-framework
##
require 'msf/core'
class MetasploitModule < Msf::Exploit::Remote
Rank = NormalRanking
def initialize(info={})
super(update_info(info,
'Name' => '[Vendor] [Software] [Root Cause] [Vulnerability type]',
'Description' => %q{
Say something that the user might need to know...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime