Class ArpMessage

java.lang.Object
org.eblocker.server.common.network.ArpMessage

public class ArpMessage extends Object
Contains data for an ARP packet.

There is a string representation that can be parsed. It is defined in: network-tools/arp_write.c.

  • Field Details

    • type

      public ArpMessageType type
    • sourceHardwareAddress

      public String sourceHardwareAddress
    • sourceIPAddress

      public String sourceIPAddress
    • targetHardwareAddress

      public String targetHardwareAddress
    • targetIPAddress

      public String targetIPAddress
    • ethernetTargetHardwareAddress

      public String ethernetTargetHardwareAddress
  • Constructor Details

    • ArpMessage

      public ArpMessage()
  • Method Details

    • parse

      public static ArpMessage parse(String message) throws ArpMessageParsingException
      Parse the string representation. See also: network-tools/arp_write.c
      Parameters:
      message -
      Returns:
      Throws:
      ArpMessageParsingException
    • format

      public String format()
      Creates the string representation
      Returns:
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • isGratuitousRequest

      public boolean isGratuitousRequest()
      A gratuitous request has the same source and target IP address
      Returns:
    • isArpProbe

      public boolean isArpProbe()