tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kfuj...@apache.org
Subject svn commit: r1666062 - /tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/DomainFilterInterceptor.java
Date Thu, 12 Mar 2015 02:14:08 GMT
Author: kfujino
Date: Thu Mar 12 02:14:08 2015
New Revision: 1666062

URL: http://svn.apache.org/r1666062
Log:
Make sure that refuse the messages from a different domain in DomainFilterInterceptor.

Modified:
    tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/DomainFilterInterceptor.java

Modified: tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/DomainFilterInterceptor.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/DomainFilterInterceptor.java?rev=1666062&r1=1666061&r2=1666062&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/DomainFilterInterceptor.java
(original)
+++ tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/DomainFilterInterceptor.java
Thu Mar 12 02:14:08 2015
@@ -41,8 +41,12 @@ public class DomainFilterInterceptor ext
 
     @Override
     public void messageReceived(ChannelMessage msg) {
-        //should we filter incoming based on domain?
-        super.messageReceived(msg);
+        if (Arrays.equals(domain, msg.getAddress().getDomain())) {
+            super.messageReceived(msg);
+        } else {
+            if (log.isWarnEnabled())
+                log.warn("Received message from cluster["+msg.getAddress()+"] was refused.");
+        }
     }//messageReceived
 
 



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message