Module: PacketFu::ICMPHeaderMixin

Included in:
ICMPPacket
Defined in:
lib/packetfu/protos/icmp/mixin.rb

Overview

This Mixin simplifies access to the ICMPHeaders. Mix this in with your packet interface, and it will add methods that essentially delegate to the ‘icmp_header’ method (assuming that it is a ICMPHeader object)

Instance Method Summary collapse

Instance Method Details

#icmp_calc_sumObject



13
# File 'lib/packetfu/protos/icmp/mixin.rb', line 13

def icmp_calc_sum; self.icmp_header.icmp_calc_sum; end

#icmp_codeObject



10
# File 'lib/packetfu/protos/icmp/mixin.rb', line 10

def icmp_code; self.icmp_header.icmp_code; end

#icmp_code=(v) ⇒ Object



9
# File 'lib/packetfu/protos/icmp/mixin.rb', line 9

def icmp_code=(v); self.icmp_header.icmp_code= v; end

#icmp_recalc(*v) ⇒ Object



14
# File 'lib/packetfu/protos/icmp/mixin.rb', line 14

def icmp_recalc(*v); self.icmp_header.icmp_recalc(*v); end

#icmp_sumObject



12
# File 'lib/packetfu/protos/icmp/mixin.rb', line 12

def icmp_sum; self.icmp_header.icmp_sum; end

#icmp_sum=(v) ⇒ Object



11
# File 'lib/packetfu/protos/icmp/mixin.rb', line 11

def icmp_sum=(v); self.icmp_header.icmp_sum= v; end

#icmp_sum_readableObject



15
# File 'lib/packetfu/protos/icmp/mixin.rb', line 15

def icmp_sum_readable; self.icmp_header.icmp_sum_readable; end

#icmp_typeObject



8
# File 'lib/packetfu/protos/icmp/mixin.rb', line 8

def icmp_type; self.icmp_header.icmp_type; end

#icmp_type=(v) ⇒ Object



7
# File 'lib/packetfu/protos/icmp/mixin.rb', line 7

def icmp_type=(v); self.icmp_header.icmp_type= v; end