diff --git a/common.hpp b/common.hpp
index b77604e..70943a6 100644
--- a/common.hpp
+++ b/common.hpp
@@ -50,6 +50,7 @@
 #include <ndn-cxx/interest.hpp>
 #include <ndn-cxx/data.hpp>
 #include <ndn-cxx/util/event-emitter.hpp>
+#include <ndn-cxx/util/ethernet.hpp>
 
 #include <boost/algorithm/string.hpp>
 #include <boost/asio.hpp>
@@ -96,6 +97,7 @@
 
 namespace name = ndn::name;
 namespace time = ndn::time;
+namespace ethernet = ndn::util::ethernet;
 
 } // namespace nfd
 
diff --git a/core/ethernet.cpp b/core/ethernet.cpp
deleted file mode 100644
index 1aeaca6..0000000
--- a/core/ethernet.cpp
+++ /dev/null
@@ -1,82 +0,0 @@
-/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2014  Regents of the University of California,
- *                     Arizona Board of Regents,
- *                     Colorado State University,
- *                     University Pierre & Marie Curie, Sorbonne University,
- *                     Washington University in St. Louis,
- *                     Beijing Institute of Technology
- *
- * This file is part of NFD (Named Data Networking Forwarding Daemon).
- * See AUTHORS.md for complete list of NFD authors and contributors.
- *
- * NFD is free software: you can redistribute it and/or modify it under the terms
- * of the GNU General Public License as published by the Free Software Foundation,
- * either version 3 of the License, or (at your option) any later version.
- *
- * NFD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
- * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
- * PURPOSE.  See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along with
- * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
-
-#include "ethernet.hpp"
-
-#include <stdio.h>
-
-namespace nfd {
-namespace ethernet {
-
-std::string
-Address::toString(char sep) const
-{
-  char s[18]; // 12 digits + 5 separators + null terminator
-  ::snprintf(s, sizeof(s), "%02x%c%02x%c%02x%c%02x%c%02x%c%02x",
-             elems[0], sep, elems[1], sep, elems[2], sep,
-             elems[3], sep, elems[4], sep, elems[5]);
-  return std::string(s);
-}
-
-Address
-Address::fromString(const std::string& str)
-{
-  unsigned short temp[ADDR_LEN];
-  char sep[5][2]; // 5 * (1 separator char + 1 null terminator)
-  int n = 0; // num of chars read from the input string
-
-  // ISO C++98 does not support the 'hh' type modifier
-  /// \todo use SCNx8 (cinttypes) when we enable C++11
-  int ret = ::sscanf(str.c_str(), "%2hx%1[:-]%2hx%1[:-]%2hx%1[:-]%2hx%1[:-]%2hx%1[:-]%2hx%n",
-                     &temp[0], &sep[0][0], &temp[1], &sep[1][0], &temp[2], &sep[2][0],
-                     &temp[3], &sep[3][0], &temp[4], &sep[4][0], &temp[5], &n);
-
-  if (ret < 11 || static_cast<size_t>(n) != str.length())
-    return Address();
-
-  Address a;
-  for (size_t i = 0; i < ADDR_LEN; ++i)
-    {
-      // check that all separators are actually the same char (: or -)
-      if (i < 5 && sep[i][0] != sep[0][0])
-        return Address();
-
-      // check that each value fits into a uint8_t
-      if (temp[i] > 0xFF)
-        return Address();
-
-      a[i] = static_cast<uint8_t>(temp[i]);
-    }
-
-  return a;
-}
-
-std::ostream&
-operator<<(std::ostream& o, const Address& a)
-{
-  return o << a.toString();
-}
-
-} // namespace ethernet
-} // namespace nfd
diff --git a/core/ethernet.hpp b/core/ethernet.hpp
deleted file mode 100644
index 56888f6..0000000
--- a/core/ethernet.hpp
+++ /dev/null
@@ -1,167 +0,0 @@
-/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2014  Regents of the University of California,
- *                     Arizona Board of Regents,
- *                     Colorado State University,
- *                     University Pierre & Marie Curie, Sorbonne University,
- *                     Washington University in St. Louis,
- *                     Beijing Institute of Technology
- *
- * This file is part of NFD (Named Data Networking Forwarding Daemon).
- * See AUTHORS.md for complete list of NFD authors and contributors.
- *
- * NFD is free software: you can redistribute it and/or modify it under the terms
- * of the GNU General Public License as published by the Free Software Foundation,
- * either version 3 of the License, or (at your option) any later version.
- *
- * NFD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
- * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
- * PURPOSE.  See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along with
- * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
-
-#ifndef NFD_CORE_ETHERNET_HPP
-#define NFD_CORE_ETHERNET_HPP
-
-#include "common.hpp"
-
-#include <boost/array.hpp>
-
-#define ETHERTYPE_NDN 0x8624
-
-namespace nfd {
-namespace ethernet {
-
-const size_t ADDR_LEN     = 6;      ///< Octets in one Ethernet address
-const size_t TYPE_LEN     = 2;      ///< Octets in Ethertype field
-const size_t HDR_LEN      = 14;     ///< Total octets in Ethernet header (without 802.1Q tag)
-const size_t TAG_LEN      = 4;      ///< Octets in 802.1Q tag (TPID + priority + VLAN)
-const size_t MIN_DATA_LEN = 46;     ///< Min octets in Ethernet payload (assuming no 802.1Q tag)
-const size_t MAX_DATA_LEN = 1500;   ///< Max octets in Ethernet payload
-const size_t CRC_LEN      = 4;      ///< Octets in Ethernet frame check sequence
-
-
-class Address : public boost::array<uint8_t, ADDR_LEN>
-{
-public:
-  /// Constructs a null Ethernet address (00:00:00:00:00:00)
-  Address();
-
-  /// Constructs a new Ethernet address with the given octets
-  Address(uint8_t a1, uint8_t a2, uint8_t a3,
-          uint8_t a4, uint8_t a5, uint8_t a6);
-
-  /// Constructs a new Ethernet address with the given octets
-  explicit
-  Address(const uint8_t octets[ADDR_LEN]);
-
-  /// Copy constructor
-  Address(const Address& address);
-
-  /// True if this is a broadcast address (ff:ff:ff:ff:ff:ff)
-  bool
-  isBroadcast() const;
-
-  /// True if this is a multicast address
-  bool
-  isMulticast() const;
-
-  /// True if this is a null address (00:00:00:00:00:00)
-  bool
-  isNull() const;
-
-  /**
-   * @brief Converts the address to a human-readable string
-   *
-   * @param sep A character used to visually separate the octets,
-   *            usually ':' (the default value) or '-'
-   */
-  std::string
-  toString(char sep = ':') const;
-
-  /**
-   * @brief Creates an Address from a string containing an Ethernet address
-   *        in hexadecimal notation, with colons or hyphens as separators
-   *
-   * @param str The string to be parsed
-   * @return Always an instance of Address, which will be null
-   *         if the parsing fails
-   */
-  static Address
-  fromString(const std::string& str);
-};
-
-/// Returns the Ethernet broadcast address (ff:ff:ff:ff:ff:ff)
-inline Address
-getBroadcastAddress()
-{
-  static Address bcast(0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF);
-  return bcast;
-}
-
-/// Returns the default Ethernet multicast address for NDN
-inline Address
-getDefaultMulticastAddress()
-{
-  static Address mcast(0x01, 0x00, 0x5E, 0x00, 0x17, 0xAA);
-  return mcast;
-}
-
-inline
-Address::Address()
-{
-  assign(0);
-}
-
-inline
-Address::Address(uint8_t a1, uint8_t a2, uint8_t a3, uint8_t a4, uint8_t a5, uint8_t a6)
-{
-  elems[0] = a1;
-  elems[1] = a2;
-  elems[2] = a3;
-  elems[3] = a4;
-  elems[4] = a5;
-  elems[5] = a6;
-}
-
-inline
-Address::Address(const uint8_t octets[])
-{
-  std::copy(octets, octets + size(), begin());
-}
-
-inline
-Address::Address(const Address& address)
-{
-  std::copy(address.begin(), address.end(), begin());
-}
-
-inline bool
-Address::isBroadcast() const
-{
-  return elems[0] == 0xFF && elems[1] == 0xFF && elems[2] == 0xFF &&
-         elems[3] == 0xFF && elems[4] == 0xFF && elems[5] == 0xFF;
-}
-
-inline bool
-Address::isMulticast() const
-{
-  return (elems[0] & 1) != 0;
-}
-
-inline bool
-Address::isNull() const
-{
-  return elems[0] == 0x0 && elems[1] == 0x0 && elems[2] == 0x0 &&
-         elems[3] == 0x0 && elems[4] == 0x0 && elems[5] == 0x0;
-}
-
-std::ostream&
-operator<<(std::ostream& o, const Address& a);
-
-} // namespace ethernet
-} // namespace nfd
-
-#endif // NFD_FACE_ETHERNET_HPP
diff --git a/core/face-uri.cpp b/core/face-uri.cpp
index 47c265e..635d8d3 100644
--- a/core/face-uri.cpp
+++ b/core/face-uri.cpp
@@ -1,12 +1,12 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2014  Regents of the University of California,
- *                     Arizona Board of Regents,
- *                     Colorado State University,
- *                     University Pierre & Marie Curie, Sorbonne University,
- *                     Washington University in St. Louis,
- *                     Beijing Institute of Technology,
- *                     The University of Memphis
+ * Copyright (c) 2014,  Regents of the University of California,
+ *                      Arizona Board of Regents,
+ *                      Colorado State University,
+ *                      University Pierre & Marie Curie, Sorbonne University,
+ *                      Washington University in St. Louis,
+ *                      Beijing Institute of Technology,
+ *                      The University of Memphis
  *
  * This file is part of NFD (Named Data Networking Forwarding Daemon).
  * See AUTHORS.md for complete list of NFD authors and contributors.
@@ -21,15 +21,11 @@
  *
  * You should have received a copy of the GNU General Public License along with
  * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
+ */
 
 #include "face-uri.hpp"
 #include "core/logger.hpp"
 
-#ifdef HAVE_LIBPCAP
-#include "ethernet.hpp"
-#endif // HAVE_LIBPCAP
-
 #include <boost/regex.hpp>
 
 NFD_LOG_INIT("FaceUri");
diff --git a/core/face-uri.hpp b/core/face-uri.hpp
index 9173d8a..17cda71 100644
--- a/core/face-uri.hpp
+++ b/core/face-uri.hpp
@@ -1,11 +1,12 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2014  Regents of the University of California,
- *                     Arizona Board of Regents,
- *                     Colorado State University,
- *                     University Pierre & Marie Curie, Sorbonne University,
- *                     Washington University in St. Louis,
- *                     Beijing Institute of Technology
+ * Copyright (c) 2014,  Regents of the University of California,
+ *                      Arizona Board of Regents,
+ *                      Colorado State University,
+ *                      University Pierre & Marie Curie, Sorbonne University,
+ *                      Washington University in St. Louis,
+ *                      Beijing Institute of Technology,
+ *                      The University of Memphis
  *
  * This file is part of NFD (Named Data Networking Forwarding Daemon).
  * See AUTHORS.md for complete list of NFD authors and contributors.
@@ -20,7 +21,7 @@
  *
  * You should have received a copy of the GNU General Public License along with
  * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
+ */
 
 #ifndef NFD_CORE_FACE_URI_H
 #define NFD_CORE_FACE_URI_H
@@ -29,12 +30,6 @@
 
 namespace nfd {
 
-#ifdef HAVE_LIBPCAP
-namespace ethernet {
-class Address;
-} // namespace ethernet
-#endif // HAVE_LIBPCAP
-
 /** \brief represents the underlying protocol and address used by a Face
  *  \sa http://redmine.named-data.net/projects/nfd/wiki/FaceMgmt#FaceUri
  */
diff --git a/core/network-interface.hpp b/core/network-interface.hpp
index 08824fa..baaa85b 100644
--- a/core/network-interface.hpp
+++ b/core/network-interface.hpp
@@ -1,11 +1,12 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2014  Regents of the University of California,
- *                     Arizona Board of Regents,
- *                     Colorado State University,
- *                     University Pierre & Marie Curie, Sorbonne University,
- *                     Washington University in St. Louis,
- *                     Beijing Institute of Technology
+ * Copyright (c) 2014,  Regents of the University of California,
+ *                      Arizona Board of Regents,
+ *                      Colorado State University,
+ *                      University Pierre & Marie Curie, Sorbonne University,
+ *                      Washington University in St. Louis,
+ *                      Beijing Institute of Technology,
+ *                      The University of Memphis
  *
  * This file is part of NFD (Named Data Networking Forwarding Daemon).
  * See AUTHORS.md for complete list of NFD authors and contributors.
@@ -20,13 +21,12 @@
  *
  * You should have received a copy of the GNU General Public License along with
  * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
+ */
 
 #ifndef NFD_CORE_NETWORK_INTERFACE_HPP
 #define NFD_CORE_NETWORK_INTERFACE_HPP
 
 #include "common.hpp"
-#include "ethernet.hpp"
 
 #include <net/if.h>
 
diff --git a/daemon/face/ethernet-face.cpp b/daemon/face/ethernet-face.cpp
index 66957db..fe110ad 100644
--- a/daemon/face/ethernet-face.cpp
+++ b/daemon/face/ethernet-face.cpp
@@ -21,7 +21,7 @@
  *
  * You should have received a copy of the GNU General Public License along with
  * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
+ */
 
 #include "ethernet-face.hpp"
 #include "core/logger.hpp"
@@ -78,7 +78,7 @@
   char filter[100];
   ::snprintf(filter, sizeof(filter),
              "(ether proto 0x%x) && (ether dst %s) && (not ether src %s)",
-             ETHERTYPE_NDN,
+             ethernet::ETHERTYPE_NDN,
              m_destAddress.toString().c_str(),
              m_srcAddress.toString().c_str());
   setPacketFilter(filter);
@@ -199,7 +199,7 @@
     }
 
   // construct and prepend the ethernet header
-  static uint16_t ethertype = htons(ETHERTYPE_NDN);
+  static uint16_t ethertype = htons(ethernet::ETHERTYPE_NDN);
   buffer.prependByteArray(reinterpret_cast<const uint8_t*>(&ethertype), ethernet::TYPE_LEN);
   buffer.prependByteArray(m_srcAddress.data(), m_srcAddress.size());
   buffer.prependByteArray(m_destAddress.data(), m_destAddress.size());
@@ -245,7 +245,7 @@
         throw Error("Received packet is too short");
 
       const ether_header* eh = reinterpret_cast<const ether_header*>(packet);
-      if (ntohs(eh->ether_type) != ETHERTYPE_NDN)
+      if (ntohs(eh->ether_type) != ethernet::ETHERTYPE_NDN)
         throw Error("Unrecognized ethertype");
 
       packet += ethernet::HDR_LEN;
diff --git a/daemon/face/ethernet-face.hpp b/daemon/face/ethernet-face.hpp
index 8fd2b08..7530648 100644
--- a/daemon/face/ethernet-face.hpp
+++ b/daemon/face/ethernet-face.hpp
@@ -27,7 +27,6 @@
 #define NFD_DAEMON_FACE_ETHERNET_FACE_HPP
 
 #include "config.hpp"
-#include "ethernet.hpp"
 #include "face.hpp"
 
 #ifndef HAVE_LIBPCAP
diff --git a/tests/core/ethernet.cpp b/tests/core/ethernet.cpp
deleted file mode 100644
index 157f574..0000000
--- a/tests/core/ethernet.cpp
+++ /dev/null
@@ -1,89 +0,0 @@
-/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2014  Regents of the University of California,
- *                     Arizona Board of Regents,
- *                     Colorado State University,
- *                     University Pierre & Marie Curie, Sorbonne University,
- *                     Washington University in St. Louis,
- *                     Beijing Institute of Technology
- *
- * This file is part of NFD (Named Data Networking Forwarding Daemon).
- * See AUTHORS.md for complete list of NFD authors and contributors.
- *
- * NFD is free software: you can redistribute it and/or modify it under the terms
- * of the GNU General Public License as published by the Free Software Foundation,
- * either version 3 of the License, or (at your option) any later version.
- *
- * NFD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
- * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
- * PURPOSE.  See the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along with
- * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
-
-#include "core/ethernet.hpp"
-#include "tests/test-common.hpp"
-
-namespace nfd {
-namespace tests {
-
-BOOST_FIXTURE_TEST_SUITE(FaceEthernetAddress, BaseFixture)
-
-BOOST_AUTO_TEST_CASE(Checks)
-{
-  BOOST_CHECK(ethernet::Address().isNull());
-  BOOST_CHECK(ethernet::getBroadcastAddress().isBroadcast());
-  BOOST_CHECK(ethernet::getDefaultMulticastAddress().isMulticast());
-}
-
-BOOST_AUTO_TEST_CASE(ToString)
-{
-  BOOST_CHECK_EQUAL(ethernet::Address().toString('-'),
-                    "00-00-00-00-00-00");
-  BOOST_CHECK_EQUAL(ethernet::getBroadcastAddress().toString(),
-                    "ff:ff:ff:ff:ff:ff");
-  BOOST_CHECK_EQUAL(ethernet::Address(0x01, 0x23, 0x45, 0x67, 0x89, 0xAB).toString('-'),
-                    "01-23-45-67-89-ab");
-  BOOST_CHECK_EQUAL(ethernet::Address(0x01, 0x23, 0x45, 0x67, 0x89, 0xAB).toString(),
-                    "01:23:45:67:89:ab");
-}
-
-BOOST_AUTO_TEST_CASE(FromString)
-{
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("0:0:0:0:0:0"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("ff-ff-ff-ff-ff-ff"),
-                    ethernet::getBroadcastAddress());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("de:ad:be:ef:1:2"),
-                    ethernet::Address(0xde, 0xad, 0xbe, 0xef, 0x01, 0x02));
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("DE:AD:BE:EF:1:2"),
-                    ethernet::Address(0xde, 0xad, 0xbe, 0xef, 0x01, 0x02));
-
-  // malformed inputs
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("01.23.45.67.89.ab"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("01:23:45 :67:89:ab"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("01:23:45:67:89::1"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("01-23-45-67-89"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("01:23:45:67:89:ab:cd"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("01:23:45:67-89-ab"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("qw-er-ty-12-34-56"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("this-is-not-an-ethernet-address"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString("foobar"),
-                    ethernet::Address());
-  BOOST_CHECK_EQUAL(ethernet::Address::fromString(""),
-                    ethernet::Address());
-}
-
-BOOST_AUTO_TEST_SUITE_END()
-
-} // namespace tests
-} // namespace nfd
diff --git a/tests/core/face-uri.cpp b/tests/core/face-uri.cpp
index c3060fd..11d7083 100644
--- a/tests/core/face-uri.cpp
+++ b/tests/core/face-uri.cpp
@@ -1,12 +1,12 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2014  Regents of the University of California,
- *                     Arizona Board of Regents,
- *                     Colorado State University,
- *                     University Pierre & Marie Curie, Sorbonne University,
- *                     Washington University in St. Louis,
- *                     Beijing Institute of Technology,
- *                     The University of Memphis
+ * Copyright (c) 2014,  Regents of the University of California,
+ *                      Arizona Board of Regents,
+ *                      Colorado State University,
+ *                      University Pierre & Marie Curie, Sorbonne University,
+ *                      Washington University in St. Louis,
+ *                      Beijing Institute of Technology,
+ *                      The University of Memphis
  *
  * This file is part of NFD (Named Data Networking Forwarding Daemon).
  * See AUTHORS.md for complete list of NFD authors and contributors.
@@ -21,12 +21,9 @@
  *
  * You should have received a copy of the GNU General Public License along with
  * NFD, e.g., in COPYING.md file.  If not, see <http://www.gnu.org/licenses/>.
- **/
+ */
 
 #include "core/face-uri.hpp"
-#ifdef HAVE_LIBPCAP
-#include "core/ethernet.hpp"
-#endif // HAVE_LIBPCAP
 
 #include "tests/test-common.hpp"
 
