· i ntroduction to h ost i dentity p rotocol (hip) and its a pplications course at cross border...
TRANSCRIPT
-
INT
RO
DU
CT
ION
TO
HO
STID
EN
TIT
YP
RO
TO
CO
L(H
IP)A
ND
ITS
AP
PL
ICA
TIO
NS
CourseatCrossBorderUniversitySummerSchool
AN
DR
EI
GU
RT
OV
Hel
sink
iIns
titut
efo
rIn
form
atio
nTe
chno
logy
http
://w
ww.
hiit.
fi/˜
gurt
ovA
ugus
t200
9
Out
line
1
•In
trodu
ctio
nto
HIP
arch
itect
ure
•B
ackg
roun
don
netw
ork
secu
rity
•Th
eH
IPar
chite
ctur
e
•B
ase
prot
ocol
•M
ain
exte
nsio
ns
•A
dvan
ced
exte
nsio
ns
•Pe
rfor
man
cem
easu
rem
ents
•Li
ghtw
eigh
tHIP
1c ©
And
reiG
urto
v,20
08.
Figu
res
from
Hos
tIde
ntity
Prot
ocol
(HIP
):To
war
dsth
eSe
cure
Mob
ileIn
tern
et,
And
reiG
urto
v,20
08,
c ©Jo
hnW
iley
&So
nsLi
mite
d.R
epro
duce
dw
ithpe
rmis
sion
.
2
Out
line
(con
t.)
•M
iddl
ebox
trave
rsal
•N
ame
reso
lutio
n
•M
icro
mob
ility
•C
omm
unic
atio
npr
ivac
y
•Po
ssib
leH
IPap
plic
atio
ns
•A
PI
•H
IPw
ithot
herp
roto
cols
•Im
plem
enta
tions
3
Rea
ding
mat
eria
lon
HIP
•M
osko
witz
Ran
dN
ikan
derP
2006
Hos
tIde
ntity
Prot
ocol
Arc
hite
ctur
e.R
FC44
23,I
ETF.
•M
osko
witz
R,N
ikan
derP
,Jok
ela
Pan
dH
ende
rson
T20
08H
ostI
dent
ityPr
otoc
ol.R
FC52
01.
•Jo
kela
P,M
osko
witz
Ran
dN
ikan
derP
2008
Usi
ngth
eEn
caps
ulat
ing
Secu
rity
Payl
oad
(ESP
)Tra
nspo
rtFo
rmat
with
the
Hos
tIde
ntity
Prot
ocol
(HIP
).R
FC52
02.
•La
gani
erJ,
Kop
onen
Tan
dEg
gert
L20
08H
ostI
dent
ityPr
otoc
ol(H
IP)
Reg
istra
tion
Exte
nsio
n.R
FC52
03.
•La
gani
erJa
ndEg
gert
L20
08H
ostI
dent
ityPr
otoc
ol(H
IP)R
ende
zvou
sEx
tens
ion.
RFC
5204
.
4
Rea
ding
mat
eria
lon
HIP
(con
t.)
•N
ikan
derP
and
Laga
nier
J.H
ostI
dent
ityPr
otoc
ol(H
IP)D
omai
nN
ame
Syst
em(D
NS)
Exte
nsio
ns,R
FC52
05.
•N
ikan
derP
,Hen
ders
onT,
Vogt
Can
dA
rkko
J200
8En
d-H
ostM
obili
tyan
dM
ultih
omin
gw
ithth
eH
ostI
dent
ityPr
otoc
ol.R
FC52
06.
•St
iem
erlin
gM
,Qui
ttek
Jand
Egge
rtL
2008
NAT
and
Fire
wal
lTra
vers
alIs
sues
ofH
ostI
dent
ityPr
otoc
ol(H
IP)C
omm
unic
atio
n.R
FC52
07.
•N
ikan
derP
,Lag
anie
rJan
dD
upon
tF20
07b
An
IPv6
prefi
xfo
rove
rlay
rout
able
cryp
togr
aphi
cha
shid
entifi
ers(
OR
CH
ID).
RFC
4843
,IET
F.
•A
.Gur
tov,
Hos
tIde
ntity
Prot
ocol
(HIP
):To
war
dsth
eSe
cure
Mob
ileIn
tern
et,I
SBN
978-
0-47
0-99
790-
1,W
iley
and
Sons
,Jun
e20
08.
(Har
dcov
er,3
32p)
.
5
Rea
ding
mat
eria
lon
cryp
to&
IPse
c
•R
ives
tRL
1992
The
MD
5m
essa
gedi
gest
algo
rithm
.RFC
1321
.
•K
raw
czyk
H,B
ella
reM
and
Can
etti
R19
97H
MA
C:K
eyed
-Has
hing
for
Mes
sage
Aut
hent
icat
ion.
RFC
2104
(Inf
orm
atio
nal).
•K
entS
and
Seo
K20
05Se
curit
yA
rchi
tect
ure
fort
heIn
tern
etPr
otoc
ol.
RFC
4301
(Pro
pose
dSt
anda
rd).
•K
entS
2005
aIP
Aut
hent
icat
ion
Hea
der.
RFC
4302
(Pro
pose
dSt
anda
rd).
•K
entS
2005
bIP
Enca
psul
atin
gSe
curit
yPa
yloa
d(E
SP).
RFC
4303
(Pro
pose
dSt
anda
rd).
•M
anra
lV20
07C
rypt
ogra
phic
Alg
orith
mIm
plem
enta
tion
Req
uire
men
tsfo
rEnc
apsu
latin
gSe
curit
yPa
yloa
d(E
SP)a
ndA
uthe
ntic
atio
nH
eade
r(A
H).
RFC
4835
(Pro
pose
dSt
anda
rd).
6
-
Rea
ding
mat
eria
l(m
isc)
•Sa
ltzer
JH19
93O
nth
ena
min
gan
dbi
ndin
gof
netw
ork
dest
inat
ions
inlo
calc
ompu
tern
etw
orks
.RFC
1498
,IET
F.
•O
rman
H19
98Th
eO
AK
LEY
key
dete
rmin
atio
npr
otoc
ol.R
FC24
12,
IETF
.
•R
osen
berg
J,W
einb
erge
rJ,H
uite
ma
Can
dM
ahy
R20
03ST
UN
:Sim
ple
trave
rsal
ofus
erda
tagr
ampr
otoc
ol(U
DP)
thro
ugh
netw
ork
addr
ess
trans
lato
rs(N
ATs)
.RFC
3489
,IET
F.
•K
ivin
enT
and
Koj
oM
2003
Mor
eM
odul
arEx
pone
ntia
l(M
OD
P)D
iffie-
Hel
lman
grou
psfo
rInt
erne
tKey
Exch
ange
(IK
E).R
FC35
26.
•K
aufm
anC
2005
Inte
rnet
key
exch
ange
(IK
Ev2)
prot
ocol
.RFC
4306
,IE
TF.
7
Ove
rvie
w
8
Iden
tifier
-loca
tor
split
•N
etw
ork
prefi
xeso
fIP
addr
esse
s
–IP
addr
esse
sare
loca
ted
ina
clos
ege
ogra
phic
alar
ea
•Th
ero
leof
host
iden
tifier
(e.g
.DN
S)
•D
ualr
ole
ofIP
addr
esse
s
–id
entif
ying
func
tion
ofIP
addr
esse
s–
loca
ting
func
tion
ofIP
addr
esse
s
9
Loc
atio
nan
did
entit
yof
host
sare
com
bine
din
the
Inte
rnet
Endp
oint
Loca
tor
Serv
ice
Sock
et
IP a
ddre
ss
•th
erol
eofI
Pas
iden
tifier
and
loca
tors
ares
till
mix
ed
•se
para
tese
rvic
eus
esow
nso
cket
•th
een
dpoi
ntid
entit
yis
atta
ched
toth
eIP
ad-
dres
s
10
Iden
tifier
-loca
tor
split
(con
t.)
•H
IPsp
litsh
osti
dent
ifier
and
loca
tor
•A
secu
rity
mec
hani
smis
esse
ntia
lto
prov
eth
eid
entit
y
–a
rand
omly
gene
rate
dst
ring
isno
tasu
itabl
eH
Iin
apu
blic
Inte
rnet
–a
self-
gene
rate
dpu
blic
-priv
ate
key
pair
asth
eho
stid
entit
y
•H
osti
dent
ityse
para
tess
ocke
tand
netw
ork
inte
rfac
es
–se
vera
lloc
ator
scan
beas
soci
ated
with
one
iden
tity
–a
sing
leho
stca
nha
vem
ultip
lyid
entit
ies
–gr
oup
host
iden
titie
s(in
the
rese
arch
phas
e)
11
Sepa
ratin
glo
catio
nan
did
entit
yof
Inte
rnet
host
s
IP a
ddre
ss 2
Endp
oint
IP a
ddre
ss 1
Serv
ice
Hos
t ID
Sock
et
Loca
tors
•th
epo
sitio
ning
ofho
stid
entit
ybe
twee
nso
cket
and
netw
ork
inte
rface
s
•th
eso
cket
sar
ebo
und
toth
eho
stid
entit
yin
-st
ead
ofa
loca
tor
12
-
HIP
inth
eIn
tern
etA
rchi
tect
ure
•IP
prot
ocol
-the
only
rout
able
netw
ork-
laye
rpro
toco
lin
use
•IP
prot
ocol
isab
leto
run
over
aw
ide
rang
eof
link
tech
nolo
gies
–Et
hern
et–
Wire
less
LAN
–To
ken
Rin
g
•M
ultip
letra
nspo
rtpr
otoc
olsc
anru
non
top
ofIP
–TC
Pan
dU
DP
•Th
ela
rge
num
bero
fapp
licat
ion
uses
the
trans
port
prot
ocol
–H
TTP
–SM
TP–
FTP
13
IPas
aw
aist
ofth
eIn
tern
etpr
otoc
olst
ack
Toke
nRin
gW
LAN
Ethe
rnet
TCP
U
DP
HTT
P
S
MTP
FT
P
IP
•IP
-nar
row
estp
arto
fthe
stac
k
•w
aist
ofth
eIn
tern
et
14
HIP
inth
eIn
tern
etA
rchi
tect
ure
(con
t.)
•A
maj
orpr
oble
min
the
orig
inal
Inte
rnet
arch
itect
ure:
–tig
htco
uplin
gbe
twee
nne
twor
king
and
trans
port
laye
rs(e
.g.,
TCP
chec
ksum
calc
ulat
ion)
–im
poss
ible
inde
pend
ente
volu
tion
oftw
ola
yers
•In
trodu
ctio
nof
ane
wne
twor
king
ortra
nspo
rtpr
otoc
olre
quire
scha
nges
toot
herl
ayer
s
•Th
edr
amat
icgr
owth
ofth
eIn
tern
etsc
ale
(intro
duct
ion
ofIP
v6)
•U
nfea
sibl
ede
ploy
men
tofa
new
IPve
rsio
nw
itha
flag
day
•Th
ene
cess
ityof
sim
ulta
neou
srou
ting
ofbo
thIP
prot
ocol
vers
ions
•H
IPar
chite
ctur
eca
nre
stor
eth
eor
igin
alIn
tern
etho
urgl
assm
odel
15
HIP
asa
new
wai
stof
the
Inte
rnet
prot
ocol
stac
k
Toke
nRin
gW
LAN
Ethe
rnet
TCP
U
DP
HTT
P
S
MTP
FT
P
IPv4
IPv6
HIP
•H
IPre
plac
esIP
v4in
itsro
le
•IP
v4an
dIP
v6ru
nun
dern
eath
HIP
•tra
nspo
rtpr
otoc
olso
nto
pof
HIP
16
HIP
inth
eIn
tern
etA
rchi
tect
ure
(con
t.)
•Th
epr
oble
mof
Den
ial-o
f-Se
rvic
e(D
oS)a
ttack
s
–se
rver
crea
tesa
sign
ifica
ntst
ate
durin
ges
tabl
ishm
ento
faTC
Pco
nnec
tion
afte
rrep
lyin
gto
aSY
Npa
cket
–th
ere
isno
assu
ranc
eth
atth
eSY
Nha
sarr
ived
from
the
genu
ine
host
–m
oder
ate
num
bero
fhos
tcan
swam
pth
ese
rver
with
SYN
mes
sage
s
•H
IPpr
even
tscr
eatin
gth
est
ate
befo
reth
ecl
ient
isve
rified
•B
ym
eans
ofcr
ypto
grap
hic
puzz
lesH
IPpr
even
tsth
ecl
ient
gene
ratin
gco
nnec
tion
atte
mpt
sata
nov
erly
fast
rate
–pu
zzle
offe
rsa
clie
ntto
reve
rse
aha
shfu
nctio
nth
atre
quire
ssi
gnifi
cant
com
puta
tiona
lres
ourc
es.V
erify
ing
the
puzz
leat
the
serv
eris
ash
orto
pera
tion
17
The
IPpr
otoc
olst
ack
App
licat
ion
IP a
ddre
ss, p
ort
IP a
ddre
ss, p
ort
IP a
ddre
ss
Tran
spor
t
MAC
add
ress
Link
Net
wor
k
•a
Ber
kley
sock
etbi
nds
toth
eIP
ad-
dres
sand
trans
port
prot
ocol
fam
ily
•th
est
ate
crea
ted
ata
trans
port
laye
rus
esth
eIP
and
trans
port
prot
ocol
port
num
bert
ode
liver
data
toa
corr
ecta
p-pl
icat
ion
•th
ene
twor
kla
yer
uses
the
dest
inat
ion
IPto
dete
rmin
ea
right
trans
mis
sion
link
•th
eN
etw
ork
Inte
rface
Car
d(N
IC)
ad-
dres
sisa
dded
onth
elin
k
18
-
The
prot
ocol
stac
kof
HIP
HIT
, por
t
IP a
ddre
ss
HIT
, por
t
MAC
add
ress
HI
App
licat
ion
Link
Net
wor
k
Tran
spor
t
Hos
t Ide
ntity
•H
IP-
asu
b-la
yer
betw
een
the
netw
ork
and
trans
port
laye
rs
•th
eap
plic
atio
nan
dtra
nspo
rtpr
otoc
olus
eth
eho
stid
entit
yta
g(H
IT)i
nth
eirm
essa
ges
•H
IPsu
b-la
yer
map
sH
ITs
toth
eIP
addr
ess
befo
repa
ssin
ga
pack
etto
the
netw
orki
ngla
yer
•tra
nsm
issi
onof
the
pack
etth
enfo
llow
sth
esa
me
patte
rnas
ina
plai
nIP
stac
k
19
Bri
efhi
stor
yof
HIP
•Th
epr
oble
mof
nam
ing
host
sand
data
inth
eIn
tern
et
–R
FC14
98fr
om19
93re
prin
tsth
epa
pero
nna
min
gfr
om19
82–
reso
urce
nam
e,ad
dres
s,an
dro
ute
–se
rvic
esan
dus
ers,
netw
ork
node
s,ne
twor
kat
tach
men
tpoi
nts,
and
path
s–
thre
ebi
ndin
gsof
ase
rvic
eto
node
,ano
deto
atta
chm
entp
oint
,and
anat
tach
men
tpoi
ntto
aro
ute
•N
ame
Spac
eR
esea
rch
Gro
up(N
SRG
)-in
IRTF
from
1993
to20
03
–ot
hern
ames
pace
stha
nth
e32
-bit
IPv4
addr
esse
s–
Rob
ertM
osko
witz
from
ICSA
,Inc
-the
orig
inal
inve
ntor
ofH
IP
20
Bri
efhi
stor
yof
HIP
(con
t.)
•Th
edr
aftm
osko
witz
-hip
-00
isan
indi
vidu
alsu
bmis
sion
inth
eIE
TF,M
ay19
99
•Fr
om19
99to
2002
,R.M
osko
witz
hash
eld
info
rmal
mee
tings
durin
gth
eIE
TFs
•Se
vera
lrev
isio
nsof
the
HIP
arch
itect
ure
and
prot
ocol
spec
ifica
tions
wer
epu
blis
hed
asin
divi
dual
subm
issi
ons
•In
2002
,Pek
kaN
ikan
derb
ecam
ein
tere
sted
inH
IPan
dto
okov
erth
ele
adin
gof
the
stan
dard
izat
ion
effo
rtfr
omR
.Mos
kow
itz
•N
ewpa
cket
stru
ctur
e,th
est
ate
mac
hine
and
the
prot
ocol
deta
ilsw
ere
deve
lope
dto
geth
erw
ithEr
icss
onN
omad
icLa
b,B
oein
g,an
dH
IIT
•Th
esp
ecifi
catio
nsw
ere
publ
ishe
das
indi
vidu
alsu
bmis
sion
sunt
il20
04
21
Bri
efhi
stor
yof
HIP
(con
t.)
•In
June
2004
anIE
TFw
orki
nggr
oup
onH
IPw
ascr
eate
dan
ddr
aft-i
etf-h
ip-b
ase-
00w
aspu
blis
hed
–th
eH
IPW
Gis
chai
red
byD
avid
War
d(C
isco
)and
Gon
zalo
Cam
arill
o(E
ricss
on)
–th
epu
rpos
ew
as”t
ode
fine
the
min
imal
elem
ents
that
are
need
edfo
rH
IPex
perim
enta
tion
ona
wid
esc
ale”
•Fi
rsto
utco
me
ofth
egr
oup
-ove
rvie
wof
HIP
arch
itect
ure
–th
eH
IPB
Ean
dES
Pen
caps
ulat
ion
spec
ifica
tions
–m
obili
tyan
dm
ultih
omin
gex
tens
ions
–D
NS
and
RVS,
and
regi
stra
tion
exte
nsio
ns
22
Bri
efhi
stor
yof
HIP
(con
t.)
•In
late
2006
,NAT
trave
rsal
,the
appl
icat
ion
supp
orta
ndna
tive
API
-as
WG
item
s
•In
2004
,HIP
RG
was
char
tere
dat
the
Inte
rnet
Res
earc
hTa
skFo
rce
(IRT
F)
•In
2005
,And
reiG
urto
v(H
IIT)
repl
aced
Pekk
aN
ikan
der
•Th
eta
skof
HIP
RG
–ev
alua
tion
ofth
eim
pact
ofw
ider
HIP
depl
oym
ento
nth
eIn
tern
et–
deve
lopm
ento
fexp
erim
enta
lpro
toco
lext
ensi
onst
hata
reno
tyet
read
yfo
rsta
ndar
diza
tion
inth
eIE
TF
23
Intr
oduc
tion
tone
twor
kse
curi
ty2
2 Bas
edon
wor
kco
ntrib
uted
byTo
bias
Hee
r,RW
TH. 24
-
Goa
lsof
cryp
togr
aphi
cpr
otoc
ols
•A
uthe
ntic
atio
n
–de
term
inat
ion
ofth
em
essa
geor
igin
•A
utho
rizat
ion
–on
lyau
thor
ized
netw
ork
entit
iesh
ave
anac
cess
tore
stric
ted
reso
urce
s,da
ta,s
ervi
ces
•A
ccou
ntab
ility
–id
entif
ying
the
user
ofa
serv
ice
unam
bigu
ousl
yin
orde
rto
acco
unt
fort
hats
ervi
ce
25
Goa
lsof
cryp
togr
aphi
cpr
otoc
ols(
cont
.)
•D
ata
inte
grity
–th
eco
nten
tsof
the
mes
sage
isno
talte
red
•C
onfid
entia
lity
–da
tapr
otec
tion
from
unau
thor
ized
acce
ss–
notn
eces
saril
yre
stric
ted
toth
epr
otec
tion
ofda
ta–
met
a-in
form
atio
nab
outt
heco
mm
unic
atio
nen
titie
s
•R
elia
bilit
y
–a
host
that
prov
ides
serv
ices
shou
ldno
tbe
vuln
erab
leto
atta
ck
26
Goa
lsof
cryp
togr
aphi
cpr
otoc
ols(
cont
.)
•N
on-r
epud
iatio
n
–a
netw
ork
entit
yor
user
shou
ldno
tbe
able
tofa
lsel
yde
nyits
parti
cipa
tion
inco
mm
unic
atio
n
•Pr
ivac
y
–th
eid
entit
yof
ane
twor
ken
tity
orus
ersh
ould
notb
ere
veal
edto
unau
thor
ized
parti
es
•C
onsi
sten
cy
–tw
oho
nest
host
sest
ablis
ha
com
mun
icat
ion
cont
ext
host
ssho
uld
have
aco
nsis
tent
view
ofth
epa
rties
invo
lved
inth
eco
mm
unic
atio
npr
oces
s
27
Bas
icsa
ndte
rmin
olog
y
•Pe
ers
two
orm
ore
host
stha
texc
hang
eda
ta
•A
orAl
ice
and
Bor
Bob
two
com
mun
icat
ing
host
s
•M
allo
ryan
atta
ckin
gpa
rty
•Se
curi
tyco
ntex
tth
ese
tofi
nfor
mat
ion
that
isre
quire
dto
appl
yse
curit
ym
essa
ges
•C
iphe
rsal
gorit
hmst
hate
ncry
ptan
dde
cryp
tdat
a
•Pl
aint
ext
the
unpr
otec
ted
text
•C
iphe
rtex
tth
een
cryp
ted
text
28
Att
ack
type
s
•Ea
vesd
ropp
ing
–th
epr
oces
sofo
verh
earin
ga
priv
ate
com
mun
icat
ion
–an
atta
cker
can
mes
sage
stha
tagr
oup
ofpe
erse
xcha
nge
–si
mpl
e-o
nun
prot
ecte
dw
irele
ssco
mm
unic
atio
nch
anne
ls–
diffi
cult
-on
wire
dco
mm
unic
atio
nch
anne
ls–
com
prom
isin
gth
eco
nfide
ntia
lity
ofda
ta–
data
encr
yptio
n-t
hem
ostc
omm
onw
ayto
deal
with
atta
cks
•Im
pers
onat
ion
–an
atta
cker
aim
satm
alic
ious
lypr
eten
ding
tore
pres
enta
noth
erho
st–
unde
rmin
ing
ara
nge
ofse
curit
ygo
als:
auth
entic
atio
n,au
thor
izat
ion,
non-
repu
diat
ion,
acco
unta
bilit
y,da
tain
tegr
ity,c
onfid
entia
lity
29
Att
ack
type
s(co
nt.)
•M
an-I
n-Th
e-M
iddl
eat
tack
s
–a
spec
ialf
orm
ofim
pers
onat
ion
atta
ck–
anat
tack
eris
onth
ene
twor
kpa
thbe
twee
ntw
oho
sts
–th
eat
tack
erca
nde
lay,
mod
ifyor
drop
pack
ets
–a
one
way
toco
mpr
omis
epu
blic
-key
cryp
togr
aphy
Alic
eB
ob
Mal
lory
Secu
rity
cont
ext 1
Secu
rity
cont
ext 2
Bob
Alic
e
30
-
Att
ack
type
s(co
nt.)
•D
elay
and
repl
ayat
tack
s
–th
eat
tack
erus
esva
lidly
encr
ypte
dor
inte
grity
prot
ecte
dda
tain
afr
audu
lent
way
tosu
bver
taco
mm
unic
atio
npr
otoc
ol–
the
goal
ofa
repl
ayat
tack
trick
ing
the
rece
iver
ofth
ere
play
sint
otri
gger
ing
dupl
icat
etra
nsac
tions
•D
enia
l-of-
Serv
ice
atta
cks
–an
atta
ckta
rget
shos
tsth
atpr
ovid
eso
me
sort
ofse
rvic
e–
the
goal
ofD
oSco
nsum
ptio
nof
the
vict
imre
sour
cest
oan
exte
ntth
atit
isno
tabl
eto
prov
ide
any
serv
ice
tole
gitim
ate
host
–ai
min
gth
ese
curit
ygo
alof
relia
bilit
y
31
Att
ack
type
s(co
nt.)
•Ex
haus
tive
key
spac
ese
arch
-bru
tefo
rce
atta
ck–
atta
ckst
hatt
ryto
brea
kth
eci
pher
sem
ploy
edby
the
prot
ocol
–fin
ding
the
secr
etke
y-t
hena
tura
lway
ofbr
eaki
ngth
epr
otec
tion
–br
eaki
nga
key-
base
dal
gorit
hm-t
ryin
gdi
ffere
ntke
ys–
usin
gla
rge
key-
spac
es-a
nen
orm
ousc
ompu
tatio
nalc
ostf
oran
exha
ustiv
eke
yse
arch
•C
rypt
oana
lysi
s–
deci
pher
ing
am
essa
gew
ithou
tkno
wle
dge
ofth
een
cryp
tion
key
–m
athe
mat
ical
findi
ngsa
ndsh
ortc
uts-
brea
king
orde
crea
seof
the
secu
rity
ofa
ciph
er–
the
side
chan
nela
ttack
-exp
loit
ofw
eakn
esse
sin
the
phys
ical
impl
emen
tatio
nof
aci
pher
32
Def
ense
mec
hani
sms.
Sym
met
ric
cryp
togr
aphy
•Th
esa
me
key
fore
ncry
ptio
nan
dde
cryp
tion
–re
quire
men
tto
keep
the
key
secr
et–
allc
omm
unic
atio
npe
ersm
ustb
ein
poss
essi
onof
the
sam
ese
cret
key
–w
idel
yus
edcr
ypto
grap
hyle
ssC
PU-d
eman
ding
than
publ
ic-k
eycr
ypto
grap
hy
•B
lock
ciph
ers
–en
cryp
tion
ofpl
aint
extb
lock
sofa
fixed
leng
thin
toid
entic
alsi
zed
bloc
ksof
ciph
erte
xt
•St
ream
ciph
ers
–en
cryp
tion
ofa
plai
ntex
tstre
amsy
mbo
lby
sym
bol
33
Def
ense
mec
hani
sms.
Sym
met
ric
cryp
togr
aphy
(con
t.)
•Th
eA
dvan
ced
Encr
yptio
nSt
anda
rd:A
ES
–th
eof
ficia
lsuc
cess
orof
DES
–Fe
dera
lInf
orm
atio
nPr
oces
sing
Stan
dard
appr
oved
encr
yptio
nal
gorit
hm(S
tand
ard
2001
)–
the
oper
atio
nsar
eap
plie
din
seve
ralr
ound
s–
oper
atin
gon
afix
edbl
ock
leng
th;a
llow
ing
128-
,192
-,25
6-bi
tkey
s–
the
num
bero
frou
nds(
10,1
2,14
)isd
eter
min
edby
the
key
leng
th
•K
eyex
chan
gefo
rsym
met
riccr
ypto
grap
hy
–ut
ilizi
ngpu
blic
-key
cryp
togr
aphy
tose
cure
lyag
ree
onsh
ared
secr
ets
–th
eD
iffie-
Hel
lman
key
exch
ange
can
beus
ed
34
Def
ense
mec
hani
sms.
Publ
ic-k
eycr
ypto
grap
hy
•En
cryp
tion
and
decr
yptio
nke
ysar
ere
late
din
ano
n-tri
vial
way
–th
een
cryp
tion
key
publ
icly
acce
ssib
leas
apu
blic
key
–th
ede
cryp
tion
key
kept
secr
etas
apr
ivat
eke
y–
encr
ypte
dda
taca
nbe
sent
toan
yho
stw
ithou
texc
hang
ing
shar
edse
cret
•Ea
sy,h
ard,
feas
ible
and
infe
asib
le
–tra
pdoo
rfun
ctio
ns–
easy
calc
ulat
ion
–ha
rdto
reve
rse
35
Def
ense
mec
hani
sms.
Publ
ic-k
eycr
ypto
grap
hy(c
ont.)
•Pr
oper
tieso
ftra
pdoo
rfun
ctio
ns
–m
ustb
eea
syto
com
pute
-the
encr
yptio
nis
com
puta
tiona
llyfe
asib
le–
mus
tbe
hard
tore
vers
eth
ew
ithou
tthe
poss
essi
onof
addi
tiona
lin
form
atio
n–
itm
ustb
eco
mpu
tatio
nally
hard
fora
nat
tack
erto
calc
ulat
eth
ese
cret
•D
iffie-
Hel
lman
key
exch
ange
–th
efir
stPK
cryp
tosy
stem
was
publ
ishe
dby
W.D
iffie
and
M.H
ellm
an–
secu
reex
chan
geof
sym
met
ricke
ysov
erin
secu
rech
anne
l–
the
disc
rete
loga
rithm
prob
lem 36
-
Def
ense
mec
hani
sms.
Publ
ic-k
eycr
ypto
grap
hy(c
ont.)
•Th
eke
yex
chan
ge
–tw
oco
mm
unic
atio
npa
rties
agre
eon
pan
dg
–on
lyfe
wco
mbi
natio
nof
pan
dg
are
inus
e–
the
DH
grou
psar
epu
blic
lyde
fined
inpr
otoc
olsp
ecifi
catio
n–
the
DH
cons
ists
offo
urst
eps
∗th
eIn
itiat
orse
lect
sanu
mbe
rx∈{1,
...,
p−
2}an
dca
lcul
ates
gxm
odp;
gx
isse
ntto
the
Res
pond
er,x
iske
ptse
cret
∗th
eR
espo
nder
sele
ctsa
num
bery
∈{1,
...,
p−
2}an
dca
lcul
ates
gym
odp
and
k=
gx
y
mod
p=
gxym
odp;
kis
the
shar
edse
cret
∗th
eR
espo
nder
send
sbac
kg
yas
itspu
blic
key
∗th
eIn
itiat
orca
lcul
ates
k=
gy
x
mod
p=
gy
x
mod
p=
gx
y
mod
p
37
Def
ense
mec
hani
sms.
Publ
ic-k
eycr
ypto
grap
hy(c
ont.)
•Th
eR
SAal
gorit
hm–
PKal
gorit
hmpu
blis
hed
byR
ives
t,Sh
amir,
and
Ade
lman
–su
itabl
efo
renc
rypt
ion
and
mes
sage
auth
entic
atio
n–
fact
oriz
ing
prod
ucto
ftw
ola
rge
prim
enu
mbe
rsin
toth
etw
oor
igin
alpr
ime
fact
orsi
scom
puta
tiona
llyha
rd
•R
SAke
yge
nera
tion
–fin
dtw
ola
rge
prim
enu
mbe
rsp
and
qof
sim
ilars
ize
–ca
lcul
ate
n=
pqan
dϕ(n
)=
(p−
1)(q
−1)
;ϕis
Eule
r’sϕ
func
tion
–ch
oose
ara
ndom
num
bere
,1<
e<
ϕ(n
)w
ithgsd
(e,ϕ
(n))
=1
–ca
lcul
ate
d=
e−1
mod
ϕ(n
)by
usin
gth
eex
tend
edEu
clid
ean
algo
rithm
38
Def
ense
mec
hani
sms.
Publ
ic-k
eycr
ypto
grap
hy(c
ont.)
•R
SAen
cryp
tion
–lo
okin
gup
the
publ
icke
yof
ape
erk
pub=
(n,e
)
–di
vidi
nga
mes
sage
into
piec
esan
dtra
nsfo
rmin
gea
chin
toa
num
ber
m∈
Zn
–ca
lcul
atin
gth
eci
pher
text
c=
mem
od
n
•R
SAde
cryp
tion
–re
peat
sthe
encr
yptio
npr
oces
swith
dus
edin
stea
dof
e
–cd
mod
n=
(mem
od
n)d
mod
n=
m
39
Def
ense
mec
hani
sms.
Publ
ic-k
eycr
ypto
grap
hy(c
ont.)
•R
SAsi
gnat
ures
–si
gnat
ure
proc
essi
ssim
ilart
oth
een
cryp
tion
proc
ess
–th
esi
gnat
ure
proc
essi
sper
form
edw
ithth
epr
ivat
eke
yof
the
send
er–
the
sign
atur
eve
rifica
tion
ispe
rfor
med
with
the
send
er’s
publ
icke
y–
CPU
-inte
nsiv
eex
pone
ntia
tion
-tra
nsm
ittin
gsh
ortm
essa
ges
•D
SAsi
gnat
ures
–sp
ecifi
edto
beus
edw
ithth
eD
igita
lSig
natu
reSt
anda
rd(D
SS)
–a
varie
tyof
the
ElG
amal
sign
atur
esc
hem
e–
the
disc
rete
loga
rithm
prob
lem
–th
epr
oper
ties,
appl
icat
ion,
and
perf
orm
ance
are
sim
ilart
oR
SA
40
Def
ense
mec
hani
sms.
One
-way
cryp
togr
aphi
cha
shfu
nctio
n
•A
third
clas
sofc
rypt
ogra
phic
mec
hani
sm
–se
cond
prei
mag
ere
sist
ant-
fora
give
nx
itis
com
puta
tiona
llyha
rdto
find
x′�=
xw
ithH
(x′ )
=H
(x)
–co
llisi
onre
sist
ant-
itis
com
puta
tiona
llyha
rdto
find
any
two
valu
esx
and
x′w
ithx�=
x′an
dH
(x)
=H
(x′ )
–pr
eim
age
resi
stan
t-fo
ragi
ven
z=
H(x
)it
isco
mpu
tatio
nally
hard
tofin
da
prei
mag
ex′w
ithH
(x′ )
=z
•Tw
ow
ayso
fdes
igni
ngcr
ypto
grap
hic
hash
func
tions
–th
esa
me
alge
brai
cpr
oble
msa
sPK
cryp
tosy
stem
s–
bloc
k-ci
pher
-bas
edha
shfu
nctio
ns
41
Def
ense
mec
hani
sms.
One
-way
cryp
togr
aphi
cha
shfu
nctio
n(c
ont.)
•M
essa
gedi
gest
s
–ha
shfu
nctio
nsar
eof
ten
used
form
essa
geau
then
ticat
ion
–pr
oduc
tion
ofa
shor
tmes
sage
dige
stof
fixed
leng
th
•H
ashe
dm
essa
geau
then
ticat
ion
code
s:H
MA
C
–si
gnin
gm
essa
ges-
allp
eers
mus
tbe
inpo
sses
sion
ofa
shar
edse
cret
–M
AC
(m)
=H
(k‖m
)
–H
MA
Ck(m
)=
H((
k⊕
opad)‖
H((
k⊕
ipad)‖
m))
–ge
nera
tion
and
verifi
catio
nis
very
chea
pin
term
sofC
PUcy
cles
42
-
Def
ense
mec
hani
sms.
One
-way
cryp
togr
aphi
cha
shfu
nctio
n(c
ont.)
•H
ash
chai
ns–
in19
81,L
eslie
Lam
port
-the
use
ofch
ains
ofha
shes
–ba
sic
idea
-the
itera
ted
appl
icat
ion
ofa
cryp
togr
aphi
cha
shfu
nctio
non
som
era
ndom
orps
eudo
rand
omse
edva
lue
r–
h0
=r;
hn
=H
(hn−
1);=
H(H
(H(...H
(r)...))
)n
times
–(h
i,h
i−1,h
i−2,.
..,h
1,r)
-the
hash
chai
n;h
i-t
heha
shch
ain
anch
or–
itis
easy
tove
rify
that
hi
belo
ngst
oth
esa
me
hash
chai
nas
hi−
1
–it
isco
mpu
tatio
nally
hard
tofin
dh
i−1
ifon
lyh
iis
give
n–
give
nh
i+1,i
tish
ard
tofin
dan
h′w
ithH
(h′ )
=H
(hi)
=H
i+1
–gi
ven
hi,
itis
poss
ible
tove
rify
that
hi−
nis
part
ofth
esa
me
hash
chai
nif
0<
n≤
i
43
Def
ense
mec
hani
sms.
One
-tim
esi
gnat
ures
•La
mpo
rt-o
ne-ti
me
sign
atur
esba
sed
onha
shfu
nctio
ns
–H
(r)
and
H(r
′ )ar
epu
blis
hed
asa
publ
icke
y–
aon
e-bi
tmes
sage
can
besi
gned
bypu
blis
hing
ras
sign
atur
es
ifth
ebi
tis1
and
r′ot
herw
ise
–co
mpa
ring
the
H(s
)w
ithH
(r)
and
H(r
′ )-v
erifi
catio
n–
the
sign
atur
eca
nbe
used
tosi
gnl−
bit
mes
sage
sby
usin
g2l
hash
es
•A
nim
prov
emen
toft
hesc
hem
e-M
erkl
e19
88
–re
duct
ion
ofth
enu
mbe
rofh
ashe
sto
l+
[log
2(l
)]+
1an
dth
eav
erag
enu
mbe
rofh
ashe
sper
sign
atur
eto
(l+
[log
2(l
)]+
1)/2
•W
inte
rnitz
-asc
hem
ere
duce
sthe
sign
atur
esi
ze
•Zh
ang
-tw
opr
otoc
olsf
orsi
gnin
gro
utin
gm
essa
ges
44
Def
ense
mec
hani
sms.
Sequ
ence
num
bers
•A
sim
ple
mea
sure
toav
oid
repl
ayin
g,re
orde
ring
ordr
oppi
ngpa
cket
s
–a
mon
oton
ical
lyin
crea
sing
num
beri
sass
igne
dto
ever
ym
essa
ge–
the
rece
iver
can
dete
rmin
eif
am
essa
geha
salre
ady
been
proc
esse
d–
mes
sage
swith
outt
hene
xtex
pect
ednu
mbe
r-a
dupl
icat
em
essa
geor
apa
rtof
are
play
atta
ck
•Th
ede
cisi
on-a
mes
sage
isa
part
ofan
atta
ck
–a
stric
tmat
chin
g-a
llpr
eced
ing
pack
etsm
usth
ave
been
rece
ived
befo
rea
pack
etw
itha
high
erse
quen
cenu
mbe
risa
ccep
ted
orpr
oces
sed
–a
rela
xed
mat
chin
g-h
osts
can
use
aw
indo
wof
legi
timat
ese
quen
cenu
mbe
rs
45
Def
ense
mec
hani
sms.
Cry
ptog
raph
icno
nces
•A
nonc
e-a
num
bero
rast
ring
that
isus
edon
lyon
ce
–ve
rifyi
ngth
ere
acha
bilit
yof
aho
st–
defe
nse
agai
nstr
epla
yat
tack
s–
requ
est-r
espo
nse
mec
hani
sms
–pr
oofo
fthe
secr
etpo
sses
sion
•Th
eno
nce
ison
lyus
edon
ce
–pr
even
tion
ofre
play
atta
cks-
nonc
eca
nnot
bere
used
byan
atta
cker
•N
once
crea
tion
–ca
nbe
deriv
edfr
omra
ndom
orps
eudo
-ran
dom
num
bers
–ca
nin
clud
ein
form
atio
nth
atth
eho
stw
ants
toem
bed
46
Def
ense
mec
hani
sms.
Clie
ntpu
zzle
s
•A
host
isal
low
edto
artifi
cial
lyge
nera
tepe
er’s
CPU
load
–a
corr
ects
olut
ion
ofth
epu
zzle
isre
quire
d–
mec
hani
smis
mad
ele
ssat
tract
ive
fora
ttack
ers
•Th
epu
zzle
isea
syto
verif
yw
hile
diffi
cult
toso
lve
–pu
zzle
sare
base
don
cryp
togr
aphi
cha
shfu
nctio
ns–
aha
shfu
nctio
nis
appl
ied
toth
eco
ncat
enat
ion
ofa
serv
er-g
ener
ated
nonc
ean
dva
ryin
gcl
ient
-cho
sen
valu
e–
the
peer
isre
quire
dto
find
jfo
rwhi
chth
ere
sult
H(i|j
)ha
skbi
tsw
ithth
eva
lue
0as
low
est-o
rder
bits
–k
defin
espu
zzle
diffi
culty
47
Secu
rity
prot
ocol
s
•So
me
oral
lsec
urity
goal
scan
beac
hiev
ed
–se
curit
ypr
otoc
olse
mpl
oycr
ypto
grap
hic
algo
rithm
s–
spec
ifyin
gho
wco
mm
unic
atio
npa
rties
mus
tact
•Se
curit
yco
ntex
t
–pa
ram
eter
sfor
the
empl
oyed
secu
rity
mec
hani
sms:
the
choi
ceof
mec
hani
sm,k
eys,
the
stat
eof
com
mun
icat
ion
peer
s
•A
nes
tabl
ishm
entp
hase
–al
lcom
mun
icat
ing
peer
sagr
eeon
ase
tofa
lgor
ithm
sand
the
keys
–th
elif
ecy
cle
ends
-the
clos
ing
ofth
ese
curit
yas
soci
atio
nan
dth
ede
letio
nof
the
secu
rity
cont
ext 48
-
Secu
rity
prot
ocol
s.M
OD
PD
iffie-
Hel
lman
grou
ps
•Su
cces
sful
gene
ratio
nof
the
secr
et
–th
esa
me
mod
ular
expo
nent
ialg
roup
smus
tbe
used
–th
enu
mbe
rofk
now
ngr
oups
issp
ecifi
ed(R
FC24
12,R
FC35
26)
–th
epr
ime
num
bers
pof
diffe
rent
grou
psva
ryfr
om76
8to
8192
bits
•A
384-
bitg
roup
isde
fined
byM
osko
witz
–de
vice
swith
few
CPU
reso
urce
sisa
llow
edto
use
HIP
–th
egr
oup
isin
secu
re
•Th
egr
oups
have
been
sele
cted
base
don
ace
rtain
patte
rn
–th
ehi
ghor
dera
ndlo
wor
der6
4bi
tsar
efo
rced
to1
–th
em
iddl
ese
ctio
nof
grou
p-t
hebi
nary
expa
nsio
nof
Pi(
π)
49
Secu
rity
prot
ocol
s.K
eyin
gm
ater
ial
•Th
eD
Hke
yex
chan
gege
nera
tesk
eyin
gm
ater
ial
–th
ele
ngth
ofth
eke
ying
mat
eria
lisg
reat
erth
anth
ele
ngth
ofth
esy
mm
etric
keys
–si
ngle
bits
mus
tbe
sele
cted
asa
sym
met
ricke
y
•IK
Ean
dH
IP
–a
hash
func
tion
isus
edto
sele
ctbi
ts–
seve
ralk
eysc
anbe
deriv
ed
•B
indi
ngbe
twee
nth
ese
ssio
nke
ysan
dad
ditio
nalp
aram
eter
soft
heke
yex
chan
ge
–pa
ram
eter
scan
bein
clud
edin
toth
eke
yde
rivat
ion
–co
ncat
enat
ion
ofth
eD
Hsh
ared
secr
etw
ithth
ead
ditio
nalp
aram
eter
s
50
Secu
rity
prot
ocol
s.Tr
ansf
orm
s
•A
larg
eva
riety
ofcr
ypto
grap
hic
algo
rithm
s
–th
ecr
ypto
grap
hic
algo
rithm
sare
inte
rcha
ngea
ble
–di
ffere
ntke
yle
ngth
scan
beus
edfo
rsym
met
rican
das
ymm
etric
ciph
ers
•K
eepi
nga
secu
rity
prot
ocol
suita
ble
form
any
appl
icat
ion
scen
ario
s
–th
ech
oice
ofal
gorit
hmsa
ndke
y-si
zess
houl
dbe
nego
tiate
d
•N
egot
iatio
nsdu
ring
the
hand
shak
e
–tra
nsfo
rmpa
ram
eter
cont
ains
trans
form
suite
s–
trans
form
suite
-the
com
bina
tion
ofse
vera
lalg
orith
msa
ndke
y-si
zes
–su
itesa
reid
entifi
edby
anin
dex
51
Secu
rity
prot
ocol
s.Tr
ansf
orm
s(co
nt.)
•Th
eor
dero
fthe
trans
form
suite
s
–th
epr
efer
ence
soft
heho
stin
decr
easi
ngor
der
–th
em
ostp
refe
rred
trans
form
suite
islis
ted
first
–a
peer
can
choo
sean
yof
the
cont
aine
dsu
ites
•H
osts
use
the
algo
rithm
sand
key-
leng
ths,
indi
cate
dby
the
chos
entra
nsfo
rmsu
ite
52
Secu
rity
prot
ocol
s.IP
secu
rity
arch
itect
ure:
IPse
c
•Th
eIP
itsel
fdoe
snot
offe
rsuf
ficie
ntse
curit
y
–no
defe
nses
agai
nste
aves
drop
pers
orat
tack
ers
•IP
sec
secu
rity
arch
itect
ure
-RFC
2401
,199
8
–au
then
ticat
ing
the
sour
ce–
the
inte
grity
ofIP
pack
ets
–ne
whe
ader
-unp
rote
cted
IPtra
ffic
isdi
stin
guis
hed
from
IPse
ctra
ffic
53
Secu
rity
prot
ocol
s.IP
secu
rity
arch
itect
ure:
IPse
c(c
ont.)
•Se
curit
yA
ssoc
iatio
ns
–en
dpoi
ntsm
usta
gree
ona
seto
falg
orith
ms
–ho
stsc
anem
ploy
ara
nge
ofpr
otoc
olst
one
gotia
te–
the
shar
edse
curit
yco
ntex
t-SA
–IP
sec
SA-s
impl
exco
nnec
tions
that
affo
rdse
curit
yse
rvic
esto
the
traffi
cca
rrie
dby
them
(RFC
4301
)–
two
SAs-
anin
com
ing
and
anou
tgoi
ng-a
rene
cess
ary
topr
otec
tadu
plex
chan
nel
54
-
Secu
rity
prot
ocol
s.IP
secu
rity
arch
itect
ure:
IPse
c(c
ont.)
•Se
curit
yA
ssoc
iatio
nD
atab
ase
(SA
D)
–in
form
atio
nab
oute
stab
lishe
dSA
–tw
oSA
sfor
ever
ydu
plex
com
mun
icat
ion
–in
form
atio
nab
outt
heIP
sofa
dist
anth
ost,
the
IPse
cpr
otoc
ol–
the
cont
exts
need
edto
proc
essi
ncom
ing
and
outg
oing
IPpa
cket
s
•Se
curit
yPo
licy
Dat
abas
e(S
PD)
–in
form
atio
nab
outt
hese
rvic
esth
atar
eof
fere
dby
IPda
tagr
ams
–ki
ndso
fsec
urity
mec
hani
smsa
rede
fined
–tra
ffic
that
stay
sunp
rote
cted
and
traffi
cth
atm
ayno
tlea
veth
eho
stis
defin
ed
55
Secu
rity
prot
ocol
s.IP
secu
rity
arch
itect
ure:
IPse
c(c
ont.)
•Se
curit
yPa
ram
eter
Inde
x(S
PI)
–de
mul
tiple
xing
info
rmat
ion
inth
eIP
sec
head
er–
iden
tifyi
ngth
erig
htse
curit
yco
ntex
t
56
Secu
rity
prot
ocol
s.IP
sec
mod
es
•Tr
ansp
ortm
ode
–th
em
ode
isus
edw
hen
traffi
cbe
twee
nho
stsh
asto
bepr
otec
ted
–th
ead
ditio
nalh
eade
rbet
wee
nth
eIP
and
trans
port
laye
rhea
der
–th
ehe
ader
stru
ctur
eco
ntai
nsal
linf
orm
atio
nre
quire
dto
verif
yor
decr
yptt
hepa
cket
IP p
aylo
adIP
hea
der
IP h
eade
rIP
sec
head
erIP
pay
load
57
Secu
rity
prot
ocol
s.IP
sec
mod
es(c
ont.)
•Tu
nnel
mod
e
–th
em
ode
isus
edto
secu
rely
conn
ectn
etw
orks
–tw
oin
term
edia
tega
tew
ayse
stab
lish
anIP
sec
asso
ciat
ion
–th
etra
ffic
isse
cure
lytu
nnel
edbe
twee
nth
ega
tew
ays
–an
addi
tiona
lIP
head
erbe
fore
the
IPse
che
ader
IP p
aylo
adIP
hea
der
IP h
eade
rO
uter
IP h
eade
rIn
ner
IP p
aylo
adIP
sec
head
er
58
Secu
rity
prot
ocol
s.IP
sec
mod
es(c
ont.)
•B
ound
End-
to-E
ndTu
nnel
mod
e
–se
man
ticss
imila
rto
the
tunn
elm
ode
with
atra
nspo
rtm
ode
like
pack
etfo
rmat
–IP
pack
etsa
retu
nnel
edfr
omon
ega
tew
ayto
anot
her
–th
eou
tgoi
ngga
tew
aym
odifi
esth
eex
istin
gIP
head
er–
impl
emen
tatio
nof
HIP
payl
oad
encr
yptio
nin
ave
ryef
ficie
ntw
ay
IP p
aylo
adIP
hea
der
IP h
eade
rIP
sec
head
er
Add
ress
tran
slat
ion
IP p
aylo
ad
59
Secu
rity
prot
ocol
s.IP
sec
secu
rity
prot
ocol
s
•Th
eA
uthe
ntic
atio
nH
eade
r(A
H)p
roto
col
–en
surin
gof
the
auth
entic
ityof
anIP
pack
etan
dits
sour
ce–
IPpa
cket
smus
tbe
inte
grity
prot
ecte
dbu
tnot
nece
ssar
ilyen
cryp
ted
–ch
ecks
ums,
base
don
cryp
togr
aphi
cha
shes
,are
empl
oyed
–th
eIP
pack
etpa
yloa
dan
dce
rtain
field
sofI
Phe
ader
prot
ectio
n–
unpr
otec
ted
field
s-Ti
me
ToLi
ve,H
eade
rChe
cksu
m
•Th
eEn
caps
ulat
ing
Secu
rity
Payl
oad
(ESP
)pro
toco
l
–pr
otec
tion
ofIP
payl
oad
agai
nste
aves
drop
pers
–sy
mm
etric
cryp
togr
aphy
isem
ploy
ed–
the
send
erau
then
ticat
ion
–pr
otec
tion
ofa
sour
cead
dres
s 60
-
Secu
rity
prot
ocol
s.IP
sec
secu
rity
prot
ocol
s(co
nt.)
•A
sequ
ence
num
berfi
eld
inth
eIP
sec
head
er
–pr
otec
tion
from
repl
ayat
tack
s–
aw
indo
wof
sequ
ence
num
bers
-rep
lay
prot
ectio
nw
indo
w–
the
high
ests
eque
nce
num
berr
ecei
ved
bya
host
-the
”rig
ht”
edge
ofth
ew
indo
w–
the
rang
eof
valid
num
bers
-the
size
ofth
ew
indo
wan
dhi
ghes
tnu
mbe
r–
the
sequ
ence
num
beri
slow
erth
an”l
eft”
edge
-pac
keti
sdro
pped
61
Secu
rity
prot
ocol
s.In
tern
etK
eyE
xcha
nge:
IKE
•Th
eIK
Epr
otoc
olsp
ecifi
catio
ns
–R
FC24
07,R
FC24
08,R
FC24
09
•IK
Ev2
–si
mpl
ifica
tion
ofth
ese
curit
ym
echa
nism
sin
IKE
–so
me
secu
rity
loop
hole
sand
wea
knes
sesa
recl
osed
•Tw
oph
ases
ofth
eke
yne
gotia
tions
inIK
Ev2
–th
efir
stph
ase
-aho
stve
rifies
the
iden
tity
ofits
peer
,gen
erat
esth
eke
ying
mat
eria
l,es
tabl
ishe
sase
cure
dch
anne
l:th
eIK
ESA
–th
ese
cond
phas
e-n
ewSA
s(ch
ildSA
s)ar
ene
gotia
ted
over
the
chan
nel
62
Secu
reD
NS
•Th
epr
esen
tDN
S
–in
secu
re,s
usce
ptib
leto
atta
cks
–ca
che
pois
onin
g-a
mos
tcom
mon
atta
ck
•Se
cure
DN
Sex
tens
ions
(DN
SSEC
)
–en
surin
gth
atth
epu
blic
key
com
esfr
oma
trust
edD
NS
–im
porta
ntfo
rHIP
depl
oym
ent
•C
urre
ntD
NSS
ECsp
ecifi
catio
ns
–R
FC40
33-o
verv
iew
and
requ
irem
ents
ofth
eD
NSS
ECar
chite
ctur
e–
RFC
4034
-new
Res
ourc
eR
ecor
ds(R
R)
–R
FC40
35-t
heD
NS
prot
ocol
exte
nsio
ns
63
Secu
reD
NS
(con
t.)
•Th
eD
NSS
ECar
chite
ctur
e
–st
orin
ga
DN
Sse
rver
’spu
blic
key
ina
DN
SKEY
RR
–th
eD
NSS
ECsu
ppor
tisi
ndic
ated
ina
quer
y-t
heD
NS
sign
srep
lies
with
priv
ate
key
–th
eD
eleg
atio
nSi
gner
(DS)
para
met
er-t
hedi
gest
ofth
ech
ildD
NS
serv
erpu
blic
key
–ve
rifyi
ngth
edi
gest
-atru
stlin
kfr
omth
epa
rent
DN
Sto
the
child
DN
S–
auth
entic
ityof
the
repl
y-a
chai
nof
trust
links
upto
the
DN
Sse
rver
forw
hich
whi
chth
ecl
ient
hasa
trust
edpu
blic
key
stor
ed
64
DN
SSE
CE
xam
ple
[gurtov@hippy˜]$dig+dnssecwww.seany
;<<>>DiG9.3.2<<>>+dnssecwww.seany
;;globaloptions:
printcmd
;;Gotanswer:
;;->>HEADER<<-opcode:QUERY,status:NOERROR,id:8237
;;flags:qrrdra;QUERY:1,ANSWER:6,AUTHORITY:3,
ADDITIONAL:2
;;OPTPSEUDOSECTION:
;EDNS:version:0,flags:do;udp:4096
;;QUESTIONSECTION:
;www.se.
IN
ANY
;;ANSWERSECTION:
www.se.
3260
IN
A212.247.204.135
www.se.
6860
IN
RRSIG
NSEC5
27200
200608211824062006081607055854245se.
Oex8Tj20u9Q9f7l5Idepb53acoFLbNvwX6xcNBpUezEnxKAze+0vrQvM
7i0X5QYq/EQ8EtPEhLH/SXjJS4+mmYXV3mNVdT96rYSeKX7oh+N82+VY
vCaKPxZLZy22JYhEPxs5CZxiSGEgPq3ncYw6+mhzKjxm3AA5XtpUhZ3BtW4=
www.se.
6860
IN
NSEC
www-3.se.NSRRSIGNSEC
www.se.
3260
IN
NS
ns.nic.se.
www.se.
3260
IN
NS
ns2.nic.se.
65
www.se.
3260
IN
NS
ns3.nic.se.
;;AUTHORITYSECTION:
www.se.
3260
IN
NS
ns.nic.se.
www.se.
3260
IN
NS
ns2.nic.se.
www.se.
3260
IN
NS
ns3.nic.se.
;;ADDITIONALSECTION:
ns3.nic.se.
17256
IN
A212.247.3.80
;;Querytime:406msec
;;SERVER:193.210.18.18#53(193.210.18.18)
;;WHEN:ThuAug1712:41:522006
;;MSGSIZE
rcvd:358
[gurtov@hippy˜]$
66
-
Arc
hite
ctur
alov
ervi
ew
67
Inte
rnet
nam
espa
ces
•N
ames
pace
allo
wsu
niqu
ely
iden
tify
anen
tity
•Tw
ona
mes
pace
sare
glob
ally
depl
oyed
inth
eIn
tern
et:
•IP
addr
esse
s
–al
sose
rve
asho
stlo
cato
rs
•D
NS
nam
es
–hu
man
-frie
ndly
host
nam
es–
can
belo
catio
nin
depe
nden
t(e.
g..n
etdo
mai
n)–
can
belim
ited
toa
certa
inge
ogra
phic
alar
ea(e
.g..
fifo
rFin
land
)
68
Inte
rnet
nam
espa
ces(
cont
.)
•D
NS
nam
espa
ceha
ssev
eral
limita
tions
–up
datin
gth
eIP
inD
NS
can
beto
osl
owto
supp
ortm
obili
ty–
mos
thos
tsdo
noth
ave
mod
ifica
tion
acce
ssto
the
DN
Sse
rver
s–
basi
cD
NS
serv
ice
isno
tsec
ure
–m
any
DN
Sna
mes
are
boun
dto
asp
ecifi
cor
gani
zatio
nor
coun
try
•Th
ree
shor
tcom
ings
ofcu
rren
tnam
espa
ces
–ch
angi
ngth
eho
stad
dres
sbre
akst
rans
port
laye
rcon
nect
ion
–au
then
ticat
ion
ofth
eho
stis
nots
uppo
rted
–pr
ivac
y-pr
eser
ving
com
mun
icat
ion
isno
tpro
vide
d
69
Met
hods
ofid
entif
ying
aho
st
•In
HIP
,apa
irof
self-
gene
rate
dpu
blic
and
priv
ate
keys
prov
ides
the
HI
–th
ele
ngth
ofth
epu
blic
key
-512
,102
4or
2048
bits
–R
SAal
gorit
hmis
used
byde
faul
t–
supp
orto
fthe
DSA
algo
rithm
–ge
nera
tion
ofth
ene
wke
ysis
time-
cons
umin
gop
erat
ion
–la
rge
and
varia
ble
size
ofth
epu
blic
key
mak
esit
inco
nven
ient
foru
se
•Tw
oad
ditio
nalf
orm
sofh
osti
dent
ity:H
ITan
dLS
I
70
Met
hods
ofid
entif
ying
aho
st(c
ont.)
32 B
its
One
−way
has
h
Last
dig
its
Publ
ic k
ey
Priv
ate
key
(IPv
6 so
cket
)H
ost I
dent
ity T
ag
(IPv
4 so
cket
)L
ocal
Sco
pe Id
entit
y
Hos
t Ide
ntity
512,
102
4, o
r 204
8 bi
ts
1.x.
y.z
2001
:001
?:a:
b:c:
d:e:
f 1
28 B
its
•H
ostI
dent
ityTa
g(H
IT)
–th
esa
me
leng
thas
anIP
v6
–st
atis
tical
lyun
ique
–pr
obab
ility
ofco
llisi
ons
isne
glig
i-bl
e
–ha
sapr
efix
2001
:001
0::/2
8
•Lo
calS
cope
Iden
tity
(LSI
)
–pr
obab
ility
ofco
llisi
ons
issi
gnifi
-ca
nt
–ha
sonl
ylo
calm
eani
ng
–ha
sapr
efix
1
71
Ove
rlay
Rou
tabl
eC
rypt
ogra
phic
Has
hId
entifi
ers
•IP
v6pr
efix
forO
RC
HID
sres
erve
sapa
rtof
the
IPv6
addr
esss
pace
tose
rve
asid
entifi
ersi
nth
eso
cket
API
•In
tern
etA
ssig
ned
Num
bers
Aut
horit
y(I
AN
A)a
lloca
ted
apr
efix
for
OR
CH
IDs
•O
RC
HID
sapp
eara
sIPv
6ad
dres
ses
•O
RC
HID
sare
notr
outa
ble
atth
eIP
laye
r,ex
pect
edto
bero
utab
leat
the
over
lay
laye
ron
top
ofIP
•A
pplic
atio
nca
ntra
nspa
rent
lyus
eO
RC
HID
sin
plac
eof
IPv6
addr
esse
s
72
-
OR
CH
IDs.
The
purp
ose
ofan
IPv6
prefi
x
•Th
ego
als
–pr
even
tion
ofco
nfus
ion
with
regu
larI
Pv6
addr
esse
s–
OR
CH
IDsa
side
ntifi
ersi
nth
ele
gacy
appl
icat
ion
API
s–
poss
ibili
tyto
expe
rimen
twith
new
netw
ork
arch
itect
ures
–su
ppor
tofs
ever
aldi
ffere
ntpr
otoc
ols(
HIP
,MIP
)with
the
sam
eIP
v6pr
efix
•Pr
oper
tieso
fOR
CH
IDS
–ge
nera
ting
usin
gth
eha
shfu
nctio
n-s
ecur
ebi
ndin
gto
the
inpu
tpa
ram
eter
sand
stat
istic
alun
ique
ness
–co
mpa
tible
with
anIP
v6fo
rmat 73
Gen
erat
ing
and
rout
ing
anO
RC
HID
•SH
A1
hash
over
a12
8-bi
tcon
text
IDco
ncat
enat
edw
ithan
inpu
tbits
tring
–bi
tstri
ngm
ustb
est
atis
tical
lyun
ique
,can
ofte
nbe
apu
blic
key
–co
ntex
tID
-ran
dom
lyge
nera
ted
valu
e,de
fines
the
type
ofO
RC
HID
•Th
efin
alO
RC
HID
-con
cate
natin
gan
IAN
Aal
loca
ted
28-b
itpr
efix
with
a10
0-bi
tbits
tring
extra
cted
from
the
mid
dle
ofth
eha
shou
tput
•Lo
catio
n-in
depe
nden
tend
-poi
ntid
entifi
er
•C
anbe
rout
edon
anov
erla
yla
yer 74
OR
CH
IDsp
rope
rtie
s
•St
atis
tical
lyun
ique
•Tw
oty
peso
fcol
lisio
nsar
eth
eore
tical
lypo
ssib
le
–tw
oho
stge
nera
ted
with
inth
esa
me
cont
ext,
butw
ithdi
ffere
ntbi
tstri
ngca
nco
llide
–tw
oO
RC
HID
sfro
mdi
ffere
ntco
ntex
tcan
colli
de
•A
llco
ntex
tsus
eth
esa
me
hash
func
tion
toge
nera
tean
OR
CH
ID
75
The
role
ofIP
Sec
•ES
Ptra
nspo
rtm
ode
isus
edto
carr
yH
IPda
tapa
cket
s
•H
IPco
ntro
lmes
sage
s
–se
ssio
nke
yex
chan
ge-f
riend
lyw
ithm
iddl
ebox
es
•Se
cure
Para
met
erIn
dex
(SPI
)
–SP
Iin
the
pack
etid
entifi
esSe
curit
yA
ssoc
iatio
n(S
A)
–SP
Iism
appe
dto
HIT
s(H
ITco
mpr
essi
on)
•Th
ere
isno
HIP
-spe
cific
data
pack
etfo
rmat
,but
the
stan
dard
IPSe
cm
ode
isus
ed
•Li
ghtw
eigh
tHIP
76
HIP
rela
tion
toot
her
IET
Fac
tiviti
es•
Mob
ility
forI
Pv4
(mip
4)an
dM
obili
tyfo
rIPv
6(m
ip6)
–de
velo
pmen
toft
heM
obile
IPpr
otoc
ol
–ad
optio
nof
IKEv
2
•B
ette
r-Tha
n-N
othi
ng-S
ecur
ity(b
tns)
–un
auth
entic
ated
Secu
rity
Ass
ocia
tions
•Si
teM
ultih
omin
gin
IPv6
(mul
ti6)
–m
ultih
omin
gis
curr
ently
impl
emen
ted
inIP
v4
Secu
rity
Mob
ility
Mul
tihom
ing
Shim
6
Mob
ike
MIP
v4 a
nd M
IPv6
IPse
c
Res
earc
h G
roup
Nam
e Sp
ace
HIP
Arc
hite
ctur
e
•Si
teM
ultih
omin
gby
IPv6
Inte
rmed
iatio
n(s
him
6)–
shim
laye
rbet
wee
nth
eIP
and
the
trans
port
laye
rs
•IK
Ev2
Mob
ility
and
Mul
tihom
ing
Prot
ocol
(MO
BIK
E)–
can
beus
edfo
rmob
ileV
PNor
site
mul
tihom
ing
•M
obili
tyfo
rIP:
Perf
orm
ance
,Sig
nalin
g,an
dH
ando
ffO
ptim
izat
ion
(mip
shop
)–
Hie
rarc
hica
lMob
ileIP
v6(H
MIP
v6),
Fast
Han
dove
rsfo
rMob
ileIP
v6(F
MIP
v6)
77
Bas
ePr
otoc
ol
78
-
The
HIP
base
exch
ange
prot
ocol
•H
IPB
Ees
tabl
ishe
sSA
betw
een
two
host
s
•fo
ur-m
essa
geex
chan
ge
I2: H
IT(i)
HIT
(r) s
olut
ion
DH
(i) K
(i) si
g
R1:
HIT
(r) H
IT (i
) puz
zle
DH
(r) K
(r) s
ig
R2:
HIT
(r) H
IT (i
) sig
IPse
c da
ta tr
affic
I1: H
IT(i)
HIT
(r)
Initi
ator
Res
pond
er
79
Bas
eE
xcha
nge
•H
IPco
ntro
lpac
kets
–tra
nsm
itted
afte
raba
sic
IPv4
orv6
head
er–
prot
ocol
num
bera
ssig
ned
byIA
NA
is13
9(e
arly
HIP
-253
)–
basi
cH
IPhe
ader
com
mon
fora
llH
IPm
essa
ges
–H
IPch
ecks
umis
calc
ulat
edov
era
pseu
dohe
ader
incl
udin
gso
urce
and
dest
inat
ion
IP,H
IPpa
cket
leng
th,a
ndpr
otoc
olnu
mbe
r
80
Age
nera
lpac
ketf
orm
atof
HIP
mes
sage
s
12
34
56
78
09
12
34
56
78
09
12
34
56
78
09
10
01
23
Nex
t Hea
der
0H
eade
r Len
Pack
et T
ype
VER
. R
ES1
Che
cksu
m
Con
trols
HIP
Par
amet
ers (
varia
ble
size
)
Des
tinat
ion
HIT
(128
bit)
Sour
ce H
IT (1
28 b
it)
81
Bas
eE
xcha
nge
(con
t.)
•I1
pack
et
–st
arts
the
Bas
eEx
chan
ge–
cont
ains
the
Initi
ator
and
the
Res
pond
erH
ITs(
can
beob
tain
edfr
omth
eD
NS)
–th
eR
espo
nder
HIT
can
beN
ULL
-opp
ortu
nist
icm
ode
–co
ntai
nsth
eba
sic
head
eran
dno
para
met
ers
–th
eon
lyde
fined
HIP
cont
rolfl
agis
the
low
erm
ostb
itfo
rAno
nym
ous
iden
tifier
82
HIP
I1pa
cket
capt
ured
with
Wir
esha
rk
InternetProtocol,Version:4
Headerlength:20bytes
DifferentiatedServicesField:0x00(DSCP0x00:Default;ECN:0x00)
TotalLength:60
Identification:0x0000(0)
Flags:0x04(Don’tFragment)
Fragmentoffset:0
Timeto
live:63
Protocol:Unknown(0xfd)
Headerchecksum:0x4087[correct]
Source:193.167.187.106(193.167.187.106)
Destination:193.167.187.132(193.167.187.132)
HostIdentityProtocol
PayloadProtocol:59
HeaderLength:4
PacketType:1
Version:1,Reserved:1
HIPControls:0x0000
..............0.=
Certificate(OneormoreCERpacketsfollows)
...............0=
Anonymous(Sender’sHIisanonymous)
Checksum:0x6b06(correct)
Sender’sHIT:200100150A097C449CA1257176DD0872
Receiver’sHIT:20010014766EFBEEF74DEC73D6C528C0
83
Bas
eE
xcha
nge
(con
t.)
•R
1pa
cket
–up
onre
ceiv
ing
the
I1pa
cket
the
Res
pond
erdo
esno
tcre
ate
ast
ate
–th
eR
espo
nder
repl
iesw
ithan
R1
pack
et–
the
pack
etca
nbe
pre-
gene
rate
d–
cont
ains
aD
iffie-
Hel
lman
key,
acr
ypto
grap
hic
puzz
le,a
nda
publ
icke
y–
sign
edby
the
Res
pond
erw
ithits
priv
ate
key
84
-
Obl
igat
ory
field
sofH
IPR
1pa
cket
12
34
56
78
09
12
34
56
78
09
12
34
56
78
09
10
01
23
Nex
t Hea
der
0H
eade
r Len
Pack
et T
ype
VER
. R
ES1
Che
cksu
m
Con
trols
Sour
ce H
IT (1
28 b
it)
Des
tinat
ion
HIT
(128
bit)
Ran
dom
I (6
4 bi
t)
K
L
ifetim
e
Opa
que
Typ
e
Len
gth
Typ
e
Len
gth
Publ
ic K
ey (v
aria
ble
size
)
Typ
e
Len
gth
Typ
e
Len
gth
Sui
te ID
1
Suite
ID 2
Hos
t ide