Question: Exercise: Decrypting a Substitution Cipher (pair) This is a pair exercise to complete with your lab partner Write a C program decode.c which decrypts text

Exercise: Decrypting a Substitution Cipher (pair) This is a pair exercise to complete with your lab partner Write a C program decode.c which decrypts text encrypted by substitution.c For example ? ./decode qwertyuiopasdfghjklzxcvbnm O vql leqktr gy rtfzolzl qfr zit rqka I was scared of dentists and the dark O vql leqktr gy hktzzn uoksl qfr lzqkzofu egfctklqzogfl I was scared of pretty girls and starting conversations Ctrl-d ? -/decode abcdefghijklmnopqrstuvwxyz The identity cipher!! The identity cipher!!! ? ./decode bcdefghijklmnopqrstuvwxyza Uif Dbftbs djqifs jt b tvctfu pg uif tvctujuvujpo djqifs! The Caesar cipher is a subset of the substitution cipher! Ctrl-d Your program will only be tested with an appropriate command line argument but a good programmer would check the command line argument is present and appropriate Manually Cracking a Substitution Cipher This English text was encrypted with a substitution cipher Di jd, vdl'ht xtqa dh 0 qn Vdl rdlwk 0'ss wdkith htqromu omkd ok Styk kd nv dxm rtzoetj Wlk kiqk'j kit royythtmet om dlh dfomodmj Vdl'ht q ndlkiyls Kiqk qndlmkj ydh qmdkith xtta dm nv dxm Mdx 0'n q mdzts nqrt htjdlhetyls 0 jkqhk q eiqom xoki nv kidluilk Kqsa oj eitqf, nv rqhsomu Xitm vdl'ht yttsomu houik qk idnt 0 xqmmq nqat vdl ndzt xoki edmyortmet What was the original text? Hint: use frequency_analysis.c on the encrypted text and compare the frequencies to English letter frequencies and then try your guesses with decode.c When you think your program is working you can use autotest to run some simple automated tests: $ 1511 autotest decode
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
