On 11/07/2012 08:09, Manel Gimeno Zaragozá wrote:
Any news about the patch? meanwhile I bind policyd to a IP address to
avoid this situation.

Here you go, the next commit will ignore peer address checks for unix socket types.
>From 932340ef7336dc40bdd3d35d2023bde1310e9066 Mon Sep 17 00:00:00 2001
From: Nigel Kukard <[email protected]>
Date: Wed, 11 Jul 2012 08:10:03 +0000
Subject: [PATCH] Better support for IPv4 & IPv6 addresses

---
 awitpt/netip.pm |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/awitpt/netip.pm b/awitpt/netip.pm
index 58d70ae..b2a9bd2 100644
--- a/awitpt/netip.pm
+++ b/awitpt/netip.pm
@@ -69,6 +69,13 @@ sub new
 
 	my $self = {};
 
+	# Check if this is an IPv4 to IPv6 mapping
+	if ($ip =~ /\:ffff\:(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})$/i) {
+
+		# Grab the IP
+		$ip = $1;
+	}
+
 	# Guess ip version
 	if ($ip =~ /:/) {
 		$self->{'ip_version'} = 6;
-- 
1.7.3.4

_______________________________________________
Users mailing list
[email protected]
http://lists.policyd.org/mailman/listinfo/users

Reply via email to