diff --git a/src/certificate-request.cpp b/src/certificate-request.cpp
index 80b5a45..d1a4545 100644
--- a/src/certificate-request.cpp
+++ b/src/certificate-request.cpp
@@ -29,52 +29,24 @@
                                        const security::v2::Certificate& cert)
   : m_caName(caName)
   , m_requestId(requestId)
-  , m_status(Pending)
   , m_cert(static_cast<const Data&>(cert))
 {
 }
 
 CertificateRequest::CertificateRequest(const Name& caName,
                                        const std::string& requestId,
-                                       const ApplicationStatus& status,
+                                       const std::string& status,
                                        const std::string& challengeType,
-                                       const std::string& challengeStatus,
-                                       const std::string& challengeDefinedField,
+                                       const std::string& challengeSecrets,
                                        const security::v2::Certificate& cert)
   : m_caName(caName)
   , m_requestId(requestId)
   , m_status(status)
   , m_challengeType(challengeType)
-  , m_challengeStatus(challengeStatus)
-  , m_challengeDefinedField(challengeDefinedField)
   , m_cert(static_cast<const Data&>(cert))
 {
-}
-
-std::ostream&
-operator<<(std::ostream& os, CertificateRequest::ApplicationStatus status)
-{
-  std::string statusString;
-  switch (status) {
-    case CertificateRequest::Pending: {
-      statusString = "pending";
-      break;
-    }
-    case CertificateRequest::Verifying: {
-      statusString = "verifying";
-      break;
-    }
-    case CertificateRequest::Success: {
-      statusString = "success";
-      break;
-    }
-    case CertificateRequest::Failure: {
-      statusString = "failure";
-      break;
-    }
-  }
-  os << statusString;
-  return os;
+  std::istringstream ss(challengeSecrets);
+  boost::property_tree::json_parser::read_json(ss, m_challengeSecrets);
 }
 
 std::ostream&
@@ -84,16 +56,14 @@
   os << "  " << request.getCaName() << "\n";
   os << "Request ID:\n";
   os << "  " << request.getRequestId() << "\n";
-  os << "Request Status:\n";
-  os << "  " << request.getStatus() << "\n";
+  if (request.getStatus() != "") {
+    os << "Request Status:\n";
+    os << "  " << request.getStatus() << "\n";
+  }
   if (request.getChallengeType() != "") {
     os << "Request Challenge Type:\n";
     os << "  " << request.getChallengeType() << "\n";
   }
-  if (request.getChallengeStatus() != "") {
-    os << "Request Challenge Status:\n";
-    os << "  " << request.getChallengeStatus() << "\n";
-  }
   os << "Certificate:\n";
   util::IndentedStream os2(os, "  ");
   os2 << request.getCert();
diff --git a/src/certificate-request.hpp b/src/certificate-request.hpp
index b8d1ccd..35fb2f7 100644
--- a/src/certificate-request.hpp
+++ b/src/certificate-request.hpp
@@ -27,6 +27,8 @@
 namespace ndn {
 namespace ndncert {
 
+typedef boost::property_tree::ptree JsonSection;
+
 /**
  * @brief Represents a certificate request instance.
  *
@@ -37,20 +39,12 @@
 class CertificateRequest
 {
 public:
-  enum ApplicationStatus {
-    Pending = 0,
-    Verifying = 1,
-    Success = 2,
-    Failure = 3
-  };
-
-public:
   CertificateRequest(const Name& caName, const std::string& requestId,
                      const security::v2::Certificate& cert);
 
   CertificateRequest(const Name& caName, const std::string& requestId,
-                     const ApplicationStatus& status, const std::string& challengeType,
-                     const std::string& challengeStatus, const std::string& challengeDefinedField,
+                     const std::string& status, const std::string& challengeType,
+                     const std::string& challengeDefinedField,
                      const security::v2::Certificate& certBlock);
 
   const Name&
@@ -65,7 +59,7 @@
     return m_requestId;
   }
 
-  const ApplicationStatus&
+  const std::string&
   getStatus() const
   {
     return m_status;
@@ -77,22 +71,10 @@
     return m_challengeType;
   }
 
-  const std::string&
-  getChallengeDefinedField() const
+  const JsonSection&
+  getChallengeSecrets() const
   {
-    return m_challengeDefinedField;
-  }
-
-  const std::string&
-  getChallengeInstruction() const
-  {
-    return m_challengeInstruction;
-  }
-
-  const std::string&
-  getChallengeStatus() const
-  {
-    return m_challengeStatus;
+    return m_challengeSecrets;
   }
 
   const security::v2::Certificate&
@@ -101,11 +83,8 @@
     return m_cert;
   }
 
-  /**
-   * These setters should only be invoked by ChallengeModule
-   */
   void
-  setStatus(const ApplicationStatus& status)
+  setStatus(const std::string& status)
   {
     m_status = status;
   }
@@ -117,58 +96,28 @@
   }
 
   void
-  setChallengeStatus(const std::string& challengeStatus)
+  setChallengeSecrets(const JsonSection& challengeSecrets)
   {
-    m_challengeStatus = challengeStatus;
-  }
-
-  void
-  setChallengeDefinedField(const std::string& challengeDefinedField)
-  {
-    m_challengeDefinedField = challengeDefinedField;
-  }
-
-  void
-  setChallengeInstruction(const std::string& challengeInstruction)
-  {
-    m_challengeInstruction = challengeInstruction;
+    m_challengeSecrets = challengeSecrets;
   }
 
 private:
   Name m_caName;
   std::string m_requestId;
-  ApplicationStatus m_status;
+  std::string m_status;
   std::string m_challengeType;
 
   /**
-   * @brief Defined by ChallengeModule to indicate the verification status.
-   *
-   * This field will be stored by CA.
-   */
-  std::string m_challengeStatus;
-
-  /**
    * @brief Defined by ChallengeModule to store secret information.
    *
    * This field will be stored by CA.
    */
-  std::string m_challengeDefinedField;
-
-  /**
-   * @brief Defined by ChallengeModule to indicate end entity the next step.
-   *
-   * This field will be presented to end entity.
-   * This field will NOT be stored by CA.
-   */
-  std::string m_challengeInstruction;
+  JsonSection m_challengeSecrets;
 
   security::v2::Certificate m_cert;
 };
 
 std::ostream&
-operator<<(std::ostream& os, CertificateRequest::ApplicationStatus status);
-
-std::ostream&
 operator<<(std::ostream& os, const CertificateRequest& request);
 
 } // namespace ndncert
diff --git a/src/json-helper.cpp b/src/json-helper.cpp
index 609b426..a7cc897 100644
--- a/src/json-helper.cpp
+++ b/src/json-helper.cpp
@@ -36,18 +36,15 @@
 }
 
 const JsonSection
-genResponseNewJson(const CertificateRequest& request,
-                   const std::list<std::tuple<std::string, std::string>> challenges)
+genResponseNewJson(const std::string& requestId, const std::list<std::string>& challenges)
 {
   JsonSection root;
   JsonSection challengesSection;
-  root.put(JSON_STATUS, boost::lexical_cast<std::string>(request.getStatus()));
-  root.put(JSON_REQUEST_ID, request.getRequestId());
+  root.put(JSON_REQUEST_ID, requestId);
 
   for (const auto& entry : challenges) {
     JsonSection challenge;
-    challenge.put(JSON_CHALLENGE_TYPE, std::get<0>(entry));
-    challenge.put(JSON_CHALLENGE_INSTRUCTION, std::get<1>(entry));
+    challenge.put(JSON_CHALLENGE_TYPE, entry);
     challengesSection.push_back(std::make_pair("", challenge));
   }
   root.add_child(JSON_CHALLENGES, challengesSection);
@@ -56,13 +53,16 @@
 }
 
 const JsonSection
-genResponsePollJson(const CertificateRequest& request)
+genResponseChallengeJson(const std::string& requestId, const std::string& challengeType,
+                         const std::string& status, const Name& name)
 {
   JsonSection root;
-  root.put(JSON_STATUS, boost::lexical_cast<std::string>(request.getStatus()));
-  root.put(JSON_CHALLENGE_TYPE, request.getChallengeType());
-  root.put(JSON_CHALLENGE_STATUS, request.getChallengeStatus());
-  root.put(JSON_CHALLENGE_INSTRUCTION, request.getChallengeInstruction());
+  root.put(JSON_REQUEST_ID, requestId);
+  root.put(JSON_CHALLENGE_TYPE, challengeType);
+  root.put(JSON_STATUS, status);
+  if (name.toUri() != "") {
+    root.put(JSON_CERTIFICATE, name.toUri());
+  }
   return root;
 }
 
diff --git a/src/json-helper.hpp b/src/json-helper.hpp
index fe3ba80..c34c631 100644
--- a/src/json-helper.hpp
+++ b/src/json-helper.hpp
@@ -26,25 +26,22 @@
 namespace ndn {
 namespace ndncert {
 
-const std::string JSON_IDNENTIFIER = "Identifier";
-const std::string JSON_CA_INFO = "CA-Info";
-const std::string JSON_STATUS = "Status";
-const std::string JSON_REQUEST_ID = "Request-ID";
-const std::string JSON_CHALLENGES = "Challenges";
-const std::string JSON_CHALLENGE_TYPE = "Challenge-Type";
-const std::string JSON_CHALLENGE_INSTRUCTION = "Challenge-Instruction";
-const std::string JSON_CHALLENGE_STATUS = "Challenge-Status";
-const std::string JSON_ERROR_INFO = "Error-Info";
-
-typedef boost::property_tree::ptree JsonSection;
+const std::string JSON_IDNENTIFIER = "identifier";
+const std::string JSON_CA_INFO = "ca-info";
+const std::string JSON_STATUS = "status";
+const std::string JSON_REQUEST_ID = "request-id";
+const std::string JSON_CHALLENGES = "challenges";
+const std::string JSON_CHALLENGE_TYPE = "challenge-type";
+const std::string JSON_ERROR_INFO = "error-info";
+const std::string JSON_CERTIFICATE = "certificate";
 
 /**
  * @brief Generate JSON file to response PROBE insterest
  *
  * Target JSON format:
  * {
- *   "Identifier": "",
- *   "CA-Info": ""
+ *   "identifier": "",
+ *   "ca-info": ""
  * }
  */
 const JsonSection
@@ -55,46 +52,54 @@
  *
  * Target JSON format:
  * {
- *   "Status": "",
- *   "Request-ID": "",
- *   "Challenges": [
+ *   "request-id": "",
+ *   "challenges": [
  *     {
- *       "Challenge-Type": "",
- *       "Challenge-Instruction": ""
+ *       "challenge-type": ""
  *     },
  *     {
- *       "Challenge-Type": "",
- *       "Challenge-Instruction": ""
+ *       "challenge-type": ""
  *     },
  *     ...
  *   ]
  * }
  */
 const JsonSection
-genResponseNewJson(const CertificateRequest& request,
-                   const std::list<std::tuple<std::string, std::string>> challenges);
+genResponseNewJson(const std::string& requestId, const std::list<std::string>& challenges);
 
 /**
- * @brief Generate JSON file to response POLL interest
+ * @brief Generate JSON file to response _SELECT, _VALIDATE, and _STATUS interest
+ *
+ * if certificate name is not present:
  *
  * Target JSON format:
  * {
- *   "Status": "",
- *   "Challenge-Type": "",
- *   "Challenge-Status": "",
- *   "Challenge-Instruction": ""
+ *   "request-id": "@p requestId",
+ *   "challenge-type": "@p challengeType",
+ *   "status": "@p status"
+ * }
+ *
+ * if certificate name is present:
+ *
+ * Target JSON format:
+ * {
+ *   "request-id": "@p requestId",
+ *   "challenge-type": "@p challengeType",
+ *   "status": "@p status",
+ *   "certificate":"@p name"
  * }
  */
 const JsonSection
-genResponsePollJson(const CertificateRequest& request);
+genResponseChallengeJson(const std::string& requestId, const std::string& challengeType,
+                         const std::string& status, const Name& name = Name());
 
 /**
  * @brief Generate JSON file when there is an Error
  *
  * Target JSON format:
  * {
- *   "Status": "",
- *   "Error-Info": ""
+ *   "status": "",
+ *   "error-info": ""
  * }
  */
 const JsonSection
diff --git a/tests/unit-tests/certificate-request.t.cpp b/tests/unit-tests/certificate-request.t.cpp
index 113748d..3282ee9 100644
--- a/tests/unit-tests/certificate-request.t.cpp
+++ b/tests/unit-tests/certificate-request.t.cpp
@@ -38,49 +38,43 @@
   CertificateRequest request1(Name("/ndn/site1"), "123", cert);
   BOOST_CHECK_EQUAL(request1.getCaName().toUri(), "/ndn/site1");
   BOOST_CHECK_EQUAL(request1.getRequestId(), "123");
-  BOOST_CHECK_EQUAL(request1.getStatus(), CertificateRequest::Pending);
-  BOOST_CHECK_EQUAL(request1.getChallengeType(), "");
-  BOOST_CHECK_EQUAL(request1.getChallengeStatus(), "");
-  BOOST_CHECK_EQUAL(request1.getChallengeDefinedField(), "");
-  BOOST_CHECK_EQUAL(request1.getChallengeInstruction(), "");
+  BOOST_CHECK_EQUAL(request1.getStatus(), "");
+  BOOST_CHECK_EQUAL(request1.getChallengeSecrets().empty(), true);
+  BOOST_CHECK_EQUAL(request1.getCert(), cert);
   BOOST_CHECK_EQUAL(request1.getCert(), cert);
 
-  CertificateRequest request2(Name("/ndn/site1"), "123", CertificateRequest::Verifying,
-                              "Email", "NEED_CODE", "123456", cert);
+  JsonSection json;
+  json.put("code", "1234");
+  std::stringstream ss;
+  boost::property_tree::write_json(ss, json);
+  std::string jsonValue = ss.str();
+
+  CertificateRequest request2(Name("/ndn/site1"), "123", "need-verify", "EMAIL", jsonValue, cert);
   BOOST_CHECK_EQUAL(request2.getCaName().toUri(), "/ndn/site1");
   BOOST_CHECK_EQUAL(request2.getRequestId(), "123");
-  BOOST_CHECK_EQUAL(request2.getStatus(), CertificateRequest::Verifying);
-  BOOST_CHECK_EQUAL(request2.getChallengeType(), "Email");
-  BOOST_CHECK_EQUAL(request2.getChallengeStatus(), "NEED_CODE");
-  BOOST_CHECK_EQUAL(request2.getChallengeDefinedField(), "123456");
-  BOOST_CHECK_EQUAL(request2.getChallengeInstruction(), "");
+  BOOST_CHECK_EQUAL(request2.getStatus(), "need-verify");
+  BOOST_CHECK_EQUAL(request2.getChallengeType(), "EMAIL");
+  BOOST_CHECK(request2.getChallengeSecrets() == json);
   BOOST_CHECK_EQUAL(request2.getCert(), cert);
 }
 
-BOOST_AUTO_TEST_CASE(GetStatusOutput)
-{
-  CertificateRequest::ApplicationStatus status = CertificateRequest::Success;
-  BOOST_CHECK_EQUAL(boost::lexical_cast<std::string>(status), "success");
-}
-
 BOOST_AUTO_TEST_CASE(GetterSetter)
 {
   auto identity = addIdentity(Name("/ndn/site1"));
   auto key = identity.getDefaultKey();
   auto cert = key.getDefaultCertificate();
 
-  CertificateRequest request(Name("/ndn/site1"), "123", cert);
-  request.setStatus(CertificateRequest::Verifying);
-  request.setChallengeType("Email");
-  request.setChallengeDefinedField("456");
-  request.setChallengeStatus("NEED_EMAIL");
-  request.setChallengeInstruction("Please provide your email address");
+  JsonSection json;
+  json.put("code", "1234");
 
-  BOOST_CHECK_EQUAL(request.getStatus(), CertificateRequest::Verifying);
-  BOOST_CHECK_EQUAL(request.getChallengeType(), "Email");
-  BOOST_CHECK_EQUAL(request.getChallengeDefinedField(), "456");
-  BOOST_CHECK_EQUAL(request.getChallengeStatus(), "NEED_EMAIL");
-  BOOST_CHECK_EQUAL(request.getChallengeInstruction(), "Please provide your email address");
+  CertificateRequest request(Name("/ndn/site1"), "123", cert);
+  request.setStatus("need-verify");
+  request.setChallengeType("EMAIL");
+  request.setChallengeSecrets(json);
+
+  BOOST_CHECK_EQUAL(request.getStatus(), "need-verify");
+  BOOST_CHECK_EQUAL(request.getChallengeType(), "EMAIL");
+  BOOST_CHECK(request.getChallengeSecrets() == json);
 }
 
 BOOST_AUTO_TEST_CASE(GetCertificateRequestOutput)
@@ -101,8 +95,6 @@
   /ndn/site1
 Request ID:
   123
-Request Status:
-  pending
 Certificate:
   Certificate name:
     /ndn/site1/KEY/ksk-1416425377094/0123/%FD%00%00%01I%C9%8B
diff --git a/tests/unit-tests/json-helper.t.cpp b/tests/unit-tests/json-helper.t.cpp
index d258e54..61a74e5 100644
--- a/tests/unit-tests/json-helper.t.cpp
+++ b/tests/unit-tests/json-helper.t.cpp
@@ -18,14 +18,14 @@
  * See AUTHORS.md for complete list of ndncert authors and contributors.
  */
 
-#include "identity-management-fixture.hpp"
+#include "boost-test.hpp"
 #include "json-helper.hpp"
 
 namespace ndn {
 namespace ndncert {
 namespace tests {
 
-BOOST_FIXTURE_TEST_SUITE(TestJsonHelper, IdentityManagementV2Fixture)
+BOOST_AUTO_TEST_SUITE(TestJsonHelper)
 
 BOOST_AUTO_TEST_CASE(GenerateProbeJson)
 {
@@ -37,45 +37,33 @@
 
 BOOST_AUTO_TEST_CASE(GenerateNewResponseJson)
 {
-  auto identity = addIdentity(Name("/ndn/site1"));
-  auto key = identity.getDefaultKey();
-  auto cert = key.getDefaultCertificate();
+  std::list<std::string> challenges;
+  challenges.push_back("PIN");
+  challenges.push_back("EMAIL");
+  auto result = genResponseNewJson("598234759", challenges);
 
-  CertificateRequest request(Name("/ndn/site1"), "598234759", cert);
-  std::list<std::tuple<std::string, std::string>> challenges;
-  challenges.push_back(std::make_tuple("PIN", "Please ask ca officer"));
-  challenges.push_back(std::make_tuple("EMAIL", "Please provide your email"));
-  auto result = genResponseNewJson(request, challenges);
-
-  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_STATUS), "pending");
   BOOST_CHECK_EQUAL(result.get<std::string>(JSON_REQUEST_ID), "598234759");
   auto child = result.get_child(JSON_CHALLENGES);
   auto it = child.begin();
   BOOST_CHECK_EQUAL(it->second.get<std::string>(JSON_CHALLENGE_TYPE), "PIN");
-  BOOST_CHECK_EQUAL(it->second.get<std::string>(JSON_CHALLENGE_INSTRUCTION),
-                    "Please ask ca officer");
   it++;
   BOOST_CHECK_EQUAL(it->second.get<std::string>(JSON_CHALLENGE_TYPE), "EMAIL");
-  BOOST_CHECK_EQUAL(it->second.get<std::string>(JSON_CHALLENGE_INSTRUCTION),
-                    "Please provide your email");
 }
 
-BOOST_AUTO_TEST_CASE(GeneratePollResponseJson)
+BOOST_AUTO_TEST_CASE(GenerateChallengeResponseJson)
 {
-  auto identity = addIdentity(Name("/ndn/site1"));
-  auto key = identity.getDefaultKey();
-  auto cert = key.getDefaultCertificate();
+  auto result = genResponseChallengeJson("598234759", "EMAIL", "need-code");
 
-  CertificateRequest request(Name("/ndn/site1"), "598234759", CertificateRequest::Verifying,
-                             "Email", "NEED_CODE", "111", cert);
-  request.setChallengeInstruction("Please provide verification code");
-  auto result = genResponsePollJson(request);
+  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_REQUEST_ID), "598234759");
+  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_CHALLENGE_TYPE), "EMAIL");
+  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_STATUS), "need-code");
 
-  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_STATUS), "verifying");
-  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_CHALLENGE_TYPE), "Email");
-  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_CHALLENGE_STATUS), "NEED_CODE");
-  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_CHALLENGE_INSTRUCTION),
-                    "Please provide verification code");
+  result = genResponseChallengeJson("598234759", "EMAIL", "need-code", Name("/ndn/test"));
+
+  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_REQUEST_ID), "598234759");
+  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_CHALLENGE_TYPE), "EMAIL");
+  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_STATUS), "need-code");
+  BOOST_CHECK_EQUAL(result.get<std::string>(JSON_CERTIFICATE), "/ndn/test");
 }
 
 BOOST_AUTO_TEST_CASE(GenerateErrorJson)
