The document discusses various polyalphabetic ciphers including the Vigenere cipher, one-time pad cipher, Playfair cipher, and Hill cipher. It provides examples of encrypting and decrypting messages with the Vigenere cipher and Playfair cipher. The Vigenere cipher uses a keyword to shift the letters of a plaintext by various amounts, while the Playfair cipher encrypts pairs of letters based on their positions in a 5x5 grid generated from a keyword. The document also describes how the Hill cipher works by converting the plaintext and keyword into matrices and performing matrix multiplication to encrypt messages in blocks of letters.
In today's high technology environment, organizations are becoming more and more dependent on their information systems. The public is increasingly concerned about the proper use of information, particularly personal data. The threats to information systems from criminals and terrorists are increasing. Many organizations will identify information as an area of their operation that needs to be protected as part of their system of internal control.
Computer and Network Security is the collection of technologies, standards, policies and management practices that are used in order to obtain a high level of security.
The aim of this course is to explore security fundamentals related to computer data, information and Network. It details the methods of attacks along with security principles.
The official learning outcome for this course is: Upon successful completion of the course the students:
• Must know the basic concepts related to computer and network security.
• Must know how to apply the techniques related to data and information.
A combination of lectures and practical sessions will be used in this course in order to achieve the aim of the course.
By MSc. Karwan Mustafa Kareem
In today's high technology environment, organizations are becoming more and more dependent on their information systems. The public is increasingly concerned about the proper use of information, particularly personal data. The threats to information systems from criminals and terrorists are increasing. Many organizations will identify information as an area of their operation that needs to be protected as part of their system of internal control.
Computer and Network Security is the collection of technologies, standards, policies and management practices that are used in order to obtain a high level of security.
The aim of this course is to explore security fundamentals related to computer data, information and Network. It details the methods of attacks along with security principles.
The official learning outcome for this course is: Upon successful completion of the course the students:
• Must know the basic concepts related to computer and network security.
• Must know how to apply the techniques related to data and information.
A combination of lectures and practical sessions will be used in this course in order to achieve the aim of the course.
By MSc. Karwan Mustafa Kareem
4. The Advanced Encryption Standard (AES)Sam Bowne
A lecture for a college course -- CNIT 140: Cryptography for Computer Networks at City College San Francisco
Based on "Understanding Cryptography: A Textbook for Students and Practitioners" by Christof Paar, Jan Pelzl, and Bart Preneel, ISBN: 3642041000
Instructor: Sam Bowne
More info: https://samsclass.info/141/141_F17.shtml
What is IDS?
Software or hardware device
Monitors network or hosts for:
Malware (viruses, trojans, worms)
Network attacks via vulnerable ports
Host based attacks, e.g. privilege escalation
What is in an IDS?
An IDS normally consists of:
Various sensors based within the network or on hosts
These are responsible for generating the security events
A central engine
This correlates the events and uses heuristic techniques and rules to create alerts
A console
To enable an administrator to monitor the alerts and configure/tune the sensors
Different types of IDS
Network IDS (NIDS)
Examines all network traffic that passes the NIC that the sensor is running on
Host based IDS (HIDS)
An agent on the host that monitors host activities and log files
Stack-Based IDS
An agent on the host that monitors all of the packets that leave or enter the host
Can monitor a specific protocol(s) (e.g. HTTP for webserver)
Basic Talk. 90 minute talk to an audience of Freshmen and Sophomores of IIT Bombay on 23/02/10 as a part of Science Week. Organised by Web and Coding Club. Place: GG 101 (Elec Department)
Intrusion detection and prevention systemNikhil Raj
This presentation describes how to implement Network based Intrusion Detection System (SNORT) in the network. Detecting and analyzing alerts generated and blocking the Attacker using Access Control List.
Introduction to cryptography and types of ciphersAswathi Nair
Cryptography is a method of storing and transmitting data in a particular form so that only those for whom it is intended can read and process it.So these slides give you an introduction to cryptography and types of ciphers.
Encrypted message transmitter on public networkRowshina Nikzad
To transmit messages in critical situations when the value of information and Data is high, For example in the military, we need to encrypt messages.
Different ways to encrypt messages have been invented, the subject of this project is encoding the message in the sender and decoding the message in the receiver using the Playfair method over the network platform. we used #c for programming this project.
4. The Advanced Encryption Standard (AES)Sam Bowne
A lecture for a college course -- CNIT 140: Cryptography for Computer Networks at City College San Francisco
Based on "Understanding Cryptography: A Textbook for Students and Practitioners" by Christof Paar, Jan Pelzl, and Bart Preneel, ISBN: 3642041000
Instructor: Sam Bowne
More info: https://samsclass.info/141/141_F17.shtml
What is IDS?
Software or hardware device
Monitors network or hosts for:
Malware (viruses, trojans, worms)
Network attacks via vulnerable ports
Host based attacks, e.g. privilege escalation
What is in an IDS?
An IDS normally consists of:
Various sensors based within the network or on hosts
These are responsible for generating the security events
A central engine
This correlates the events and uses heuristic techniques and rules to create alerts
A console
To enable an administrator to monitor the alerts and configure/tune the sensors
Different types of IDS
Network IDS (NIDS)
Examines all network traffic that passes the NIC that the sensor is running on
Host based IDS (HIDS)
An agent on the host that monitors host activities and log files
Stack-Based IDS
An agent on the host that monitors all of the packets that leave or enter the host
Can monitor a specific protocol(s) (e.g. HTTP for webserver)
Basic Talk. 90 minute talk to an audience of Freshmen and Sophomores of IIT Bombay on 23/02/10 as a part of Science Week. Organised by Web and Coding Club. Place: GG 101 (Elec Department)
Intrusion detection and prevention systemNikhil Raj
This presentation describes how to implement Network based Intrusion Detection System (SNORT) in the network. Detecting and analyzing alerts generated and blocking the Attacker using Access Control List.
Introduction to cryptography and types of ciphersAswathi Nair
Cryptography is a method of storing and transmitting data in a particular form so that only those for whom it is intended can read and process it.So these slides give you an introduction to cryptography and types of ciphers.
Encrypted message transmitter on public networkRowshina Nikzad
To transmit messages in critical situations when the value of information and Data is high, For example in the military, we need to encrypt messages.
Different ways to encrypt messages have been invented, the subject of this project is encoding the message in the sender and decoding the message in the receiver using the Playfair method over the network platform. we used #c for programming this project.
An introductory presentation on cryptography. From ancient ciphers to modern public key encryption, it follows the evolution of a science and how it affects society.
Understanding the History of EncryptionUnderstanding thecorbing9ttj
Understanding the History of Encryption
Understanding the History of Encryption
Few facts -
Encryption has been around for a very long time. Instead of explaining the History of Cryptography, I am going to recommend a very good book by David Khan called "The Code Breakers" , published in 1996.
Instead of starting with early encryption algorithm, I am going to used two interesting encryption algorithms that will capture manu of the concepts that Khan outline in his book. The first algorithm is Character Substitution. Remember, the problem we are trying to solve is "how do we secure communications?". An example is - Suppose Alice and Bob wants to communicate securely using Eve is an attacker that wants to eavesdrop on the conversation. In order to communicate securely, Alice and Bob are going to share a secret key, which we are going to call K. Eve does not know anything about the key K.
Alice, Bob and even Eve know the algorithm (say character substitution). We all have played the substitution game in School. A is map to C and B is map to X and C is map to W and so on and so forth. So, if EVE gets the mapping and the ciphered text, she will be able to decipher the secret. Let supposed Eve gets the ciphered text but not the mapping (key). It will be difficult to figure the key out.
Assuming we have 26 letters, how many possibilities are there --> guess?
1. 26
2. 26X26
3. 26! (factorial)
4. 2^26
The answer is 26! which is about 2^88 if I remember correctly, which is a very large sample space. I hope you understand where I got the 26!. Think of one mapping and now think of another mapping and so on.
What is factorial? 1! = 1, 2! = 1X2 = 2, 3! = 1X2X3 = 6 and so on.
When I said 2^88, it is a good key since it is using 88 bits. Note that I am not saying it is great.
What I want you to do is to think about how you would break a substitution cipher? It is not hard but it needs some imagination.
The Substitution Cipher and How to break the Cipher
Breaking The Substitution Cipher
One way to break a substitution cipher is to use frequency analysis. Let's focus on the English language for now but the process works the same way for other languages. The character "e" occurs 12.7% in the Eglish language and the letter "t" occurs 9.35% and the letter "a" is 8.2% of the time. So, you can count each character in the ciphered text, compute its frequency and start replacing it. After you complete the first say 4 characters, you may want to change your strategy. Can you explain why you want to stop after the first 4 characters? The two-character "of" is about 4.16% and "to" is about 2%. Now try three characters frequency.
After a period of time, you will be able to decipher most of the text. I am going to ask you to do your first significant homework using frequency analysis.
One possibility for the substitution cipher:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
↕
↕
↕
↕
↕
↕
↕
↕
↕
↕
...
Amanda Sopkin - Computational Randomness: Creating Chaos in an Ordered Machin...Codemotion
There are many computational needs for randomness, from video games to making a cryptographically secure id. Generally, using the default random libraries to create random numbers is sufficient, but for secure cases we require something better. We will begin by reviewing some historical examples of hacks that exploited weaknesses in random number generators. Next we will look at common random number generators and the algorithms and seeds that are used. Finally, we will explore modern random number generators that take different approaches and discuss the best uses for each type.
Cryptography, Classical Encryption
Breaking the Cryptosystem
Review the Simple attack to break the cryptosystem
Modular Arithmetic, Groups and Rings
One example each in classical substitutive and transposition ciphering.
Caesar/Affine Cipher –Worksheet and Lab Program
How to Add Chatter in the odoo 17 ERP ModuleCeline George
In Odoo, the chatter is like a chat tool that helps you work together on records. You can leave notes and track things, making it easier to talk with your team and partners. Inside chatter, all communication history, activity, and changes will be displayed.
Introduction to AI for Nonprofits with Tapp NetworkTechSoup
Dive into the world of AI! Experts Jon Hill and Tareq Monaur will guide you through AI's role in enhancing nonprofit websites and basic marketing strategies, making it easy to understand and apply.
MATATAG CURRICULUM: ASSESSING THE READINESS OF ELEM. PUBLIC SCHOOL TEACHERS I...NelTorrente
In this research, it concludes that while the readiness of teachers in Caloocan City to implement the MATATAG Curriculum is generally positive, targeted efforts in professional development, resource distribution, support networks, and comprehensive preparation can address the existing gaps and ensure successful curriculum implementation.
Biological screening of herbal drugs: Introduction and Need for
Phyto-Pharmacological Screening, New Strategies for evaluating
Natural Products, In vitro evaluation techniques for Antioxidants, Antimicrobial and Anticancer drugs. In vivo evaluation techniques
for Anti-inflammatory, Antiulcer, Anticancer, Wound healing, Antidiabetic, Hepatoprotective, Cardio protective, Diuretics and
Antifertility, Toxicity studies as per OECD guidelines
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...Dr. Vinod Kumar Kanvaria
Exploiting Artificial Intelligence for Empowering Researchers and Faculty,
International FDP on Fundamentals of Research in Social Sciences
at Integral University, Lucknow, 06.06.2024
By Dr. Vinod Kumar Kanvaria
A review of the growth of the Israel Genealogy Research Association Database Collection for the last 12 months. Our collection is now passed the 3 million mark and still growing. See which archives have contributed the most. See the different types of records we have, and which years have had records added. You can also see what we have for the future.
Macroeconomics- Movie Location
This will be used as part of your Personal Professional Portfolio once graded.
Objective:
Prepare a presentation or a paper using research, basic comparative analysis, data organization and application of economic information. You will make an informed assessment of an economic climate outside of the United States to accomplish an entertainment industry objective.
Delivering Micro-Credentials in Technical and Vocational Education and TrainingAG2 Design
Explore how micro-credentials are transforming Technical and Vocational Education and Training (TVET) with this comprehensive slide deck. Discover what micro-credentials are, their importance in TVET, the advantages they offer, and the insights from industry experts. Additionally, learn about the top software applications available for creating and managing micro-credentials. This presentation also includes valuable resources and a discussion on the future of these specialised certifications.
For more detailed information on delivering micro-credentials in TVET, visit this https://tvettrainer.com/delivering-micro-credentials-in-tvet/
How to Build a Module in Odoo 17 Using the Scaffold MethodCeline George
Odoo provides an option for creating a module by using a single line command. By using this command the user can make a whole structure of a module. It is very easy for a beginner to make a module. There is no need to make each file manually. This slide will show how to create a module using the scaffold method.
Thesis Statement for students diagnonsed withADHD.ppt
Computer Security (Cryptography) Ch03
1. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 1
Polyalphabetic Cipher
Leon Battista invented the Polyalphabetic Substitution Cipher in year 1568.
“Poly means Many in Greek language”. This method uses a mixed alphabet to
encrypt a message. The Enigma machine is more complex but still fundamentally a
polyalphabetic substitution cipher.
In polyalphabetic substitution, each occurrence of a character may have a different
substitute. The Polyalphabetic Cipher was adapted as a twist on the standard
Caesar cipher to reduce the effectiveness of frequency analysis on the ciphertext.
The polyalphabetic cipher uses a text string (for example, a word) as a key, which
is then used for doing a number of shifts on the plaintext.
Polyalphabetic Cipher Types
A. Vigenère Cipher
B. One Time Pad Cipher
C. Playfair Cipher
D. Hill Cipher
Vigenere cipher
One such cipher is the famous Vigenere cipher, the Vigenere cipher uses
the power of 26 possible shift ciphers. A tool that was used for the Vigenère
Cipher was a (code wheel) or (Keyword). Vigenere cipher shifts the characters in a
string by some places. Now those some places are determined by the characters
that are present in the key string.
P=P1P2P3…… C=C1C2C3…….. k=[(K1,K2,….. , KM), (K1,K2,….. , KM),..]
Encryption : Ci = Pi + Ki Decryption : Pi = Ci - Ki
2. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 2
Example
Plain Text: “Computer Science”. Key = Security, Cipher Text?
Encode plain text.
Write key under coded plaintext, repeating as many times as necessary.
Encode key.
Add key character code to corresponding plain text code (mod 26).
Decoding of resulting integer is Ciphertext.
Note: If (Pencoding + Kencoding) >= 26 then - 26
Answer (Encryption)
Plain text C O M P U T E R S C I E N C E
Pencoding 2 14 12 15 20 19 4 17 18 2 8 4 13 2 4
Key S E C U R I T Y S E C U R I T
Kencoding 18 4 2 20 17 8 19 24 18 4 2 20 17 8 19
Cipher Code 20 18 14 9 11 1 23 15 10 6 10 24 4 10 23
Cipher text U S O J L B X P K G K Y E K X
+
3. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 3
Decryption
Ciphertext = USOJLBXPKGKYEKX , Key = Security . Plaintext ??
Cipher text U S O J L B X P K G K Y E K X
Cipher Code 20 18 14 9 11 1 23 15 10 6 10 24 4 10 23
Key S E C U R I T Y S E C U R I T
Kencoding 18 4 2 20 17 8 19 24 18 4 2 20 17 8 19
Pencoding 2 14 12 15 20 19 4 17 18 2 8 4 13 2 4
Plain text C O M P U T E R S C I E N C E
-
9 – 20 = – 11 : 26 – 11 = 15
4. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 4
Build Program
1. Add a three label control on the form. Set the first Text property to Plain
text , second label set to Key and third to Cipher text .
2. Add three text box controls as shown.
o Name the first text box control PTtxt
o Name the second text box control Keytxt
o Name the third text box control CTtxt
3. Add two button controls as shown.
o Name the first button control Encryption
o Name the second button control Decryption
5. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 5
Program Coding
Double-click the Encryption control. And write follow code.
Double-click the Decryption control. And write follow code.
Now you can write class VigenereCipher that contain two function Encrypt
For return Cipher text and Decrypt for return Result Plain to the end user
Depending on the key type string , this function will receive 2 parameters
when you click button Enc or Dec :
Plain text
Key Secret
Private Sub Encbtn_Click(sender As Object, e As EventArgs) Handles Encbtn.Click
CTtxt.Text = VigenereCipher.Encrypt(PTtxt.Text, Keytxt.Text)
End Sub
Private Sub Decbtn_Click(sender As Object, e As EventArgs) Handles Decbtn.Click
CTtxt.Text = VigenereCipher.Decrypt(PTtxt.Text, Keytxt.Text)
End Sub
6. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 6
Public Class VigenereCipher
Public Shared Function Encrypt(ByVal plainTxt As String, ByVal key As
String)
Dim encryptedText As String = ""
For i As Integer = 1 To cipherTxt.Length
Dim temp As Integer = AscW(GetChar(cipherTxt, i)) +
AscW(GetChar(key, i Mod key.Length + 1))
encryptedText += ChrW(temp)
Next
Return encryptedText
End Function
Public Shared Function Decrypt(ByVal cipherTxt As String, ByVal key
As String)
Dim decryptedText As String = ""
For i As Integer = 1 To cipherTxt.Length
Dim temp As Integer = AscW(GetChar(cipherTxt, i)) -
AscW(GetChar(key, i Mod key.Length + 1))
decryptedText += ChrW(temp)
Next
Return decryptedText
End Function
End Class
7. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 7
One Time Pad Cipher
known as Vernam Cipher is implemented using a random set of non
repeating characters as the Key. The rest of process is same as the Vigenère cipher.
The sender uses each key letter on the pad to encrypt exactly one plaintext
character. Encryption is the addition modulo 26 of the plaintext character and the
one-time pad key character
(Pencoding + Kencoding) >= 26 then - 26
Example: ( Encryption )
Plaintext: “ HOW ARE YOU ’’ Key = NCBTZQARX Ciphertext: ?
Plain text H O W A R E Y O U
Pencoding 7 14 22 0 17 4 24 14 20
Key N C B T Z Q A R X
Kencoding 13 2 1 19 25 16 0 17 23
Cipher Code 20 16 23 19 16 20 24 5 17
Cipher text U Q X T Q U Y F R
+
8. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 8
(Decryption)
Cipher text U Q X T Q U Y F R
Cipher Code 20 16 23 19 16 20 24 5 17
Key N C B T Z Q A R X
Kencoding 13 2 1 19 25 16 0 17 23
Pencoding 7 14 22 0 17 4 24 14 20
Plain text H O W A R E Y O U
-
16 – 25 = – 9 26 – 9 = 17
9. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 9
Playfair Cipher
The Playfair cipher encrypts pairs of letters, instead of single letters. This is
significantly harder to break. Each plaintext letter is replaced by a diagram in this
cipher.
User chooses a keyword and puts it in the cells of a 5 x 5 matrix.
Letter I and J always stay in one cell .
Duplicate letters appear only once.
Number of diagrams is 26 x 26 = 676.
To encrypt a message, one would break the message into groups of 2
letters. If there is a dangling letter at the end, we add an X. For
example. "Secret Message" becomes "SE CR ET ME SS AG EX".
We now take each group and find them out on the table. we apply the
following rules, in order.
Playfair Cipher Rules
1. If the digraph consists of the same letter twice (or there is only one
letter left by itself at the end of the plaintext) then insert the letter "X"
between the same letters (or at the end), and then continue with the
rest of the steps.
2. If the two letters appear on the same row in the square, then replace
each letter by the letter immediately to the right of it in the square
(cycling round to the left hand side if necessary).
3. If the two letters appear in the same column in the square, then
replace each letter by the letter immediately below it in the square
(cycling round to the top of the square if necessary).
4. Otherwise, form the rectangle for which the two plaintext letters are
two opposite corners. Then replace each plaintext letter with the letter
that forms the other corner of the rectangle that lies on the
same row as that plaintext letter (being careful to maintain the order).
10. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 10
Example
Plain text = Hide the gold in the tree stump , key = playfair example ,
Cipher text ??
Firstly we must generate the Polybius Square that we are going to use. We
do this by setting out a 5x5 grid, and filling it with the alphabet, starting with the
letters of the keyphrase, and ignoring any letters we already have in the square. We
are also going to combine "I" and "J" in the square.
We must now split the plaintext into digraphs, and split up any double letter
digraphs by inserting an "x" between them. The first image below shows the initial
digraph split of the plaintext, and the second image displays how we split up the
"ee" into "ex" and "es". In this case, when we insert this extra "x", we no longer
need to have one at the end of the plaintext.
HI DE TH EG OL DI NT HE TR EE ST UM P
P L A Y F
I R E X M
B C D G H
K N O Q S
T U V W Z
HI DE TH EG OL DI NT HE TR EX ES TU MP
11. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 11
We now take each digraph in turn and apply rule 2, 3 or 4 as necessary. Each
step is show below with a visual representation of what is done for each digraph.
15. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 15
We can now take each of the ciphertext digraphs that we produced and put
them all together.
BM OD ZB XD NA BE KU DM UI XM MO UV IF
Homework
Decrypt the Cipher text = BMODZBXDNABEKUDMUIXMMOUVIF .
When the key = playfair example
16. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 16
Hill Cipher
The Hill Cipher was invented by Lester S. Hill in 1929, and like the
other Digraphic Ciphersit acts on groups of letters. Unlike the others though it is
extendable to work on different sized blocks of letters. So, technically it is a
polygraphic substitution cipher, as it can work on digraphs, trigraphs (3 letter
blocks) or theoretically any sized blocks.
The Hill Cipher uses an area of mathematics called Linear Algebra, and in
particular requires the user to have an elementary understanding of matrices. It also
make use of Modulo Arithmetic (like the Affine Cipher). Because of this, the
cipher has a significantly more mathematical nature than some of the others.
However, it is this nature that allows it to act (relatively) easily on larger blocks of
letters.
Encryption
To encrypt a message using the Hill Cipher we must first turn our keyword into a
key matrix (a 2 x 2 matrix for working with digraphs, a 3 x 3 matrix for working
with trigraphs, etc). We also turn the plaintext into digraphs (or trigraphs) and each
of these into a column vector. We then perform matrix multiplication modulo the
length of the alphabet (i.e. 26) on each vector. These vectors are then converted
back into letters to produce the ciphertext.
2 x 2 Example
We shall encrypt the plaintext message "short example" using the
keyword hill and a 2 x 2 matrix. The first step is to turn the keyword into a matrix.
With the keyword in a matrix, we need to convert this into a key matrix.
17. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 17
We now split the plaintext into digraphs, and write these as column vectors. That
is, in the first column vector we write the first plaintext letter at the top, and the
second letter at the bottom
Now we must convert the plaintext column vectors in the same way that we
converted the keyword into the key matrix.
Now we must perform some matrix multiplication. We multiply the key matrix by
each column vector in turn.
To perform matrix multiplication we "combine" the top row of the key matrix with
the column vector to get the top element of the resulting column vector. We then
"combine" the bottom row of the key matrix with the column vector to get the
bottom element of the resulting column vector.
18. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 18
Next we have to take each of these numbers, in our resultant column vector,
modulo 26 (remember that means divide by 26 and take the remainder).
Finally we have to convert these numbers back to letters, so 0 becomes "A" and 15
becomes "P", and our first two letters of the ciphertext are "AP".
19. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 19
Encryption process of the first digraph
22. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 22
Decryption
To decrypt a ciphertext encoded using the Hill Cipher, we must find the inverse
matrix. Once we have the inverse matrix, the process is the same as encrypting.
In general, to find the inverse of the key matrix, we perform the calculation below,
where Kis the key matrix, d is the determinant of the key matrix and adj(K) is the
adjugate matrix of K.
2 x 2 Example
We shall decrypt the example above, so we are using the keyword hill and our
ciphertext is "APADJ TFTWLFJ".
Step 1 - Find the Multiplicative Inverse of the Determinant
The determinant is a number that relates directly to the entries of the matrix. It is
found by multiplying the top left number by the bottom right number and
subtracting from this the product of the top right number and the bottom left
number.
23. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 23
We now have to find the multiplicative inverse of the determinant working
modulo 26. That is, the number between 1 and 25 that gives an answer of 1 when
we multiply it by the determinant. So, in this case, we are looking for the number
that we need to multiply 15 by to get an answer of 1 modulo 26.
So the multiplicative inverse of the determinant modulo 26 is 7. We shall need this
number later.
Step 2 - Find the Adjugate Matrix
The adjugate matrix is a matrix of the same size as the original. For a 2 x 2 matrix,
this is fairly straightforward as it is just moving the elements to different positions
and changing a couple of signs.
24. Computer Security & Networks
Dr. Saif Kassim Alfraije Page 24
Again, once we have these values we will need to take each of them modulo 26 (in
particular, we need to add 26 to the negative values to get a number between 0 and
25. For our example we get the matrix below.
Step 3 - Multiply the Multiplicative Inverse of the Determinant by the
Adjugate Matrix
To get the inverse key matrix, we now multiply the inverse determinant (that was 7
in our case) from step 1 by each of the elements of the adjugate matrix from step 2.
Then we take each of these answers modulo 26.
Now we have the inverse key matrix, we have to convert the ciphertext into
column vectors and multiply the inverse matrix by each column vector in turn, take
the results modulo 26 and convert these back into letters to get the plaintext.