diff --git a/include/ccnx-tunnel.h b/include/ccnx-tunnel.h
index 21cbcbb..c17569d 100644
--- a/include/ccnx-tunnel.h
+++ b/include/ccnx-tunnel.h
@@ -1,7 +1,6 @@
 #ifndef CCNX_TUNNEL_H
 #define CCNX_TUNNEL_H
 
-#include <ccnx-wrapper.h>
 #include <string>
 #include <boost/function.hpp>
 #include <boost/variant.hpp>
@@ -9,7 +8,16 @@
 #include <utility>
 #include <map>
 
-using namespace Sync;
+#include "ccnx-wrapper.h"
+
+#define _OVERRIDE 
+#ifdef __GNUC__
+#if __GNUC_MAJOR >= 4 && __GNUC_MINOR__ >= 7
+  #undef _OVERRIDE
+  #define _OVERRIDE override
+#endif // __GNUC__ version
+#endif // __GNUC__
+
 using namespace std;
 
 // Eventually, Sync::CcnxWrapper should be moved to this namespace. 
@@ -20,9 +28,8 @@
 class CcnxTunnel : public CcnxWrapper 
 {
 public: 
-  typedef boost::variant<StringDataCallback, RawDataCallback> DataCallback;
   typedef multimap<string, InterestCallback> RegisteredInterestTable;
-  typedef multimap<string, InterestCallback>iterator RitIter;
+  typedef multimap<string, InterestCallback>::iterator RitIter;
   typedef boost::shared_mutex Lock;
   typedef boost::unique_lock<Lock> WriteLock;
   typedef boost::shared_lock<Lock> ReadLock;
@@ -33,40 +40,43 @@
 
   // name is topology-independent
   virtual int
-  publishRawData(const string &name, const char *buf, size_t len, int freshness);
+  publishData(const string &name, const char *buf, size_t len, int freshness) _OVERRIDE;
+
+  virtual int
+  sendInterest (const std::string &interest, const DataCallback &dataCallback, int retry = 0, const TimeoutCallback &timeoutCallback = TimeoutCallback()) _OVERRIDE;
+
 
   // prefix is topology-independent
   virtual int
-  setInterestFilter(const string &prefix, const InterestCallback &interestCallback);
+  setInterestFilter(const string &prefix, const InterestCallback &interestCallback) _OVERRIDE;
 
   // prefix is topology-independent
   // this clears all entries with key equal to prefix
   virtual void
-  clearInterestFilter(const string &prefix);
+  clearInterestFilter(const string &prefix) _OVERRIDE;
 
   // subclass should provide translation service from topology-independent name
   // to routable name
   virtual string
-  queryRoutableName(string &name) = 0;
+  queryRoutableName(const string &name) = 0;
 
   // subclass should implement the function to store ContentObject with topoloy-independent
   // name to the permanent storage; default does nothing
   virtual void
-  storeContentObject(string &name, ContentObjectPtr co) {}
+  storeContentObject(const string &name, const Bytes &content) {}
 
   // should be called  when connect to a different network
   void
   refreshLocalPrefix();
 
   static bool
-  isPrefix(string &prefix, string &name);
+  isPrefix(const string &prefix, const string &name);
 
-protected:
   void
-  handleTunneledInterest(string tunneldInterest);
-
-  virtual int
-  sendInterest (const std::string &strInterest, void *dataPass);
+  handleTunneledInterest(const string &tunneldInterest);
+  
+  void
+  handleTunneledData(const string &name, const Bytes &tunneledData, const DataCallback &originalDataCallback);
 
 protected:
   // need a way to update local prefix, perhaps using macports trick, but eventually we need something more portable
@@ -75,6 +85,22 @@
   Lock m_ritLock;
 };
 
+class TunnelClosurePass : public ClosurePass
+{
+public:
+  TunnelClosurePass(int retry, const CcnxWrapper::DataCallback &dataCallback, const CcnxWrapper::TimeoutCallback &timeoutCallback, CcnxTunnel *tunnel, const string &originalInterest);
+
+  virtual void 
+  runDataCallback(const string &name, const Bytes &content) _OVERRIDE;
+
+  virtual CcnxWrapper::TimeoutCallbackReturnValue
+  runTimeoutCallback(const string &interest) _OVERRIDE;
+
+private:
+  CcnxTunnel *m_tunnel;
+  string m_originalInterest;
+};
+
 };
 
 #endif
