<s>
DomainKeys	B-Protocol
Identified	I-Protocol
Mail	I-Protocol
(	O
DKIM	B-Protocol
)	O
is	O
an	O
email	O
authentication	O
method	O
designed	O
to	O
detect	O
forged	O
sender	O
addresses	O
in	O
email	O
(	O
email	O
spoofing	O
)	O
,	O
a	O
technique	O
often	O
used	O
in	O
phishing	O
and	O
email	O
spam	O
.	O
</s>
<s>
DKIM	B-Protocol
allows	O
the	O
receiver	O
to	O
check	O
that	O
an	O
email	O
claimed	O
to	O
have	O
come	O
from	O
a	O
specific	O
domain	O
was	O
indeed	O
authorized	O
by	O
the	O
owner	O
of	O
that	O
domain	O
.	O
</s>
<s>
The	O
recipient	O
system	O
can	O
verify	O
this	O
by	O
looking	O
up	O
the	O
sender	O
's	O
public	B-Application
key	I-Application
published	O
in	O
the	O
DNS	B-Protocol
.	O
</s>
<s>
Usually	O
,	O
DKIM	B-Protocol
signatures	O
are	O
not	O
visible	O
to	O
end-users	O
,	O
and	O
are	O
affixed	O
or	O
verified	O
by	O
the	O
infrastructure	O
rather	O
than	O
the	O
message	O
's	O
authors	O
and	O
recipients	O
.	O
</s>
<s>
DKIM	B-Protocol
is	O
an	O
Internet	O
Standard	O
.	O
</s>
<s>
DKIM	B-Protocol
provides	O
the	O
ability	O
to	O
sign	O
a	O
message	O
,	O
and	O
allows	O
the	O
signer	O
(	O
author	O
organization	O
)	O
to	O
communicate	O
which	O
email	O
it	O
considers	O
legitimate	O
.	O
</s>
<s>
DKIM	B-Protocol
also	O
provides	O
a	O
process	O
for	O
verifying	O
a	O
signed	O
message	O
.	O
</s>
<s>
All	O
of	O
this	O
is	O
independent	O
of	O
Simple	B-Protocol
Mail	I-Protocol
Transfer	I-Protocol
Protocol	I-Protocol
(	O
SMTP	B-Protocol
)	O
routing	O
aspects	O
,	O
in	O
that	O
it	O
operates	O
on	O
the	O
RFC	O
5322	O
message	O
—	O
the	O
transported	O
mail	O
's	O
header	O
and	O
body	O
—	O
not	O
the	O
SMTP	B-Protocol
"	O
envelope	O
"	O
defined	O
in	O
RFC	B-Protocol
5321	I-Protocol
.	O
</s>
<s>
Hence	O
,	O
DKIM	B-Protocol
signatures	O
survive	O
basic	O
relaying	O
across	O
multiple	O
MTAs	B-Protocol
.	O
</s>
<s>
The	O
signing	O
organization	O
can	O
be	O
a	O
direct	O
handler	O
of	O
the	O
message	O
,	O
such	O
as	O
the	O
author	O
,	O
the	O
submission	B-Protocol
site	O
or	O
a	O
further	O
intermediary	O
along	O
the	O
transit	O
path	O
,	O
or	O
an	O
indirect	O
handler	O
such	O
as	O
an	O
independent	O
service	O
that	O
is	O
providing	O
assistance	O
to	O
a	O
direct	O
handler	O
.	O
</s>
<s>
Signing	O
modules	O
insert	O
one	O
or	O
more	O
DKIM-Signature	B-Protocol
:	O
header	O
fields	O
,	O
possibly	O
on	O
behalf	O
of	O
the	O
author	O
organization	O
or	O
the	O
originating	O
service	O
provider	O
.	O
</s>
<s>
The	O
DKIM-Signature	B-Protocol
:	O
field	O
of	O
the	O
signature	O
being	O
created	O
,	O
with	O
bh	O
equal	O
to	O
the	O
computed	O
body	O
hash	O
and	O
b	O
equal	O
to	O
the	O
empty	O
string	O
,	O
is	O
implicitly	O
added	O
to	O
the	O
second	O
hash	O
,	O
albeit	O
its	O
name	O
must	O
not	O
appear	O
in	O
h	O
—	O
if	O
it	O
does	O
,	O
it	O
refers	O
to	O
another	O
,	O
preexisting	O
signature	O
.	O
</s>
<s>
The	O
result	O
,	O
after	O
encryption	O
with	O
the	O
signer	O
's	O
private	B-Application
key	I-Application
and	O
encoding	O
using	O
Base64	O
,	O
is	O
b	O
.	O
</s>
<s>
A	O
receiving	O
SMTP	B-Protocol
server	I-Protocol
wanting	O
to	O
verify	O
uses	O
the	O
domain	O
name	O
and	O
the	O
selector	O
to	O
perform	O
a	O
DNS	B-Protocol
lookup	O
.	O
</s>
<s>
This	O
gives	O
the	O
TXT	B-Protocol
resource	O
record	O
to	O
be	O
looked	O
up	O
as	O
:	O
</s>
<s>
In	O
that	O
case	O
the	O
label	O
must	O
be	O
encoded	O
according	O
to	O
IDNA	B-Language
before	O
lookup	O
.	O
</s>
<s>
It	O
includes	O
the	O
domain	O
's	O
public	B-Application
key	I-Application
,	O
along	O
with	O
other	O
key	O
usage	O
tokens	O
and	O
flags	O
(	O
e.g.	O
</s>
<s>
The	O
receiver	O
can	O
use	O
the	O
public	B-Application
key	I-Application
(	O
value	O
of	O
the	O
p	O
tag	O
)	O
to	O
then	O
validate	O
the	O
signature	O
on	O
the	O
hash	O
value	O
in	O
the	O
header	O
field	O
,	O
and	O
check	O
it	O
against	O
the	O
hash	O
value	O
for	O
the	O
mail	O
message	O
(	O
headers	O
and	O
body	O
)	O
that	O
was	O
received	O
.	O
</s>
<s>
Although	O
DomainKeys	B-Protocol
is	O
covered	O
,	O
Yahoo	B-Application
!	I-Application
</s>
<s>
has	O
licensed	O
its	O
patent	O
claims	O
under	O
a	O
dual	O
license	O
scheme	O
:	O
the	O
DomainKeys	B-Protocol
Patent	O
License	O
Agreement	O
v1.2	O
,	O
or	O
GNU	O
General	O
Public	O
License	O
v2.0	O
(	O
and	O
no	O
other	O
version	O
)	O
.	O
</s>
<s>
In	O
essence	O
,	O
both	O
DKIM	B-Protocol
and	O
SPF	B-Protocol
provide	O
different	O
measures	O
of	O
email	O
authenticity	O
.	O
</s>
<s>
DMARC	O
provides	O
the	O
ability	O
for	O
an	O
organisation	O
to	O
publish	O
a	O
policy	O
that	O
specifies	O
which	O
mechanism	O
(	O
DKIM	B-Protocol
,	O
SPF	B-Protocol
,	O
or	O
both	O
)	O
is	O
employed	O
when	O
sending	O
email	O
from	O
that	O
domain	O
;	O
how	O
to	O
check	O
the	O
From	O
:	O
field	O
presented	O
to	O
end	O
users	O
;	O
how	O
the	O
receiver	O
should	O
deal	O
with	O
failures	O
—	O
and	O
a	O
reporting	O
mechanism	O
for	O
actions	O
performed	O
under	O
those	O
policies	O
.	O
</s>
<s>
It	O
allows	O
a	O
great	O
reduction	O
in	O
abuse	O
desk	O
work	O
for	O
DKIM-enabled	O
domains	O
if	O
e-mail	O
receivers	O
use	O
the	O
DKIM	B-Protocol
system	O
to	O
identify	O
forged	O
e-mail	O
messages	O
claiming	O
to	O
be	O
from	O
that	O
domain	O
.	O
</s>
<s>
DKIM	B-Protocol
is	O
a	O
method	O
of	O
labeling	O
a	O
message	O
,	O
and	O
it	O
does	O
not	O
itself	O
filter	O
or	O
identify	O
spam	O
.	O
</s>
<s>
However	O
,	O
widespread	O
use	O
of	O
DKIM	B-Protocol
can	O
prevent	O
spammers	O
from	O
forging	O
the	O
source	O
address	O
of	O
their	O
messages	O
,	O
a	O
technique	O
they	O
commonly	O
employ	O
today	O
.	O
</s>
<s>
Conversely	O
,	O
DKIM	B-Protocol
can	O
make	O
it	O
easier	O
to	O
identify	O
mail	O
that	O
is	O
known	O
not	O
to	O
be	O
spam	O
and	O
need	O
not	O
be	O
filtered	O
.	O
</s>
<s>
DKIM	B-Protocol
can	O
be	O
useful	O
as	O
an	O
anti-phishing	O
technology	O
.	O
</s>
<s>
DKIM	B-Protocol
used	O
to	O
have	O
an	O
optional	O
feature	O
called	O
ADSP	O
that	O
lets	O
authors	O
that	O
sign	O
all	O
their	O
mail	O
self-identify	O
,	O
but	O
it	O
was	O
demoted	O
to	O
historic	O
status	O
in	O
November	O
2013	O
.	O
</s>
<s>
Instead	O
,	O
DMARC	O
can	O
be	O
used	O
for	O
the	O
same	O
purpose	O
and	O
allows	O
domains	O
to	O
self-publish	O
which	O
techniques	O
(	O
including	O
SPF	B-Protocol
and	O
DKIM	B-Protocol
)	O
they	O
employ	O
,	O
which	O
makes	O
it	O
easier	O
for	O
the	O
receiver	O
to	O
make	O
an	O
informed	O
decision	O
whether	O
a	O
certain	O
mail	O
is	O
spam	O
or	O
not	O
.	O
</s>
<s>
For	O
example	O
,	O
using	O
DMARC	O
,	O
eBay	B-Application
and	O
PayPal	O
both	O
publish	O
policies	O
that	O
all	O
of	O
their	O
mail	O
is	O
authenticated	O
,	O
and	O
requesting	O
that	O
any	O
receiving	O
system	O
,	O
such	O
as	O
Gmail	B-Application
,	O
should	O
reject	O
any	O
that	O
is	O
not	O
.	O
</s>
<s>
Because	O
it	O
is	O
implemented	O
using	O
DNS	B-Protocol
records	O
and	O
an	O
added	O
RFC	O
5322	O
header	O
field	O
,	O
DKIM	B-Protocol
is	O
compatible	O
with	O
the	O
existing	O
e-mail	O
infrastructure	O
.	O
</s>
<s>
In	O
particular	O
,	O
it	O
is	O
transparent	O
to	O
existing	O
e-mail	O
systems	O
that	O
lack	O
DKIM	B-Protocol
support	O
.	O
</s>
<s>
This	O
design	O
approach	O
also	O
is	O
compatible	O
with	O
other	O
,	O
related	O
services	O
,	O
such	O
as	O
the	O
S/MIME	B-Protocol
and	O
OpenPGP	O
content-protection	O
standards	O
.	O
</s>
<s>
DKIM	B-Protocol
is	O
compatible	O
with	O
the	O
DNSSEC	B-Protocol
standard	O
and	O
with	O
SPF	B-Protocol
.	O
</s>
<s>
DKIM	B-Protocol
requires	O
cryptographic	O
checksums	O
to	O
be	O
generated	O
for	O
each	O
message	O
sent	O
through	O
a	O
mail	B-Protocol
server	I-Protocol
,	O
which	O
results	O
in	O
computational	O
overhead	O
not	O
otherwise	O
required	O
for	O
e-mail	O
delivery	O
.	O
</s>
<s>
This	O
facet	O
of	O
DKIM	B-Protocol
may	O
look	O
similar	O
to	O
hashcash	O
,	O
except	O
that	O
the	O
receiver	O
side	O
verification	O
is	O
a	O
negligible	O
amount	O
of	O
work	O
,	O
while	O
a	O
typical	O
hashcash	O
algorithm	O
would	O
require	O
far	O
more	O
work	O
.	O
</s>
<s>
DKIM	B-Protocol
's	O
non-repudiation	O
feature	O
prevents	O
senders	O
(	O
such	O
as	O
spammers	O
)	O
from	O
credibly	O
denying	O
having	O
sent	O
an	O
email	O
.	O
</s>
<s>
It	O
has	O
proven	O
useful	O
to	O
news	O
media	O
sources	O
such	O
as	O
WikiLeaks	O
,	O
which	O
has	O
been	O
able	O
to	O
leverage	O
DKIM	B-Protocol
body	O
signatures	O
to	O
prove	O
that	O
leaked	O
emails	O
were	O
genuine	O
and	O
not	O
tampered	O
with	O
—	O
for	O
example	O
definitively	O
repudiating	O
such	O
claims	O
by	O
Hillary	O
Clinton	O
's	O
2016	O
US	O
Presidential	O
Election	O
running	O
mate	O
Tim	O
Kaine	O
,	O
and	O
DNC	O
Chair	O
Donna	O
Brazile	O
.	O
</s>
<s>
DKIM	B-Protocol
signatures	O
do	O
not	O
encompass	O
the	O
message	O
envelope	O
,	O
which	O
holds	O
the	O
return-path	O
and	O
message	O
recipients	O
.	O
</s>
<s>
Since	O
DKIM	B-Protocol
does	O
not	O
attempt	O
to	O
protect	O
against	O
mis-addressing	O
,	O
this	O
does	O
not	O
affect	O
its	O
utility	O
.	O
</s>
<s>
Replay	O
can	O
be	O
inferred	O
by	O
using	O
per-message	O
public	B-Application
keys	I-Application
,	O
tracking	O
the	O
DNS	B-Protocol
queries	I-Protocol
for	O
those	O
keys	O
and	O
filtering	O
out	O
the	O
high	O
number	O
of	O
queries	O
due	O
to	O
e-mail	O
being	O
sent	O
to	O
large	O
mailing	O
lists	O
or	O
malicious	O
queries	O
by	O
bad	O
actors	O
.	O
</s>
<s>
An	O
evil	O
email	O
user	O
of	O
a	O
reputable	O
domain	O
can	O
compose	O
a	O
bad	O
message	O
and	O
have	O
it	O
DKIM-signed	O
and	O
sent	O
from	O
that	O
domain	O
to	O
any	O
mailbox	O
from	O
where	O
they	O
can	O
retrieve	O
it	O
as	O
a	O
file	O
,	O
so	O
as	O
to	O
obtain	O
a	O
signed	O
copy	O
of	O
the	O
message	O
.	O
</s>
<s>
The	O
signed	O
copy	O
can	O
then	O
be	O
forwarded	O
to	O
a	O
million	O
recipients	O
,	O
for	O
example	O
through	O
a	O
botnet	B-Architecture
,	O
without	O
control	O
.	O
</s>
<s>
The	O
validity	O
of	O
signatures	O
in	O
such	O
messages	O
can	O
be	O
limited	O
by	O
always	O
including	O
an	O
expiration	O
time	O
tag	O
in	O
signatures	O
,	O
or	O
by	O
revoking	O
a	O
public	B-Application
key	I-Application
periodically	O
or	O
upon	O
a	O
notification	O
of	O
an	O
incident	O
.	O
</s>
<s>
DKIM	B-Protocol
currently	O
features	O
two	O
canonicalization	B-General_Concept
algorithms	O
,	O
and	O
,	O
neither	O
of	O
which	O
is	O
MIME-aware	O
.	O
</s>
<s>
Mail	B-Protocol
servers	I-Protocol
can	O
legitimately	O
convert	O
to	O
a	O
different	O
character	O
set	O
,	O
and	O
often	O
document	O
this	O
with	O
X-MIME-Autoconverted	O
header	O
fields	O
.	O
</s>
<s>
In	O
addition	O
,	O
servers	O
in	O
certain	O
circumstances	O
have	O
to	O
rewrite	O
the	O
MIME	B-Protocol
structure	O
,	O
thereby	O
altering	O
the	O
preamble	O
,	O
the	O
epilogue	O
,	O
and	O
entity	O
boundaries	O
,	O
any	O
of	O
which	O
breaks	O
DKIM	B-Protocol
signatures	O
.	O
</s>
<s>
Only	O
plain	O
text	O
messages	O
written	O
in	O
us-ascii	B-Protocol
,	O
provided	O
that	O
MIME	B-Protocol
header	O
fields	O
are	O
not	O
signed	O
,	O
enjoy	O
the	O
robustness	O
that	O
end-to-end	O
integrity	O
requires	O
.	O
</s>
<s>
The	O
OpenDKIM	O
Project	O
organized	O
a	O
data	O
collection	O
involving	O
21	O
mail	B-Protocol
servers	I-Protocol
and	O
millions	O
of	O
messages	O
.	O
</s>
<s>
Without	O
specific	O
precaution	O
implemented	O
by	O
the	O
sender	O
,	O
the	O
footer	O
addition	O
operated	O
by	O
most	O
mailing	O
lists	O
and	O
many	O
central	O
antivirus	B-Application
solutions	O
will	O
break	O
the	O
DKIM	B-Protocol
signature	O
.	O
</s>
<s>
It	O
is	O
indicated	O
by	O
l	O
tag	O
in	O
DKIM-Signature	B-Protocol
header	O
.	O
</s>
<s>
Anything	O
added	O
beyond	O
the	O
specified	O
length	O
of	O
the	O
message	O
body	O
is	O
not	O
taken	O
into	O
account	O
while	O
calculating	O
DKIM	B-Protocol
signature	O
.	O
</s>
<s>
This	O
wo	O
n't	O
work	O
for	O
MIME	B-Protocol
messages	O
.	O
</s>
<s>
Another	O
workaround	O
is	O
to	O
whitelist	O
known	O
forwarders	O
;	O
e.g.	O
,	O
by	O
SPF	B-Protocol
.	O
</s>
<s>
However	O
,	O
this	O
solution	O
has	O
its	O
risk	O
with	O
forwarded	O
third	O
party	O
signed	O
messages	O
received	O
at	O
SMTP	B-Protocol
receivers	O
supporting	O
the	O
RFC	O
5617	O
ADSP	O
protocol	O
.	O
</s>
<s>
The	O
Authenticated	B-Protocol
Received	I-Protocol
Chain	I-Protocol
(	O
ARC	O
)	O
is	O
an	O
email	O
authentication	O
system	O
designed	O
to	O
allow	O
an	O
intermediate	O
mail	B-Protocol
server	I-Protocol
like	O
a	O
mailing	O
list	O
or	O
forwarding	O
service	O
to	O
sign	O
an	O
email	O
's	O
original	O
authentication	O
results	O
.	O
</s>
<s>
This	O
allows	O
a	O
receiving	O
service	O
to	O
validate	O
an	O
email	O
when	O
the	O
email	O
's	O
SPF	B-Protocol
and	O
DKIM	B-Protocol
records	O
are	O
rendered	O
invalid	O
by	O
an	O
intermediate	O
server	O
's	O
processing	O
.	O
</s>
<s>
In	O
October	O
2012	O
,	O
Wired	O
reported	O
that	O
mathematician	O
Zach	O
Harris	O
detected	O
and	O
demonstrated	O
an	O
email	O
source	O
spoofing	O
vulnerability	O
with	O
short	O
DKIM	B-Protocol
keys	O
for	O
the	O
google.com	O
corporate	O
domain	O
,	O
as	O
well	O
as	O
several	O
other	O
high-profile	O
domains	O
.	O
</s>
<s>
He	O
states	O
that	O
768-bit	O
keys	O
could	O
be	O
factored	O
with	O
access	O
to	O
very	O
large	O
amounts	O
of	O
computing	O
power	O
,	O
so	O
he	O
suggests	O
that	O
DKIM	B-Protocol
signing	O
should	O
use	O
key	O
lengths	O
greater	O
than	O
1,024	O
.	O
</s>
<s>
DKIM	B-Protocol
resulted	O
in	O
2004	O
from	O
merging	O
two	O
similar	O
efforts	O
,	O
"	O
enhanced	O
DomainKeys	B-Protocol
"	O
from	O
Yahoo	B-Application
and	O
"	O
Identified	O
Internet	O
Mail	O
"	O
from	O
Cisco	O
.	O
</s>
<s>
while	O
DomainKeys	B-Protocol
was	O
designed	O
by	O
Yahoo	B-Application
to	O
verify	O
the	O
DNS	B-Protocol
domain	O
of	O
an	O
e-mail	O
sender	O
and	O
the	O
message	O
integrity	O
.	O
</s>
<s>
Aspects	O
of	O
DomainKeys	B-Protocol
,	O
along	O
with	O
parts	O
of	O
Identified	O
Internet	O
Mail	O
,	O
were	O
combined	O
to	O
create	O
DomainKeys	B-Protocol
Identified	I-Protocol
Mail	I-Protocol
(	O
DKIM	B-Protocol
)	O
.	O
</s>
<s>
Trendsetting	O
providers	O
implementing	O
DKIM	B-Protocol
include	O
Yahoo	B-Application
,	O
Gmail	B-Application
,	O
AOL	O
and	O
FastMail	O
.	O
</s>
<s>
Any	O
mail	O
from	O
these	O
organizations	O
should	O
carry	O
a	O
DKIM	B-Protocol
signature	O
.	O
</s>
<s>
Discussions	O
about	O
DKIM	B-Protocol
signatures	O
passing	O
through	O
indirect	O
mail	O
flows	O
,	O
formally	O
in	O
the	O
DMARC	O
working	O
group	O
,	O
took	O
place	O
right	O
after	O
the	O
first	O
adoptions	O
of	O
the	O
new	O
protocol	O
wreaked	O
havoc	O
on	O
regular	O
mailing	O
list	O
use	O
.	O
</s>
<s>
However	O
,	O
none	O
of	O
the	O
proposed	O
DKIM	B-Protocol
changes	O
passed	O
.	O
</s>
<s>
In	O
2017	O
,	O
another	O
working	O
group	O
was	O
launched	O
,	O
DKIM	B-Protocol
Crypto	O
Update	O
(	O
dcrup	O
)	O
,	O
with	O
the	O
specific	O
restriction	O
to	O
review	O
signing	O
techniques	O
.	O
</s>
<s>
It	O
bans	O
SHA-1	B-Algorithm
and	O
updates	O
key	O
sizes	O
(	O
from	O
512-2048	O
to	O
1024-4096	O
)	O
.	O
</s>
<s>
It	O
adds	O
an	O
elliptic	O
curve	O
algorithm	O
to	O
the	O
existing	O
RSA	B-Architecture
.	O
</s>
<s>
The	O
added	O
key	O
type	O
,	O
k	O
=	O
ed25519	O
is	O
adequately	O
strong	O
while	O
featuring	O
short	O
public	B-Application
keys	I-Application
,	O
more	O
easily	O
publishable	O
in	O
DNS	B-Protocol
.	O
</s>
<s>
The	O
original	O
DomainKeys	B-Protocol
was	O
designed	O
by	O
Mark	O
Delany	O
of	O
Yahoo	B-Application
!	I-Application
</s>
<s>
It	O
is	O
specified	O
in	O
Historic	O
RFC	O
4870	O
,	O
superseded	O
by	O
Standards	O
Track	O
RFC	O
4871	O
,	O
DomainKeys	B-Protocol
Identified	I-Protocol
Mail	I-Protocol
(	O
DKIM	B-Protocol
)	O
Signatures	O
;	O
both	O
published	O
in	O
May	O
2007	O
.	O
</s>
<s>
In	O
September	O
2011	O
,	O
RFC	O
6376	O
merged	O
and	O
updated	O
the	O
latter	O
two	O
documents	O
,	O
while	O
preserving	O
the	O
substance	O
of	O
the	O
DKIM	B-Protocol
protocol	O
.	O
</s>
<s>
Public	B-Application
key	I-Application
compatibility	O
with	O
the	O
earlier	O
DomainKeys	B-Protocol
is	O
also	O
possible	O
.	O
</s>
<s>
Eric	O
Allman	O
of	O
sendmail	B-Application
,	O
</s>
