diff --git a/tools/nfd-autoreg.cpp b/tools/nfd-autoreg.cpp
index 3745cb0..7a72b82 100644
--- a/tools/nfd-autoreg.cpp
+++ b/tools/nfd-autoreg.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2014-2021,  Regents of the University of California,
+ * Copyright (c) 2014-2022,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -27,8 +27,6 @@
 #include "core/version.hpp"
 
 #include <ndn-cxx/face.hpp>
-#include <ndn-cxx/name.hpp>
-#include <ndn-cxx/encoding/buffer-stream.hpp>
 #include <ndn-cxx/mgmt/nfd/controller.hpp>
 #include <ndn-cxx/mgmt/nfd/face-monitor.hpp>
 #include <ndn-cxx/mgmt/nfd/face-status.hpp>
@@ -37,35 +35,25 @@
 
 #include <boost/exception/diagnostic_information.hpp>
 #include <boost/program_options/options_description.hpp>
-#include <boost/program_options/variables_map.hpp>
 #include <boost/program_options/parsers.hpp>
+#include <boost/program_options/variables_map.hpp>
 
 #include <iostream>
 
-namespace ndn {
-namespace nfd_autoreg {
-
-using ::nfd::Network;
+namespace nfd::tools::autoreg {
 
 class AutoregServer : boost::noncopyable
 {
 public:
-  AutoregServer()
-    : m_controller(m_face, m_keyChain)
-    , m_faceMonitor(m_face)
-    , m_cost(255)
-  {
-  }
-
-  void
+  static void
   onRegisterCommandSuccess(uint64_t faceId, const Name& prefix)
   {
-    std::cerr << "SUCCEED: register " << prefix << " on face " << faceId << std::endl;
+    std::cerr << "SUCCESS: register " << prefix << " on face " << faceId << std::endl;
   }
 
-  void
+  static void
   onRegisterCommandFailure(uint64_t faceId, const Name& prefix,
-                           const nfd::ControlResponse& response)
+                           const ndn::nfd::ControlResponse& response)
   {
     std::cerr << "FAILED: register " << prefix << " on face " << faceId
               << " (code: " << response.getCode() << ", reason: " << response.getText() << ")"
@@ -90,7 +78,7 @@
   isBlacklisted(const boost::asio::ip::address& address) const
   {
     return std::any_of(m_blackList.begin(), m_blackList.end(),
-                       std::bind(&Network::doesContain, _1, address));
+                       [&] (const auto& net) { return net.doesContain(address); });
   }
 
   /**
@@ -100,27 +88,27 @@
   isWhitelisted(const boost::asio::ip::address& address) const
   {
     return std::any_of(m_whiteList.begin(), m_whiteList.end(),
-                       std::bind(&Network::doesContain, _1, address));
+                       [&] (const auto& net) { return net.doesContain(address); });
   }
 
   void
   registerPrefixesForFace(uint64_t faceId, const std::vector<Name>& prefixes)
   {
     for (const Name& prefix : prefixes) {
-      m_controller.start<nfd::RibRegisterCommand>(
-        nfd::ControlParameters()
+      m_controller.start<ndn::nfd::RibRegisterCommand>(
+        ndn::nfd::ControlParameters()
           .setName(prefix)
           .setFaceId(faceId)
-          .setOrigin(nfd::ROUTE_ORIGIN_AUTOREG)
+          .setOrigin(ndn::nfd::ROUTE_ORIGIN_AUTOREG)
           .setCost(m_cost)
           .setExpirationPeriod(time::milliseconds::max()),
-        std::bind(&AutoregServer::onRegisterCommandSuccess, this, faceId, prefix),
-        std::bind(&AutoregServer::onRegisterCommandFailure, this, faceId, prefix, _1));
+        [=] (auto&&...) { onRegisterCommandSuccess(faceId, prefix); },
+        [=] (const auto& response) { onRegisterCommandFailure(faceId, prefix, response); });
     }
   }
 
   void
-  registerPrefixesIfNeeded(uint64_t faceId, const FaceUri& uri, nfd::FacePersistency facePersistency)
+  registerPrefixesIfNeeded(uint64_t faceId, const FaceUri& uri, ndn::nfd::FacePersistency facePersistency)
   {
     if (hasAllowedSchema(uri)) {
       boost::system::error_code ec;
@@ -131,7 +119,7 @@
         registerPrefixesForFace(faceId, m_allFacesPrefixes);
 
         // register autoreg prefixes if new face is on-demand and not blacklisted and whitelisted
-        if (facePersistency == nfd::FACE_PERSISTENCY_ON_DEMAND &&
+        if (facePersistency == ndn::nfd::FACE_PERSISTENCY_ON_DEMAND &&
             !isBlacklisted(address) && isWhitelisted(address)) {
           registerPrefixesForFace(faceId, m_autoregPrefixes);
         }
@@ -140,10 +128,10 @@
   }
 
   void
-  onNotification(const nfd::FaceEventNotification& notification)
+  onNotification(const ndn::nfd::FaceEventNotification& notification)
   {
-    if (notification.getKind() == nfd::FACE_EVENT_CREATED &&
-        notification.getFaceScope() != nfd::FACE_SCOPE_LOCAL) {
+    if (notification.getKind() == ndn::nfd::FACE_EVENT_CREATED &&
+        notification.getFaceScope() != ndn::nfd::FACE_SCOPE_LOCAL) {
       std::cerr << "PROCESSING: " << notification << std::endl;
 
       registerPrefixesIfNeeded(notification.getFaceId(), FaceUri(notification.getRemoteUri()),
@@ -154,16 +142,6 @@
     }
   }
 
-  static void
-  usage(std::ostream& os,
-        const boost::program_options::options_description& desc,
-        const char* programName)
-  {
-    os << "Usage: " << programName << " [--prefix=</autoreg/prefix>]... [options]\n"
-       << "\n"
-       << desc;
-  }
-
   void
   startProcessing()
   {
@@ -188,7 +166,7 @@
       std::cout << "  " << network << std::endl;
     }
 
-    m_faceMonitor.onNotification.connect(std::bind(&AutoregServer::onNotification, this, _1));
+    m_faceMonitor.onNotification.connect([this] (const auto& notif) { onNotification(notif); });
     m_faceMonitor.start();
 
     boost::asio::signal_set signalSet(m_face.getIoService(), SIGINT, SIGTERM);
@@ -200,7 +178,7 @@
   void
   startFetchingFaceStatusDataset()
   {
-    m_controller.fetch<nfd::FaceDataset>(
+    m_controller.fetch<ndn::nfd::FaceDataset>(
       [this] (const auto& faces) {
         for (const auto& faceStatus : faces) {
           registerPrefixesIfNeeded(faceStatus.getFaceId(), FaceUri(faceStatus.getRemoteUri()),
@@ -224,7 +202,7 @@
       ("all-faces-prefix,a", po::value<std::vector<Name>>(&m_allFacesPrefixes)->composing(),
        "prefix that should be automatically registered for all TCP and UDP non-local faces "
        "(blacklists and whitelists do not apply to this prefix)")
-      ("cost,c", po::value<uint64_t>(&m_cost)->default_value(255),
+      ("cost,c", po::value<uint64_t>(&m_cost)->default_value(m_cost),
        "FIB cost that should be assigned to autoreg nexthops")
       ("whitelist,w", po::value<std::vector<Network>>(&m_whiteList)->composing(),
        "Whitelisted network, e.g., 192.168.2.0/24 or ::1/128")
@@ -232,6 +210,12 @@
        "Blacklisted network, e.g., 192.168.2.32/30 or ::1/128")
       ;
 
+    auto usage = [&] (std::ostream& os) {
+      os << "Usage: " << argv[0] << " [--prefix=</autoreg/prefix>]... [options]\n"
+         << "\n"
+         << optionsDesc;
+    };
+
     po::variables_map options;
     try {
       po::store(po::parse_command_line(argc, argv, optionsDesc), options);
@@ -239,12 +223,12 @@
     }
     catch (const std::exception& e) {
       std::cerr << "ERROR: " << e.what() << std::endl << std::endl;
-      usage(std::cerr, optionsDesc, argv[0]);
+      usage(std::cerr);
       return 2;
     }
 
     if (options.count("help") > 0) {
-      usage(std::cout, optionsDesc, argv[0]);
+      usage(std::cout);
       return 0;
     }
 
@@ -256,7 +240,7 @@
     if (m_autoregPrefixes.empty() && m_allFacesPrefixes.empty()) {
       std::cerr << "ERROR: at least one --prefix or --all-faces-prefix must be specified"
                 << std::endl << std::endl;
-      usage(std::cerr, optionsDesc, argv[0]);
+      usage(std::cerr);
       return 2;
     }
 
@@ -279,23 +263,22 @@
   }
 
 private:
-  Face m_face;
-  KeyChain m_keyChain;
-  nfd::Controller m_controller;
-  nfd::FaceMonitor m_faceMonitor;
+  ndn::Face m_face;
+  ndn::KeyChain m_keyChain;
+  ndn::nfd::Controller m_controller{m_face, m_keyChain};
+  ndn::nfd::FaceMonitor m_faceMonitor{m_face};
   std::vector<Name> m_autoregPrefixes;
   std::vector<Name> m_allFacesPrefixes;
-  uint64_t m_cost;
+  uint64_t m_cost = 255;
   std::vector<Network> m_whiteList;
   std::vector<Network> m_blackList;
 };
 
-} // namespace nfd_autoreg
-} // namespace ndn
+} // namespace nfd::tools::autoreg
 
 int
 main(int argc, char* argv[])
 {
-  ndn::nfd_autoreg::AutoregServer server;
+  nfd::tools::autoreg::AutoregServer server;
   return server.main(argc, argv);
 }
