diff --git a/src/encoding/tlv.cpp b/src/encoding/tlv.cpp
new file mode 100644
index 0000000..4de73a1
--- /dev/null
+++ b/src/encoding/tlv.cpp
@@ -0,0 +1,42 @@
+/* -*- 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 "tlv.hpp"
+
+namespace ndn {
+namespace tlv {
+
+std::ostream&
+operator<<(std::ostream& os, const SignatureTypeValue& signatureType)
+{
+  switch (signatureType) {
+    case SignatureTypeValue::DigestSha256:
+      return os << "DigestSha256";
+    case SignatureTypeValue::SignatureSha256WithRsa:
+      return os << "SignatureSha256WithRsa";
+    case SignatureTypeValue::SignatureSha256WithEcdsa:
+      return os << "SignatureSha256WithEcdsa";
+  }
+  return os << "Unknown Signature Type";
+}
+
+} // namespace tlv
+} // namespace ndn
diff --git a/src/encoding/tlv.hpp b/src/encoding/tlv.hpp
index ad964e2..c9a6520 100644
--- a/src/encoding/tlv.hpp
+++ b/src/encoding/tlv.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).
  *
@@ -99,6 +99,9 @@
   SignatureSha256WithEcdsa = 3
 };
 
+std::ostream&
+operator<<(std::ostream& os, const SignatureTypeValue& signatureType);
+
 /** @brief TLV codes for SignatureInfo features
  *  @sa docs/tutorials/certificate-format.rst
  */
diff --git a/src/key-locator.cpp b/src/key-locator.cpp
index 151a704..8eef8cc 100644
--- a/src/key-locator.cpp
+++ b/src/key-locator.cpp
@@ -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).
  *
@@ -21,6 +21,7 @@
 
 #include "key-locator.hpp"
 #include "encoding/block-helpers.hpp"
+#include "util/string-helper.hpp"
 
 namespace ndn {
 
@@ -189,4 +190,30 @@
   return wireEncode() == other.wireEncode();
 }
 
+std::ostream&
+operator<<(std::ostream& os, const KeyLocator& keyLocator)
+{
+  switch (keyLocator.getType()) {
+    case KeyLocator::KeyLocator_Name: {
+      return os << "Name=" << keyLocator.getName();
+    }
+    case KeyLocator::KeyLocator_KeyDigest: {
+      const size_t MAX_DIGEST_OCTETS_TO_SHOW = 5;
+      const Block& digest = keyLocator.getKeyDigest();
+      os << "KeyDigest=" << toHex(digest.value(), digest.value_size()).substr(0, MAX_DIGEST_OCTETS_TO_SHOW * 2);
+      if (digest.value_size() > MAX_DIGEST_OCTETS_TO_SHOW) {
+        os << "...";
+      }
+      return os;
+    }
+    case KeyLocator::KeyLocator_None: {
+      return os << "None";
+    }
+    case KeyLocator::KeyLocator_Unknown: {
+      return os << "Unknown";
+    }
+  }
+  return os << "Unknown";
+}
+
 } // namespace ndn
diff --git a/src/key-locator.hpp b/src/key-locator.hpp
index 8c206e4..b442854 100644
--- a/src/key-locator.hpp
+++ b/src/key-locator.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).
  *
@@ -162,6 +162,9 @@
   mutable Block m_wire;
 };
 
+std::ostream&
+operator<<(std::ostream& os, const KeyLocator& keyLocator);
+
 } // namespace ndn
 
 #endif // NDN_KEY_LOCATOR_HPP
diff --git a/src/security/v2/certificate.cpp b/src/security/v2/certificate.cpp
index b6a08ab..dcd6ae0 100644
--- a/src/security/v2/certificate.cpp
+++ b/src/security/v2/certificate.cpp
@@ -23,7 +23,10 @@
  */
 
 #include "certificate.hpp"
+#include "additional-description.hpp"
 #include "../../encoding/block-helpers.hpp"
+#include "../../util/indented-stream.hpp"
+#include "../transform.hpp"
 
 namespace ndn {
 namespace security {
@@ -132,6 +135,52 @@
           certName.get(Certificate::KEY_COMPONENT_OFFSET) == Certificate::KEY_COMPONENT);
 }
 
+std::ostream&
+operator<<(std::ostream& os, const Certificate& cert)
+{
+  os << "Certificate name:\n";
+  os << "  " << cert.getName() << "\n";
+  os << "Validity:\n";
+  {
+    os << "  NotBefore: " << time::toIsoString(cert.getValidityPeriod().getPeriod().first) << "\n";
+    os << "  NotAfter: "  << time::toIsoString(cert.getValidityPeriod().getPeriod().second)  << "\n";
+  }
+
+  try {
+    const Block& info = cert.getSignature().getSignatureInfo().getTypeSpecificTlv(tlv::AdditionalDescription);
+    os << "Additional Description:\n";
+    for (const auto& item : v2::AdditionalDescription(info)) {
+      os << "  " << item.first << ": " << item.second << "\n";
+    }
+  }
+  catch (const SignatureInfo::Error&) {
+    // ignore
+  }
+
+  os << "Public key bits:\n";
+  {
+    util::IndentedStream os2(os, "  ");
+    namespace t = ndn::security::transform;
+    t::bufferSource(cert.getPublicKey().buf(), cert.getPublicKey().size()) >> t::base64Encode() >> t::streamSink(os2);
+  }
+
+  os << "Signature Information:\n";
+  {
+    os << "  Signature Type: " << static_cast<tlv::SignatureTypeValue>(cert.getSignature().getType()) << "\n";
+
+    if (cert.getSignature().hasKeyLocator()) {
+      os << "  Key Locator: ";
+      const KeyLocator& keyLocator = cert.getSignature().getKeyLocator();
+      if (keyLocator.getType() == KeyLocator::KeyLocator_Name && keyLocator.getName() == cert.getKeyName()) {
+        os << "Self-Signed ";
+      }
+      os << keyLocator << "\n";
+    }
+  }
+
+  return os;
+}
+
 Name
 extractIdentityFromCertName(const Name& certName)
 {
diff --git a/src/security/v2/certificate.hpp b/src/security/v2/certificate.hpp
index c451277..c5e2c97 100644
--- a/src/security/v2/certificate.hpp
+++ b/src/security/v2/certificate.hpp
@@ -172,6 +172,9 @@
   static const name::Component KEY_COMPONENT;
 };
 
+std::ostream&
+operator<<(std::ostream& os, const Certificate& cert);
+
 /**
  * @brief Extract identity namespace from the certificate name @p certName
  */
