Rename RequestState to CaState
 - to prevent confusion with RequesterState

Change-Id: I56048e289fded44bf39dd1fe6a5e26ddd3938b99
diff --git a/src/challenge-modules/challenge-credential.cpp b/src/challenge-modules/challenge-credential.cpp
index 50a15c0..f6e26c2 100644
--- a/src/challenge-modules/challenge-credential.cpp
+++ b/src/challenge-modules/challenge-credential.cpp
@@ -76,7 +76,7 @@
 
 // For CA
 std::tuple<ErrorCode, std::string>
-ChallengeCredential::handleChallengeRequest(const Block& params, RequestState& request)
+ChallengeCredential::handleChallengeRequest(const Block& params, CaState& request)
 {
   params.parse();
   if (m_trustAnchors.empty()) {
diff --git a/src/challenge-modules/challenge-credential.hpp b/src/challenge-modules/challenge-credential.hpp
index 07b0158..2354767 100644
--- a/src/challenge-modules/challenge-credential.hpp
+++ b/src/challenge-modules/challenge-credential.hpp
@@ -53,7 +53,7 @@
 
   // For CA
   std::tuple<ErrorCode, std::string>
-  handleChallengeRequest(const Block& params, RequestState& request) override;
+  handleChallengeRequest(const Block& params, CaState& request) override;
 
   // For Client
   std::vector<std::tuple<std::string, std::string>>
diff --git a/src/challenge-modules/challenge-email.cpp b/src/challenge-modules/challenge-email.cpp
index d98972f..2775d9e 100644
--- a/src/challenge-modules/challenge-email.cpp
+++ b/src/challenge-modules/challenge-email.cpp
@@ -43,7 +43,7 @@
 
 // For CA
 std::tuple<ErrorCode, std::string>
-ChallengeEmail::handleChallengeRequest(const Block& params, RequestState& request)
+ChallengeEmail::handleChallengeRequest(const Block& params, CaState& request)
 {
   params.parse();
   auto currentTime = time::system_clock::now();
@@ -157,7 +157,7 @@
 
 void
 ChallengeEmail::sendEmail(const std::string& emailAddress, const std::string& secret,
-                          const RequestState& request) const
+                          const CaState& request) const
 {
   std::string command = m_sendEmailScript;
   command += " \"" + emailAddress + "\" \"" + secret + "\" \"" + request.m_caPrefix.toUri() + "\" \"" + request.m_cert.getName().toUri() + "\"";
diff --git a/src/challenge-modules/challenge-email.hpp b/src/challenge-modules/challenge-email.hpp
index bfae052..5d803f1 100644
--- a/src/challenge-modules/challenge-email.hpp
+++ b/src/challenge-modules/challenge-email.hpp
@@ -57,7 +57,7 @@
 
   // For CA
   std::tuple<ErrorCode, std::string>
-  handleChallengeRequest(const Block& params, RequestState& request) override;
+  handleChallengeRequest(const Block& params, CaState& request) override;
 
   // For Client
   std::vector<std::tuple<std::string, std::string>>
@@ -81,7 +81,7 @@
 
   void
   sendEmail(const std::string& emailAddress, const std::string& secret,
-            const RequestState& request) const;
+            const CaState& request) const;
 
 private:
   std::string m_sendEmailScript;
diff --git a/src/challenge-modules/challenge-pin.cpp b/src/challenge-modules/challenge-pin.cpp
index ecc17db..a5d5580 100644
--- a/src/challenge-modules/challenge-pin.cpp
+++ b/src/challenge-modules/challenge-pin.cpp
@@ -38,7 +38,7 @@
 
 // For CA
 std::tuple<ErrorCode, std::string>
-ChallengePin::handleChallengeRequest(const Block& params, RequestState& request)
+ChallengePin::handleChallengeRequest(const Block& params, CaState& request)
 {
   params.parse();
   auto currentTime = time::system_clock::now();
diff --git a/src/challenge-modules/challenge-pin.hpp b/src/challenge-modules/challenge-pin.hpp
index 7b58a27..cd85eec 100644
--- a/src/challenge-modules/challenge-pin.hpp
+++ b/src/challenge-modules/challenge-pin.hpp
@@ -52,7 +52,7 @@
 
   // For CA
   std::tuple<ErrorCode, std::string>
-  handleChallengeRequest(const Block& params, RequestState& request) override;
+  handleChallengeRequest(const Block& params, CaState& request) override;
 
   // For Client
   std::vector<std::tuple<std::string, std::string>>