Index: /source/ariba/SideportListener.cpp
===================================================================
--- /source/ariba/SideportListener.cpp	(revision 4733)
+++ /source/ariba/SideportListener.cpp	(revision 4738)
@@ -71,4 +71,34 @@
 }
 
+//******************************************************
+//
+// JUST EXPERIMENTAL WITH RANDOM RESULTS
+//
+
+// 0 = normal node    --> directly accessible
+// 1 = relaying node  --> node that is relaying for us (must also be 0)
+// 2 = relayed node   --> node that we cannot access directly
+static map<NodeID,short> relayingnodes;
+
+bool SideportListener::isRelayingNode(const NodeID& node){
+
+	map<NodeID,short>::iterator i = relayingnodes.find(node);
+	if(i != relayingnodes.end()) return (i->second == 1);
+
+	relayingnodes.insert( std::make_pair( node, rand()%3 ) );
+}
+
+bool SideportListener::isRelayedNode(const NodeID& node){
+
+	map<NodeID,short>::iterator i = relayingnodes.find(node);
+	if(i != relayingnodes.end()) return (i->second == 2);
+
+	relayingnodes.insert( std::make_pair( node, rand()%3 ) );
+}
+
+//
+//
+//******************************************************
+
 void SideportListener::configure( overlay::BaseOverlay* _overlay ) {
 	overlay = _overlay;
Index: /source/ariba/SideportListener.h
===================================================================
--- /source/ariba/SideportListener.h	(revision 4733)
+++ /source/ariba/SideportListener.h	(revision 4738)
@@ -41,7 +41,9 @@
 
 #include <vector>
+#include <map>
 #include "Identifiers.h"
 #include "CommunicationListener.h"
 
+using std::map;
 using std::vector;
 
@@ -131,4 +133,20 @@
 			) const;
 
+	/**
+	 * Is this node acting as a relay for us
+	 *
+	 * @param The node in question
+	 * @return true, if this node is relaying for us
+	 */
+	bool isRelayingNode(const NodeID& node);
+
+	/**
+	 * Is this node only reachable for us through a relay?
+	 *
+	 * @param The node in question
+	 * @return true, if we reach this node only over a relay
+	 */
+	bool isRelayedNode(const NodeID& node);
+
 protected:
 
