Name:

SE550 final exam: Autumn 2000-2001

Answer all questions.

Time allowed: 2 hours

Total number of points: 100

Question 1 (20 points)

A simple algorithm for object serialization is:

a) What is object serialization?

b) Give an example where the simple algorithm described above will not work.

c) Explain how to fix the problem in your answer to b).

Question 1 continued

Question 2 (15 points)

The following code:

  class Person { String name; int age; }
  Person fred = new Person (); fred.name = "Fred Flintstone"; fred.age=37;
  XMLSerializer.serialize (fred);

might produce the following XML:

  <Person id="handle1">
    <String>Fred Flintstone</String>
    <int>37</int>
  </Person>

What XML might the following programs produce?

a)

  class A { String foo; int bar; }
  A a = new A (); a.foo = "hello"; a.bar = 12;
  XMLSerializer.serialize (a);










b)

  class A { String foo; int bar; }
  class B { A baz; }
  A a = new A (); a.foo = "hello"; a.bar = 12;
  B b = new B (); b.baz = a;
  XMLSerializer.serialize (b);

Question 2 continued

c)

  class A { String foo; int bar; }
  class B { A baz; A bang; }
  A a1 = new A (); a1.foo = "hello"; a1.bar = 12;
  A a2 = new A (); a2.foo = "world"; a2.bar = 17;
  B b = new B (); b.baz = a1; b.bang = a2;
  XMLSerializer.serialize (b);










d)

  class A { String foo; int bar; }
  class B { A baz; A bang; }
  A a = new A (); a.foo = "hello"; a.bar = 12;
  B b = new B (); b.baz = a; b.bang = a;
  XMLSerializer.serialize (b);










e)

  class A { String foo; int bar; }
  class B { A baz; B bang; }
  A a = new A (); a.foo = "hello"; a.bar = 12;
  B b1 = new B (); b1.baz = a; b1.bang = b1;
  B b2 = new B (); b2.baz = a; b2.bang = b1;
  XMLSerializer.serialize (b2);

Question 3 (10 points)

a) What is a three-tiered architecture?

b) What makes a database relational?

c) What is SQL?

Question 4 (15 points)

a) What is a public (or asymmetric) key cryptosystem?

b) What is a hashing algorithm?

c) What is a digital signature?

d) Explain how a public key cryptosystem and a hashing algorithm can be used to implement digital signatures.

Question 4 continued

Question 5 (15 points)

The RSA algorithm has:

where de = 1 mod phi(n) and n is the product of two primes.

The prime decomposition problem is:

Show that:

You should state clearly any algebraic properties you are using, such as:

Question 5 continued

Question 6 (20 points)

TheNeedham-Schroeder key exchange protocol is:

a) What is a key-exchange protocol?

b) Explain the purpose of each of the messages in the Needham-Schroeder protocol.

c) At the end of the protocol, what does Alice believe? What does Bob belive?

d) Show how an attacker Charlie can use the Needham-Schroeder protocol to fool Bob into believing that Charlie is Alice.

Question 7 (5 points)

What was your favorite topic in this course? What was your least favorite?

Worksheet

You can use this sheet as scrap paper.

Worksheet

You can use this sheet as scrap paper.

Worksheet

You can use this sheet as scrap paper.

Worksheet

You can use this sheet as scrap paper.