0f54f2ed23
SPORE: - pk is not known to all agents, only pk(Simon) is known - Use new naming convention: - Protocol name starting with an @ means internal protocol - For non internal protocols naming is as follows: protocolname-variant^subprotocol For example: yahalom-Lowe^KeyCompromise meaning the key compromise sub protocol of the Lowe variant of the Yahalom protocol.
119 lines
2.9 KiB
Plaintext
119 lines
2.9 KiB
Plaintext
# Lowe modified KSL
|
|
#
|
|
# Modelled after the description in the SPORE library
|
|
# http://www.lsv.ens-cachan.fr/spore/kslLowe.html
|
|
#
|
|
# Note:
|
|
# This protocol uses a ticket so scyther will only be able to verify
|
|
# the protocol using the ARACHNE engine (-a)
|
|
#
|
|
# Note:
|
|
# According to SPORE there are no attacks on this protocol, scyther
|
|
# finds one however. This has to be investigated further.
|
|
|
|
usertype Server, SessionKey, TimeStamp, TicketKey;
|
|
usertype ExpiredTimeStamp;
|
|
secret k: Function;
|
|
|
|
const a, b, e: Agent;
|
|
const s: Server;
|
|
const Fresh: Function;
|
|
const Compromised: Function;
|
|
|
|
|
|
const ne: Nonce;
|
|
const kee: SessionKey;
|
|
untrusted e;
|
|
compromised k(e,s);
|
|
|
|
protocol ksl-Lowe^KeyCompromise(C)
|
|
{
|
|
// Read the names of 3 agents and disclose a session between them including
|
|
// corresponding session key to simulate key compromise
|
|
role C {
|
|
const Ni,Nr,Nc,Ma,Mb: Nonce;
|
|
const Kir: SessionKey;
|
|
const Kbb: TicketKey;
|
|
const Tr: ExpiredTimeStamp;
|
|
var I,R,S: Agent;
|
|
|
|
read_C1(C,C, I,R,S);
|
|
send_C2(C,C, (Ni,I),
|
|
(Ni,I,Nr,R),
|
|
{I,Nr,Kir}k(R,S),{Ni,R,Kir}k(I,S),
|
|
{Tr,I,Kir}Kbb,Nc,{R,Ni}k(I,R),
|
|
{Nc}Kir,
|
|
Ma,
|
|
Mb,{Ma,R}Kir,
|
|
{I,Mb}Kir,
|
|
Kir,
|
|
Kbb
|
|
);
|
|
claim_C3(C,Empty, (Compromised,Kir));
|
|
claim_C4(C,Empty, (Compromised,Kbb));
|
|
}
|
|
}
|
|
|
|
protocol ksl-Lowe(A,B,S)
|
|
{
|
|
role A
|
|
{
|
|
const Na, Ma: Nonce;
|
|
var Nc, Mb: Nonce;
|
|
var T: Ticket;
|
|
var Kab: SessionKey;
|
|
|
|
send_1(A,B, Na, A);
|
|
read_4(B,A, { Na,B,Kab }k(A,S), T, Nc, {B,Na}Kab );
|
|
send_5(A,B, { Nc }Kab );
|
|
|
|
send_6(A,B, Ma,T );
|
|
read_7(B,A, Mb,{Ma, B}Kab );
|
|
send_8(A,B, {A,Mb}Kab );
|
|
|
|
claim_A1(A,Secret, Kab);
|
|
claim_A2(A,Niagree);
|
|
claim_A3(A,Nisynch);
|
|
claim_A4(A,Empty, (Fresh,Kab));
|
|
}
|
|
|
|
role B
|
|
{
|
|
var Na,Ma: Nonce;
|
|
const Nb,Nc,Mb: Nonce;
|
|
var Kab: SessionKey;
|
|
const Kbb: TicketKey;
|
|
const Tb: TimeStamp;
|
|
var T: Ticket;
|
|
|
|
read_1(A,B, Na, A);
|
|
send_2(B,S, Na, A, Nb, B );
|
|
read_3(S,B, { A, Nb, Kab }k(B,S), T );
|
|
send_4(B,A, T, { Tb, A, Kab }Kbb, Nc, {B, Na}Kab );
|
|
read_5(A,B, { Nc }Kab );
|
|
|
|
read_6(A,B, Ma,{ Tb, A, Kab }Kbb );
|
|
send_7(B,A, Mb,{Ma,B}Kab );
|
|
read_8(A,B, {A,Mb}Kab );
|
|
|
|
claim_B1(B,Secret, Kab);
|
|
claim_B2(B,Niagree);
|
|
claim_B3(B,Nisynch);
|
|
claim_B4(B,Empty, (Fresh,Kab));
|
|
}
|
|
|
|
role S
|
|
{
|
|
var Na, Nb: Nonce;
|
|
const Kab: SessionKey;
|
|
|
|
read_2(B,S, Na, A, Nb, B );
|
|
send_3(S,B, { A, Nb, Kab }k(B,S), { Na,B,Kab }k(A,S) );
|
|
}
|
|
}
|
|
|
|
run ksl-Lowe.A(a,b,s);
|
|
run ksl-Lowe.B(a,b,s);
|
|
run ksl-Lowe.S(a,b,s);
|
|
|