Homework 1 – Permutation Cipher in C++The permutation ciphers are used to generate a ciphertext (encrypted text) by re-arranging the position of the letters in a given plaintext.How does it work?Select the block size (n) and a permutation.Divide a given plaintext into blocks of n letters and use ‘x’ as padding, if necessary.Apply a permutation to each block and generate the encrypted ciphertext.For example, for n = 4 and permutation of (2, 1, 4, 3)Unencrypted plaintext is gentlemen do not read each other’s mail [1]1234 1234 1234 1234 1234 1234 1234 1234 1234 1234 gentlemendo not readeachother’smailx2143 2143 2143 2143 2143 2143 2143 2143 2143 2143 egtn elem nod n to r ae dae hco htre s’m iaxlEncrypted ciphertext is egtnelem nodn tor ae daehco htres’m iaxlThe program needs to get the following information from the user:To encrypt: a text file that includes the plaintext, and a block size and the permutationinformation via standard input (keyboard).To decrypt: a binary file that includes an encrypted ciphertext, and a block size and thepermutation information via standard input (keyboard). Here’s what a sample run should look like:> ./PermCipherUsage: ./PermCipher option -i InputFileName -o OutputFileName Options: -e Encrypt-d Decrypt> ./PermCipher -e -i PlaintextFile -o CiphertextFile Welcome to the Permutation CipherSelected Mode: EncryptInput File: PlaintextFileOutput File: CiphertextFilePlease enter the block size (2-8) and the permutation (e.g., 4 2413): 4 2143 Encrypted ciphertext file: egtnelem nodn tor ae daehco htres’m iaxl> ./PermCipher -d -i CiphertextFile -o PlaintextFile Welcome to the Permutation CipherSelected Mode: DecryptInput File: CiphertextFileOutput File: PlaintextFilePlease enter the block size (2-8) and the permutation (e.g., 4 2413): 4 2143 Decrypted ciphertext file: gentlemen do not read each other’s mailThe program should be able to process up to 8 characters at each block with a minimum of 2 characters. Submit your makefile, source code (encrypt.h encrypt.cpp, decrypt.h, decrypt.cpp, main.cpp) and test files to your BitBucket repository.




Why Choose Us

  • 100% non-plagiarized Papers
  • 24/7 /365 Service Available
  • Affordable Prices
  • Any Paper, Urgency, and Subject
  • Will complete your papers in 6 hours
  • On-time Delivery
  • Money-back and Privacy guarantees
  • Unlimited Amendments upon request
  • Satisfaction guarantee

How it Works

  • Click on the “Place Order” tab at the top menu or “Order Now” icon at the bottom and a new page will appear with an order form to be filled.
  • Fill in your paper’s requirements in the "PAPER DETAILS" section.
  • Fill in your paper’s academic level, deadline, and the required number of pages from the drop-down menus.
  • Click “CREATE ACCOUNT & SIGN IN” to enter your registration details and get an account with us for record-keeping and then, click on “PROCEED TO CHECKOUT” at the bottom of the page.
  • From there, the payment sections will show, follow the guided payment process and your order will be available for our writing team to work on it.