diff --git a/src/face.cpp b/src/face.cpp
index d20f57c..430f65e 100644
--- a/src/face.cpp
+++ b/src/face.cpp
@@ -240,10 +240,22 @@
 {
   Block wire = data.wireEncode();
 
+  lp::Packet packet;
+  bool hasLpFields = false;
+
   shared_ptr<lp::CachePolicyTag> cachePolicyTag = data.getTag<lp::CachePolicyTag>();
   if (cachePolicyTag != nullptr) {
-    lp::Packet packet;
     packet.add<lp::CachePolicyField>(*cachePolicyTag);
+    hasLpFields = true;
+  }
+
+  shared_ptr<lp::CongestionMarkTag> congestionMarkTag = data.getTag<lp::CongestionMarkTag>();
+  if (congestionMarkTag != nullptr) {
+    packet.add<lp::CongestionMarkField>(*congestionMarkTag);
+    hasLpFields = true;
+  }
+
+  if (hasLpFields) {
     packet.add<lp::FragmentField>(std::make_pair(wire.begin(), wire.end()));
     wire = packet.wireEncode();
   }
@@ -264,6 +276,11 @@
   const Block& interestWire = nack.getInterest().wireEncode();
   packet.add<lp::FragmentField>(std::make_pair(interestWire.begin(), interestWire.end()));
 
+  shared_ptr<lp::CongestionMarkTag> congestionMarkTag = nack.getTag<lp::CongestionMarkTag>();
+  if (congestionMarkTag != nullptr) {
+    packet.add<lp::CongestionMarkField>(*congestionMarkTag);
+  }
+
   Block wire = packet.wireEncode();
 
   if (wire.size() > MAX_NDN_PACKET_SIZE)
@@ -500,13 +517,17 @@
 /**
  * @brief extract local fields from NDNLPv2 packet and tag onto a network layer packet
  */
-template<typename NETPKT>
+template<typename NetPkt>
 static void
-extractLpLocalFields(NETPKT& netPacket, const lp::Packet& lpPacket)
+extractLpLocalFields(NetPkt& netPacket, const lp::Packet& lpPacket)
 {
   if (lpPacket.has<lp::IncomingFaceIdField>()) {
     netPacket.setTag(make_shared<lp::IncomingFaceIdTag>(lpPacket.get<lp::IncomingFaceIdField>()));
   }
+
+  if (lpPacket.has<lp::CongestionMarkField>()) {
+    netPacket.setTag(make_shared<lp::CongestionMarkTag>(lpPacket.get<lp::CongestionMarkField>()));
+  }
 }
 
 void
