From 487f5a20b690058cc57f83cce94c2df60499fb8b Mon Sep 17 00:00:00 2001
From: yang-g <yangg@google.com>
Date: Tue, 28 Jul 2015 23:21:03 -0700
Subject: [PATCH] add warning comments

---
 include/grpc++/client_context.h | 4 ++++
 include/grpc++/server_context.h | 4 ++++
 2 files changed, 8 insertions(+)

diff --git a/include/grpc++/client_context.h b/include/grpc++/client_context.h
index f18fb61b4c..bb39042bcb 100644
--- a/include/grpc++/client_context.h
+++ b/include/grpc++/client_context.h
@@ -118,6 +118,10 @@ class ClientContext {
 
   std::shared_ptr<const AuthContext> auth_context() const;
 
+  // Return the peer uri in a string.
+  // WARNING: this value is never authenticated or subject to any security
+  // related code. It must not be used for any authentication related
+  // functionality. Instead, use auth_context.
   grpc::string peer() const;
 
   // Get and set census context
diff --git a/include/grpc++/server_context.h b/include/grpc++/server_context.h
index 393822c4fd..1e848935a2 100644
--- a/include/grpc++/server_context.h
+++ b/include/grpc++/server_context.h
@@ -116,6 +116,10 @@ class ServerContext {
 
   std::shared_ptr<const AuthContext> auth_context() const;
 
+  // Return the peer uri in a string.
+  // WARNING: this value is never authenticated or subject to any security
+  // related code. It must not be used for any authentication related
+  // functionality. Instead, use auth_context.
   grpc::string peer() const;
 
  private:
-- 
GitLab