DHCPV4: make and send dhcp packet

This adds two functions.
One is MakeRawPacket(), extracting payload from DHCPMessage
object and filling the IP and UDP headers.

Another is SendRawPacket(), sending the dhcp packet through
raw socket.

Bug: 25642025
TEST=compile and unittest

Change-Id: Ib9efca5d96b768757d26e70119564b98e819bb34
diff --git a/dhcpv4.h b/dhcpv4.h
index f0132c8..6d32e52 100644
--- a/dhcpv4.h
+++ b/dhcpv4.h
@@ -21,12 +21,13 @@
 
 #include <base/macros.h>
 #include <base/strings/stringprintf.h>
+#include <shill/net/byte_string.h>
+#include <shill/net/io_handler_factory_container.h>
+#include <shill/net/sockets.h>
 
 #include "dhcp_client/dhcp.h"
+#include "dhcp_client/dhcp_message.h"
 #include "dhcp_client/event_dispatcher_interface.h"
-#include "shill/net/byte_string.h"
-#include "shill/net/io_handler_factory_container.h"
-#include "shill/net/sockets.h"
 
 namespace dhcp_client {
 
@@ -47,6 +48,12 @@
   void Stop();
 
  private:
+  bool CreateRawSocket();
+  bool MakeRawPacket(const DHCPMessage& message, shill::ByteString* buffer);
+  void OnReadError(const std::string& error_msg);
+  void ParseMessage(shill::InputData* data);
+  bool SendRawPacket(const shill::ByteString& buffer);
+
   // Interface parameters.
   std::string interface_name_;
   shill::ByteString hardware_address_;
@@ -76,9 +83,8 @@
   // Helper class with wrapped socket relavent functions.
   std::unique_ptr<shill::Sockets> sockets_;
 
-  bool CreateRawSocket();
-  void ParseMessage(shill::InputData* data);
-  void OnReadError(const std::string& error_msg);
+  uint32_t from_;
+  uint32_t to_;
 
   DISALLOW_COPY_AND_ASSIGN(DHCPV4);
 };