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
52b0ac93
Commit
52b0ac93
authored
19 years ago
by
Stuart Gathman
Browse files
Options
Downloads
Patches
Plain Diff
Put guessed result in separate header.
parent
8bc182cb
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
TODO
+0
-4
0 additions, 4 deletions
TODO
bms.py
+6
-2
6 additions, 2 deletions
bms.py
with
6 additions
and
6 deletions
TODO
+
0
−
4
View file @
52b0ac93
Include full info in Received-SPF for neutral. When making best
guess, Received-SPF should be none. Add additional keywords or
another header.
Require signed MFROM for all incoming bounces when signing all outgoing mail -
Require signed MFROM for all incoming bounces when signing all outgoing mail -
except from trusted relays.
except from trusted relays.
...
...
This diff is collapsed.
Click to expand it.
bms.py
+
6
−
2
View file @
52b0ac93
#!/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.44 2005/12/23 21:47:07 customdesigned
# Move Received-SPF header to top.
#
# Revision 1.43 2005/12/09 16:54:01 customdesigned
# Revision 1.43 2005/12/09 16:54:01 customdesigned
# Select neutral DSN template for best_guess
# Select neutral DSN template for best_guess
#
#
...
@@ -1012,7 +1015,6 @@ class bmsMilter(Milter.Milter):
...
@@ -1012,7 +1015,6 @@ class bmsMilter(Milter.Milter):
res
,
code
,
txt
=
q
.
best_guess
(
'
v=spf1 a/24 mx/24
'
)
res
,
code
,
txt
=
q
.
best_guess
(
'
v=spf1 a/24 mx/24
'
)
else
:
else
:
res
,
code
,
txt
=
q
.
best_guess
()
res
,
code
,
txt
=
q
.
best_guess
()
receiver
+=
'
: guessing
'
if
q
.
perm_error
:
# FIXME: should never happen?
if
q
.
perm_error
:
# FIXME: should never happen?
res
,
code
,
txt
=
q
.
perm_error
.
ext
# extended result
res
,
code
,
txt
=
q
.
perm_error
.
ext
# extended result
txt
=
'
EXT:
'
+
txt
txt
=
'
EXT:
'
+
txt
...
@@ -1094,7 +1096,9 @@ class bmsMilter(Milter.Milter):
...
@@ -1094,7 +1096,9 @@ class bmsMilter(Milter.Milter):
self
.
log
(
'
TEMPFAIL: SPF %s %i %s
'
%
(
res
,
code
,
txt
))
self
.
log
(
'
TEMPFAIL: SPF %s %i %s
'
%
(
res
,
code
,
txt
))
self
.
setreply
(
str
(
code
),
'
4.3.0
'
,
txt
)
self
.
setreply
(
str
(
code
),
'
4.3.0
'
,
txt
)
return
Milter
.
TEMPFAIL
return
Milter
.
TEMPFAIL
self
.
add_header
(
'
Received-SPF
'
,
q
.
get_header
(
res
,
receiver
),
0
)
self
.
add_header
(
'
Received-SPF
'
,
q
.
get_header
(
q
.
result
,
receiver
),
0
)
if
res
!=
q
.
result
:
self
.
add_header
(
'
X-Guessed-SPF
'
,
res
,
0
)
self
.
spf
=
q
self
.
spf
=
q
if
res
==
'
pass
'
and
auto_whitelist
.
has_key
(
self
.
canon_from
):
if
res
==
'
pass
'
and
auto_whitelist
.
has_key
(
self
.
canon_from
):
self
.
whitelist
=
True
self
.
whitelist
=
True
...
...
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