Skip to content
Snippets Groups Projects
Commit 2f533c45 authored by Stuart Gathman's avatar Stuart Gathman
Browse files

Use CIDR notation for internal connect list.

parent 04c8b2e1
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/env python #!/usr/bin/env python
# A simple milter that has grown quite a bit. # A simple milter that has grown quite a bit.
# $Log$ # $Log$
# Revision 1.51 2006/02/12 01:13:58 customdesigned
# Don't check rcpt user list when signed MFROM.
#
# Revision 1.50 2006/02/09 20:39:43 customdesigned # Revision 1.50 2006/02/09 20:39:43 customdesigned
# Use CIDR notation for trusted_relay iplist # Use CIDR notation for trusted_relay iplist
# #
...@@ -677,10 +680,8 @@ class bmsMilter(Milter.Milter): ...@@ -677,10 +680,8 @@ class bmsMilter(Milter.Milter):
self.receiver = self.getsymval('j').strip() self.receiver = self.getsymval('j').strip()
if hostaddr and len(hostaddr) > 0: if hostaddr and len(hostaddr) > 0:
ipaddr = hostaddr[0] ipaddr = hostaddr[0]
for pat in internal_connect: if iniplist(ipaddr,internal_connect):
if fnmatchcase(ipaddr,pat):
self.internal_connection = True self.internal_connection = True
break
if iniplist(ipaddr,trusted_relay): if iniplist(ipaddr,trusted_relay):
self.trusted_relay = True self.trusted_relay = True
else: ipaddr = '' else: ipaddr = ''
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment