src/HOL/Auth/Guard/GuardK.thy
changeset 20768 1d478c2d621f
parent 19233 77ca20b0ed77
child 21404 eb85850d3eb7
equal deleted inserted replaced
20767:9bc632ae588f 20768:1d478c2d621f
   156 [| K:Ks'; K ~:Ks |] ==> Key K ~:parts G |] ==> GuardK n Ks' G"
   156 [| K:Ks'; K ~:Ks |] ==> Key K ~:parts G |] ==> GuardK n Ks' G"
   157 by (auto simp: GuardK_def dest: guardK_extand parts_sub)
   157 by (auto simp: GuardK_def dest: guardK_extand parts_sub)
   158 
   158 
   159 subsection{*set obtained by decrypting a message*}
   159 subsection{*set obtained by decrypting a message*}
   160 
   160 
   161 syntax decrypt :: "msg set => key => msg => msg set"
   161 abbreviation (input)
   162 
   162   decrypt :: "msg set => key => msg => msg set"
   163 translations "decrypt H K Y" => "insert Y (H - {Crypt K Y})"
   163   "decrypt H K Y == insert Y (H - {Crypt K Y})"
   164 
   164 
   165 lemma analz_decrypt: "[| Crypt K Y:H; Key (invKey K):H; Key n:analz H |]
   165 lemma analz_decrypt: "[| Crypt K Y:H; Key (invKey K):H; Key n:analz H |]
   166 ==> Key n:analz (decrypt H K Y)"
   166 ==> Key n:analz (decrypt H K Y)"
   167 apply (drule_tac P="%H. Key n:analz H" in ssubst [OF insert_Diff])
   167 apply (drule_tac P="%H. Key n:analz H" in ssubst [OF insert_Diff])
   168 apply assumption 
   168 apply assumption