Security Tutorial (Java/AnBx)

Security Programming, Protocol Verification and Code Generation
Paolo Modesti -

Part 2 - Key Generation - Secret and Authentic Channels

During Part 1 we setup and tested the Java environment running a simple distributed system composed by a client and a server.
Review Task 0 and Task 1 if you do not remember how to compile and run Java programs using the AnBxJ library.

We are working in this folder

To use the scripts on this page, the environmental variables JAVA_HOME and PATH must be set are described in Task 0.
Download the following command files (they will help you to compile and run the programs):

After downloading these files, double check that the extension of is .cmd/.sh (sometimes the browser may change it to .cmd.txt)

TASK 1 - Key generation

We are going to create RSA (2048 bits) keypairs (private and public) for alice and bob; keys will be stored on keystore of type PKCS12.

TASK 2 - Configure the keystores for this tutorial

TASK 3 - Exchanging encrypted messages (Secrecy)

TASK 4 - Digitally signing messages (Authentication)

TASK 5 - (optional)

TASK 6 - (optional)