Security Tutorial (Java/AnBx)

Security Programming, Protocol Verification and Code Generation
Paolo Modesti -

Part 3 - Configuration of the cryptographic engine

In the Part 1 we setup and tested the Java environment.
In the Part 2 we began using keystores, asymmetric encryption and digital signature.
Review the previous parts if you are unsure on how to build and run these programs.

Important: We are working in this folder

If you have not completed part 1 and 2, complete them before doing this part!

TASK 1 - Understanding the configuration of the cryptographic engine

In order to set which cryptographic algorithms are used (and their parameters) we use a configuration file.
The file will be <projectname>.properties and must be on the same folder of the main class.

Installation of Bouncy Castle library (optional)

TASK 2 - Run an application with a configuration

TASK 3 - Setting the configuration

We want to run Tutorial_04 with different encryption scheme. Look at Tutorial_04.proprierties. Based on what you have learned so far, try to run Tutorial_04.java with the following settings - cipherScheme (keySize). If there is any error understand the error and try to fix the configuration (N.B. Every algorithm works only with keys of a specific size). There is no need to recompile the program. Just stop and restart the server after every change of configuration.

TASK 4 - Performance of different cipher schemes (optional)

Based on the experiments made in task 3, you should have noticed that some schemes execute faster than other. Think about this and try to measure execution times. You need to adapt your java program.
Write a short document and:

TASKS 5 - (optional)

TASK 6 - (optional)

TASK 7 - (optional)