← Back to 15. Security

πŸ“ Implementation of cryptography

πŸ“– From Operating System β€’ 15. Security β€’ 12 questions available

Practice MCQs for Implementation of cryptography. Test your knowledge with carefully crafted questions across easy, medium, and hard difficulty levels.

πŸ”„ Last updated: 2026-07-27

2
Easy Questions
6
Medium Questions
4
Hard Questions

πŸ“ Sample Questions

Q1. A program allocates a char buffer[64] on the stack and copies user input using strcpy. Which of the following actions will cause the function to return to attacker‑controlled code?

πŸ”Ή A. Provide exactly 64 bytes
πŸ”Ή B. Provide 63 bytes
πŸ”Ή C. Provide 70 bytes
πŸ”Ή D. Provide 0 bytes

πŸ’‘ Difficulty: easy | βœ… Correct: C

Q2. Given a stack frame where buffer occupies bytes 0–79, the saved frame pointer occupies bytes 80–87, and the return address occupies bytes 88–95, how many bytes must the attacker write to reach the return address?

πŸ”Ή A. 80
πŸ”Ή B. 88
πŸ”Ή C. 96
πŸ”Ή D. 72

πŸ’‘ Difficulty: medium | βœ… Correct: B

Q3. An exploit overwrites the return address with the address of buffer[0]. On a system that uses Address Space Layout Randomization (ASLR), why is this approach unreliable?

πŸ”Ή A. ASLR randomizes the stack base making the address unpredictable
πŸ”Ή B. Buffer[0] is always executable
πŸ”Ή C. Return address cannot be changed
πŸ”Ή D. NOP sled prevents execution

πŸ’‘ Difficulty: hard | βœ… Correct: A

⬆️ View all questions in the quiz below

πŸ”— Related Topics

πŸ“ The Security Problem in Operating SystemπŸ“ Program Threats in Operating SystemπŸ“ Trojan horseπŸ“ Trap doorπŸ“ Logic bomb
πŸš€ Start Quiz πŸ“ Practice Mode