author | cu |
Fri, 27 Oct 2017 23:57:21 +0100 | |
changeset 558 | 86334134abe5 |
parent 198 | 2ce98ee39990 |
permissions | -rw-r--r-- |
198
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
1 |
theory Send |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
2 |
imports Main |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
3 |
begin |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
4 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
5 |
typedecl principal |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
6 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
7 |
consts A :: principal |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
8 |
consts S :: principal |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
9 |
consts B :: principal |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
10 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
11 |
consts Says :: "principal \<Rightarrow> bool \<Rightarrow> bool" ("_ says _") |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
12 |
consts Sends :: "principal \<Rightarrow> principal \<Rightarrow> bool \<Rightarrow> bool" ("_ sends _ : _") |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
13 |
consts Enc :: "bool \<Rightarrow> bool \<Rightarrow> bool" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
14 |
consts CAB :: "bool" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
15 |
consts KAB :: "bool" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
16 |
consts KAS :: "bool" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
17 |
consts KBS :: "bool" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
18 |
consts M :: "bool" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
19 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
20 |
axiomatization where |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
21 |
saysI[intro]: "F \<Longrightarrow> P says F" and |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
22 |
saysE[elim]: "\<lbrakk>P says (F1 \<longrightarrow> F2); P says F1\<rbrakk> \<Longrightarrow> P says F2" and |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
23 |
says_encI[intro]: "\<lbrakk>P says F1; P says F2\<rbrakk> \<Longrightarrow> P says (Enc F1 F2)" and |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
24 |
says_encE[elim]: "\<lbrakk>P says (Enc F1 F2); P says F2\<rbrakk> \<Longrightarrow> P says F1" and |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
25 |
sendsE[elim]: "\<lbrakk>P sends Q : F; P says F\<rbrakk> \<Longrightarrow> Q says F" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
26 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
27 |
lemma |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
28 |
assumes start: "A says CAB" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
29 |
and msg1: "A sends S : CAB" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
30 |
and serv1: "S says (CAB \<longrightarrow> Enc KAB KAS)" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
31 |
and serv2: "S says (CAB \<longrightarrow> Enc (Enc KAB KBS) KAS)" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
32 |
and msg2a: "S sends A : (Enc KAB KAS)" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
33 |
and msg2b: "S sends A : (Enc (Enc KAB KBS) KAS)" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
34 |
and msg3: "A sends B : (Enc KAB KBS)" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
35 |
and msg4: "A sends B : (Enc M KAB)" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
36 |
and keyA: "A says KAS" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
37 |
and keyB: "B says KBS" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
38 |
and keyS: "S says KAS" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
39 |
and MA: "A says (Enc M KAB)" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
40 |
shows "S says M" |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
41 |
using assms |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
42 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
43 |
by (metis saysE says_encE sendsE) |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
44 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
45 |
by (metis saysE says_encE sendsE) |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
46 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
47 |
by metis |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
48 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
49 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
50 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
51 |
by (metis saysE says_encE sendsE) |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
52 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
53 |
by (metis saysE says_encE sendsE) |
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
54 |
|
2ce98ee39990
reorganised
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
55 |
end |