Module: PatronusFati::MessageModels

Defined in:
lib/patronus_fati/message_models.rb,
lib/patronus_fati/message_models/ack.rb,
lib/patronus_fati/message_models/gps.rb,
lib/patronus_fati/message_models/info.rb,
lib/patronus_fati/message_models/ssid.rb,
lib/patronus_fati/message_models/time.rb,
lib/patronus_fati/message_models/alert.rb,
lib/patronus_fati/message_models/bssid.rb,
lib/patronus_fati/message_models/error.rb,
lib/patronus_fati/message_models/client.rb,
lib/patronus_fati/message_models/clisrc.rb,
lib/patronus_fati/message_models/clitag.rb,
lib/patronus_fati/message_models/common.rb,
lib/patronus_fati/message_models/kismet.rb,
lib/patronus_fati/message_models/nettag.rb,
lib/patronus_fati/message_models/packet.rb,
lib/patronus_fati/message_models/plugin.rb,
lib/patronus_fati/message_models/remove.rb,
lib/patronus_fati/message_models/source.rb,
lib/patronus_fati/message_models/status.rb,
lib/patronus_fati/message_models/string.rb,
lib/patronus_fati/message_models/wepkey.rb,
lib/patronus_fati/message_models/battery.rb,
lib/patronus_fati/message_models/channel.rb,
lib/patronus_fati/message_models/bssidsrc.rb,
lib/patronus_fati/message_models/critfail.rb,
lib/patronus_fati/message_models/spectrum.rb,
lib/patronus_fati/message_models/btscandev.rb,
lib/patronus_fati/message_models/protocols.rb,
lib/patronus_fati/message_models/terminate.rb,
lib/patronus_fati/message_models/trackinfo.rb,
lib/patronus_fati/message_models/capability.rb

Overview

Note:

In all of the message models the ordering of the attributes is actually important, as these are the default orderings provided by the server I was developing against. The casing of the name is also important as the best we can automatically do from the header information is a downcase and capitalize.

Constant Summary collapse

Ack =
CapStruct.new(:cmdid, :text)
Gps =
CapStruct.new(:lat, :lon, :alt, :spd, :heading, :fix, :satinfo, :hdop, :vdop, :connected)
Info =
CapStruct.new(
  :networks, :packets, :crypt, :noise, :dropped, :rate, :filtered, :clients,
  :llcpackets, :datapackets, :numsources, :numerrorsources
)
Ssid =

NOTE: If you change these fields the SSID message parser needs to be manually updated since these fields are very broken.

CapStruct.new(
  :mac, :checksum, :type, :ssid, :beaconinfo, :cryptset, :cloaked,
  :maxrate, :beaconrate, :firsttime, :lasttime, :wps, :wps_device_name,
  :wps_manuf, :wps_model_name, :wps_model_number
)
Time =
CapStruct.new(:timesec)
Alert =
CapStruct.new(
  :sec, :usec, :header, :bssid, :source, :dest, :other, :channel, :text
)
Bssid =
CapStruct.new(
  :bssid, :type, :llcpackets, :datapackets, :cryptpackets, :manuf, :channel,
  :firsttime, :lasttime, :atype, :rangeip, :netmaskip, :gatewayip, :gpsfixed,
  :minlat, :minlon, :minalt, :minspd, :maxlat, :maxlon, :maxalt, :maxspd,
  :signal_dbm, :noise_dbm, :minsignal_dbm, :minnoise_dbm, :maxsignal_dbm,
  :maxnoise_dbm, :signal_rssi, :noise_rssi, :minsignal_rssi, :minnoise_rssi,
  :maxsignal_rssi, :maxnoise_rssi, :bestlat, :bestlon, :bestalt, :agglat,
  :agglon, :aggalt, :aggpoints, :datasize, :turbocellnid, :turbocellmode,
  :turbocellsat, :carrierset, :maxseenrate, :encodingset, :decrypted,
  :dupeivpackets, :bsstimestamp, :cdpdevice, :cdpport, :fragments, :retries,
  :newpackets, :freqmhz, :datacryptset
)
Error =
CapStruct.new(:cmdid, :text)
Client =
CapStruct.new(
  :bssid, :mac, :type, :firsttime, :lasttime, :manuf, :llcpackets,
  :datapackets, :cryptpackets, :gpsfixed, :minlat, :minlon, :minalt,
  :minspd, :maxlat, :maxlon, :maxalt, :maxspd, :agglat, :agglon, :aggalt,
  :aggpoints, :signal_dbm, :noise_dbm, :minsignal_dbm, :minnoise_dbm,
  :maxsignal_dbm, :maxnoise_dbm, :signal_rssi, :noise_rssi,
  :minsignal_rssi, :minnoise_rssi, :maxsignal_rssi, :maxnoise_rssi,
  :bestlat, :bestlon, :bestalt, :atype, :ip, :gatewayip, :datasize,
  :maxseenrate, :encodingset, :carrierset, :decrypted, :channel,
  :fragments, :retries, :newpackets, :freqmhz, :cdpdevice, :cdpport,
  :dot11d, :dhcphost, :dhcpvendor, :datacryptset
)
Clisrc =
CapStruct.new(
  :bssid, :mac, :uuid, :lasttime, :numpackets, :signal_dbm, :noise_dbm,
  :minsignal_dbm, :minnoise_dbm, :maxsignal_dbm, :maxnoise_dbm,
  :signal_rssi, :noise_rssi, :minsignal_rssi, :minnoise_rssi,
  :maxsignal_rssi, :maxnoise_rssi
)
Clitag =
CapStruct.new(:bssid, :mac, :tag, :value)
Common =
CapStruct.new(
  :phytype, :macaddr, :firsttime, :lasttime, :packets, :llcpackets,
  :errorpackets, :datapackets, :cryptpackets, :datasize, :newpackets,
  :channel, :frequency, :freqmhz, :gpsfixed, :minlat, :minlon, :minalt,
  :minspd, :maxlat, :maxlon, :maxalt, :maxspd, :signaldbm, :noisedbm,
  :minsignaldbm, :minnoisedbm, :signalrssi, :noiserssi, :minsignalrssi,
  :minnoiserssi, :maxsignalrssi, :maxnoiserssi, :bestlat, :bestlon,
  :bestalt, :agglat, :agglon, :aggalt, :aggpoints
)
Kismet =
CapStruct.new(
  :version, :starttime, :servername, :dumpfiles, :uid
)
Nettag =
CapStruct.new(:bssid, :tag, :value)
Packet =
CapStruct.new(
  :type, :subtype, :timesec, :encrypted, :weak, :beaconrate, :sourcemac,
  :destmac, :bssid, :ssid, :prototype, :sourceip, :destip, :sourceport,
  :destport, :nbtype, :nbsource, :sourcename
)
Plugin =
CapStruct.new(
  :filename, :name, :version, :description, :unloadable, :root
)
Remove =
CapStruct.new(:bssid)
Source =
CapStruct.new(
  :interface, :type, :username, :channel, :uuid, :packets, :hop, :velocity,
  :dwell, :hop_time_sec, :hop_time_usec
)
Status =
CapStruct.new(:text, :flags)
String =
CapStruct.new(:bssid, :source, :dest, :string)
Wepkey =
CapStruct.new(:origin, :bssid, :key, :encrypted, :failed)
Battery =
CapStruct.new(:percentage, :charging, :ac, :remaining)
Channel =
CapStruct.new(
  :channel, :time_on, :packets, :packetsdelta, :usecused, :bytes,
  :bytesdelta, :networks, :maxsignal_dbm, :maxsignal_rssi, :maxnoise_dbm,
  :maxnoise_rssi, :activenetworks
)
Bssidsrc =
CapStruct.new(
  :bssid, :uuid, :lasttime, :numpackets, :signal_dbm, :noise_dbm,
  :minsignal_dbm, :minnoise_dbm, :maxsignal_dbm, :maxnoise_dbm, :signal_rssi,
  :noise_rssi, :minsignal_rssi, :minnoise_rssi, :maxsignal_rssi,
  :maxnoise_rssi
)
Critfail =
CapStruct.new(:id, :time, :message)
Spectrum =
CapStruct.new(
  :devname, :amp_offset_mdbm, :amp_res_mdbm, :rssi_max, :start_khz,
  :res_hz, :num_samples, :samples
)
Btscandev =
CapStruct.new(
  :bdaddr, :name, :class, :firsttime, :lasttime, :packets, :gpsfixed,
  :minlat, :minlon, :minalt, :minspd, :maxlat, :maxlon, :maxalt, :maxspd,
  :agglat, :agglon, :aggalt, :aggpoints
)
Protocols =
CapStruct.new(:protocols)
Terminate =
CapStruct.new(:text)
Trackinfo =
CapStruct.new(
  :devices, :packets, :datapackets, :cryptpackets, :errorpackets,
  :filterpackets, :packetrate
)
Capability =
CapStruct.new(:name, :capabilities)