Sunday, August 30, 2009

Lab 4­

Venue : Makmal Sistem, Building FTMK.
Date : 13-8-2009
Time : 10.00 a.m. – 11.50 a.m.


The title for the lab session this week was “Modern Cryptography”. According to the contents, there are two types of cryptography will be learnt by us and they are RSA algorithm and DES algorithm. For this week, we have learnt about RSA Algorithm. RSA algorithm is one of the algorithms that used to find private and public key. There are several steps need to be gone through according to the lab manual. The most important step for this algorithm is to find modulo numbers with the formulae d = e-1 mod n. Owing to the power of -1for the e value, it could not be solved using the ordinary method. Mr. Zaki taught us the method to calculate it. However, there is still one thing I am not very understand, that is I could not get the same answer for modulo numbers by using calculator. After Mr. Zaki has explained a bit about that, I understood a bit, but I think I still need some time to digest it… …

Tuesday, August 18, 2009

Modern Cryptography – Part 1

Venue : BK7, Building FTMK.
Date : 12-8-2009
Time : 9.00 a.m. – 10.50 a.m.

After understanding the concept of basic cryptography through the two lectures previously, we have learnt something much deeper about the cryptography for today’s lecture. Yeah, the title of the slides today is “Modern Cryptography”. It was taught in the same place, and was being taught by the same lecturer, Mr Zaki. Topics to be covered in this chapter are:

  • Modern Cryptography Algorithm

  • Block and Stream

  • DES

  • AES

  • MAC

  • Digital Signature, RSA

However, Mr Zaki managed to cover until the topic AES only because everyone in the class felt dizzy and scared to continue after listening the algorithms used in DES and AES (p/s: that was really though and I do not think that I am able to remember them in a day, oh my god!). The lecture began with a brief explanation about Modern Cryptography Algorithm given by Mr Zaki. In modern cryptography, the ciphers use a sequence of binary digits such as ASCII most of the time. Basically, Exclusive OR (XOR or Å) is the method used to combine two bits since modern ciphers applying binary digits on their algorithm. The four results of XOR are:
  • 0 Å 0 = 0

  • 0 Å 1 = 1

  • 1 Å 0 = 1

  • 1 Å 1 = 0

After that, Mr Zaki explained about the differences between Stream Ciphers and Block Ciphers. Stream Ciphers is the process to convert one symbol of plaintext immediately into a symbol of ciphertext; whereas Clock Ciphers is the process to encrypt a group of plaintext symbols as one block. The next topic after this was Data Encryption Standards (DES). The algorithm for DES is very complicated, so how it works? First, divide the plaintext 64 bit blocks with a key of 56 bits(with 8 bit parity). Then, process through 16 round of Expansion, substitution, key mixing and permutation process. The diagram below depicts how it actually works:


The last topic for today is Advance Encryption Standard (AES). It is used to replace DES. Instead of using 64 bits, AES uses 128 bit data and 128 or 192 or 256 bit keys. Mr Zaki taught this topic by using a flash clip, so it was quite interesting although the algorithm is much complicated than DES. We need time to digest the two algorithms, so everyone asked Mr Zaki to stop there and continue next week. Hope that next week won’t have this kind of algorithms to learn any more before i can understand algorithms just now… ^^

Thursday, August 13, 2009

Lab 3 – Classic Cryptography

Venue : Makmal Sistem, Building FTMK.
Date : 30-7-2009
Time : 10.00 a.m. – 11.50 a.m.


The lab session this week was about Classic Cryptography. Below are some of the things that I have learnt throughout the lab:
  1. Symmetric and Asymmetric Cryptography.

  2. Method to do Caesar Cipher.

  3. Method to do Vigeneré Cipher.
Mr Zaki started the lab session by giving a brief introduction about Symmetric and Asymmetric Cryptography. After that, we were given two tasks, where task 1 was about Caesar Cipher and task two was about Vigeneré Cipher. Basically, we were applying what we have learnt from yesterday’s lecture and the previous week’s lecture. Hence, I think that this lab was very useful for us to understand the lecture clearer. Actually, there is a simpler way to do the task by using Microsoft Excel. Since we do not know the formula to break the Cipher text, we have to do it manually. However, Mr Zaki gave us the formula and taught us to do it after we have finished both of the tasks. I feel that the formula really helps a lot; the time to solve the tasks became shorter. Before the lecture ended, we were asked to do the self-review questions and submit it as lab report by next week. The third question was very challenging. It was about using kasiski to find the key for the Vigeneré cipher text. This was not taught in the lecture, oh my god, hope that I can to solve it... ...

Third lecture

Venue : BK7, Building FTMK.
Date : 29 -7-2009
Time : 9.00 a.m. – 10.50 a.m.

The story continues and it was about the second part of basic cryptography. First of all, the Mr Zaki gave the answer for the task given last week. Yes, I got it correctly; the answer is “THE FUEL PRICE WILL INCREASE TO RM FOUR BY NEXT WEEK”. After a brief discussion on how to get the answer, Mr Zaki continued to teach chapter 2, it was first begun with Simple Substitution Ciphers (Random). This method is a bit different from the Caesar Cipher method, as it is a more secure. Basically, the alphabets for the key are arranged randomly with respective to an ordered set of alphabets. For example:

Ordered AlphabetA BCDEFGHIJKLM
KeyDIQMTBZSYKVOF

Ordered AlphabetNOPQRSTUVWXYZ
KeyERJAUWPXHLCNG

No matter how secure this method was, the text still can be decrypted also due to the language characteristic. For instance, in English, ‘E’ is the most common letter used, followed by ‘T’, ‘R’, ‘N’, ‘I’, ‘O’, ‘A’ , ‘S’... Hence, the code can be broken using the Frequency Attack.

Next, Mr Zaki taught us another method which is known as Vigenère Ciphers. The key is created by using the table as shown below:

The last method is transposition which the letters are rearranged. Basically, there are two types of transposition, they are unkeyed single transposition and keyed single. There is a simple review question given on the last slide of the chapter. The question is to find the enciphering key for a cipher text. The cipher text given is
“FQJCB RWJWJ VNJAX BNKHJ WHXCQ NAWJV NFXDU MBVNU UJBBF NNC”
It took me some times to find out the original message and I got the answer “WHATS IN A NAME AROSE BY ANY OTHER NAME WOULD SMELL AS SWEET” .

Lab 2 – The goals of Information Technology Security

Date: 23-7-2009

The lab session for today is a bit “special” from the previous week. Although the lab session is cancelled because Mr Zaki has a course to attend, if I am not mistaken, we were required to download the lab module from eftmk and complete it at home during the lecture yesterday. We were told that this is a very simple lab module, so it won’t be any problem if we do it ourselves.
The lab this week was mainly about the three goals of the Information security which are confidentiality, integrity and availability as shown in the diagram below:


Basically, there were four tasks in this lab module. We used VM to complete the four tasks. Before that, I have taken a snapshot before start to do the tasks in case any unpredicted problems occur. The first task was about the use of NTFS to Secure Local Resources. Two main outcomes from this task were:
  1. To check whether a drive is in NTFS format or not, type the command “chkntfs d:” in command prompt.

  2. To convert a FAT disk to NTFS, type the command “convert d: /fs:ntfsd”.

The rest of the tasks were about data confidentiality, data availability and data integrity accordingly.