diff --git a/src/encoding/tlv-nfd.hpp b/src/encoding/tlv-nfd.hpp
index 584f62a..c7f3620 100644
--- a/src/encoding/tlv-nfd.hpp
+++ b/src/encoding/tlv-nfd.hpp
@@ -40,6 +40,13 @@
 
 } // namespace nfd
 } // namespace tlv
+
+namespace nfd {
+
+const uint64_t INVALID_FACE_ID = std::numeric_limits<uint64_t>::max();
+
+} // namespace nfd
+
 } // namespace ndn
 
 #endif // NDN_TLV_NFD_HPP
diff --git a/src/management/nfd-controller.cpp b/src/management/nfd-controller.cpp
index 00a5378..c6fa7e7 100644
--- a/src/management/nfd-controller.cpp
+++ b/src/management/nfd-controller.cpp
@@ -9,6 +9,7 @@
 
 #include "nfd-controller.hpp"
 #include "nfd-fib-management-options.hpp"
+#include "nfd-face-management-options.hpp"
 #include "nfd-control-response.hpp"
 
 namespace ndn {
@@ -45,7 +46,7 @@
         onFail("Face ID is not set, should have been set after a successful prefix registration command");
       return;
     }
-  
+
   startFibCommand("remove-nexthop",
                   FibManagementOptions()
                   .setName(prefixToRegister)
@@ -65,7 +66,7 @@
     .append(options.wireEncode());
 
   Interest fibCommandInterest(fibCommandInterestName);
-  m_keyChain.sign(fibCommandInterest);
+  // m_keyChain.sign(fibCommandInterest);
 
   m_face.expressInterest(fibCommandInterest,
                          bind(&Controller::processFibCommandResponse, this, _2,
@@ -81,11 +82,6 @@
   onSuccess();
 }
 
-// void
-// processFaceActionResponse(Data& data,
-//                           const FaceOperationSucceedCallback& onSuccess,
-//                           const FailCallback&    onFail);
-
 void
 Controller::processFibCommandResponse(Data& data,
                                       const FibCommandSucceedCallback& onSuccess,
@@ -94,7 +90,6 @@
   try
     {
       ControlResponse response(data.getContent().blockFromValue());
-
       if (response.getCode() != 200)
         return onFail(response.getText());
 
@@ -108,5 +103,45 @@
     }
 }
 
+void
+Controller::startFaceCommand(const std::string& command,
+                             const FaceManagementOptions& options,
+                             const FaceCommandSucceedCallback& onSuccess,
+                             const FailCallback& onFail)
+{
+  Name faceCommandInterestName("/localhost/nfd/faces");
+  faceCommandInterestName
+    .append(command)
+    .append(options.wireEncode());
+
+  Interest faceCommandInterest(faceCommandInterestName);
+  // m_keyChain.sign(fibCommandInterest);
+
+  m_face.expressInterest(faceCommandInterest,
+                         bind(&Controller::processFaceCommandResponse, this, _2,
+                              onSuccess, onFail),
+                         bind(onFail, "Command Interest timed out"));
+}
+
+void
+Controller::processFaceCommandResponse(Data& data,
+                                       const FaceCommandSucceedCallback& onSuccess,
+                                       const FailCallback& onFail)
+{
+  try
+    {
+      ControlResponse response(data.getContent().blockFromValue());
+      if (response.getCode() != 200)
+        return onFail(response.getText());
+
+      FaceManagementOptions options(response.getBody());
+      return onSuccess(options);
+    }
+  catch(ndn::Tlv::Error& e)
+    {
+      if (static_cast<bool>(onFail))
+        return onFail(e.what());
+    }
+}
 } // namespace nfd
 } // namespace ndn
diff --git a/src/management/nfd-controller.hpp b/src/management/nfd-controller.hpp
index aa788a9..850c72d 100644
--- a/src/management/nfd-controller.hpp
+++ b/src/management/nfd-controller.hpp
@@ -16,11 +16,13 @@
 namespace nfd {
 
 class FibManagementOptions;
+class FaceManagementOptions;
 
 class Controller : public ndn::Controller
 {
 public:
   typedef function<void(const FibManagementOptions&)> FibCommandSucceedCallback;
+  typedef function<void(const FaceManagementOptions&)> FaceCommandSucceedCallback;
 
   /**
    * @brief Construct ndnd::Control object
@@ -37,27 +39,35 @@
                        const SuccessCallback& onSuccess,
                        const FailCallback&    onFail);
 
+protected:
   void
   startFibCommand(const std::string& command,
                   const FibManagementOptions& options,
                   const FibCommandSucceedCallback& onSuccess,
                   const FailCallback& onFailure);
+
+  void
+  startFaceCommand(const std::string& command,
+                   const FaceManagementOptions& options,
+                   const FaceCommandSucceedCallback& onSuccess,
+                   const FailCallback& onFailure);
+
 private:
   void
   recordSelfRegisteredFaceId(const FibManagementOptions& entry,
                              const SuccessCallback& onSuccess);
 
-  // void
-  // processFaceActionResponse(Data& data,
-  //                           const FaceOperationSucceedCallback& onSuccess,
-  //                           const FailCallback&    onFail);
-
   void
   processFibCommandResponse(Data& data,
                             const FibCommandSucceedCallback& onSuccess,
                             const FailCallback& onFail);
-  
-private:
+
+  void
+  processFaceCommandResponse(Data& data,
+                             const FaceCommandSucceedCallback& onSuccess,
+                             const FailCallback& onFail);
+
+protected:
   Face& m_face;
   KeyChain m_keyChain;
   uint64_t m_faceId; // internal face ID (needed for prefix de-registration)
diff --git a/src/management/nfd-face-management-options.hpp b/src/management/nfd-face-management-options.hpp
index 7158352..802cde0 100644
--- a/src/management/nfd-face-management-options.hpp
+++ b/src/management/nfd-face-management-options.hpp
@@ -66,15 +66,12 @@
   wireDecode (const Block &wire);
   
 private:
-  static const uint64_t INVALID_FACE_ID;
-
   uint64_t m_faceId;
   std::string m_uri;
 
   mutable Block wire_;
 };
 
-const uint64_t FaceManagementOptions::INVALID_FACE_ID = std::numeric_limits<uint64_t>::max();
 
 template<bool T>
 inline size_t
diff --git a/src/management/nfd-local-control-header.hpp b/src/management/nfd-local-control-header.hpp
index 5ddc14b..e3bbe0c 100644
--- a/src/management/nfd-local-control-header.hpp
+++ b/src/management/nfd-local-control-header.hpp
@@ -13,8 +13,6 @@
 namespace ndn {
 namespace nfd {
 
-const uint64_t INVALID_FACE_ID = std::numeric_limits<uint64_t>::max();
-
 class LocalControlHeader
 {
 public:
