diff --git a/src/encoding/der/visitor/print-visitor.cpp b/src/encoding/der/visitor/print-visitor.cpp
index cba5d2d..4c5ee64 100644
--- a/src/encoding/der/visitor/print-visitor.cpp
+++ b/src/encoding/der/visitor/print-visitor.cpp
@@ -78,7 +78,7 @@
 PrintVisitor::visit(DerOid& derOid, ndnboost::any param)
 {
   const string& indent = ndnboost::any_cast<const string&>(param);
-	
+  
   printData(derOid.getHeader(), indent);
   printData(derOid.getPayload(), indent + "   ");
 
@@ -88,7 +88,7 @@
 PrintVisitor::visit(DerGtime& derGtime, ndnboost::any param)
 {
   const string& indent = ndnboost::any_cast<const string&>(param);
-	
+  
   printData(derGtime.getHeader(), indent);
   printData(derGtime.getPayload(), indent + "   ");
 }
@@ -103,7 +103,7 @@
   const DerNodePtrList& children = derSequence.getChildren();
   DerNodePtrList::const_iterator it = children.begin();
   for(; it != children.end(); it++)
-	(*it)->accept(*this, indent + " | ");
+  (*it)->accept(*this, indent + " | ");
 }
 
 
diff --git a/src/security/certificate/identity-certificate.cpp b/src/security/certificate/identity-certificate.cpp
index a328112..2e2ea79 100644
--- a/src/security/certificate/identity-certificate.cpp
+++ b/src/security/certificate/identity-certificate.cpp
@@ -18,6 +18,8 @@
 {
   if (!isCorrectName(data.getName()))
     throw SecurityException("Wrong Identity Certificate Name!");
+  
+  setPublicKeyName();
 }
 
 IdentityCertificate::~IdentityCertificate()
@@ -29,14 +31,25 @@
 {
   int i = name.size() - 1;
   
+  string idString("ID-CERT");
   for (; i >= 0; i--) {
-    if(name.get(i).toEscapedString() == string("ID-CERT"))
+    if(name.get(i).toEscapedString() == idString)
       break;
   }
 
   if (i < 0)
     return false;
   
+  int keyIdx = 0;
+  string keyString("KEY");
+  for (; keyIdx < name.size(); keyIdx++) {
+    if(name.get(keyIdx).toEscapedString() == keyString)
+      break;
+  }
+
+  if (keyIdx >= name.size())
+    return false;
+
   return true;
 }
 
@@ -47,20 +60,30 @@
     throw SecurityException("Wrong Identity Certificate Name!");
   
   Data::setName(name);
+  setPublicKeyName();
   return *this;
 }
 
-Name
-IdentityCertificate::getPublicKeyName() const
+void
+IdentityCertificate::setPublicKeyName()
 {
   const Name& certificateName = getName();
-  int i = certificateName.size() - 1;
 
-  for (; i >= 0; i--)
-    if(certificateName.get(i).toEscapedString() == string("ID-CERT"))
-  break; 
+  int i = certificateName.size() - 1;
+  string idString("ID-CERT");
+  for (; i >= 0; i--) {
+    if (certificateName.get(i).toEscapedString() == idString)
+      break;
+  }
+    
+  Name tmpName = certificateName.getSubName(0, i);    
+  string keyString("KEY");
+  for (i = 0; i < tmpName.size(); i++) {
+    if (tmpName.get(i).toEscapedString() == keyString)
+      break;
+  }
   
-  return certificateName.getSubName(0, i);
+  publicKeyName_ = tmpName.getSubName(0, i).append(tmpName.getSubName(i + 1, tmpName.size() - i - 1));
 }
 
 bool
