From b46cdd37023fccc545db507b939f70bf8af7f7a0 Mon Sep 17 00:00:00 2001 From: Marcello Coutinho Date: Thu, 10 Oct 2013 00:41:08 -0300 Subject: bind - add rate limit option --- config/bind/bind.inc | 17 +++++++++++++++-- config/bind/bind.xml | 52 ++++++++++++++++++++++++++++++++++++++++------------ 2 files changed, 55 insertions(+), 14 deletions(-) (limited to 'config/bind') diff --git a/config/bind/bind.inc b/config/bind/bind.inc index d1ff106f..4e01214a 100644 --- a/config/bind/bind.inc +++ b/config/bind/bind.inc @@ -72,7 +72,20 @@ $bind_conf .= <<$bind_listenonv6 $bind_listenon"; + //print "
$bind_listenonv6 $bind_listenon";
 	if (key_exists("ipv6allow",$config['system'])){
 		$bind_conf .="\t\tlisten-on-v6 { $bind_listenonv6 };\n";
 		}
diff --git a/config/bind/bind.xml b/config/bind/bind.xml
index a3b9e572..97dc7012 100644
--- a/config/bind/bind.xml
+++ b/config/bind/bind.xml
@@ -124,6 +124,11 @@
                 http://www.pfsense.org/packages/config/bind/pkg_bind.inc
         
         
+                
+                        listtopic
+                        Daemon Settings
+                        temp01
+                
                 
                         Enable Bind
                         enable_bind
@@ -132,6 +137,15 @@
                         checkbox
                         
                 
+              
+                        Listen-on
+                        listenon
+                        
+                        interfaces_selection
+                        
+                        
+                        
+                
                 
                         Enable logging
                         bind_logging
@@ -151,27 +165,43 @@
                         checkbox
                 
                 
-					Limitar Memory RAM
+					Limit Memory use
 					bind_ram_limit
-					Limits the use of RAM for the DNS when much use does not exhaust the resources of the machine, recommend 256M
+					Limits RAM use for DNS server, recommend 256M
 					input
                 	10
 					256M
                	
                 
                         listtopic
-                        Listen on Interfaces
+                        Response limit
                         temp01
                 
                 
-                        Listen-on
-                        listenon
-                        
-                        interfaces_selection
-                        
-                        
-                        
+                        Rate limit
+                        rate_enabled
+                        Limit/rate response queries to prevent DOS attack.
+                        checkbox
+                        rate_limit,log_only
+                
+				
+					Limit Action
+					log_only
+					Select what to do when a query reaches a limit.
+					select
+						
+							
+							
+						
+				
+				
+					limit
+					rate_limit
+					Set rate limit. Default to 15.
+					input
+                	10
                 
+
                 
                         listtopic
                         Forwarder Config
@@ -211,8 +241,6 @@
     	
     	
         
-                bind_views_before_form_dest(&$pkg,"bindacls","name","listenonv6");
-                bind_views_before_form_dest(&$pkg,"bindacls","name","listenon");
         
         
         
-- 
cgit v1.2.3