diff --git a/src/mgmt/nfd/controller.cpp b/src/mgmt/nfd/controller.cpp
index bfb0843..945c16d 100644
--- a/src/mgmt/nfd/controller.cpp
+++ b/src/mgmt/nfd/controller.cpp
@@ -1,5 +1,5 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
+/*
  * Copyright (c) 2013-2017 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
@@ -20,9 +20,12 @@
  */
 
 #include "controller.hpp"
-#include "../../face.hpp"
-#include "../../security/key-chain.hpp"
-#include "../../util/segment-fetcher.hpp"
+#include "face.hpp"
+#include "security/v2/key-chain.hpp"
+#include "security/validator-null.hpp"
+#include "util/segment-fetcher.hpp"
+
+#include <boost/lexical_cast.hpp>
 
 namespace ndn {
 namespace nfd {
@@ -34,13 +37,12 @@
 const uint32_t Controller::ERROR_VALIDATION = 10021; // 10000 + TLS1_ALERT_DECRYPTION_FAILED
 const uint32_t Controller::ERROR_SERVER = 500;
 const uint32_t Controller::ERROR_LBOUND = 400;
-ValidatorNull Controller::s_validatorNull;
 
-Controller::Controller(Face& face, KeyChain& keyChain, Validator& validator)
+Controller::Controller(Face& face, KeyChain& keyChain, security::v2::Validator& validator)
   : m_face(face)
   , m_keyChain(keyChain)
-  , m_signer(keyChain)
   , m_validator(validator)
+  , m_signer(keyChain)
 {
 }
 
@@ -79,11 +81,11 @@
                                    const CommandFailCallback& onFailure)
 {
   m_validator.validate(data,
-    [=] (const shared_ptr<const Data>& data) {
-      this->processValidatedCommandResponse(*data, command, onSuccess, onFailure);
+    [=] (const Data& data) {
+      this->processValidatedCommandResponse(data, command, onSuccess, onFailure);
     },
-    [=] (const shared_ptr<const Data>&, const std::string& msg) {
-      onFailure(ControlResponse(ERROR_VALIDATION, msg));
+    [=] (const Data& data, const security::v2::ValidationError& error) {
+      onFailure(ControlResponse(ERROR_VALIDATION, boost::lexical_cast<std::string>(error)));
     }
   );
 }
diff --git a/src/mgmt/nfd/controller.hpp b/src/mgmt/nfd/controller.hpp
index d9bfa1f..6582a66 100644
--- a/src/mgmt/nfd/controller.hpp
+++ b/src/mgmt/nfd/controller.hpp
@@ -1,5 +1,5 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
+/*
  * Copyright (c) 2013-2017 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
@@ -26,15 +26,13 @@
 #include "control-response.hpp"
 #include "status-dataset.hpp"
 #include "command-options.hpp"
-#include "../../security/validator-null.hpp"
-#include "../../security/key-chain.hpp"
 #include "../../security/command-interest-signer.hpp"
+#include "../../security/validator-null.hpp"
+#include "../../security/v2/key-chain.hpp"
+#include "../../security/v2/validator.hpp"
 
 namespace ndn {
 
-namespace security {
-class Validator;
-} // namespace security
 class Face;
 
 namespace nfd {
@@ -67,7 +65,7 @@
   /** \brief construct a Controller that uses face for transport,
    *         and uses the passed KeyChain to sign commands
    */
-  Controller(Face& face, KeyChain& keyChain, security::Validator& validator = s_validatorNull);
+  Controller(Face& face, KeyChain& keyChain, security::v2::Validator& validator = security::getAcceptAllValidator());
 
   /** \brief start command execution
    */
@@ -172,11 +170,8 @@
 protected:
   Face& m_face;
   KeyChain& m_keyChain;
+  security::v2::Validator& m_validator;
   security::CommandInterestSigner m_signer;
-  security::Validator& m_validator;
-
-private:
-  static ValidatorNull s_validatorNull;
 };
 
 template<typename Dataset>
diff --git a/src/security/validator-null.cpp b/src/security/validator-null.cpp
new file mode 100644
index 0000000..6ca3174
--- /dev/null
+++ b/src/security/validator-null.cpp
@@ -0,0 +1,44 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/*
+ * Copyright (c) 2013-2017 Regents of the University of California.
+ *
+ * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
+ *
+ * ndn-cxx library is free software: you can redistribute it and/or modify it under the
+ * terms of the GNU Lesser General Public License as published by the Free Software
+ * Foundation, either version 3 of the License, or (at your option) any later version.
+ *
+ * ndn-cxx library 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 Lesser General Public License for more details.
+ *
+ * You should have received copies of the GNU General Public License and GNU Lesser
+ * General Public License along with ndn-cxx, e.g., in COPYING.md file.  If not, see
+ * <http://www.gnu.org/licenses/>.
+ *
+ * See AUTHORS.md for complete list of ndn-cxx authors and contributors.
+ */
+
+#include "validator-null.hpp"
+#include "v2/validation-policy-accept-all.hpp"
+#include "v2/certificate-fetcher-offline.hpp"
+
+namespace ndn {
+namespace security {
+namespace v2 {
+
+ValidatorNull::ValidatorNull()
+  : Validator(make_unique<ValidationPolicyAcceptAll>(), make_unique<CertificateFetcherOffline>())
+{
+}
+
+security::v2::Validator&
+getAcceptAllValidator()
+{
+  static security::ValidatorNull validator;
+  return validator;
+}
+
+} // namespace v2
+} // namespace security
+} // namespace ndn
diff --git a/src/security/validator-null.hpp b/src/security/validator-null.hpp
index 36448af..f8f48ce 100644
--- a/src/security/validator-null.hpp
+++ b/src/security/validator-null.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2013-2016 Regents of the University of California.
+/*
+ * Copyright (c) 2013-2017 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -17,53 +17,35 @@
  * <http://www.gnu.org/licenses/>.
  *
  * See AUTHORS.md for complete list of ndn-cxx authors and contributors.
- *
- * @author Yingdi Yu <http://irl.cs.ucla.edu/~yingdi/>
- * @author Jeff Thompson <jefft0@remap.ucla.edu>
  */
 
 #ifndef NDN_SECURITY_VALIDATOR_NULL_HPP
 #define NDN_SECURITY_VALIDATOR_NULL_HPP
 
-#include "validator.hpp"
+#include "v2/validator.hpp"
 
 namespace ndn {
 namespace security {
+namespace v2 {
 
+/**
+ * @brief Validator with "accept-all" policy and offline certificate fetcher
+ */
 class ValidatorNull : public Validator
 {
 public:
-  virtual
-  ~ValidatorNull()
-  {
-  }
-
-protected:
-  virtual void
-  checkPolicy(const Data& data,
-              int nSteps,
-              const OnDataValidated& onValidated,
-              const OnDataValidationFailed& onValidationFailed,
-              std::vector<shared_ptr<ValidationRequest> >& nextSteps)
-  {
-    onValidated(data.shared_from_this());
-  }
-
-  virtual void
-  checkPolicy(const Interest& interest,
-              int nSteps,
-              const OnInterestValidated& onValidated,
-              const OnInterestValidationFailed& onValidationFailed,
-              std::vector<shared_ptr<ValidationRequest> >& nextSteps)
-  {
-    onValidated(interest.shared_from_this());
-  }
+  ValidatorNull();
 };
 
+security::v2::Validator&
+getAcceptAllValidator();
+
+} // namespace v2
+
+using v2::ValidatorNull;
+using v2::getAcceptAllValidator;
+
 } // namespace security
-
-using security::ValidatorNull;
-
 } // namespace ndn
 
-#endif //NDN_SECURITY_VALIDATOR_NULL_HPP
+#endif // NDN_SECURITY_VALIDATOR_NULL_HPP
diff --git a/src/util/segment-fetcher.cpp b/src/util/segment-fetcher.cpp
index 70ad632..c8075e7 100644
--- a/src/util/segment-fetcher.cpp
+++ b/src/util/segment-fetcher.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2013-2016 Regents of the University of California.
+/*
+ * Copyright (c) 2013-2017 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -25,13 +25,15 @@
 #include "../lp/nack.hpp"
 #include "../lp/nack-header.hpp"
 
+#include <boost/lexical_cast.hpp>
+
 namespace ndn {
 namespace util {
 
 const uint32_t SegmentFetcher::MAX_INTEREST_REEXPRESS = 3;
 
 SegmentFetcher::SegmentFetcher(Face& face,
-                               shared_ptr<Validator> validator,
+                               shared_ptr<security::v2::Validator> validator,
                                const CompleteCallback& completeCallback,
                                const ErrorCallback& errorCallback)
   : m_face(face)
@@ -46,19 +48,18 @@
 void
 SegmentFetcher::fetch(Face& face,
                       const Interest& baseInterest,
-                      Validator& validator,
+                      security::v2::Validator& validator,
                       const CompleteCallback& completeCallback,
                       const ErrorCallback& errorCallback)
 {
-  shared_ptr<Validator> sharedValidator = shared_ptr<Validator>(&validator, [] (Validator*) {});
-
-  fetch(face, baseInterest, sharedValidator, completeCallback, errorCallback);
+  shared_ptr<security::v2::Validator> validatorPtr(&validator, [] (security::v2::Validator*) {});
+  fetch(face, baseInterest, validatorPtr, completeCallback, errorCallback);
 }
 
 void
 SegmentFetcher::fetch(Face& face,
                       const Interest& baseInterest,
-                      shared_ptr<Validator> validator,
+                      shared_ptr<security::v2::Validator> validator,
                       const CompleteCallback& completeCallback,
                       const ErrorCallback& errorCallback)
 {
@@ -106,29 +107,29 @@
   m_validator->validate(data,
                         bind(&SegmentFetcher::afterValidationSuccess, this, _1,
                              isSegmentZeroExpected, origInterest, self),
-                        bind(&SegmentFetcher::afterValidationFailure, this, _1));
+                        bind(&SegmentFetcher::afterValidationFailure, this, _1, _2));
 
 }
 
 void
-SegmentFetcher::afterValidationSuccess(const shared_ptr<const Data> data,
+SegmentFetcher::afterValidationSuccess(const Data& data,
                                        bool isSegmentZeroExpected,
                                        const Interest& origInterest,
                                        shared_ptr<SegmentFetcher> self)
 {
-  name::Component currentSegment = data->getName().get(-1);
+  name::Component currentSegment = data.getName().get(-1);
 
   if (currentSegment.isSegment()) {
     if (isSegmentZeroExpected && currentSegment.toSegment() != 0) {
-      fetchNextSegment(origInterest, data->getName(), 0, self);
+      fetchNextSegment(origInterest, data.getName(), 0, self);
     }
     else {
-      m_buffer->write(reinterpret_cast<const char*>(data->getContent().value()),
-                      data->getContent().value_size());
+      m_buffer->write(reinterpret_cast<const char*>(data.getContent().value()),
+                      data.getContent().value_size());
 
-      const name::Component& finalBlockId = data->getMetaInfo().getFinalBlockId();
+      const name::Component& finalBlockId = data.getMetaInfo().getFinalBlockId();
       if (finalBlockId.empty() || (finalBlockId > currentSegment)) {
-        fetchNextSegment(origInterest, data->getName(), currentSegment.toSegment() + 1, self);
+        fetchNextSegment(origInterest, data.getName(), currentSegment.toSegment() + 1, self);
       }
       else {
         return m_completeCallback(m_buffer->buf());
@@ -141,9 +142,10 @@
 }
 
 void
-SegmentFetcher::afterValidationFailure(const shared_ptr<const Data> data)
+SegmentFetcher::afterValidationFailure(const Data& data, const security::v2::ValidationError& error)
 {
-  return m_errorCallback(SEGMENT_VALIDATION_FAIL, "Segment validation fail");
+  return m_errorCallback(SEGMENT_VALIDATION_FAIL, "Segment validation fail " +
+                         boost::lexical_cast<std::string>(error));
 }
 
 
diff --git a/src/util/segment-fetcher.hpp b/src/util/segment-fetcher.hpp
index 0c2e908..99510f5 100644
--- a/src/util/segment-fetcher.hpp
+++ b/src/util/segment-fetcher.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
-/**
- * Copyright (c) 2013-2015 Regents of the University of California.
+/*
+ * Copyright (c) 2013-2017 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -25,7 +25,7 @@
 #include "scheduler.hpp"
 #include "../common.hpp"
 #include "../face.hpp"
-#include "../security/validator.hpp"
+#include "../security/v2/validator.hpp"
 
 namespace ndn {
 
@@ -140,7 +140,7 @@
   void
   fetch(Face& face,
         const Interest& baseInterest,
-        Validator& validator,
+        security::v2::Validator& validator,
         const CompleteCallback& completeCallback,
         const ErrorCallback& errorCallback);
 
@@ -163,13 +163,13 @@
   void
   fetch(Face& face,
         const Interest& baseInterest,
-        shared_ptr<Validator> validator,
+        shared_ptr<security::v2::Validator> validator,
         const CompleteCallback& completeCallback,
         const ErrorCallback& errorCallback);
 
 private:
   SegmentFetcher(Face& face,
-                 shared_ptr<Validator> validator,
+                 shared_ptr<security::v2::Validator> validator,
                  const CompleteCallback& completeCallback,
                  const ErrorCallback& errorCallback);
 
@@ -185,13 +185,13 @@
                        const Data& data, bool isSegmentZeroExpected,
                        shared_ptr<SegmentFetcher> self);
   void
-  afterValidationSuccess(const shared_ptr<const Data> data,
+  afterValidationSuccess(const Data& data,
                          bool isSegmentZeroExpected,
                          const Interest& origInterest,
                          shared_ptr<SegmentFetcher> self);
 
   void
-  afterValidationFailure(const shared_ptr<const Data> data);
+  afterValidationFailure(const Data& data, const security::v2::ValidationError& error);
 
   void
   afterNackReceived(const Interest& origInterest, const lp::Nack& nack,
@@ -204,7 +204,7 @@
 private:
   Face& m_face;
   Scheduler m_scheduler;
-  shared_ptr<Validator> m_validator;
+  shared_ptr<security::v2::Validator> m_validator;
   CompleteCallback m_completeCallback;
   ErrorCallback m_errorCallback;
 
