2014-08-22 17:49:28 +00:00
|
|
|
# -*- coding: binary -*-
|
|
|
|
require 'rex/proto/natpmp'
|
|
|
|
|
|
|
|
module Msf
|
|
|
|
|
|
|
|
###
|
|
|
|
#
|
|
|
|
# This module provides methods for working with NAT-PMP
|
|
|
|
#
|
|
|
|
###
|
|
|
|
module Auxiliary::NATPMP
|
|
|
|
|
|
|
|
include Auxiliary::Scanner
|
2014-08-22 18:01:17 +00:00
|
|
|
include Rex::Proto::NATPMP
|
2014-08-22 17:49:28 +00:00
|
|
|
|
|
|
|
def initialize(info = {})
|
|
|
|
super
|
|
|
|
register_options(
|
|
|
|
[
|
|
|
|
Opt::RPORT(Rex::Proto::NATPMP::DefaultPort),
|
|
|
|
Opt::CHOST
|
|
|
|
],
|
|
|
|
self.class
|
|
|
|
)
|
|
|
|
end
|
2014-10-15 13:39:38 +00:00
|
|
|
|
|
|
|
def lifetime
|
|
|
|
@lifetime ||= datastore['LIFETIME']
|
|
|
|
end
|
|
|
|
|
|
|
|
def protocol
|
|
|
|
@protocol ||= datastore['PROTOCOL']
|
|
|
|
end
|
2014-08-22 17:49:28 +00:00
|
|
|
end
|
|
|
|
end
|