Docsity

Homework 4 with Solution - Computer and Network Security | CMSC 414, Assignments of Computer Science

Toggle sidebar
bg1
udaya shankar Page 1 of 4 November 20, 2006
CMSC 414: HW 4
___________________________________________________________
1. (text 11.3) In section 11.3.1, we discuss various ways for forming a session key.
Remember that R is the challenge sent by Bob to Alice, and A is Alice’s secret, which
Bob also knows. Which of the following are secure for a session key?
• A ⊕ R
• {R + A}
A
• {A}
A
• {R}
R+A
Solution
A ⊕ R is not secure: eavesdropper who discovers it also discovers A.
{R + A}
A
is secure.
{R}
R+A
is secure.
{A}
A
is not secure: it is the same for all sessions.
___________________________________________________________
2. (text 11.4) Design a variant of Otway-Rees that only has one nonce generated by
Alice and one nonce generated by Bob. Explain why it is still as secure.
Solution
Essentially, replace N
C
by K
A
{N
A
, “A”, “B”}
A (Alice) KDC
B (Bob)
1 generate nonces N
A
send [ A, B, K
A
{N
A
, A, B} ] to B
2
generate nonce N
B
send [ K
B
{N
B
, K
A
{N
A
, A, B}, A, B} ]
to KDC
3
invent session key K
AB
extract N
A
, N
B
• send [ K
A
{N
A
, K
AB
}, K
B
{N
B
, K
AB
}] to B
4 send K
A
{N
A
, K
AB
} to A
5 send K
AB
{anything recognizable} to B
<-------- A and B establish data session key (eg, (K
AB
+1){R
1
⊕R
2
} ----->
When the KDC extracts N
A
and N
B
(step 3), it ensures that B is making the request, that
A made the request that B is forwarding inside B’s request, and that A and B want to talk
to each other.
The nonce N
B
in B’s ticket ensures that the ticket is freshly created by KDC.
The nonce N
A
in A’s ticket ensures that the ticket is freshly created by KDC.
___________________________________________________________
pf3
pf4

Partial preview of the text

Download Homework 4 with Solution - Computer and Network Security | CMSC 414 and more Assignments Computer Science in PDF only on Docsity!

CMSC 414: HW 4

___________________________________________________________

  1. (text 11.3) In section 11.3.1, we discuss various ways for forming a session key. Remember that R is the challenge sent by Bob to Alice, and A is Alice’s secret, which Bob also knows. Which of the following are secure for a session key?
    • A ⊕ R
    • {R + A}A
    • {A}A
    • {R}R+A

Solution A ⊕ R is not secure: eavesdropper who discovers it also discovers A. {R + A}A is secure. {R}R+A is secure. {A}A is not secure: it is the same for all sessions.


  1. (text 11.4) Design a variant of Otway-Rees that only has one nonce generated by Alice and one nonce generated by Bob. Explain why it is still as secure.

Solution Essentially, replace NC by KA{NA, “A”, “B”}

A (Alice) KDC B (Bob) 1  generate nonces NA  send [ A, B, KA{NA, A, B} ] to B

2

 generate nonce NB  send [ KB{NB, KA{NA, A, B}, A, B} ] to KDC

3

 invent session key KAB  extract NA, NB

  • send [ KA{NA, KAB}, KB{NB, KAB}] to B

4  send KA{NA, KAB} to A 5 send KAB{anything recognizable} to B <-------- A and B establish data session key (eg, (KAB+1){R 1 ⊕R 2 } ----->

When the KDC extracts NA and NB (step 3), it ensures that B is making the request, that A made the request that B is forwarding inside B’s request, and that A and B want to talk to each other. The nonce NB in B’s ticket ensures that the ticket is freshly created by KDC. The nonce NA in A’s ticket ensures that the ticket is freshly created by KDC.

___________________________________________________________

  1. (text 11.8) Design a two-message authentication protocol that achieves both mutual authentication and establishment of a session key, assuming that Alice and Bob know each other’s public keys.

Solution Alice picks a session key K and sends a signed message containing K encrypted by Bob’s public key and a timestamp ts. Bob responds with the timestamp ts encrypted with K.

A (Alice) B (Bob)

  • send [ {K}B, ts ]A to B
    • send [ K{ts}]

___________________________________________________________

  1. (text 11.10) Section 11.4 Mediated Authentication (with KDC) describes several protocols. For each of those protocols, describe which nonces have to be unpredictable (i.e., cannot be sequence numbers).

Solution Protocol 11-18 (Needham-Schroeder): N 1 must be unpredictable (otherwise Trudy can impersonate the KDC by giving Alice an old ticket to Bob with a key that Trudy had stolen earlier).

Protocol 11-19 (Expanded Needham-Schroeder) and protocol 11-21 (Kerberos): N 1 must be unpredictable.

Protocol 11-20 (Otway-Rees): NC must be unpredictable (explained in text).


  1. (text 16.1) Which of the following properties does protocol 16-2 have: perfect forward secrecy (PFS); escrow foilage against passive attacks; escrow foilage against active attacks; identity hiding; perfect forward secrecy for identity hiding. Assume private encryption keys are escrowed and private signature keys are not escrowed.

Solution PFS; escrow foilage against passive attacks; escrow foilage against active attacks (unless signature key is escrowed); no identity hiding.

___________________________________________________________

  1. (text 16.5) Referring to section 16.6 Endpoint Identifier Hiding , show a protocol that hides both identifiers from an active attacker, assuming that Alice (the initiator) already knows Bob’s public key.

Solution Have Alice send her name, her public encryption key certificate, and her DIffie-Hellman value encrypted with Bob’s public key. Bob replies encrypted with Alice’s public key.


  1. (text 16.7) Devise a protocol based on a pre-shared secret key that hides identities and gives PFS for identity hiding. Make two variants, one in which an active attacker can learn only the initiator’s identity, and one in which an active attacker can learn only the target’s identity.

Solution Variant where attacker only learn’s initiator identity Messages 1 and 2: Diffie-Hellman exchange. Msg 3: initiator sends its id and proof of knowledge of shared key, encrypted with the Diffie-Hellman key. Msg 4: target sends its id and proof of knowledge of the shared key encrypted with the Diffie-Hellman key.

Variant where attacker only learn’s target’s identity Msg 1: Diffie-Hellman number. Msg 2: (a) Diffie-Hellman number and (b) target’s id and proof of knowledge of shared key, encrypted with Diffie-Hellman key. Msg 3: initiator sends its id and proof of knowledge of shared key, encrypted with the Diffie-Hellman key.