diff --git a/ndn-cxx/net/dns.cpp b/ndn-cxx/net/dns.cpp
index 9942867..c3e04b1 100644
--- a/ndn-cxx/net/dns.cpp
+++ b/ndn-cxx/net/dns.cpp
@@ -24,6 +24,9 @@
 
 #include <boost/asio/io_service.hpp>
 #include <boost/asio/ip/udp.hpp>
+#if BOOST_VERSION >= 106600
+#include <boost/asio/post.hpp>
+#endif
 
 namespace ndn {
 namespace dns {
@@ -72,8 +75,13 @@
                   iterator it, const shared_ptr<Resolver>& self)
   {
     m_resolveTimeout.cancel();
+
     // ensure the Resolver isn't destructed while callbacks are still pending, see #2653
+#if BOOST_VERSION >= 106600
+    boost::asio::post(m_resolver.get_executor(), [self] {});
+#else
     m_resolver.get_io_service().post([self] {});
+#endif
 
     if (error) {
       if (error == boost::asio::error::operation_aborted)
@@ -99,8 +107,13 @@
   onResolveTimeout(const shared_ptr<Resolver>& self)
   {
     m_resolver.cancel();
+
     // ensure the Resolver isn't destructed while callbacks are still pending, see #2653
+#if BOOST_VERSION >= 106600
+    boost::asio::post(m_resolver.get_executor(), [self] {});
+#else
     m_resolver.get_io_service().post([self] {});
+#endif
 
     if (m_onError)
       m_onError("Hostname resolution timed out");
diff --git a/ndn-cxx/transport/detail/stream-transport-impl.hpp b/ndn-cxx/transport/detail/stream-transport-impl.hpp
index 944b743..a90143a 100644
--- a/ndn-cxx/transport/detail/stream-transport-impl.hpp
+++ b/ndn-cxx/transport/detail/stream-transport-impl.hpp
@@ -24,7 +24,7 @@
 
 #include "ndn-cxx/transport/transport.hpp"
 
-#include <boost/asio/deadline_timer.hpp>
+#include <boost/asio/steady_timer.hpp>
 #include <boost/asio/write.hpp>
 
 #include <list>
@@ -62,11 +62,15 @@
 
       // Wait at most 4 seconds to connect
       /// @todo Decide whether this number should be configurable
-      m_connectTimer.expires_from_now(boost::posix_time::seconds(4));
-      m_connectTimer.async_wait(bind(&Impl::connectTimeoutHandler, this->shared_from_this(), _1));
+      m_connectTimer.expires_from_now(std::chrono::seconds(4));
+      m_connectTimer.async_wait([self = this->shared_from_this()] (const auto& error) {
+        self->connectTimeoutHandler(error);
+      });
 
       m_socket.open();
-      m_socket.async_connect(endpoint, bind(&Impl::connectHandler, this->shared_from_this(), _1));
+      m_socket.async_connect(endpoint, [self = this->shared_from_this()] (const auto& error) {
+        self->connectHandler(error);
+      });
     }
   }
 
@@ -275,7 +279,7 @@
   TransmissionQueue m_transmissionQueue;
   bool m_isConnecting;
 
-  boost::asio::deadline_timer m_connectTimer;
+  boost::asio::steady_timer m_connectTimer;
 };
 
 } // namespace detail
diff --git a/ndn-cxx/transport/detail/stream-transport-with-resolver-impl.hpp b/ndn-cxx/transport/detail/stream-transport-with-resolver-impl.hpp
index 986eb57..a59e873 100644
--- a/ndn-cxx/transport/detail/stream-transport-with-resolver-impl.hpp
+++ b/ndn-cxx/transport/detail/stream-transport-with-resolver-impl.hpp
@@ -34,8 +34,6 @@
 class StreamTransportWithResolverImpl : public StreamTransportImpl<BaseTransport, Protocol>
 {
 public:
-  using Impl = StreamTransportWithResolverImpl<BaseTransport,Protocol>;
-
   StreamTransportWithResolverImpl(BaseTransport& transport, boost::asio::io_service& ioService)
     : StreamTransportImpl<BaseTransport, Protocol>(transport, ioService)
   {
@@ -47,16 +45,25 @@
     if (this->m_isConnecting) {
       return;
     }
-
     this->m_isConnecting = true;
 
     // Wait at most 4 seconds to connect
     /// @todo Decide whether this number should be configurable
-    this->m_connectTimer.expires_from_now(boost::posix_time::seconds(4));
-    this->m_connectTimer.async_wait(bind(&Impl::connectTimeoutHandler, this->shared_from_this(), _1));
+    this->m_connectTimer.expires_from_now(std::chrono::seconds(4));
+    this->m_connectTimer.async_wait([self = this->shared_from_base()] (const auto& ec) {
+      self->connectTimeoutHandler(ec);
+    });
 
-    auto resolver = make_shared<typename Protocol::resolver>(ref(this->m_socket.get_io_service()));
-    resolver->async_resolve(query, bind(&Impl::resolveHandler, this->shared_from_base(), _1, _2, resolver));
+    auto resolver = make_shared<typename Protocol::resolver>(this->m_socket
+#if BOOST_VERSION >= 107000
+                                                             .get_executor()
+#else
+                                                             .get_io_service()
+#endif
+                                                             );
+    resolver->async_resolve(query, [self = this->shared_from_base(), resolver] (auto&&... args) {
+      self->resolveHandler(std::forward<decltype(args)>(args)..., resolver);
+    });
   }
 
 protected:
@@ -78,10 +85,14 @@
       NDN_THROW(Transport::Error(error, "Unable to resolve host or port"));
     }
 
-    this->m_socket.async_connect(*endpoint, bind(&Impl::connectHandler, this->shared_from_this(), _1));
+    this->m_socket.async_connect(*endpoint, [self = this->shared_from_base()] (const auto& ec) {
+      self->connectHandler(ec);
+    });
   }
 
 private:
+  using Impl = StreamTransportWithResolverImpl<BaseTransport, Protocol>;
+
   shared_ptr<Impl>
   shared_from_base()
   {
diff --git a/ndn-cxx/util/scheduler.hpp b/ndn-cxx/util/scheduler.hpp
index 8e2e7fb..ed81a03 100644
--- a/ndn-cxx/util/scheduler.hpp
+++ b/ndn-cxx/util/scheduler.hpp
@@ -183,7 +183,7 @@
   void
   cancelImpl(const shared_ptr<EventInfo>& info);
 
-  /** \brief Schedule the next event on the deadline timer
+  /** \brief Schedule the next event on the internal timer
    */
   void
   scheduleNext();
