Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pymilter
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
misc
pymilter
Commits
a5078a6e
Commit
a5078a6e
authored
16 years ago
by
Stuart Gathman
Browse files
Options
Downloads
Patches
Plain Diff
Release 0.8.11
parent
96f5b6e9
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
MANIFEST.in
+1
-0
1 addition, 0 deletions
MANIFEST.in
ban2zone.py
+4
-5
4 additions, 5 deletions
ban2zone.py
pymilter.spec
+4
-3
4 additions, 3 deletions
pymilter.spec
with
9 additions
and
8 deletions
MANIFEST.in
+
1
−
0
View file @
a5078a6e
...
@@ -16,6 +16,7 @@ include bms.py
...
@@ -16,6 +16,7 @@ include bms.py
include spf.py
include spf.py
include cid2spf.py
include cid2spf.py
include spfquery.py
include spfquery.py
include ban2zone.py
include test.py
include test.py
include sample.py
include sample.py
include milter-template.py
include milter-template.py
...
...
This diff is collapsed.
Click to expand it.
ban2zone.py
+
4
−
5
View file @
a5078a6e
#!/usr/bin/python2.4
#!/usr/bin/python2.4
# Convert banned ip list to zonefile data suitable for use as a
# DNS blacklist with BIND. This is a way to share your banned ips
# with friends.
import
socket
import
socket
import
sys
import
sys
from
glob
import
glob
from
glob
import
glob
banned_ips
=
[
socket
.
inet_aton
(
ip
)
for
fn
in
sys
.
argv
[
1
:]
for
ip
in
open
(
fn
)]
banned_ips
=
set
(
socket
.
inet_aton
(
ip
)
for
fn
in
sys
.
argv
[
1
:]
for
ip
in
open
(
fn
))
banned_ips
=
list
(
banned_ips
)
banned_ips
.
sort
()
banned_ips
.
sort
()
for
ip
in
banned_ips
:
for
ip
in
banned_ips
:
a
=
socket
.
inet_ntoa
(
ip
).
split
(
'
.
'
)
a
=
socket
.
inet_ntoa
(
ip
).
split
(
'
.
'
)
...
...
This diff is collapsed.
Click to expand it.
pymilter.spec
+
4
−
3
View file @
a5078a6e
...
@@ -2,9 +2,9 @@
...
@@ -2,9 +2,9 @@
# module. To compile all three on 32-bit Intel, use:
# module. To compile all three on 32-bit Intel, use:
# rpmbuild -ba --target=i386,noarch pymilter.spec
# rpmbuild -ba --target=i386,noarch pymilter.spec
%define __python python
%define __python python
2.4
%define version 0.8.11
%define version 0.8.11
%define release 1%{?dist}
%define release 1%{?dist}
.py24
# what version of RH are we building for?
# what version of RH are we building for?
%define redhat7 0
%define redhat7 0
...
@@ -73,7 +73,7 @@ mkdir -p $RPM_BUILD_ROOT/etc/mail
...
@@ -73,7 +73,7 @@ mkdir -p $RPM_BUILD_ROOT/etc/mail
mkdir $RPM_BUILD_ROOT/var/log/milter/save
mkdir $RPM_BUILD_ROOT/var/log/milter/save
mkdir -p $RPM_BUILD_ROOT%{libdir}
mkdir -p $RPM_BUILD_ROOT%{libdir}
cp *.txt $RPM_BUILD_ROOT/var/log/milter
cp *.txt $RPM_BUILD_ROOT/var/log/milter
cp bms.py spfmilter.py $RPM_BUILD_ROOT%{libdir}
cp
-p
bms.py spfmilter.py
ban2zone.py
$RPM_BUILD_ROOT%{libdir}
cp milter.cfg $RPM_BUILD_ROOT/etc/mail/pymilter.cfg
cp milter.cfg $RPM_BUILD_ROOT/etc/mail/pymilter.cfg
cp spfmilter.cfg $RPM_BUILD_ROOT/etc/mail
cp spfmilter.cfg $RPM_BUILD_ROOT/etc/mail
...
@@ -172,6 +172,7 @@ fi
...
@@ -172,6 +172,7 @@ fi
%dir /var/log/milter
%dir /var/log/milter
%dir /var/log/milter/save
%dir /var/log/milter/save
%config %{libdir}/bms.py
%config %{libdir}/bms.py
%config %{libdir}/ban2zone.py
%config(noreplace) /var/log/milter/strike3.txt
%config(noreplace) /var/log/milter/strike3.txt
%config(noreplace) /var/log/milter/softfail.txt
%config(noreplace) /var/log/milter/softfail.txt
%config(noreplace) /var/log/milter/fail.txt
%config(noreplace) /var/log/milter/fail.txt
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment