Method: PacketFu::TcpOption::ECHO#decode

Defined in:
lib/packetfu/protos/tcp/option.rb

#decodeObject

ECHO options with lengths other than 6 are malformed.



251
252
253
254
255
256
257
# File 'lib/packetfu/protos/tcp/option.rb', line 251

def decode
  if self[:optlen].to_i == 6
    "ECHO:#{self[:value]}"
  else
    "ECHO-bad:#{self[:value]}"
  end
end