> Anyway, when I make a policy with a policy group of domains as source, 
> my internal domains as destination,  I get this in my cbpolicyd.log:
>
> [2009/05/31-22:12:27 - 82459] [POLICIES] WARNING: 
> [ID:10/Name:whitelistdnsname]=>(group:whitelist_dns_names): - Source 
> '.google.com' is not a valid specification
>   
Try the attached patch.

-N
Index: cbp/policies.pm
===================================================================
--- cbp/policies.pm	(revision 459)
+++ cbp/policies.pm	(working copy)
@@ -403,7 +403,7 @@
 			$server->log(LOG_DEBUG,"[POLICIES] $debugTxt: - Resolved source '$item' to a email address specification, match = $res") if ($log);
 
 		# Match domain name (for reverse dns)
-		} elsif ($item =~ /^(?:[a-z0-9\-_\*]+\.)+[a-z0-9]+$/i) {
+		} elsif ($item =~ /^\.?(?:[a-z0-9\-_\*]+\.)+[a-z0-9]+$/i) {
 			$res = reverseDNSMatches($sessionData->{'ClientReverseName'},$item);
 			$server->log(LOG_DEBUG,"[POLICIES] $debugTxt: - Resolved source '$item' to a reverse dns specification, match = $res") if ($log);
 
_______________________________________________
Users mailing list
[email protected]
http://lists.policyd.org/mailman/listinfo/users

Reply via email to