Chapter 1: General Security Concepts

Domain 1.0 — General Security Concepts · 16% of the SY0-801 exam

Reading

Controls are not only products. All of these are controls: a written password policy, a locked server-room door, a trained employee, and an intrusion prevention system. The exam expects you to sort controls along two independent axes: Category — how the control is implemented. Type — what the control is trying to do. A single real-world safeguard has one category. It usually has one primary type.

Exam questions love to test whether you can keep the two axes separate.

KEY DEFINITION — Security control.

A safeguard or countermeasure that reduces risk to an asset

1.1.1 Security control categories

The four categories describe the mechanism of the control. Technical controls — also called logical controls. They are implemented in hardware or software. Examples are operating system permissions, firewall rules, encryption, antivirus software, and multi-factor authentication apps.

Technology enforces them. No human makes a judgment call in the moment. Managerial controls — also called administrative controls. They are the policies, procedures, and governance decisions that direct the organization. Examples are a risk assessment, an acceptable use policy, a vendor review process, and a security awareness program's plan.

Decision-makers create them. They tell everyone else what must happen. Operational controls — carried out by people performing day-to-day tasks. Examples: reviewing logs each morning, running backups, onboarding and offboarding users, conducting phishing-awareness training sessions, and performing change-management approvals The distinction from managerial controls is subtle but testable.

Managerial controls — decide. Operational controls — do. The policy that says "logs are reviewed daily" is managerial. The analyst who actually reviews them is performing an operational control. Physical controls — affect the tangible environment.

Examples are fences, gates, locks, badge readers, security cameras, bollards, Faraday cages, and cable locks. They interact with the physical world. They do not interact with data or decisions.

Table 1 — Security control categories

CategoryImplemented byExamples
TechnicalHardware or softwareFirewall rules, disk encryption, MFA, OS permissions, antivirus
ManagerialPolicy and governance decisionsRisk assessments, security policies, vendor reviews, awareness program planning
OperationalPeople doing recurring tasksLog reviews, backups, user provisioning, training delivery, change approvals
PhysicalTangible barriers and sensorsLocks, fences, cameras, badge readers, bollards, Faraday cages
EXAM TIP

Use this test: Operational — a person follows a procedure to enforce the control. Managerial — the control is the written policy itself. Questions that describe "a policy requiring X" are almost always testing the managerial category. This is true even if X is a technical action.

1.1.2 Security control types

The six types describe the control's intent — its relationship to an incident in time and purpose. Preventive controls — stop an incident before it happens. Examples: a firewall blocking a port, an application allow list refusing unknown software, and encryption making stolen data unreadable. This is the type organizations want most. Preventing an incident is cheaper than responding to one.

KEY DEFINITION — Preventive control.

A control type that stops an incident before it occurs

Detective controls — identify an incident while it is happening or after it has occurred. Examples are log monitoring, intrusion detection systems (IDS), security cameras recording a hallway, and file-integrity monitoring.

A detective control does not stop anything by itself. It creates the signal that triggers a response. Corrective controls — fix a system after an incident and restore normal operations. Examples:

Corrective controls close the loop: detect, respond, repair.

Compensating controls — substitutes used when the primary control cannot be implemented. Example: a legacy application cannot support multi-factor authentication. Place it behind a jump server that does support MFA. Restrict it to a dedicated VLAN.

You have not fixed the application. You have compensated for its weakness with a different control. The new control achieves a similar risk reduction. Compensating controls appear frequently in compliance work. A standard may demand a control that is technically impossible on a particular system.

Deterrent controls — discourage an attacker from trying in the first place. Examples are warning banners on login screens, visible security cameras, guard dogs, and the credible threat of prosecution. They work on the attacker's decision-making. They do not work on the attack itself.

So the same camera can be both: Deterrent — people see it and behave. Detective — its recordings identify what happened. The exam classifies by the purpose stated in the scenario. Directive controls — tell people what they must or must not do.

Examples are policies, procedures, standards, signs ("Authorized Personnel Only"), and mandatory training. A directive control has no technical enforcement behind it. Compliance depends on people reading, understanding, and obeying. So directive controls are usually paired with preventive or detective controls that verify obedience.

Table 2 — Security control types

TypeGoalTimingExamples
PreventiveStop the incidentBeforeFirewall rules, encryption, allow listing, access control
DetectiveFind the incidentDuring / afterIDS, log review, cameras, file-integrity monitoring
CorrectiveRestore and repairAfterBackups restored, patches applied, systems re-imaged
CompensatingSubstitute for an impossible controlOngoingJump server in front of a legacy app, network segmentation for an unpatchable system
DeterrentDiscourage the attemptBeforeWarning banners, visible cameras, prosecution notices
DirectiveInstruct behaviorOngoingPolicies, procedures, mandatory training, signage
EXAM TIP

The same product can be different types in different scenarios. IPS — an intrusion prevention system that blocks traffic is preventive. IDS — an intrusion detection system that only alerts is detective. Read what the scenario says the control does. Do not rely on what it is called.

Consider a small clinic rolling out a new patient-records system. One project uses many controls: encrypts the database — technical, preventive; writes a policy requiring unique accounts — managerial, directive; help desk verifies identity documents before resetting passwords — operational, preventive; installs a badge reader on the records-room door — physical, preventive; enables login auditing — technical, detective; and schedules quarterly restore tests from backup — operational, corrective. The exam will hand you exactly this kind of mixed list. It will ask you to classify individual items.

Practice naming both axes for every control you meet in daily life. This section of the exam then becomes free marks.

1.1.3 Zero trust: never trust, always verify

Traditional network security drew a hard boundary — the perimeter. It trusted everything inside it. That model collapsed for three reasons: Employees work from anywhere. Applications live in the cloud rather than in your building. Attackers who breach the perimeter once can then move sideways (laterally) through a soft, trusting interior.

Zero trust is a security model built on the opposite assumption. No user, device, or network location is trusted by default. Every request for access must be authenticated, authorized, and continuously evaluated. This includes requests coming from inside the office.

KEY DEFINITION — Zero trust.

A model that trusts no user, device, or network location by default and verifies every request

Zero Trust Architecture (NIST SP 800-207): Control Plane vs. Data Plane CONTROL PLANE (Trust Evaluation & Session Policy) Policy Engine (PE) Evaluates identity, device posture & threat intel Policy Admin (PA) Establishes or shuts down session tokens Telemetry Signals • IdP & MFA / Passkey • Device Health / MDM • SIEM & Threat Feeds • Geo / Risk Context DATA PLANE (Untrusted Zone → Explicit Verification → Protected Resource) Subject & Endpoint Untrusted by default Policy Enforcement Point PEP (Gateway / Micro-proxy) Enterprise Resource App / API / Data
Figure 2 — Zero Trust Architecture separating the Control Plane (PE/PA) from the Data Plane (PEP).

Above it, on the control plane, the policy engine decides using inputs such as identity, device posture, and threat intelligence, while the policy administrator configures the session if access is approved. Nothing is trusted because it is inside the network. Every request is verified, every time, and access is granted only to that specific resource.

Three principles define zero trust: Verify explicitly — use every available signal to decide each request. Signals include identity, device health, location, and behavior. Use least-privilege access — grant the minimum permissions needed. Grant them ideally just in time and for a limited duration.

Assume breach — design as if attackers are already inside. Segment aggressively, encrypt everywhere, and monitor everything. This limits the "blast radius" of any single compromise. Architecturally, zero trust implementations are described with two planes: Control plane — the decision-making layer. It evaluates policies and signals. It decides whether a request should be allowed.

Data plane — where the actual traffic flows. It holds users, devices, applications, and the resources they access. Separating the planes matters. The control plane's components can be reasoned about individually. The exam tests them individually.

The control plane contains two logical components: Policy engine (PE) — the brain. It takes the request, the identity information, device posture, threat intelligence, and the organization's access policies. It makes the trust decision: allow, deny, or allow with restrictions.

Policy administrator (PA) — carries out the engine's decision. It generates or updates the credentials, tokens, or session configurations needed to establish the connection. It instructs the enforcement point to open or close the path. Policy enforcement point (PEP) sits in the data plane, in front of each resource (or group of resources). It is the gatekeeper. It forwards the request. It permits the session once the administrator tells it to. It can terminate the session if trust changes.

A typical flow works like this: A user requests a database. The PEP intercepts the request and asks the policy administrator. The administrator consults the policy engine. The engine evaluates the signals and decides. The administrator provisions the session.

The PEP allows the flow and keeps monitoring it.

KEY DEFINITION — Policy engine.

The zero trust control-plane component that makes the trust/access decision.

In real products these components are rarely three separate boxes — they are logical roles inside an identity-aware proxy, a ZTNA (zero trust network access) service, or a cloud access broker — but the exam tests the roles, not the packaging.

EXAM TIP

Remember the three roles: Policy engine — decides. Policy administrator — acts on the decision. It configures the session and instructs the gate. Policy enforcement point — enforces the decision in the data path. If a question asks "which component makes the trust algorithm decision?" — that is always the policy engine.

Zero trust also leans on supporting capabilities. You will meet them in later chapters: strong identity and MFA, device certificates and posture checks, micro-segmentation, and continuous logging. Its companion concept is the opposite number in legacy designs: implicit trust based on network location.

Exam questions often present a flat network with a hard firewall. They ask what is wrong with it. The answer they want: everything inside is trusted. So a single breach exposes all of it.

1.1.4 The CIA triad

The CIA triad is the oldest model in security, and it defines what "secure" means for information:

CIA Triad, Non-Repudiation & Security Control Matrix (SY0-801 Obj. 1.1) CONFIDENTIALITY INTEGRITY AVAILABILITY Protected Data & Systems 4 Control Categories × 6 Functional Types Categories: Technical · Managerial · Operational · Physical • Preventive: Firewalls, MFA, encryption, mantraps (stop attack) • Deterrent: Warning banners, signage, visible cameras • Detective: SIEM alerts, IDS, audit logs, motion sensors • Corrective: Patching, EDR isolation, restoring backups • Compensating / Directive: Virtual patch; AUP & SOPs
Figure 3 — The CIA Triad and the 4×6 security control classification matrix (SY0-801 Obj. 1.1).

Confidentiality at the top means only authorized people see data, achieved with encryption and access control. Integrity at the bottom left means data is accurate and unaltered, checked with hashing and digital signatures. Availability at the bottom right means systems and data are there when needed, supported by redundancy and backups. Weakening one corner weakens the whole model, so good designs consider all three together rather than protecting secrecy alone.

Confidentiality — information is accessible only to those authorized to see it. Encryption, access control lists, and classification schemes protect confidentiality. A leaked customer database is a confidentiality failure.

Integrity — information is accurate and has not been altered without authorization. Hashing, digital signatures, and file-integrity monitoring protect integrity. An attacker quietly changing account balances is an integrity failure, even if nothing was "stolen." Availability — information and systems are usable when authorized users need them.

Redundancy, backups, load balancing, and DDoS protection protect availability. Ransomware that encrypts a hospital's systems is an availability failure (and usually a confidentiality one too).

KEY DEFINITION — Confidentiality.

Ensuring information is accessible only to authorized parties.

Every security decision is a trade among the three. Example: encrypting everything with keys stored in one place strengthens confidentiality. But it creates an availability risk if that place fails.

Publishing data openly maximizes availability. It destroys confidentiality. When a scenario asks which leg of the triad a control or an incident concerns, anchor on the harm: Confidentiality — was data seen by the wrong people? Integrity — was data changed?

Availability — could legitimate users not get to it?

1.1.5 AAA: authentication, authorization, and accounting

AAA Security Framework: Authentication, Authorization & Accounting (Obj. 1.1) 1. Identification Claims who you are Username · Email Badge ID · Device Cert 2. Authentication Proves the identity FIDO2 Passkey · MFA Smart Card · Biometric 3. Authorization Enforces permissions RBAC · ABAC · ACLs Least Privilege / JIT 4. Accounting Tracks every action SIEM · Audit Trails RADIUS / TACACS+ Logs Exam Clue: RADIUS (UDP 1812/1813, encrypts password) vs. TACACS+ (TCP 49, encrypts full packet & separates A-A-A)
Figure 4 — AAA pipeline from identification through authentication, authorization, and accounting (Obj. 1.1).

Authentication — proving you are who you claim to be, using factors such as something you know (password), something you have (token or smart card), and something you are (fingerprint). Authentication answers "who are you, really?" Authorization — deciding what the authenticated subject is allowed to do: which files, which applications, which privilege level. Authorization answers "what may you do?" Giving a verified employee access to systems their role does not need is an authorization failure, not an authentication one.

Accounting — recording what the subject did: logons, commands, files accessed, times, and source addresses. Accounting (sometimes called auditing in AAA contexts) creates the trail used for investigations, billing, and compliance. RADIUS and TACACS+, which you will study in depth later, are AAA protocols.

KEY DEFINITION — Authentication.

Proving a claimed identity

Do not confuse authentication with identification. Identification — merely claiming an identity. Example: "I am user jdoe." Authentication — proving the claim. Example: "...and here is my password and my hardware key." A username alone identifies. It never authenticates.

EXAM TIP

If a scenario says a user "logged in successfully but opened a system their job does not require," authentication worked and authorization failed. If a scenario says actions cannot be traced to a person afterward, accounting failed.

One piece of vocabulary belongs to the next domain. A threat actor is any person or group that causes or can cause harm to systems or data. The exam's actor types — nation-state APTs, organized crime groups, hacktivists, insider threats, and script kiddies — differ in resources, sophistication, and motivation, and Chapter 2 compares them in full in section 2.2.1.

1.1.6 Gap analysis: measuring the distance to where you should be

Every control in this chapter raises the same practical question. How do you know whether your organization is actually doing these things — and doing them well enough? The tool for answering that question is a gap analysis.

KEY DEFINITION — Gap analysis.

A comparison of an organization's current security state against a required or desired state, identifying each difference — each gap — so it can be risk-rated, assigned, and closed.

A gap analysis needs two fixed points: The target state — what a standard, framework, regulation, or your own policy requires. The current state — what your controls actually do today, proven by evidence, not by intention. Every difference between the two is a gap. A gap is not a complaint. It is a named, measurable risk.

The gap analysis process. Define the target state — the standard or policy you are measuring against. Assess the current state — gather evidence: configurations, scans, documents, interviews, test results. Record each gap — exactly where reality falls short of the requirement.

Rate each gap's risk — a gap on an internet-facing system outranks the same gap on an isolated one. Assign an owner, a remediation, and a deadline for each gap. Reassess after remediation — a gap is closed by new evidence, not by a promise. A worked example.

Your policy requires MFA for every administrator account. That is the target state. An account audit finds that 30% of administrator accounts still sign in with a password alone. That is the current state. The gap is those unprotected accounts. The risk is high: administrator accounts are the first target of password spraying and credential stuffing. The remediation is to enroll the remaining accounts in MFA. The owner is the IAM team lead. The deadline is 30 days. The reassessment is a fresh account audit.

Notice what the gap analysis did. It turned a vague worry — “our MFA rollout feels unfinished” — into a specific, owned, dated piece of work. Gap analysis results feed two places you will meet later in this book: the risk register in Chapter 5, and audit planning. One warning belongs here: a gap you have documented and then ignored is worse than a gap you never found. The document proves you knew.

EXAM TIP

“Compare current controls against the required standard and identify the differences” = gap analysis. The difference between the requirement and reality is the gap — closing it means remediation plus reassessment, not just a report.

1.3.1 Cryptography fundamentals

Cryptography is how we protect data mathematically. You do not need to be a mathematician for SY0-801. But you must know what each primitive does, where it is used, and what breaks it. Start with the vocabulary: Plaintext — readable data. Ciphertext — scrambled data. Encryption — converts plaintext to ciphertext using an algorithm and a key. Decryption — reverses encryption. Modern security obeys Kerckhoffs's principle. The algorithm is public. All secrecy lives in the key.

If your security depends on nobody knowing how the cipher works, you do not have security. You have a secret waiting to leak.

Symmetric vs. Asymmetric Encryption & Hybrid TLS Exchange (Obj. 1.3) Symmetric (Single Shared Secret Key) • Same key encrypts & decrypts (AES-256-GCM, ChaCha20) • Extremely fast — used for bulk data & TLS sessions • Weakness: Secure key distribution; no non-repudiation Key Scaling: n(n−1)/2 keys for n parties Asymmetric (Public / Private Key Pair) • Encrypt with recipient Public Key → Private Key decrypts • Sign with sender Private Key → Public Key verifies • Algorithms: RSA, ECC / ECDSA, ECDHE (Forward Secrecy) Trade-off: Slow for bulk data; solves key exchange Hybrid TLS 1.3 Pattern: Asymmetric (ECDHE + X.509 Cert) negotiates ephemeral session key →Symmetric (AES-GCM) encrypts traffic
Figure 6 — Visual comparison of ECB pattern leakage versus AES-GCM authenticated encryption with unique nonces (Obj. 1.3).

Table 4 — Block cipher modes of operation compared

ECBEach block encrypted independently; no chainingNoneNoSingle random blocks only (for example, encrypting a key); never bulk data
CBCEach plaintext block XORed with previous ciphertext block before encryptionIV must be unique and unpredictableNo — needs a separate MACLegacy TLS, IPsec, and disk encryption; being replaced by GCM
CTREncrypted nonce-plus-counter values form a keystream XORed with dataNonce must never repeat under the same keyNoHigh-speed and random-access encryption; the engine inside GCM
GCMCTR encryption plus a Galois-field authentication tag; AEADNonce (usually 96-bit) must never repeat under the same keyYes — built-in tag, covers AAD tooTLS 1.3, IPsec, SSH, cloud storage — the modern default
ModeHow it worksIV / nonce needsIntegrity?Typical use
CFBPrevious ciphertext feeds back into the cipher to make the next keystream blockUnique IVNoLegacy stream-style encryption of small units of data
OFBCipher output feeds back to make a keystream independent of the dataUnique IV; reuse is catastrophicNoLegacy use on error-prone links; largely displaced by CTR and GCM
ChaCha20- Poly1305ChaCha20 stream cipher plus Poly1305 authenticator; AEADNonce must never repeat under the same keyYes — built-in tagTLS 1.3 on devices without AES hardware acceleration

Read the table the way the exam reads a scenario. Ask three questions: Is integrity built in? Only the two AEAD rows — GCM and ChaCha20-Poly1305 — can answer yes. This is why they dominate every "best choice" question about protecting data in transit.

What does the initialization value demand? Unpredictable for CBC. Never-repeated for the counter-based modes. Nonexistent for ECB. Remember that "nonexistent" is itself the tell for the weakest row in the table. Does the use column match the scenario's era and platform? Legacy protocol descriptions point to CBC. Mobile and software-only performance points to ChaCha20- Poly1305. Anything current and general-purpose points to GCM.

1.3.3 Hashing, salting, and digital signatures

A hash function converts input of any size into a fixed-size output. The output is called a digest or fingerprint. It has three essential properties: One-way — you cannot reconstruct the input from the digest Deterministic — the same input always produces the same digest Collision-resistant — finding two inputs with the same digest should be computationally infeasible. Hashing provides integrity, not confidentiality.

A digest reveals nothing about the content. But it changes completely if one bit of the input changes. So comparing digests detects tampering. File downloads publish SHA-256 digests for this reason. You can verify the file you received is the file the author released.

KEY DEFINITION — Hashing.

A one-way function producing a fixed-size digest used to verify integrity

Key Concept Summary — Hashing, Encryption, and Digital Signatures Compared

SHA-2 (SHA-256, SHA-512) — the current standard family. MD5 — produces a 128-bit digest and is broken. Researchers can manufacture collisions cheaply. A collision means two different files with the same MD5 digest. So MD5 must never be used where collision resistance matters. Examples are verifying software or storing passwords.

It survives only for non-security checksums. Exam questions treat "MD5" as the wrong answer whenever integrity or password storage is the goal. SHA-1 is likewise deprecated for collisions. Storing passwords as plain hashes is still not enough.

Identical passwords produce identical digests. Attackers precompute rainbow tables to reverse stolen databases instantly. A rainbow table is a giant lookup of password-to-hash pairs. Salting defeats this. Here is how salting works: The system generates a unique random salt for each password.

The system stores the salt alongside the hash of (salt + password). At login, the system verifies by repeating the computation. Now identical passwords hash differently per user. Rainbow tables are useless. The attacker would need a table per salt. Cracking must proceed one password at a time.

Slow, deliberately expensive password hashing functions add key stretching. Examples are bcrypt, PBKDF2, and Argon2. Key stretching uses thousands of iterations. One legitimate login costs a fraction of a second. Billions of guesses become impractical.

KEY DEFINITION — Salt.

A unique random value stored with a password hash to defeat precomputed rainbow tables.

A digital signature proves both integrity and authenticity. It proves data came from a specific sender and was not altered. Here is how the sender creates a signature: Hash the message.

Apply the private key to that hash using a signature algorithm. The result is the signature. Use RSA-PSS for RSA keys. Use ECDSA for elliptic-curve keys. This is hash-then-sign. The private-key operation is a signing primitive, not ordinary encryption.

Textbooks often shorten it to "encrypting the hash with the private key." That shorthand is a simplification. With ECDSA there is no encryption step at all. Here is how anyone verifies the signature: Hash the received message. Run the verification algorithm on the signature and that hash. Use the sender's public key.

Check whether verification passes. If verification passes, two things hold. The message is unchanged. Only the private-key holder could have signed it. This also gives non-repudiation. The signer cannot credibly deny signing. Note the direction, because the exam tests it: Signatures — sign with the private key, verify with the public key. Confidentiality encryption — the opposite direction

KEY DEFINITION — Digital signature.

A private-key signature (RSA-PSS or ECDSA) over a message hash, proving authenticity, integrity, and non-repudiation

1.3.4 Key stretching and password storage in depth

Beyond the exam. This section goes deeper than SY0-801 requires; skip it on a first pass if time is short. Salting is only half of safe password storage. The scenario questions SY0-801 actually asks describe a breached database, a hashing choice, or a cracking result. They expect you to reason about why one design survives and another collapses.

That reasoning starts with an uncomfortable fact. General-purpose hash functions are engineered to be fast. For password storage, fast is a defect. Why fast hashes fail for passwords SHA-256 is an excellent hash function — for file integrity.

It was designed for speed. A modern processor can compute millions of digests per second. A single high-end graphics card can test billions of candidate passwords per second against a stolen SHA-256 database. Its thousands of parallel cores suit hashing perfectly.

Human passwords make the attacker's job easier still. People choose from a small, predictable pool: dictionary words and names; keyboard walks; seasons and sports teams; and a capital letter, a digit, and a symbol arranged in familiar patterns. Cracking tools combine two things: Dictionaries of previously breached passwords, which now number in the billions Rule sets that mutate each entry through the substitutions and suffixes humans favor. Against a fast hash, the majority of a typical user database falls in hours to days.

The recovered plaintexts are then replayed against other services in credential-stuffing attacks. Users reuse passwords, so this works. This is the complete failure chain the exam assumes you understand: The algorithm did exactly what it was designed to do.

The passwords were never stored in plaintext. The database still effectively spilled its secrets. So storing passwords with MD5, SHA-1, or a single round of SHA-256 is a wrong answer in any storage scenario. This holds however respectable those functions are elsewhere.

The defense is to change the economics. Make each individual guess expensive. Billions of guesses then stop being cheap. Key stretching: making each guess cost Key stretching — the family of techniques that deliberately makes a password-derived computation slow and resource-hungry.

The core mechanism is iteration: Hash the password once. Hash the result again and again — tens or hundreds of thousands of times. Verifying one login attempt now costs, by design, a noticeable slice of a second. A legitimate server performs that cost once per login. It barely notices it.

An attacker performs it billions of times. The same cost multiplies into years of computation, or a ruinous hardware and electricity bill. Stretching functions expose the cost as a tunable parameter. It may be an iteration count, a cost factor, or a memory size.

Defenders can raise it as hardware improves. The per-guess price then stays roughly constant across the years a database might survive. Most guidance aims for a verification time of a few hundred milliseconds on the defender's own server. A person logging in cannot perceive it. At cracking scale it is devastating.

Two refinements complete the design: Memory-hard — some functions force each guess to use a large amount of RAM. This neutralizes the graphics-card advantage. GPU cores are plentiful, but each has little memory attached. An attacker must buy expensive memory for every parallel guess instead of renting cheap parallel arithmetic.

Salted — every stretched hash is computed over a salted password. Stretching and salting solve different problems. Neither substitutes for the other. WORKED CALCULATION — THE ECONOMICS OF KEY STRETCHING Setup: A stolen database used a single round of SHA-256.

An attacker's rig tests 10 billion guesses per second. The password space has 1 trillion candidates (1,000,000,000,000). Work through the fast-hash case: Divide the password space by the guessing rate: 1 trillion divided by 10 billion. The result is 100 seconds. The whole space is exhausted in 100 seconds.

Now work through the stretched case. The stretching function is tuned so each verification takes 0.25 seconds of comparable computation: The attacker's effective rate falls to roughly 4 guesses per second per unit of hardware. Divide the same 1 trillion candidates by 4 guesses per second.

The result is 250 billion seconds — about 7,900 years on that single unit. The attacker can buy more hardware. But every dollar now purchases four guesses per second instead of ten billion. That change in economics is the entire defense. No secrecy about the algorithm is involved.

This is why "slow on purpose" is a security feature. Raising the cost parameter over time is routine maintenance, not a redesign. Salt, pepper, and what each one actually stops. The exam delights in near-identical definitions. So separate the three ingredients cleanly.

Salt — a unique, random value generated per password. It is at least 32 bits. The modern norm is 64 bits or more. The salt is stored in plaintext beside the resulting hash. It is mixed into the computation. Its uniqueness is what matters: No two users share a salt.

No two identical passwords produce the same stored value. Precomputed rainbow tables become useless. A table would have to be rebuilt for every individual salt. The attacker must attack each account separately. The whole database cannot be cracked in one pass.

A salt does not need to be secret. It does not slow the attacker down. Slowing the attacker down is stretching's job. Pepper — the complement. It is a single secret value, shared across all passwords on a system. It is not stored in the password database.

It lives in a separate, protected location: a hardware security module, a secrets vault, and a configuration store with different access controls. It is mixed into every password computation. Its purpose is breach containment. Suppose attackers steal only the database. The hashes are useless to them because an ingredient is missing. They would also have to compromise the separate store holding the pepper.

The trade-off is operational: Lose the pepper and no password can ever be verified again. So back it up and manage it like a key. Rotating it is a deliberate, planned event. Exam questions test the storage location as the distinguishing fact: Salt — stored with each hash, per user, not secret Pepper — stored separately, one per system, secret

EXAM TIP

Salt versus pepper is a favorite discrimination point: Salt — unique per password, random, stored in the database next to the hash. It defeats rainbow tables and precomputation. Pepper — one secret per system, stored outside the database. It defeats offline cracking when only the database is stolen.

A scenario says "a secret value kept in an HSM and applied to all password hashes." That is describing a pepper, every time. PBKDF2: the standardized workhorse PBKDF2 (Password-Based Key Derivation Function 2) — standardized in RFC 8018. It is the oldest and most widely approved stretching function.

It takes four inputs: a password, a salt, an underlying pseudorandom function — in practice HMAC-SHA-256, and an iteration count. It applies the function that many times to derive the output. Its strengths are ubiquity and compliance: It is available in essentially every platform and cryptographic library.

It is the option most often named in government and enterprise standards. So it is the answer when a scenario stresses regulatory approval or FIPS-validated modules. Current guidance calls for iteration counts in the hundreds of thousands for HMAC-SHA-256. OWASP's cheat sheet has recommended 600,000 iterations. Tune the count so verification lands near the target delay on the server's hardware.

PBKDF2's weakness is architectural. It uses almost no memory. So it parallelizes beautifully on the very graphics cards attackers use. Its per-guess cost advantage over raw hashing is large. But it is smaller than what memory-hard designs achieve.

It remains acceptable and enormously common. For a brand-new system with no compliance constraint, the exam's "best" answer is usually one of the memory-hard successors. bcrypt: salt and cost built in bcrypt — designed in 1999 specifically for password storage. It builds the right practices into the algorithm, so they are hard to omit.

It works like this: It generates a 128-bit salt automatically. It takes an exponential cost factor. The work is 2 raised to the power of the cost. Raising the cost by one doubles the computation time. It outputs a single self-describing string. The string encodes the algorithm version, the cost, the salt, and the hash together.

That packaging matters operationally. The verifier needs nothing stored anywhere else. Suppose the organization later raises its cost factor. Old and new hashes coexist, because each string carries its own parameters. The system simply rehashes at the higher cost the next time each user logs in.

A typical cost of 12 makes each verification take roughly a quarter of a second on modern server hardware. bcrypt's limits are worth knowing at exam depth: It uses only a small, fixed amount of memory (about 4 kilobytes). So it is less resistant to massively parallel hardware than scrypt or Argon2.

It effectively uses only the first 72 bytes of a password. It silently ignores anything longer. Neither limit makes bcrypt a bad answer. It remains a sound, widely deployed choice. But both explain why newer designs exist. scrypt and Argon2id: memory-hard by design scrypt — the first widely adopted design to attack the hardware problem directly.

It requires a CPU cost parameter plus a large block of memory. The memory is configurable and commonly tens of megabytes. It must be filled and accessed in a pattern that cannot be shortcut. An attacker with a graphics card now hits a wall. Each parallel guessing core needs its own large slice of fast memory. Memory is the expensive, space-consuming part of custom cracking hardware.

scrypt appears in cryptocurrency mining designs and older password stores for exactly this reason. Argon2 — the winner of the 2015 Password Hashing Competition. It is the current state of the art and the recommendation for new systems.

It exposes three independent tuning knobs: memory size; iteration count (passes over that memory); parallelism (lanes of work) Defenders can spend whichever resources their servers have. Argon2 comes in variants: Argon2d — maximizes resistance to GPU cracking, but has side-channel exposure. Argon2i — resists side channels, but needs more passes. Argon2id — the hybrid. Its first half of passes uses the Argon2i approach. The rest use Argon2d. It delivers both resistances at once.

Argon2id is the variant standards bodies name. RFC 9106 standardizes it. Current OWASP guidance recommends it first. Suggested starting parameters are around 19 megabytes of memory, 2 iterations, and 1 lane of parallelism. Tune them upward to the server's budget.

For SY0-801, carry this hierarchy: Argon2id is best for new password storage. bcrypt and scrypt are strong. PBKDF2 is the compliance-friendly standard. Any fast general-purpose hash alone is wrong.

Table 5 — Password hashing and key stretching functions compared

FunctionCore mechanismTunable costMemory-hard?Exam notes
PBKDF2Repeats HMAC (usually HMAC-SHA-256) over password and saltIteration count (hundreds of thousands)NoStandardized, FIPS-friendly, most widely approved; parallelizes well on GPUs
bcryptBlowfish-based key setup repeated per cost factor; salt built inCost factor; each +1 doubles the workNo (about 4 KB fixed)128-bit automatic salt; self-describing output string; ignores password bytes past 72
scryptCPU iterations plus large memory blocks accessed unpredictablyCPU/memory cost, block size, parallelismYesFirst mainstream memory-hard design; blunts GPU and ASIC advantage
Argon2idHybrid Argon2 passes over a large memory arrayMemory, iterations, and lanes independentlyYesPassword Hashing Competition winner; the recommended default for new systems
SHA-256 (single round)One fast general-purpose hashNoneNoCorrect for file integrity; a wrong answer for password storage

Storing passwords correctly: the complete pattern

Assemble the pieces into one procedure. An exam scenario will describe this procedure — or conspicuously fail to describe it.

When a user sets or changes a password, follow these steps: The server generates a fresh random salt for that password. The server runs the chosen stretching function with the salt. If a system pepper is used, it is applied from its separate store.

The server stores only the resulting encoded string in the database. The string holds the algorithm, parameters, salt, and hash together. The plaintext password is never stored. It is never logged. It is never emailed. At login, follow these steps: The server retrieves the stored string.

It extracts the parameters and salt. It recomputes the function on the candidate password. It compares the results using a constant-time comparison. The comparison itself must not leak how many leading characters matched. On a successful login, check the stored parameters. Suppose they are below the current policy because the cost factor has been raised. Then follow these steps: Transparently rehash the just-verified password at the new cost.

Replace the stored value. The database then migrates gradually. No password reset campaign is needed. Passwords in transit to the server are protected by TLS. None of this storage care helps if the credential is sniffed on the wire. The whole scheme also assumes defense-in-depth controls from the rest of this chapter. Rate limiting and account lockout work online. Attackers then cannot simply guess through the login page instead of cracking offline.

Note what is absent from the correct pattern: No encryption of the password database with a key the application also holds. Encryption is reversible. Anyone who obtains both the database and the key has every password. Hashing's one-wayness is the point.

No home-grown stretching loop around MD5. Unvetted constructions are a wrong answer whenever a named standard function is offered. No password hints or recovery questions that bypass the store entirely.

EXAM TIP

For any "how should passwords be stored" question, the correct answer combines all three ingredients:

An option stores passwords encrypted with a key held by the same application. Or it hashes them once with SHA-256 or MD5. Either way, it is the distractor, however modern it sounds.

How password stores still fail: pitfalls the exam recycles

Knowing the right functions is only half the tested material. The other half is recognizing deployments that use the right vocabulary and still fail.

Salt reuse — the most common failure. A developer generates one salt for the whole application. Or the developer derives the salt from the username. Every password is then stored under that one salt. Precomputation is back. An attacker builds one table for that single salt and cracks the entire database in one pass.

Uniqueness was the property doing the work. Secrecy or length alone was not. Short or predictable salt — closely related. A four-digit salt, or one drawn from a counter, offers so few variants that per-salt tables remain practical. Stale stretching parameters — a second family of failures.

Examples: a cost factor chosen in 2012 and never raised; an iteration count set to 1,000 because logins "felt slow" in testing; and parameters stored nowhere, so a library upgrade silently changes them and locks every user out. Cost parameters are a maintenance commitment. Review them on the same cadence as the hardware budget.

Leaks around the store — a third failure is architectural rather than cryptographic. The stretched hash is computed correctly. But the plaintext password is written to an application log, echoed in an error message, or transmitted to an analytics service.

The storage was impeccable. The secret leaked around it. Online guessing — remember the online half of the problem. None of these functions stops an attacker who never steals the database at all. Two attacks work this way: Password spraying — tries a handful of common passwords against many accounts through the login page. Credential stuffing — replays breached credentials from another service. Those attacks are answered by different controls: rate limiting, lockout and throttling, breached-password screening at enrollment, and multifactor authentication. These controls come from other sections of this domain.

An exam scenario that describes online guessing is not asking you to pick a stronger hash. The discrimination the exam rewards is matching the defense to the attack surface: Offline cracking — stretching and salting defend the stored database.

Online guessing — throttling and MFA defend the live login. Confusing the two produces the plausible-sounding wrong answers.

1.3.5 Digital signatures in depth: hash-then-sign

Beyond the exam. This section goes deeper than SY0-801 requires; skip it on a first pass if time is short. Digital signatures are often taught with a shorthand — "the private key encrypts the hash." The shorthand is wrong, and the exam expects the real mechanism.

Professional scrutiny — and real implementations — distinguish the algorithms that actually sign from the shorthand used to teach them. A digital signature scheme has three operations: key generation, signing, and verification Signing always begins the same way: The signer runs the message through a cryptographic hash function.

This produces a fixed-size digest. The digest, not the message, is what the signature algorithm processes. This hash-then-sign construction exists for three reasons: Signature algorithms operate on small, fixed-size inputs. Hashing first means a signature over a terabyte file costs the same as a signature over a sentence.

Signing a properly constructed digest is what the security proofs of the schemes actually cover. What happens next depends on the algorithm. "The private key encrypts the hash" is not an accurate description of either mainstream scheme. With RSA signatures, follow these steps: Encode the digest inside a padding structure.

Raise the result to the signer's private exponent. This private-key operation is mathematically similar in shape to RSA decryption. That similarity is why the "encrypt with the private key" shorthand arose. But it is a distinct operation with distinct padding. Treating signatures as encryption leads to real implementation errors.

The modern padding is RSA-PSS (Probabilistic Signature Scheme). It mixes fresh randomness into the encoding on every signature. So signing the same message twice produces two different valid signatures. It also carries a tight security proof.

The older PKCS #1 v1.5 signature padding is deterministic. It is still widely deployed. But standards prefer PSS for new designs. Verification works like this: Reverse the process with the public exponent. Check that the recovered encoding is well formed.

Check that its embedded digest matches a freshly computed hash of the received message. With ECDSA (Elliptic Curve Digital Signature Algorithm), there is no encryption-like operation at all.

Here is how signing works: The signer combines the message digest, the private key, and a fresh random per-signature value. The random value is called a nonce, conventionally k. The signer uses elliptic-curve arithmetic. The result is a pair of numbers, (r, s). Together they are the signature.

Here is how verification works: The verifier uses the signer's public key, the digest, and the pair (r, s). The verifier runs a different computation. The computation succeeds only if the signature was genuinely produced from that digest by the holder of the matching private key.

ECDSA signatures are compact — about 64 bytes for a 256-bit curve. So ECDSA dominates in TLS certificates, code signing at scale, and cryptocurrencies. Its Achilles' heel is that random value k. It must be unique and unpredictable for every signature.

Suppose the same k is ever used for two different messages under one key. The two signatures then leak enough algebra for an attacker to solve for the private key itself. This exact failure is how a famous games console's signing key was extracted. A flawed random number generator caused it.

Modern implementations therefore often derive k deterministically from the private key and the message. Repetition is then impossible unless the message itself repeats. In that case the signature safely repeats too. EdDSA — most commonly Ed25519. It builds that deterministic approach in from the start.

It is fast and produces 64-byte signatures. It is increasingly the default in SSH keys and new protocols. Know the name. Know that it is a signature scheme, not an encryption algorithm. Verification answers three questions at once. The exam maps them onto the security services from the start of this chapter: Integrity — the digest comparison proves it. The message received is bit-for-bit the message signed.

Authenticity — the mathematics tying the signature to the public key proves it. The signature could only have been produced by whoever holds the corresponding private key. Non-repudiation — only one party holds that private key, assuming it was never copied, escrowed, or stolen. So the signer cannot credibly claim someone else produced it.

Notice what a signature does not provide: confidentiality. A signed message is sent in plaintext unless it is also encrypted. Anyone can read it. Indeed, anyone can verify the signature, which is the point. Verification is a public operation requiring no secret.

Exam scenarios routinely mix these up: They offer "encrypt the document with the recipient's public key" as the answer to a signing question. They offer "sign it" as the answer to a confidentiality question. Keep the services separate.

One operational warning completes the picture. Every guarantee above collapses if the verifier accepts a signature under the wrong public key. Signatures in practice therefore ride on the certificate system covered next. The certificate is what binds the verification key to a name worth trusting.

EXAM TIP

Sign with the private key. Verify with the public key. Describe the mechanism as hash-then-sign using RSA-PSS or ECDSA. Do not describe it as "encrypting the hash." Signatures deliver:

Signatures never deliver confidentiality.

Use this guide: A scenario asks for proof of who sent a document and that it was not altered. The answer is a digital signature. A scenario asks that no one else can read it. The answer is encryption.

1.3.6 Digital certificates and PKI

Asymmetric cryptography raises a trust question. A public key is just a number. How do you know the key claiming to belong to your bank really does? Digital certificates answer this. They bind an identity to a public key. A trusted third party vouches for the binding.

The system of parties, processes, and standards that does this is PKI (public key infrastructure).

PKI X.509 Certificate Lifecycle, Trust Chain & OCSP Stapling (Obj. 1.3) 1. Key Pair & CSR Private key stays on server / HSM 2. RA/CA Verify Validates domain or org identity 3. Sign & Issue Intermediate CA signs leaf X.509 4. TLS + OCSP Server staples signed status 5. Renew/Revoke ACME auto-renew or CRL / OCSP Chain of Trust: Offline Root CA (in OS/Browser Trust Store) → Online Intermediate CA → Leaf Server Cert Why OCSP Stapling Wins: Eliminates client-to-CA privacy leak & latency while proving non-revocation inside the TLS handshake
Figure 7 — End-to-end PKI certificate lifecycle, chain of trust, and OCSP stapling verification (Obj. 1.3).

A certificate follows the X.509 standard format. It contains: the subject's identity (such as a domain name), the subject's public key, the issuer's name, a serial number, validity dates, and the issuer's digital signature over all of it. The issuer is a certificate authority (CA). It is an organization such as DigiCert, Let's Encrypt, Sectigo, or your own internal CA.

Your devices trust it because its root certificate is pre-installed in their trust stores. When your browser connects over HTTPS, it validates the server's certificate step by step: Validate the certificate chain up to a trusted root. Check the dates.

Check the name matches the site. Check the certificate has not been revoked, via CRL lists or OCSP. Any failure produces a warning. Users are trained — usually in vain — not to click through.

KEY DEFINITION — Certificate authority (CA).

A trusted organization that issues and signs digital certificates.

The supporting roles and steps matter for the exam. Registration authority (RA) — verifies the requester's identity and eligibility before the CA issues. It offloads identity proofing from the CA.

To request a certificate, follow these steps: The applicant generates a key pair. The applicant submits a certificate signing request (CSR) to the CA. The CSR is a file containing the public key and identity details. It is signed with the corresponding private key.

The private key never leaves the applicant's system. If a process asks you to send your private key to a CA, something is deeply wrong. Validation depth determines certificate class: DV (domain-validated) — proves only that the requester controls the domain. These certificates are automated and cheap. Let's Encrypt issues only DV.

OV (organization-validated) — additionally verifies that a real organization exists and is the applicant. EV (extended validation) — requires the most rigorous vetting of the organization's legal identity. All three encrypt identically. The difference is how much identity assurance stands behind the name in the certificate.

Certificate shapes also vary: Wildcard certificate — for example, *.example.com. It covers one level of subdomains. It is convenient. But one stolen private key exposes every covered host. SAN (subject alternative name) certificate — lists multiple specific names in a single certificate. The names may span different domains.

Self-signed certificate — signed by its own subject rather than by a CA. Browsers do not trust it by default. It suits internal systems, labs, and development. In those settings the operator controls both ends and can distribute trust manually.

It is inappropriate for public websites. Visitors cannot distinguish it from an attacker's forgery. Certificate pinning — hard-codes an expected certificate or public key inside an application. It is common in mobile apps. The app then rejects even a validly issued certificate if it is not the pinned one. This is a strong defense against compromised CAs and rogue certificates.

The cost is breakage. The app breaks if keys rotate without an app update. Key escrow — storing a copy of a private key with a trusted third party. Encrypted data can then be recovered if the owner loses the key or leaves the organization. It trades a measure of confidentiality for recoverability.

Organizations often apply it to encryption keys. They refuse to escrow signature keys. A signature key held by two parties destroys non-repudiation.

KEY DEFINITION — Certificate pinning.

Hard-coding an expected certificate or key in an app so other certificates are rejected.

One related technology deserves a mention: blockchain. It is an append-only, distributed ledger. Records are chained together with hashes.

Each block commits to the previous block's hash. So altering a historical record invalidates every later block. The change is visible to all participants. PKI-adjacent uses include public, tamper-evident logs of issued certificates and software releases.

The blockchain itself is not encryption. But it is a strong integrity and transparency mechanism.

EXAM TIP

Certificates prove identity, not safety. A phishing site can hold a perfectly valid DV certificate for its own domain. If a question asks what a certificate guarantees, answer this: "This public key belongs to the named subject, as vouched by the CA." A certificate guarantees nothing about the subject's honesty.

1.3.7 Hiding data: obfuscation, steganography, tokenization, and masking

Four techniques protect data by transforming how it is represented, and exam scenarios hinge on picking the right one. Obfuscation — deliberately makes something hard to understand while keeping it functional or recoverable.

Examples are obfuscated source code, packed malware, and a spreadsheet formula buried under nested functions. Obfuscation is not encryption. There is no key. Given time, a determined analyst can reverse it. It raises the attacker's cost. It does not provide cryptographic protection.

Steganography — hides the existence of a message inside something innocuous. Examples: data embedded in the least significant bits of an image, text concealed in audio files, and payloads tucked into whitespace. Encryption announces "there is a secret here that you cannot read." Steganography whispers "there is nothing here at all." Attackers use it to smuggle data out past monitoring. Defenders and watermarking systems use it to trace leaked copies.

Tokenization — replaces a sensitive value with a random substitute, called a token. The token has no mathematical relationship to the original. The real value, say a credit card number, is stored in a secure token vault. Business systems work with the token.

The token is useless if stolen. It cannot be reversed without the vault. Tokenization is a cornerstone of payment-card compliance. It removes real card numbers from most of the environment. Contrast it with encryption: Encryption — an encrypted value can be decrypted by anyone holding the key Tokenization — a token can only be resolved by querying the vault

KEY DEFINITION — Tokenization.

Replacing sensitive data with a random substitute token resolvable only via a secure vault

Data masking — hides some or all of real data while preserving its format. Examples:

Masking protects data in non-production use: training, development, and display. People need realistic-looking data there. They must never see the genuine values.

EXAM TIP

Use these matches: "Replace card numbers with randomly generated values stored in a vault" = tokenization "Show only the last four digits" = masking "Hide a message inside an image" = steganography "Make code hard to reverse-engineer" = obfuscation. None of the four is encryption. Questions will try to get you to call them that.

How the concepts combine: defense in depth

None of these concepts lives alone. Mature security programs deliberately layer controls of different categories and types. If any single control fails, a breach does not follow. This strategy is called defense in depth, or layered security.

Imagine an attacker targeting the clinic from earlier in this chapter. Work through the layers: The warning banner (deterrent) does not stop them. The firewall and allow listing (preventive) slow them. The badge reader (physical, preventive) keeps them out of the records room.

Encryption (preventive) makes the database they copied unreadable. The IDS and log review (detective) reveal the attempt in time to respond. The backups (corrective) restore operations. The incident report feeds a managerial review. The review improves the policy (directive) for next time.

Remove any one layer and the others still provide protection. Remove the variety and the result is different. Ten firewalls and nothing else can all fall to a single firewall bypass. This layering is also why this chapter's frameworks are not competing. The CIA triad, AAA, zero trust, and cryptography are complementary lenses: CIA — tells you what you are protecting AAA — tells you how access is governed Zero trust — tells you where trust is placed: nowhere, by default Cryptography — provides the mathematical machinery that makes confidentiality, integrity, and authentication possible at all. When you reach the later domains — architecture, operations, governance — notice a pattern. The correct answer is often one of this chapter's concepts wearing a specific product's clothing: A question about a SIEM is a detective-control question.

A question about a jump server in front of an unpatchable system is a compensating-control question. A question about an app that rejects a valid certificate is a certificate-pinning question. Learn to translate product language back into concept language. The whole exam then becomes shorter than it looks.

1.3.8 Blockchain and smart contracts in depth

Beyond the exam. This section goes deeper than SY0-801 requires; skip it on a first pass if time is short. Blockchain appears in the exam’s cryptographic integrity concepts, and this section covers its distributed ledger directly, in the depth the questions expect.

Scenario questions assume you can reason about: how the chain resists tampering, how strangers agree on its contents, what a smart contract does once deployed, and where the whole design breaks. The difference between genuine enterprise uses and marketing claims is where the exam lives.

Blocks and hash chaining: tamper evidence by construction. A blockchain is an append-only, distributed ledger. It is a growing sequence of records. The records are replicated across many independent participants. History can be added to, but not quietly rewritten.

The structure that enforces this is the hash chain. Transactions are collected into a block. Each block carries three pieces of connective tissue alongside its transactions: the hash of the previous block's header; a timestamp; and in proof-of-work systems, a nonce the block's creator adjusted to satisfy the network's difficulty rule. The block's own hash is then computed over all of that content, including the previous block's hash.

Follow the consequence carefully. It is the single most tested property: Someone alters a transaction in an old block. That block's contents change, so its hash changes. The next block already stores the old hash as its "previous hash" pointer. So the chain no longer links.

To hide the edit, the attacker must rewrite the next block with the corrected pointer. That rewrite changes that block's hash and breaks the link after it. The attacker must repeat this through every subsequent block to the present day. Tampering is not prevented in the sense of being physically impossible. It is made evident and expensive.

The forged history must be recomputed faster than the honest network extends the real one. Every participant holding a copy can detect the mismatch independently. This is the same integrity logic as the hashing section earlier in this chapter. It is scaled from one file's digest to an entire shared history.

Two supporting structures deserve a sentence each. Merkle tree — transactions inside a block are typically organized this way. Pairs of transaction hashes are hashed together, level by level, up to a single Merkle root. The root is stored in the block header.

Any participant can then verify that one specific transaction is included in a block. The participant checks a short chain of hashes instead of downloading the whole block. Node — because there is no central server, each participant keeps its own copy of the ledger.

A full node stores and independently validates the entire chain. This is what makes the system distributed rather than merely backed up. Exam questions describe blockchain as providing integrity and transparency without a central authority. Three mechanisms are being summarized: the hash chain, the replication, and the independent validation.

Hash Chaining: Why Altering One Block Invalidates Every Subsequent Block Block 0 (Genesis — Valid) Prev Hash: 00000000 Data: Initial Ledger Hash H0: 9a4f...c21e Block 1 (Tampered!) Prev Hash: 9a4f...c21e Data: Edited Amount Old: 4c8d... → New: 7e1b... ✕ Block 2 (Chain Broken) Prev Hash: 4c8d... (MISMATCH) Data: Audit Record Hash H2: Invalidated Editing Block 1 changes H1 to H1' and immediately breaks Block 2's Prev Hash reference. Every downstream block fails integrity verification unless the entire chain is recomputed.
Figure 8 — Cryptographic hash chaining — editing Block 1 changes H1 from 4c8d... to 7e1b..., breaking Block 2 and all downstream blocks.

Consensus: how strangers agree on one history

A shared ledger creates an obvious problem. If anyone can propose the next block, whose version wins? How do honest participants converge on a single history when some participants are malicious?

The answer is a consensus mechanism — the rules by which the network agrees. The two the exam contrasts are proof of work and proof of stake. Proof of work (PoW) — participants called miners compete to solve a deliberately wasteful computational puzzle.

Here is how PoW works: Miners search for a nonce that makes the block's hash fall below a difficulty target. The first to succeed proposes the block. The work itself is the credential. Forging history means redoing all that work faster than the rest of the network combined.

This is designed to cost more than any plausible gain. Bitcoin is the canonical example. PoW's costs are its criticisms: enormous electricity consumption, slow transaction confirmation, and limited throughput. Proof of stake (PoS) — there is no puzzle.

Participants called validators lock up — stake — a quantity of the network's own currency as a bond. The protocol selects validators to propose and attest to blocks, roughly in proportion to their stake. Dishonesty is punished economically. A validator caught signing conflicting histories can have its stake destroyed. This penalty is called slashing.

No computation race exists. So PoS consumes a tiny fraction of PoW's energy. Ethereum's move from PoW to PoS in 2022 cut its energy use by well over 99 percent. PoS also confirms blocks faster. Its corresponding worry is concentration. Influence follows wealth. So a small number of large stakeholders can dominate validation.

Enterprise and permissioned networks often use lighter variants. Recognize them by name: Proof of authority — a small set of known, vetted validators sign blocks. It is fast and efficient, but only as trustworthy as the vetting. Byzantine fault tolerant protocols such as PBFT — known validators vote in rounds.

The chain finalizes once a supermajority agrees. One attack name completes the consensus picture. A 51 percent attack occurs when a single party gains majority control of the consensus resource. That means more than half the mining power in PoW, or a dominant share of stake in PoS.

The attacker can then: outpace honest participants, rewrite recent history, censor transactions, and double-spend — spend the same asset twice. Double-spending works like this: Get one payment accepted. Publish a longer forged chain in which it never happened.

Note the limits. Exam distractors often overstate them. Majority control does not let the attacker: forge other people's signatures, steal assets from arbitrary wallets, and change the protocol's rules. It corrupts ordering and recent history, not the underlying cryptography.

Small, young networks are realistically vulnerable. The largest networks make majority control astronomically expensive. That expense is precisely the security argument for their scale.

EXAM TIP

Contrast the pair cleanly: Proof of work — secures the chain with computational cost and electricity. Proof of stake — secures it with locked-up currency and slashing. A question about majority control, rewriting history, or double-spending is asking about a 51 percent attack.

Remember what even that attack cannot do. It cannot forge a digital signature. Consensus and signatures are separate layers. Public, private, and consortium ledgers "Blockchain" in a scenario is incomplete until you know two things: who may read the ledger, and who may write to it.

Public (permissionless) ledger — Bitcoin and Ethereum are the models. Anyone can download the chain, submit transactions, and participate in consensus. Transparency is total. Identities are pseudonymous addresses rather than names. No administrator can exclude a participant.

Private (permissioned) ledger — restricts participation to an approved set of organizations or users. An operator controls membership. Reads and writes are limited to those granted access. Consensus can use the lightweight voting schemes that only work among known parties. Throughput is far higher, because no puzzle or global competition is involved.

Consortium ledger — the middle pattern. A group of organizations governs it jointly: several banks, or a manufacturer and its suppliers. None of them wants any single member operating the shared record. The exam-relevant trade-off is direct. Permissioning buys privacy, speed, and governance. It costs the decentralization that made the public design trustless.

A private ledger run entirely inside one company is, functionally, a database with extra steps. Questions will sometimes ask you to notice exactly that. Whichever the type, do not let a stem tell you a blockchain provides confidentiality by default.

Public ledgers are transparent to every reader. Even permissioned ones share data with all members. Sensitive fields still need encryption, or they must be kept off-chain entirely. Smart contracts: self-executing code on the ledger. A smart contract is a program stored on the blockchain. Its code executes automatically when predetermined conditions are met. The ledger itself records the execution and its result.

The classic analogy is a vending machine. The rules — insert the price, receive the item — are enforced by the mechanism. They are not enforced by a clerk who might be bribed, delayed, or unavailable. An escrow contract works like this: The contract holds a buyer's payment.

A delivery confirmation satisfying the contract's conditions is recorded. The contract releases the payment to the seller. No intermediary holds the funds. No party can renege after the trigger fires. The contract's code and its execution history live on the ledger. So all parties can inspect the rules in advance. They can verify afterward that the rules ran as written.

This is the genuine innovation: agreements whose enforcement is a property of the platform. It is not a property of courts, counterparties, or trusted middlemen. The same properties create the risks. The exam expects you to name them. Immutability cuts both ways — a deployed contract generally cannot be patched. So a bug in the code is a permanent feature of the system. It is executed faithfully forever.

The canonical disaster is the 2016 DAO incident. A flaw in a contract's withdrawal logic let an attacker drain roughly 3.6 million ether. The attacker did not break any cryptography. The attacker invoked the code exactly as written, in a sequence its authors had not anticipated. The code did what it said, and what it said was wrong.

The community's eventual remedy was rewriting history through a hard fork. A hard fork is a protocol change that splits the chain into two incompatible histories. A soft fork is backward-compatible, by contrast. The remedy itself demonstrated that "immutable" ledgers bend when enough stakeholders agree they must.

Oracle problem — contracts cannot see the outside world. A contract knows only what is already on the chain. Any real-world fact it needs — a price, a delivery, a weather reading — must be supplied by an external data feed called an oracle. The oracle reintroduces exactly the trusted third party the design existed to remove.

If the oracle is wrong, manipulated, or compromised, the contract will execute flawlessly on false facts. The ledger will faithfully immortalize the result. Public code — code on a public chain is visible to everyone, including attackers. Attackers can study it at leisure for the one exploitable path.

Professional practice therefore demands: independent code audits, formal testing, minimal on-chain logic, and upgrade or pause mechanisms designed in from the start. Each of these slightly dilutes the purity of immutability. Each does so in exchange for survivability.

EXAM TIP

Smart contract questions hinge on three phrases: "Self-executing when conditions are met" — the definition "Cannot be changed once deployed" — immutability, a strength for trust and a disaster for bugs "Relies on external data" — the oracle problem. A scenario's contract misfires because a price feed was manipulated. The vulnerability is the oracle. It is not the blockchain and not the cryptography.

Real uses, hype, and how the exam tests it Separate the durable uses from the conference-keynote claims. Blockchain earns its complexity in one setting. Several parties who do not fully trust one another must share one history. None of them controls that history. All of them can audit it.

Supply chain provenance — the textbook fit. Growers, shippers, processors, and retailers each append custody events for a shipment. A contamination recall that once took days of phone calls becomes a query against a shared, tamper-evident record.

Certificate Transparency — applies the same append-only logic to the PKI from this chapter. Publicly auditable logs of every certificate a CA issues make rogue or mistaken certificates detectable by anyone. Other fits share the same shape: multiple writers, mutual distrust, one history. They include: software release integrity, land and credential registries shared across agencies, trade finance among banks, and audit trails that must convince an external regulator. The design fails its cost-benefit test just as predictably in other settings: One organization controls all the writers. A conventional database with digital signatures and a good audit log then delivers the same integrity at a fraction of the cost and complexity.

Throughput demands thousands of transactions per second on a public chain. Personal data must later be erased. An append-only ledger collides head-on with erasure rights such as the GDPR's right to be forgotten. For erasure, the standard mitigation works like this: Store the data off-chain.

Place only its hash on the chain. Deleting the data then leaves a hash that proves nothing about anyone. SY0-801 tests this material conceptually, never as development work. Expect: definitions (ledger, block, consensus, smart contract); property questions (which mechanism makes history tamper-evident — hash chaining; which attack rewrites history — 51 percent); and selection questions (which consensus uses least energy — proof of stake)

Judgment questions complete the set: which proposed deployment actually benefits from a blockchain — the multi-party, low-trust one. You will not be asked to write a contract or compute a hash. You will be asked whether the described system gains anything from the chain at all. The honest answer is usually the point of the question.

Limits and trade-offs: what a blockchain does not give you

Professional judgment about blockchain is mostly judgment about its costs. Collect them in one place. Throughput and latency — the structural costs. Every node validates everything, and consensus takes time. So public chains process a small fraction of the transactions per second that a centralized payment network handles.

A transaction is not final the moment it appears. Prudent recipients wait for several further blocks to bury it. The most recent blocks can still be displaced if a competing chain overtakes them. Storage — grows monotonically.

An append-only ledger held in full by every node is the most expensive possible way to keep a record. So large files, images, and personal data are kept off-chain. Only their hashes are anchored on it. Key management — unforgiving in a way enterprise systems are not.

Control of assets and identities on a chain reduces to control of private keys. There is no help desk and no reset flow. A lost key means permanently lost access. A stolen key means irreversible transfers. The ledger will faithfully execute the thief's properly signed instructions. From the protocol's perspective they are indistinguishable from the owner's.

Governance — the quiet cost. Sometimes the rules themselves must change: to fix a catastrophic bug, comply with a court order, or reverse a theft. A decentralized system has no administrator to do it. It has only the fork process. The community splits, and both histories may continue. The DAO incident produced both Ethereum and Ethereum Classic this way.

None of these limits makes the technology useless. They define its niche. The exam's judgment questions are built from this list. A proposal needs one of these: high throughput, erasable personal data, recoverable credentials, and a single controlling organization. Its correct answer is then usually a conventional database with strong access control, digital signatures, and an audit log. Recognizing that is itself a tested security concept.

Table 6 — Blockchain designs at a glance

DesignWho can read and writeTypical consensusStrengthsWatch out for
Public (permissionless)AnyoneProof of work or proof of stakeNo central control; fully auditable; censorship-resistantTransparent by default; slow; energy cost under PoW
Private (permissioned)Approved members onlyProof of authority or voting (PBFT-style)Privacy, speed, clear governanceTrust rests on the operator; little benefit over a database if one party controls it
ConsortiumA defined group of organizationsVoting among known validatorsShared control among rivals; auditable by all membersGovernance disputes; member compromise affects the whole

Key terms

KEY TERMS AND CORE CONCEPTS

Exercise 1: Control classification scavenger hunt (paper, 20 minutes) THE SCENARIO.

Goal: Find ten real safeguards around you. Classify each one by category and by type. What you need: Paper and a pen. No tools. You can do this walk in your mind. Steps: Walk through your home, school, or workplace. Mentally is fine. List ten safeguards you can find. Examples to get you started: a deadbolt, a phone lock screen, a "no tailgating" sign, a smoke detector, a password manager, a guest Wi-Fi network.

For each safeguard, write down its category: technical, managerial, operational, or physical. Next to it, write its primary type: preventive, detective, corrective, compensating, deterrent, or directive. Pick the two safeguards that were hardest to classify.

Write one sentence explaining the ambiguity for each one. Hint: cameras are usually the hardest — deterrent or detective? Decide based on the purpose you wrote down. Discussion key: Check your work against these decision rules. Any safeguard whose category is "a person doing a task" must be operational.

Any safeguard that is a written rule must be managerial/directive. Exercise 2: See hashing and the avalanche effect (home machine, 15 minutes) THE SCENARIO. Goal: See the avalanche effect for yourself. Change one character, and watch the whole hash change.

What you need: A home computer, a text editor, and a SHA-256 hash tool (commands are given in Step 2). Steps: Create a text file named hashlab.txt. It must contain exactly the line: Security+ is worth it. On Linux/macOS use: echo "Security+ is worth it" > hashlab.txt. On Windows, use Notepad and save it.

Generate its SHA-256 hash: Linux: sha256sum hashlab.txt macOS: shasum -a 256 hashlab.txt Windows PowerShell: Get-FileHash hashlab.txt -Algorithm SHA256 Write the digest down. Change one character in the file. For example, change the "S" to "s".

Hash the file again. Compare the two digests character by character. Count how many characters are the same. Re-save the original file. Hash it a third time. Confirm the digest is identical to Step 2.

On paper: explain in two sentences why this property lets a website prove that a downloaded file was not tampered with. Also explain why a hash alone cannot be used to "decrypt" the file. Discussion key: Check your work against these decision rules.

The two digests in Steps 3–7 look completely unrelated. That is the avalanche effect. The third digest matches the first one exactly. Hashing is deterministic. Exercise 3: Inspect a real certificate (browser, 15 minutes) THE SCENARIO. Goal: Open a real website certificate. Read its key fields and decide what type of certificate it is.

What you need: A web browser and paper to record what you find. Steps: In your browser, open https://www.wikipedia.org. Click the padlock/site-information icon in the address bar. Open the certificate viewer: "Connection is secure" → "Certificate is valid", or similar, depending on browser.

Record the issuing CA. Record the validity dates. Record the subject name. Record the list of names in the Subject Alternative Name field. Answer on paper: Is this a wildcard certificate, a SAN certificate, or both/neither? How can you tell?

Find the certificate's SHA-256 fingerprint. Find the signature algorithm. Decide which algorithm family is used — RSA or ECC. Look at the public key type/ size. In one paragraph, explain what would change in this inspection if the certificate were self-signed. Also explain why your browser would warn you.

Discussion key: Check your work against these decision rules. Decide from the SAN field. The names in the Subject Alternative Name field decide wildcard or SAN. Read the public key. Its type/size decides the algorithm family — RSA or ECC. Self-signed means a warning. Explain what changes, and why the browser warns.

Exercise 4: Salting, demonstrated (paper or home machine, 20 minutes) THE SCENARIO. Goal: Show why two users with the same password get different stored hashes once salts are added.

What you need: Paper, or any hash tool from Exercise 2. The password for this exercise is Sunshine2026!. Steps: On paper (or with a hash tool), take the password Sunshine2026!. Compute or imagine its SHA-256 hash as User A, with no salt. Record it as H(password).

Now suppose User B chooses the same password. Without salt, write down what User B's stored hash is. Write down what an attacker who steals the database immediately learns from seeing two identical hashes. Now add salts. User A's salt is 7f3a. User B's salt is c91d.

The stored values are H(7f3a + password) and H(c91d + password). Explain why the two stored hashes now differ even though the passwords are identical. Finish on paper: explain why a rainbow table built for unsalted SHA-256 is useless against this database.

State the one thing the attacker must now do for each user separately. Discussion key: Check your work against these decision rules. Without salt, both users have the same stored hash. So the attacker can see they share a password. With different salts, the stored hashes differ. One precomputed table no longer works for both users.

PBQ practice Scenario Print this page and complete the task by hand. Meridian Accounting is a 40-person firm. Their current setup: All office computers sit on one flat LAN. Once any device is on the LAN (including the guest Wi-Fi, which shares the same network), it can reach the file server, the tax-software server, and the printers.

The tax-software server is old. The vendor confirms it cannot support multi-factor authentication and cannot be patched against a known vulnerability until next year. Staff share one generic "office" login for the file server. Client tax records (names, national ID numbers, income) are stored in a database.

The support team wants to show clients "only the last four characters" of their ID numbers on screen. The firm is buying a certificate for its new client portal, portal.meridian.example, which will also serve upload.meridian.example and billing.meridian.example.

Your task. For each requirement below, write the control you would implement and classify it by category and type: (a) The old tax server must be protected despite having no MFA and an unpatched vulnerability.

(b) Management wants a written rule that every employee uses a unique account. (c) Someone must notice if the tax server is attacked at 3 a.m. A consultant proposes "zero trust" for the new portal. In the flow "employee → portal → client database," label where the policy enforcement point sits, and state which component decides access and which component configures the session.

Choose the certificate approach for the portal (wildcard, SAN, or three separate certificates) and justify your choice in one sentence. Name the data-protection technique that matches the support team's "show only the last four characters" requirement.

Model answer Part 1 — control selection and classification (a) The primary control — MFA on the tax server — is impossible. So this calls for a compensating control. A sound implementation: Move the tax server onto its own restricted VLAN. Require staff to reach it only through a hardened jump server that enforces MFA.

Set firewall rules permitting only the jump server to talk to the tax server. The jump-server/VLAN arrangement is a technical control. Systems enforce it. Its type is compensating. The scenario's key facts — "cannot support MFA" and "cannot be patched" — are the textbook trigger for compensating.

On an exam, you could also argue preventive for the purpose served day to day. Patching next year, when possible, becomes the corrective/permanent fix. (b) A written rule is a policy: managerial category, directive type. The policy directs behavior. It enforces nothing by itself.

So pair it with two more controls: Technical control — disable the shared account and issue unique accounts Operational control — run a quarterly account review to verify compliance (c) "Notice an attack at 3 a.m." is detection. Do this: Deploy an IDS/host monitoring with alerting on the tax server segment.

Forward logs to a monitored alerting service. The monitoring tooling is a technical control of the detective type. The human who responds is performing an operational task. But the control that notices is technical/detective. Part 2 — zero trust flow 1.

The policy enforcement point sits directly in front of the protected resource. Here, it sits in front of the client database. It typically also sits in front of the portal application. It intercepts every request before it reaches the data.

The three roles work like this: Policy engine — makes the decision. It evaluates the employee's identity, MFA result, device posture, and the access policy. It returns allow or deny. Policy administrator — acts on that decision. It establishes or tears down the session. It issues the token/configuration the PEP needs. It instructs the PEP to permit the flow.

Policy enforcement point — enforces the decision in front of the resource. Engine decides, administrator configures, enforcement point enforces. Part 3 — certificate choice Choose a SAN certificate. It lists three names: portal.meridian.example, upload.meridian.example, and billing.meridian.example. One certificate covers exactly the three named hosts.

A wildcard (*.meridian.example) would also work. But it would cover every current and future subdomain with a single private key. One key compromise would then expose hosts that were never meant to share it. Three separate certificates are valid. But they triple the renewal and management work for no security gain over SAN here.

Part 4 — data protection technique Data masking. Displaying only the last characters of an ID number while hiding the rest is the definition of masking. The format is preserved. The real value is partially concealed. Staff see only what their task requires.

Contrast: if the firm instead replaced the ID numbers throughout its systems with random stand-ins resolved through a vault, that would be tokenization. A display rule is masking.

1.2 Change Management Processes and Security Impact (SY0-801 Obj. 1.2)

In CompTIA Security+ (SY0-801), Change Management is a core Domain 1.0 objective (16% weight). Undocumented, unreviewed production changes cause both security misconfigurations and availability outages. Every production modification — firewall rules, IAM roles, OS kernels, API schemas, or cloud IaC templates — must follow a governed lifecycle:

Security Change Management Lifecycle (SY0-801 Objective 1.2) 1. Request Ticket & Owner 2. Impact Risk & Deps 3. CAB Review Approve / Defer 4. Stage Test Backout Ready 5. Deploy Window / Freeze 6. Document CMDB & Version If Validation Fails (Reversible): Execute Backout Plan Restore last known-good snapshot & versioned config If Rollback Unsafe: Execute Fail-Forward Strategy Deploy rapid corrective hotfix & log emergency CAB review
Figure 9 — End-to-end Security Change Management lifecycle with backout vs. fail-forward paths (Obj. 1.2).

OCSP Stapling, TPM/HSM/KMS & Physical Controls (Obj. 1.1 & 1.3)

OCSP Stapling improves certificate revocation checking by having the web server fetch a CA-signed, time-stamped OCSP response and attach ("staple") it directly to the TLS handshake — eliminating client latency and preventing CAs from tracking user browsing. Hardware roots of trust include the soldered endpoint TPM (sealing full-disk BitLocker/FileVault keys and measured boot), rack/cloud HSM appliances (protecting CA/signing keys), and cloud KMS platforms. Physical preventive controls include interlocking access control vestibules (mantraps), bollards, lighting, and infrared/ultrasonic/pressure sensors.

Digital Signatures (Hash-then-Sign): Integrity, Authenticity & Non-Repudiation SIGNING (Sender) Original Message Document / Patch SHA-256 Hash Fixed-length digest Sign (ECDSA/RSA-PSS) Uses Sender's PRIVATE Key Digital Signature Sent with message VERIFICATION (Any Recipient) Recompute SHA-256 Digest of received message Verify(Digest, Signature, PubKey) Uses Sender's PUBLIC Key (CA-trusted) VALID = Authentic Unaltered & Non-repudiable
Figure 10 — Hash-then-Sign digital signature creation and public-key verification flow (Obj. 1.3).
Cryptographic Algorithm Decision Guide (SY0-801 Objective 1.3) What Security Property Do You Need? File Integrity SHA-256 / SHA-3 One-way keyless digest; verifies downloads/logs Avoid MD5/SHA-1 Passwords Argon2id / bcrypt Unique random salt + key stretching slows brute force Never plain SHA Bulk Data AES-256-GCM Fast symmetric AEAD (conf + int) Disk, DB, TLS data Avoid ECB / DES Key Exchange ECDHE (PFS) Ephemeral keys protect past traffic if priv key leaks TLS 1.3 Standard Non-Repudiation ECDSA / RSA-PSS Hash-then-Sign w/ sender private key; verify w/ public key Unique nonce k!
Figure 11 — Cryptographic algorithm decision tree mapping security goals to exact SY0-801 algorithms (Obj. 1.3).
WORKED EXAMPLE / WORKOUT 1.1 — Classifying Overlapping Security Controls

Scenario: A hospital places a badge-reader mantrap at its server room door, logs every badge swipe to a SIEM, and installs an inline IPS to drop SQLi packets. Step 1 (Category): Mantrap = Physical; SIEM & IPS = Technical. Step 2 (Functional Type): Mantrap = Preventive (stops tailgating); SIEM = Detective (records events); Inline IPS = Preventive (actively blocks traffic). Exam Takeaway: Always distinguish category (how it is built) from functional type (when it acts in the attack timeline).

MAIN NOTE — Zero Trust Control Plane vs. Data Plane (Obj. 1.1)

Never confuse the three NIST SP 800-207 roles: the Policy Engine (PE) evaluates trust and makes the grant/deny decision; the Policy Administrator (PA) opens or terminates the session; both live in the Control Plane. The Policy Enforcement Point (PEP) sits in the Data Plane and enforces the decision on live traffic.

SCENARIO & EXAM TRAP — Rollback vs. Fail-Forward in Change Management

Scenario: During a 2026 payment-gateway schema migration, rolling back after 12 minutes of live transactions would have destroyed 1,400 customer orders. Engineers executed a pre-tested fail-forward hotfix instead. Exam Trap: Standard backout plans are the default—choose fail-forward only when the stem explicitly states rollback would corrupt live data or worsen downtime.

WORKED EXAMPLE / WORKOUT 1.2 — Choosing the Right Cryptographic Control

Match each requirement to the exact SY0-801 algorithm: (1) Encrypt 4 TB of customer backups at rest → AES-256-GCM (fast symmetric AEAD). (2) Prove a firmware update came from the vendor and wasn't modified → SHA-256 + ECDSA Digital Signature (integrity + non-repudiation). (3) Verify a web cert isn't revoked without leaking client browsing to the CA → OCSP Stapling.

TOPIC NOTE — Hashing, Salting & Key Management Rules (Obj. 1.3)

Encryption is reversible (confidentiality); hashing is one-way (integrity). Never store passwords with raw SHA-256—always use a unique per-user salt plus a slow password-hashing function (Argon2id, bcrypt, PBKDF2) to defeat rainbow tables and GPU cracking.

CHAPTER 1 EXAM ESSENTIALS — FINAL REVIEW CHECKLIST

Chapter Summary

Chapter 1 builds the vocabulary every other Security+ domain depends on. Security controls are classified on two independent axes: category — technical, managerial, operational, or physical — and type — preventive, detective, corrective, compensating, deterrent, or directive. Zero trust replaces perimeter trust with “never trust, always verify”: the policy engine decides, the policy administrator configures the session, and the policy enforcement point enforces the decision in the data plane.

The CIA triad defines what is protected — confidentiality, integrity, and availability — while AAA governs access through authentication, authorization, and accounting, which must not be confused with mere identification. The people behind the attacks — threat actors, compared by resources, sophistication, and motivation — are Domain 2 material, covered in full in Chapter 2. Cryptography supplies the machinery: fast symmetric AES for bulk data, asymmetric RSA and ECC for key exchange, signatures, and certificates, and Diffie-Hellman for agreeing a secret over an untrusted channel, with ephemeral variants providing forward secrecy. Hashing with SHA-256 protects integrity, salting defeats rainbow tables, and digital signatures — signed with the private key, verified with the public key — add authenticity and non-repudiation. PKI binds identities to keys through CAs, RAs, CSRs, and X.509 certificates, while tokenization, masking, steganography, and obfuscation hide data in different ways.

Layered together, these concepts form defense in depth. The cryptography coverage in this chapter adds three layers to the fundamentals. First, modes of operation decide what AES actually guarantees: ECB leaks patterns and must never protect bulk data; CBC chains blocks but needs an unpredictable IV, padding, and a separate integrity control, and careless padding errors enable padding oracle attacks; CTR builds a keystream from a nonce and counter, parallelizes fully, and collapses if a nonce ever repeats; and GCM adds an authentication tag to counter mode, making it — with ChaCha20-Poly1305 — one of the AEAD schemes TLS 1.3 requires. Second, password storage is an economics problem: salts are unique, public, and stored per password; peppers are secret, system-wide, and stored separately; and key stretching with PBKDF2, bcrypt, scrypt, or Argon2id makes each guess expensive enough that a stolen database stays uncracked. Signatures follow a hash-then-sign flow using RSA-PSS or ECDSA, delivering integrity, authenticity, and non-repudiation but never confidentiality. Finally, blockchain chains blocks with hashes so tampering is evident, reaches agreement through proof of work or proof of stake, resists rewriting until an attacker holds majority control, and runs smart contracts whose immutability and dependence on external oracles are risks as much as features.

Gap analysis turns these concepts into a working method: define the target state, measure the current state honestly, and treat every difference between the two as a gap — a named risk with an owner, a fix, and a deadline.

End-of-chapter test

1. A company requires all employees to read and sign an acceptable use policy during onboarding. Which control category and type is the policy itself?

A. Managerial, directive
B. Technical, preventive
C. Physical, directive
D. Operational, deterrent

2. A legacy application cannot support multi-factor authentication, so administrators place it behind a jump host that enforces MFA and restrict access to a dedicated VLAN. The jump host arrangement is best described as which control type?

A. Compensating
B. Corrective
C. Detective
D. Deterrent

3. In a zero trust architecture, which component evaluates identity, device posture, and policy to make the final allow/deny decision for a request?

A. Policy administrator
B. Policy enforcement point
C. Policy engine
D. Data plane

4. An attacker breaches a retailer and silently modifies prices in the product database for two weeks before anyone notices. No data was copied out. Which leg of the CIA triad was primarily violated?

A. Integrity
B. Availability
C. Accounting
D. Confidentiality

5. An employee signs in with a password and hardware key, but is then able to open payroll records that their role does not require. Which part of the AAA framework has failed?

A. Identification
B. Authorization
C. Authentication
D. Accounting

6. A security team must choose an algorithm to encrypt a 2 TB database at rest with the best performance. Which is the most appropriate choice?

A. SHA-256
B. RSA with a 4,096-bit key
C. Diffie-Hellman
D. AES-256

7. A company installs a TLS certificate from a public certificate authority on its web server. A customer’s browser trusts the certificate immediately, with no configuration by the customer. What makes this trust possible?

A. The browser contacts the company directly and asks it to confirm the certificate is genuine
B. The certificate chains to a root CA in the browser’s built-in trust store, and each signature in the chain verifies
C. The certificate contains the server’s private key, which the browser uses to verify the server
D. The certificate is encrypted with each customer’s public key before it is sent

8. A developer verifies a downloaded update by comparing its hash to the value published by the vendor. Which statement about this process is correct?

A. A matching digest proves the vendor's server was not compromised
B. Hashing the file encrypts it so it cannot be read in transit
C. MD5 is the best choice because its digests are shortest
D. The comparison provides integrity, because any change to the file changes its digest

9. A messaging app needs to guarantee that a received message was sent by the claimed sender and was not altered. The sender will sign the message. Which key is used to create the signature, and which key verifies it?

A. Sign with the shared symmetric key; verify with the same key
B. Sign with the private key; verify with the public key
C. Sign with the public key; verify with the private key
D. Sign with the recipient's public key; verify with the recipient's private key

10. A payment processor replaces full card numbers in its business systems with randomly generated substitutes. The original numbers are kept in a hardened vault, and systems resolve the substitutes through the vault when needed. Which technique is this?

A. Obfuscation
B. Steganography
C. Tokenization
D. Data masking

11. A penetration tester sends modified ciphertext blocks to a web application and studies whether it answers "invalid padding" or "invalid MAC." By adjusting one byte at a time, the tester recovers the plaintext without ever learning the key. Which weakness is being exploited, and what is the durable fix?

A. The initialization vector is predictable; fix it by keeping the IV secret
B. CBC padding validation acts as a padding oracle; fix it with authenticated encryption such as AES-GCM (or encrypt-then-MAC) and uniform error responses
C. ECB mode leaks plaintext patterns; fix it by salting the plaintext before encryption
D. The key is too short; fix it by moving from AES-128 to AES-256

12. A company still stores password hashes as a single round of SHA-256. An auditor recommends bcrypt with a cost factor of 12 instead. What does the cost factor actually control?

A. The amount of work in the hashing process, so every password guess becomes slower and more expensive
B. Encryption of the finished hash with the server's private key
C. The length of the salt added to each password
D. The length of the output hash, raising it to 512 bits

13. A user's browser reports that a banking site's certificate is properly signed by a trusted CA but was issued to a different hostname. The user asks whether the CA signature alone makes the site safe to use. What is the correct answer?

A. Yes — a valid CA signature is the check that matters
B. Yes — the site is safe as long as the padlock icon is displayed
C. No — the site is unsafe because the certificate uses RSA
D. No — validation also requires that the hostname matches, the certificate is unexpired and unrevoked, and the chain leads to a trusted root

14. A developer implements ECDSA signing but, to save effort, reuses the same random nonce for two different signed messages. What is the consequence of this mistake?

A. Verifiers will reject both signatures as malformed
B. The hash function is weakened to half of its designed strength
C. The signer's private key can be calculated from the two signatures
D. Nothing serious — the signatures simply become deterministic

15. Before deploying a major firewall rule update to production, a security engineer documents a rollback procedure, identifies affected stakeholders, and presents the impact analysis to a formal review group. Which group is responsible for approving or deferring this change?

A. The external compliance auditor verifying annual control effectiveness
B. The human resources department reviewing employee onboarding policies
C. The Change Advisory Board (CAB) evaluating business risk and readiness
D. The Computer Security Incident Response Team (CSIRT) handling triage

16. During a database schema migration, a post-change validation check fails and rolling back the database would cause irreversible data loss. The engineering team deploys a pre-tested hotfix patch to resolve the defect in production instead. Which recovery approach did the team use?

A. A table-top exercise simulating a disaster recovery drill
B. A version freeze halting software repository commits
C. A standard backout plan reverting to the prior snapshot
D. A fail-forward strategy applying a corrective fix ahead

Answer key

1. A — A written policy is a managerial control (it comes from governance decisions), and its type is directive because it instructs people on required behavior; it has no technical enforcement of its own.

2. A — When the primary control (MFA on the application) cannot be implemented, a substitute that achieves a similar risk reduction — here, MFA at a jump host plus segmentation — is a compensating control.

3. C — The policy engine is the decision-maker in the zero trust control plane. The policy administrator carries out the decision by configuring the session, and the enforcement point blocks or allows the actual traffic in the data plane.

4. A — Data was changed without authorization, which is an integrity violation. Nothing was disclosed (confidentiality) and the data remained accessible (availability).

5. B — Authentication succeeded (the user proved their identity), but the system granted access beyond the role's needs, which is an authorization failure.

6. D — AES-256 is a fast symmetric cipher designed for bulk data such as full databases. RSA is far too slow for bulk encryption, Diffie-Hellman only exchanges keys, and SHA-256 is a hash, not encryption.

7. B — Browsers and operating systems ship with a built-in store of trusted root CA certificates. A server certificate is trusted because it forms a chain — through any intermediate CAs — up to one of those roots, and every signature in the chain verifies; the browser also checks the expiry date and revocation status. "The certificate contains the server’s private" is incorrect because a certificate contains the server’s public key; the private key never leaves the server. "The certificate is encrypted with each" is incorrect because the CA signs the certificate so that anyone can read and verify it — it is not encrypted to individual customers. "The browser contacts the company directly" is incorrect because validation happens locally against the trust store, with CRL or OCSP revocation checks; the browser never asks the organization to vouch for its own certificate.

8. D — Hash comparison detects modification: any alteration produces a different digest. MD5 is collision-broken and unsuitable; hashing is one-way and provides no confidentiality; and a matching digest only shows the file matches the published digest, not that the publisher's infrastructure is safe.

9. B — Digital signatures are created with the signer's private key and verified by anyone using the corresponding public key, providing authenticity, integrity, and non-repudiation.

10. C — Replacing sensitive values with random substitutes that only a secure vault can resolve back to the originals is tokenization. Masking would merely hide part of the real value on display while the real value stays in place.

11. B — Distinguishable padding errors turn the server into a padding oracle: each error message tells the attacker whether a guessed byte produced valid padding, so CBC plaintext can be recovered byte by byte. Authenticated encryption (AES-GCM, or CBC with encrypt-then-MAC) rejects modified ciphertext before padding is ever checked, and uniform errors remove the signal. "ECB mode leaks plaintext patterns" is incorrect because ECB's pattern leakage is a different failure and salting is a password-storage technique, not a mode fix. "The initialization vector is predictable" is incorrect because CBC IVs must be unpredictable but are not secret; secrecy would not remove the oracle. "The key is too short" is incorrect because a longer key does nothing against an oracle that never attacks the key.

12. A — Bcrypt's cost factor sets how much work each hashing operation performs (the work doubles with each increment), which is exactly what key stretching is for: legitimate logins stay fast enough, while an attacker testing billions of stolen hashes pays the cost on every guess. "The length of the salt added" is incorrect because the salt is a fixed-size random value whose job is uniqueness per password, not slowness. "The length of the output hash," is incorrect because bcrypt's output size does not grow with the cost factor. "Encryption of the finished hash with" is incorrect because password hashes are not encrypted with an asymmetric key; a server-side secret added to hashing is a pepper, a different control.

13. D — Certificate validation is a bundle of checks: a trusted chain, validity dates, revocation status, and a hostname (subject/SAN) match for the site actually visited. A genuine CA signature on a certificate issued to a different name proves only that some certificate was issued — not that this server is the bank. "Yes — a valid CA signature is the check that matters" is incorrect because the signature is one check among several. "Yes — the site is safe as long as the padlock icon is displayed" is incorrect because the padlock reflects the browser's overall verdict, which here is already a warning. "No — the site is unsafe because the certificate uses RSA" is incorrect because RSA certificates are normal and widely trusted; the algorithm is not the problem.

14. C — ECDSA's security collapses when a nonce repeats: the two signatures give two equations with the same unknown nonce, and solving them reveals the private key — the failure behind real-world key thefts. "Nothing serious" is incorrect because determinism is not the issue (deterministic nonces derived as in RFC 6979 are fine); reuse of one nonce across messages is. "The hash function is weakened to half of its designed strength" is incorrect because the hash function is untouched. "Verifiers will reject both signatures as malformed" is incorrect because both signatures verify perfectly — the damage is silent key exposure, not rejection.

15. C — The Change Advisory Board (CAB) reviews proposed production changes for business risk, technical impact, testing evidence, and rollback readiness before granting approval. Why the others are wrong — A: External auditors assess compliance periodically and do not approve operational changes; B: HR manages personnel policies rather than IT infrastructure changes; D: CSIRT responds to active security incidents rather than governing routine change requests.

16. D — Fail-forward (roll-forward) resolves a failed deployment by applying a rapid corrective patch when rolling back is impossible or riskier than advancing. Why the others are wrong — A: A tabletop exercise is a discussion-based simulation, not a live recovery method; B: A version freeze stops new commits but does not remediate a broken production deployment; C: A backout plan reverts the system to its pre-change state, which would cause data loss here.

Want the full CompTIA Security+ (SY0-801) package?

This guidebook is free to read. Get the full SY0-801 practice exam — 800 questions, 18 PBQs and 3 capstone labs — with the complete PDF and unlimited online access that never expires.

Get SY0-801 Full Access — $10