Courseiva
System SecurityhardMultiple ChoiceObjective-mapped

LPIC-2 System Security Practice Question

An administrator needs to encrypt a large file using GPG with a symmetric cipher and then decrypt it on another system. Which command encrypts the file using AES256 and prompts for a passphrase?

⚠ Common exam trap

Watch out — candidates often confuse `--encrypt` (which implies public-key encryption) with `--symmetric` (which uses a passphrase), leading them to select option B even though it requires a recipient key rather than a passphrase prompt.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

gpg --symmetric --cipher-algo AES256 file.txt

`--symmetric` tells GPG to encrypt the file using a symmetric cipher (i.e., a single passphrase shared between sender and receiver), and `--cipher-algo AES256` selects the AES-256 encryption algorithm. The command will prompt for a passphrase interactively, which is exactly what the scenario requires.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • gpg --clearsign --cipher-algo AES256 file.txt

    Why it's wrong here

    --clearsign creates a clearsign signature.

  • gpg --encrypt --cipher-algo AES256 file.txt

    Why it's wrong here

    --encrypt requires a recipient key; prompts for key not passphrase.

  • gpg --sign --cipher-algo AES256 file.txt

    Why it's wrong here

    --sign creates a signature, not encryption.

  • gpg --symmetric --cipher-algo AES256 file.txt

    Why this is correct

    Symmetric encryption prompts for passphrase; uses AES256.

Quick reference

Symmetric Encryption Algorithm Comparison

AlgorithmKey SizeBlock SizeStatusNotes
AES-128128-bit128-bitCurrent standardNIST approved; WPA3, TLS
AES-256256-bit128-bitCurrent standardPreferred for sensitive / govt data
3DES112-bit effective64-bitDeprecated (2023)Replaced by AES
DES56-bit64-bitBrokenCracked in < 24 h; never deploy
ChaCha20256-bitStream cipherCurrentTLS 1.3, WireGuard

About these practice questions

This LPIC-2 question is part of Courseiva's 507-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This LPIC-2 practice question is part of Courseiva's free LPI certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the LPIC-2 exam.