security: Split KeyChain into signing (KeyChain) and verification (Verifier) interfaces
This split removes the need for IdentityManager.
Also in this commit: Make verifySignature methods a set of static methods of Verifier.
Change-Id: Iea1c4353857a21417b2dcd1f91ba7013995d1459
diff --git a/include/ndn-cpp/security/policy/policy-manager.hpp b/include/ndn-cpp/security/policy/policy-manager.hpp
index f84a505..400360d 100644
--- a/include/ndn-cpp/security/policy/policy-manager.hpp
+++ b/include/ndn-cpp/security/policy/policy-manager.hpp
@@ -10,7 +10,7 @@
#define NDN_POLICY_MANAGER_HPP
#include "../../data.hpp"
-#include "../key-chain.hpp"
+#include "validation-request.hpp"
namespace ndn {
@@ -22,6 +22,8 @@
*/
class PolicyManager {
public:
+ struct Error : public std::runtime_error { Error(const std::string &what) : std::runtime_error(what) {} };
+
/**
* The virtual destructor.
*/
diff --git a/include/ndn-cpp/security/policy/validation-request.hpp b/include/ndn-cpp/security/policy/validation-request.hpp
index 78f2d6c..69a1079 100644
--- a/include/ndn-cpp/security/policy/validation-request.hpp
+++ b/include/ndn-cpp/security/policy/validation-request.hpp
@@ -9,7 +9,7 @@
#ifndef NDN_VALIDATION_REQUEST_HPP
#define NDN_VALIDATION_REQUEST_HPP
-#include "../key-chain.hpp"
+#include "../../interest.hpp"
namespace ndn {