Elementary Information Security: Comprehensive Study Guide

Fundamental Security Concepts, Risk Management, and Decision-Making

Security architecture and decision-making depend heavily on the relationships between possession, ownership, and control. In computing, holding a physical device does not guarantee complete administrative authority over its software or data. For example, a personal laptop is possessed, owned, and controlled by the individual, allowing arbitrary software installations. Conversely, a corporate laptop is possessed by an employee but owned and controlled by the enterprise through user access rights. Mobile devices represent a third paradigm: an individual possesses and owns a cell phone, but operational control is retained by cellular carriers, operating system vendors, and application developers. Mobile OS vendors implement ecosystem controls such as application store vetting to filter out malicious software, although telemetry collection, targeted advertising, and background tracking remain prevalent in free applications. To protect third-party privacy, mobile operating systems like Apple iOS block applications from accessing surrounding Media Access Control (MAC) addresses.

Security decisions generally follow three distinct strategies: rule-based decisions, relativistic decisions, and formal risk assessments. Rule-based strategies apply fixed standards regardless of context. Relativistic strategies mirror the security behaviors of peers, which can lead to ineffective security posture or "Security Theater"—measures designed to provide the illusion of safety without mitigating real risk. Formal risk assessment calculates risk dynamically based on specific asset vulnerabilities, threat vectors, and life cycle evaluations. Decision-making throughout an asset's life cycle requires establishing concrete operational goals, identifying system vulnerabilities, selecting countermeasures that balance usability with security, and continuously measuring operational success to recover from disruptions.


Risk management framework

The U.S. National Institute of Standards and Technology (NIST) formalizes security decision-making through the Risk Management Framework (RMF). The standard RMF process comprises seven lifecycle phases:

  1. Prepare: Establish organizational scope, operational context, risk priorities, and resource allocations.

  2. Categorize: Define the information system's boundaries, business goals, security requirements, and potential impact levels.

  3. Select: Choose baseline security controls from published standards (such as NIST Special Publication 800-53) and tailor them to system specifics.

  4. Implement: Construct and configure the system incorporating the chosen security controls.

  5. Assess: Verify through technical testing that the controls operate correctly and satisfy security requirements.

  6. Authorize: Formal executive approval to deploy and operate the information system based on explicit risk acceptance.

  7. Monitor: Continuously track security control performance, analyze system incidents, and evaluate environmental changes.

In rule-based RMF categorizations, systems evaluate potential security failures against the Confidentiality, Integrity, and Availability (CIA) triad. Each security objective is rated by potential operational impact: Not Applicable, Low (noticeable impact), Moderate (significant damage), or High (catastrophic organizational damage). For example, a public-facing promotional website for an e-commerce firm named Amawig possesses a Confidentiality rating of Not Applicable, an Integrity rating of Low, and an Availability rating of Low, because an outage does not prevent sales transactions. Conversely, Amawig's primary e-commerce transaction site requires Moderate ratings across Confidentiality, Integrity, and Availability due to the handling of electronic payment data, pricing controls, and direct revenue dependence.


Proprietor's risk management framework (PRMF)

Because full NIST RMF guidelines cater to government agencies and large enterprises capable of absorbing noticeable financial shocks, smaller enterprises often adopt the streamlined Proprietor's Risk Management Framework (PRMF). PRMF condenses risk management into a four-phase, requirements-driven continuous improvement cycle:

  1. Establish System and Security Goals: Conduct a risk assessment to produce explicit security requirements.

  2. Select Security Controls: Identify existing safeguards and engineer required technical controls.

  3. Validate the Information System: Test implemented controls directly against defined security requirements to confirm risk mitigation before operational deployment.

  4. Monitor Security Controls: Maintain log audit trails and track environmental shifts to update security goals dynamically.

The initial assessment phase within PRMF uses a 6-step quantitative methodology:

  1. Step 1: Identify Assets: Catalog high-value hardware, software, customization, data files, and external accounts that support business goals.

  2. Step 2: Identify Threat Actors and Attacks: Map potential threat agents to generic attack vectors using attack matrices and risk matrices.

  3. Step 3: Estimate Likelihood: Quantify expected attack frequency over a defined time horizon (e.g., annual frequency).

  4. Step 4: Estimate Impact: Calculate single-occurrence financial or time-based recovery costs (replacement hardware, labor hours, lost income).

  5. Step 5: Calculate Relative Significance: Multiply attack impact by likelihood (Significance=Impact×Likelihood\text{Significance} = \text{Impact} \times \text{Likelihood}) and rank risks by total score.

  6. Step 6: Write Requirements: Draft testable security policy statements addressing the highest-ranked risks.


Elements of identifying risks

Risk assessment relies on precise domain terminology. Protected systems are enclosed within a security boundary. Unprotected gaps or flaws in this boundary represent vulnerabilities. The sum of all accessible vulnerabilities and exposed system functions constitutes the attack surface. An external entity attempting unauthorized actions is a threat actor (or threat agent), who utilizes a specific attack vector (methodology) to compromise assets. Defenses, safeguards, or countermeasures are controls deployed to protect the boundary. A system breached by an attacker becomes a compromised system; when multiple compromised systems across networks are centrally controlled by a single adversary, they form a botnet.


Physical boundaries in Alice's store

To demonstrate PRMF application, consider Alice's Arts, a sole-proprietorship retail business operated by Alice. The business relies on a point-of-sale (POS) terminal, a office laptop, financial spreadsheets, online banking, and social media channels. Physical security architecture leverages physical boundaries, applying Least Privilege (restricting physical access to authorized personnel) and Defense in Depth (layering protections so an adversary must breach outer store locks, inner office locks, and hardware anchors to steal assets).

Threat actor profiling classifies threat agents by goals, mode of operation (MO), motivation levels (Unmotivated, Scant, Stealth, Low, Moderate, High), capabilities, and logistical constraints. Adversaries range from individual cyber-criminals (e.g., Kevin Mitnick, Jerry Schneider) and decentralized activist collectives (e.g., Anonymous, LulzSec) to organized cybercrime syndicates (e.g., Clop, Lazarus Group) and state-sponsored Advanced Persistent Threats (APTs) operating under national intelligence or military structures (e.g., NSA, GCHQ, Cozy Bear, Sandworm, Double Dragon).

Risk identification maps adversary types against threat categories (Physical loss/damage, Denial of Service, Subversion, Masquerade, Disclosure, Forgery) using structured matrices.

Attack Matrix for Alice's Arts

Possible Attacks

Shoplifters

Malicious Employees

Property Thieves

Identity Thieves

Botnet Operators

Physical loss

Shoplifting

Shoplifting, Robbing the till

Burglary, Armed robbery



Denial of service



Files lost


Computer crash, Ransomware

Disclosure




Password theft


Subversion





Back door

Masquerade


Social engineering


Identity theft


Forgery


Embezzlement


Bogus purchase


Risk Matrix for Alice's Arts

Assets

Disclosure

Subversion

Forgery

Masquerade

DOS

Physical Damage

Computer hardware and software


✓



✓

✓

Recovery disks and activation keys






✓

Computer customization






✓

Spreadsheets

✓


✓


✓

✓

Online business and credentials

✓


✓

✓

✓


Social media and credentials

✓


✓

✓

✓


By quantifying recovery costs and annual attack frequency, Alice calculates annual risk significance scores to prioritize capital expenditure and operational requirements.

Quantitative Risk Impact Calculations for Alice's Arts

Computing Asset

Attack Vector

Single Impact ()</p></th><thcolspan="1"rowspan="1"style="text−align:center;"><p>Likelihood(PerYear)</p></th><thcolspan="1"rowspan="1"style="text−align:center;"><p>AnnualSignificance()</p></th><th colspan="1" rowspan="1" style="text-align: center;"><p>Likelihood (Per Year)</p></th><th colspan="1" rowspan="1" style="text-align: center;"><p>Annual Significance ()

Computer hardware and software

Physical damage

$1,500.00

1.1700

$1,755.00

Recovery disks

Physical damage

$200.00

1.1700

$234.00

Spreadsheets

Physical damage

$75.00

1.1700

$87.75

Computer customization

Physical damage

$25.00

1.1700

$29.25

Computer hardware and software

Subversion

$150.00

0.0833

$12.50

Online business and credentials

DoS

$25.00

0.3333

$8.33

Online business and credentials

Identity theft

$100.00

0.0490

$4.90

Computer hardware and software

DoS

$50.00

0.0833

$4.17

Spreadsheets

Disclosure

$75.00

0.0208

$1.56

Social media and credentials

Identity theft

$50.00

0.0208

$1.04

Social media and credentials

DoS

$25.00

0.0208

$0.52

Based on calculated significance, Alice formalizes security requirements using testable, positive language containing mandatory regulatory terms (e.g., "shall"):

  • Requirement 1: The store shall be locked up when no store employees are present. (Addresses physical damage/theft)

  • Requirement 2: There shall be insurance to cover risks of theft, fire, and natural disasters. (Addresses physical damage recovery)

  • Requirement 3: POS shall be physically secured to the sales counter. (Addresses hardware theft)

  • Requirement 4: Only Alice or a trusted sales clerk is allowed to change the POS configuration. (Addresses subversion and unauthorized manager overrides)

  • Requirement 5: Alice's laptop shall be locked in her office when she is not in the store. (Addresses insider and laptop theft risks)

Security analysis presents distinct ethical and legal challenges depending on whether vulnerability discovery is authorized, unauthorized, or unplanned. Authorized testing requires written scope approval, non-disruptive execution, and strict report confidentiality. Unauthorized testing risks violating anti-hacking statutes, such as the U.S. Digital Millennium Copyright Act (DMCA), national security secrecy laws, or corporate Acceptable Use Policies (AUP). Responsible disclosure practices dictate that security researchers report vulnerabilities confidentially to system vendors, allowing a 30-to-45-day remediation window before public disclosure.

File System Architecture, Ownership, Access Control, and Vulnerabilities

Modern operating systems organize stored data into hierarchical directory trees (folders) where every file is designated by a unique path name. Access decisions rely on subject identity validation established during login. Operating systems attach user ownership to files upon creation and enforce access permissions whenever a process attempts interaction.


Bob's processes inherit his identity and access rights

Process ownership dictates runtime file access. When a user logs in, the operating system's authentication service initializes user-level execution environments. Any process executed by a user inherits that user's security context and access rights. As illustrated in process execution flows, when user Bob logs in, the primary system login process (owned by System) spawns Bob's graphical user interface (GUI) process (owned by Bob). When Bob launches a word processor, the resulting application process inherits Bob's identity (Owner: Bob). Consequently, this process possesses Read and Write (RW-) permissions over Bob's personal essay file, but cannot access files restricted to other subjects.


Directory and file ownership

File systems maintain explicit ownership structures across directories. The root directory of a hard drive is owned by the System account and contains top-level directories such as bin, bob, etc, and suitemates. Subdirectories created within user spaces, such as Bob's personal directory containing files essay.doc and surv.doc, inherit or explicitly assign Bob as the owner. Access rights over stored resources govern CRUD operations (Create, Read, Update, Delete). On directory structures, an Update permission grants the authority to delete or add contained files. Default security settings or dynamic folder inheritance assign initial access rights to newly created files.

Executable files are categorized into binary executables (compiled machine instructions executed directly by the CPU) and script files (text code evaluated by an interpreter). Binary executables follow structured binary formats.


Executable file format

A binary executable file consists of a File Header containing a Magic Number (a unique byte sequence identifying file format), Program Size data, and layout specifications for data sections, followed by the machine instructions comprising the program binaries. To execute programs, the operating system requires an explicit Execute (X) access right.


Bob executes the word processor to edit his essay

When Bob executes a word processor binary owned by System, the CPU loads the executable's read-only control section into memory with Read-Execute (R-X) permissions. The spawned process running under Bob's identity allocates a separate data section in RAM with Read-Write (RW-) permissions, enabling the process to read the binary instructions while modifying Bob's document file.


A virus infection in an executable program file

Malicious software (malware) targets executable files to subvert execution contexts. A computer virus is malware that attaches its code to legitimate executable programs, spreading across files when the host program runs. Infection vectors include application executables, storage boot sectors, removable USB media, and email attachments. Mechanically, classic file infection modifies the target binary's entry point: the original entry instruction is replaced with a JUMP to Virus instruction, redirecting CPU execution to malicious machine code appended to the file. After running payload operations, the virus executes the relocated original instruction and executes a JUMP back instruction to resume original program flow without user detection.

Modernized infections often use wrapper techniques. An attacker wraps a legitimate application binary in a malicious loader. When invoked, the wrapper executes two distinct background processes: Process 1 executes the malware payload silently in the background, while Process 2 starts the host application normally to conceal infection. Prominent malware families illustrating subversion include Conficker (or Downadup, exploiting Windows vulnerabilities to build spam/malware botnets), ZeuS (engineered for financial credential theft), and Stuxnet (a highly sophisticated cyberweapon that subverted industrial control logic in Iranian nuclear enrichment centrifuges).

System security policies balance resource availability against multi-user isolation. Generic system risks include Denial of Service, Extortion, Subversion, Masquerade, Disclosure, and Forgery. Operating systems enforce global baseline policies that are subsequently modified through tailored exception rules:

  • Global Isolation Policy: Restricts user data files to private access by default, preventing multi-user exposure.

  • Global Sharing Policy: Grants general read-only visibility across user data files by default while blocking unauthorized modification.

Baseline System Policy Statements for Shared Systems

Requirement #

Policy Requirement Statement

Mapped Threats

1

All users shall be able to execute customary application programs and operating system service programs.

Denial of Service (1)

2

Each user shall have a separate login and, optionally, a password.

Masquerade (4)

3

Programs shall be protected from damage or other modifications by regular users.

DoS (1), Subversion (3)

Global User Isolation Policy

Requirement #

Policy Requirement Statement

Mapped Threats

1

All users shall be able to execute customary application programs and operating system service programs.

Denial of Service (1)

2

Each user shall have a separate login and a password.

Disclosure (5)

3

Programs shall be protected from damage or other modifications by regular users.

DoS (1), Extortion (2), Subversion (3), Masquerade (4)

4

Files belonging to one user shall be protected from access (read or write) by other users.

DoS (1), Subversion (3), Disclosure (6)

To address individual security requirements, system policies incorporate specific user conditions:

Additional System Requirements for Bob's Workspace

Requirement #

Policy Requirement Statement

Mapped Threats

5

The system shall have two regular users: Bob and Alice.

Disclosure (5), Disruption (7)

6

Bob shall have a password to protect his login.

Extortion (2), Disclosure (5), Subversion (6), Disruption (7)

7

Alice shall have a password to protect her login.

Denial of Service (1)

Global File Sharing Policy

Requirement #

Policy Requirement Statement

Mapped Threats

1

All users shall be able to execute customary application programs and operating system service programs.

Denial of Service (1)

2

Each user shall have a separate login and a password.

Disclosure (5)

3

Programs shall be protected from damage or other modifications by regular users.

DoS (1), Masquerade (4)

4

Files belonging to one user shall be readable by other users.

Denial of Service (1)

5

Files belonging to one user shall be protected from writing by other users.

DoS (1), Masquerade (4), Subversion (6)

Operating system access controls implement the fundamental principle of Deny by Default, granting zero initial access rights and explicitly enabling necessary privileges to enforce Least Privilege.


Access rights to executable files

Access matrix architectures cluster permissions by subject column or resource row:

  • Capability-Based Security (Column Clustering): Access rights are attached to active entities (users or processes). Capabilities act like digital key-rings or access tickets; possession of the capability grants immediate access to the referenced resource.

  • File Permissions (Row Clustering): Access rights are attached directly to system resources (files, directories, devices). The resource maintains a record of authorized subjects and corresponding access rights. Standard implementations include Unix permission flags and Windows/macOS Access Control Lists (ACLs).

Compact access rules represent logical file permissions by defining file ownership and non-owner ("World") access rights.


Access rights to personal files
Compact Access Rules for the Isolation Policy

Rule #

Target File Type

Assigned Owner

World Access Rights

Derived Requirement

6

Executable programs

System

R-X

3, 4

7

Bob's data files

Bob

---

5

8

Bob's directory

Bob

---

5

9

Alice's data files

Alice

---

5

10

Alice's directory

Alice

---

5

Information transitions through four operational states: Storage state ("data at rest" on persistent media), Processing state (data active in volatile RAM/CPU cache), Transmission state ("data in motion" across communication networks), and Transit state (physical movement of backup media between facilities).


Information states of the essay file

System patch management mitigates vulnerabilities discovered during software operation. When a security flaw is identified, a race begins between developers engineering a patch and adversaries crafting exploit code. The duration between exploit availability and patch deployment is the window of vulnerability.


Timeline for attacking unpatched flaws

The software patching process transitions through distinct operational states:


Software vulnerability state diagram
  1. Flawed State: Software contains an unmanaged security vulnerability.

  2. Patchable State: The software vendor releases an official security patch before an exploit is publicly engineered.

  3. Unprotected State: An active exploit is developed before a vendor patch becomes available.

  4. Vulnerable State: An exploit is publicly active while a released patch remains uninstalled on local systems.

  5. Hardened State: The security patch is deployed, verified, and tested, remediating the flaw.

System hardening reduces attack surfaces by disabling unnecessary services, altering default configurations, and applying security baselines such as Center for Internet Security (CIS) Benchmarks or DISA Security Technical Implementation Guides (STIGs). Failure to maintain systems accumulates Technical Debt—the accumulation of legacy, unsupported software, operating systems, or hardware caused by financial constraints or vendor obsolescence.

Advanced File Sharing, Access Control Lists, Administrative Controls, and Monitoring

Tailoring system access policies overrides global isolation or global sharing defaults to grant explicit, granular privileges to individual users or functional teams. Tailoring policies address three sharing scenarios:

  1. Privacy Policies: Override global file-sharing policies to restrict a specific subset of files from general access.

  2. Shared Reading Policies: Override global isolation policies to grant explicit read-only access over specific directories.

  3. Shared Updating Policies: Override either global baseline policy to grant read and write access over shared project spaces.

Engineering a tailored access policy requires answering four technical questions:

  1. Which specific resources are being managed?

  2. Which authorized users require access?

  3. Will the policy enforce Deny by Default or modify existing rights?

  4. What explicit access rights do non-owners ("World") retain?


Sharing files for reading on Microsoft Windows 10

Simple permission flags cannot express complex sharing policies involving dynamic user sets. On Microsoft Windows, simple sharing interfaces manage access lists for folder trees using simplified access roles: Read-only, Contributor, Co-owner, and Owner.

User Groups solve multi-user file sharing by aggregating individual user accounts under a common Group Identifier (GID). While every file maintains a single individual user owner, it also assigns a specific group identity and group permission set. Group administration requires defining named user lists within local account databases or enterprise domain services.

To solve shared access requirements between specific workers (e.g., Bob and Tina collaborating on a surveying project), systems establish project-specific user groups and assign tailored group permissions over shared directories.

Policy Additions for Tailored Sharing of Survey Files

Policy #

Explicit Policy Requirement Statement

Mapped Threats

8

The system shall have a regular user named Tina.

Subversion (4), Disruption (7)

9

Tina shall have a password to protect her login.

Extortion (2), Subversion (3), Disclosure (4), Masquerade (5), Disruption (7)

10

All surveying company files shall belong to the "survey" group.

Disruption (7)

11

Only Bob and Tina shall be members of the "survey" group.

Disclosure (4), Disruption (7)

12

Bob and Tina shall have full access to the "survey" group files.

DoS (1), Disclosure (4), Disruption (7)

Administrative groups streamline system management. Windows and Unix environments assign administrative rights to specialized user groups (e.g., Administrators or wheel). In legacy Unix systems, administrative operations required logging directly into the superuser account (root, UID 0). However, direct root logins eliminate individual accountability because audit logs record actions as root rather than identifying the human operator. Modern POSIX systems mitigate this using privileged execution utilities like sudo or setuid programs, requiring users to authenticate with their personal user ID before executing privileged operations.


MacOS padlock unlocks with an administrator's password

In macOS, administrative modifications require clicking the UI lock icon and authenticating with an administrator password. Similarly, Windows enforces User Account Control (UAC) prompts to prevent background processes from quietly inheriting full administrative privileges.


User Account Control prompt on Microsoft Windows

Operating continuously under privileged administrative accounts creates severe security risks: if an administrator executes a Trojan or infected file, the malware inherits full administrative authority and can compromise the underlying kernel. To enforce Least Privilege, systems mandate temporary privilege elevation via UAC or sudo. Administrators should maintain two distinct user accounts: a standard user ID without administrative rights for daily tasks, and a dedicated administrative ID reserved strictly for system maintenance.

Traditional Unix file systems enforce permission flags categorized into three triads: Owner (u), Group (g), and World/Other (o). Permission sets evaluate Read (r), Write (w), and Execute (x) rights, represented sequentially in terminal outputs as rwxrwxrwx (where a hyphen indicates a denied right).

Executing terminal directory listing commands illustrates permission flag structures:

$ ls -l total 56
-rw-r--r--@ 1 rick ops 4321 Nov 23 08:58 data1.txt
-rwxr-xr-x  1 rick ops 12588 Nov 23 10:19 hello
-rw-r--r--@ 1 rick rick 59 Nov 23 10:18 hello.c

In this output, data1.txt and hello.c are standard data files owned by user rick. The file hello is an executable binary owned by rick and group ops, granting execute rights to the owner, group members, and world users.

To accommodate the surveying collaboration between Bob and Tina, technical controls define directory and file permissions across user contexts:

Security Controls for Shared Project Files

Control #

Resource Target

Assigned Owner

Owning Group

Owner Rights

Group Rights

World Rights

Policy Statement

11

Tina's directory

Tina

Tina

RWX

RWX

---

4, 9

12

Tina's files

Tina

Tina

RWX

RW-

---

4, 9

13

Project directory

Bob or Tina

Survey (Bob, Tina)

RWX

RWX

---

10, 11, 12

14

Project files

Bob or Tina

Survey (Bob, Tina)

RWX

RW-

---

10, 11, 12

15

Executable programs

System

System

RWX

R-X

R-X

1, 3

Permission evaluation logic varies across operating systems, causing potential ambiguity when permission sets conflict. Consider a scenario where user Tina attempts to read a file with the following settings: Owner: Bob (RWX), Group: Survey (no access), World: Read-only (R--). Operating systems evaluate access differently:

  • OpenVMS: Evaluates permissions cumulatively (OR logic). Because World permissions allow Read access, access is GRANTED.

  • Unix / POSIX: Applies the single permission scope closest to the requesting user. Because Tina is an explicit member of group Survey, the system checks group rights first. Because group rights specify no access, access is DENIED.

Access Control Lists (ACLs) resolve permission flag limitations by attaching detailed, arbitrary-length permission entries directly to resources.


macOS ACL for Bob and Tina's shared file

In macOS, ACLs extend POSIX permission flags, allowing custom Read and Write assignments for specific users (e.g., tina, bob, petergregory) and groups (staff), while setting World (everyone) to No Access.


Choosing users for a group in macOS

Group memberships are managed visually through macOS system management interfaces, enabling administrators to bind users to local groups.


Access control list from Microsoft Windows

Microsoft Windows implements ACLs within business and enterprise editions (NTFS file system). Windows ACL entries specify access rights (Full Control, Modify, Read & Execute, List Folder Contents, Read, Write) assigned to local or network domain subjects, with each privilege explicitly declared as Permit or Deny.

Windows evaluates ACL permissions using a deterministic search order:

  1. Explicit permissions defined directly on the target file or directory are evaluated first.

  2. Inherited permissions passed down from parent directories are evaluated next, ordered from closest parent to furthest ancestor.

  3. Within each permission set, Deny rules are processed prior to Allow rules.

  4. Processing terminates immediately upon encountering the first rule matching the requesting subject identity.

Effective ACL construction relies on starting with Deny by Default, granting minimum required Allow permissions, and keeping policy rules simple. When explicit exclusions are required within large groups—such as granting access to a Students group while excluding freshmen—the most efficient configuration applies an explicit Deny rule to a Freshmen sub-group alongside an Allow rule for Students.


Advanced security settings for Windows ACLs

Windows ACLs support dynamic inheritance: modifying permissions on an enclosing directory automatically updates access rights across contained subfolders and files. Inheritance can be explicitly disabled to establish custom security boundaries.


Revised ACL for the survey folder

Disabling inheritance converts inherited permissions into explicit local ACL entries, allowing system administrators to strip system-wide groups and enforce strict project isolation.

Access controls can be bypassed through software subversion exploitation and transitive trust vulnerabilities. Transitive trust dictates that if Subject A trusts Program 1, and Program 1 trusts Program 2, Subject A implicitly trusts Program 2.


Trojan game copies one of the survey files

In a Trojan horse scenario, adversary Eve places a game executable on a shared computer. When Tina or Bob executes the game, the game process runs under the executing user's operational authority. Because Bob's process possesses Read-Write access over his private project spreadsheets, the Trojan game reads Bob's secret files without his knowledge and writes duplicate copies into a directory accessible to Eve. The access control system permits this transfer because the process operates under Bob's valid permissions.

Transitive Trust Permissions Matrix

Resource Target

World Rights

Effective Access by Bob

Effective Access by Eve

Bob's Secret Files

---

RW-

---

Eve's Game Binary

R-X

R-X

RWX

Eve's Copy of Secret Files

RW-

RW-

RW-

Preventative security controls block unauthorized actions, whereas detective controls monitor and record system events to surface active attacks. System monitoring historically uncovered significant security breaches, such as Clifford Stoll's tracking of the "Wily Hacker" (detailed in The Cuckoo's Egg). Stoll, an astronomer managing university systems, investigated a 75-cent accounting discrepancy between system usage logs and user billing records. The investigation uncovered a KGB-sponsored spy in Germany penetrating defense networks; the adversary utilized computing resources that generated OS event entries but suppressed accounting log updates.


Event logging in the operating system

Operating system logging uses a centralized infrastructure shared by software components. System applications generate event descriptors and transmit them to a log input buffer. A background logging service filters out low-significance events, writes filtered records to protected audit logs, and exposes log data to administrators via log viewers.


Windows security event log

Windows systems record operational metrics through the Windows Event Viewer, categorizing events under Application, Security, Setup, and System logs. Log entries capture accurate timestamps, event source names, Event IDs (e.g., Kernel-General Event ID 16/24/1, Kernel-Power Event ID 566), and detailed event parameters.

Organizations maintain log infrastructure to comply with external statutory, regulatory, and industry frameworks, including:

  • PCI DSS: Payment Card Industry Data Security Standard governing credit card processing security.

  • ISO 27000 Series: International standards for information security management systems.

  • NIST RMF / FIPS: Federal Information Processing Standards for government systems.

  • SOX (Sarbanes-Oxley Act): Governance over corporate financial accounting controls.

  • HIPAA: Health Insurance Portability and Accountability Act protecting personal health data.

  • GLBA (Gramm-Leach-Bliley Act): Financial privacy standards for consumer financial institutions.

  • FISMA: Federal Information Security Modernization Act enforcing agency cybersecurity.

Enterprise monitoring aggregates distributed system logs into central log repositories. To correlate events across servers and network appliances accurately, systems synchronize clocks using the Network Time Protocol (NTP) to eliminate clock drift. Enterprise Security Operations Centers (SOC) deploy modern monitoring platforms:

  • SIEM (Security Information and Event Management): Centralizes log ingestion, correlates disparate event data, and triggers alerts based on anomaly signatures.

  • SOAR (Security Orchestration, Automation, and Response): Automates threat remediation playbooks in response to SIEM alerts.

  • TIP (Threat Intelligence Platform): Aggregates global threat feeds to contextualize security events.

  • Threat Hunting: Proactive human analysis seeking Indicators of Compromise (IoCs) within network environments without waiting for automated alerts.

Principles of Cryptography, Ciphers, and File Encryption

Cryptography protects information stored or transmitted in exposed, insecure environments by mathematically transforming readable text into unintelligible formats, ensuring Confidentiality and Integrity.

Historically, physical document protection relied on concealment or manual substitution ciphers. In military communications, confidential orders (assets) face disclosure risks that eliminate tactical surprise. Manual ciphers or electromechanical rotor devices (e.g., WWII Enigma or Typex machines) protected orders during transit, backed by strict key distribution monitoring and device zeroization protocols upon breach.


Procedure diagram of encryption

Encryption transforms readable Plaintext (PP) into scrambled Ciphertext (CC) using an Algorithm and a Secret Key (KK). Decryption reverses the process inside a secure boundary to recover plaintext.

Modern cryptography relies on Kerckhoffs' Principle, which dictates that the security of a cryptosystem must depend entirely on the secrecy of the key, not on keeping the encryption algorithm secret. Expressed by Claude Shannon as Shannon's Maxim: "The enemy knows the system." Algorithm transparency enables global cryptanalytic peer review, while system security is maintained simply by selecting strong, unguessable keys and changing them periodically.


Categories of encryption algorithms

Encryption algorithms are divided into Symmetric (secret-key) and Asymmetric (public-key) categories:

  • Codes: Map fixed words or phrases to arbitrary substitutes (e.g., substituting "Operation Overlord" for a landing plan).

  • Ciphers: Operate on individual letters, characters, or single bits. Ciphers are further classified as Transposition (rearranging character order), Substitution (replacing characters with alternate characters), or Mixed algorithms.


Information states using encryption

File encryption maintains security across lifecycle data states: processing in RAM as plaintext, encrypting prior to entering storage, remaining encrypted on local storage or removable media, and traversing networks in encrypted transmission states.

Cryptanalysis is the science of breaking ciphers to recover plaintext without prior knowledge of the secret key. Cryptanalysis attacks are grouped into three primary tiers:

  1. Known Ciphertext (Ciphertext Only): The analyst possesses only encrypted ciphertext. This represents the most difficult cryptanalytic condition.

  2. Known Plaintext: The analyst possesses matching pairs of plaintext and ciphertext encrypted under the target key.

  3. Chosen Plaintext: The analyst can feed arbitrary plaintext into the target cipher machine and obtain the corresponding ciphertext output.

Classical encryption algorithms illustrate historical cryptanalytic weaknesses. The Caesar Cipher replaces each character with the letter residing three positions forward in the alphabet (e.g., ABCD becomes DEFG, CAT becomes FDW). The Vigenère Cipher applies a polyalphabetic series of Caesar rotations guided by a repeating keyword passphrase.


A metal cipher disk

Vigenère encryption relies on physical or mechanical cipher disks containing concentric alphabet rings. To encrypt plaintext SENDMOREFOOD using keyword stream HUNGRYHUNGRY, each character aligns against the offset specified by the key letter, producing ciphertext ZYAJDMYYSUFB.

The advent of early electromechanical cipher devices like Enigma catalyzed the development of automated cryptanalysis at Bletchley Park, driving the invention of modern electronic computing.

In computer-based cryptography, the U.S. Data Encryption Standard (DES) was introduced in 1975 using a 56-bit symmetric key space (256=72,057,594,037,927,9002^{56} = 72,057,594,037,927,900 or over 72 quadrillion keys). Although computationally secure in 1975, hardware advancements enabled the Electronic Frontier Foundation (EFF) DES Cracker in 1998 to evaluate 92 billion keys per second, breaking DES keys in 3.5 days. By 2012, specialized cloud cracking arrays broke 56-bit DES keys in 26 hours.

In 2002, NIST selected the Advanced Encryption Standard (AES), adopting the Rijndael cipher algorithm. AES supports 128-bit, 192-bit, and 256-bit key lengths. Brute-forcing a 128-bit AES key space (21282^{128}) would require approximately 101910^{19} years using classical computing superstructures.

Future cracking rates driven by hardware performance growth are modeled using Moore's Law estimations: Ratefuture=Ratepast×2future−past1.5\text{Rate}_{\text{future}} = \text{Rate}_{\text{past}} \times 2^{\frac{\text{future} - \text{past}}{1.5}}

Emerging quantum computing architectures pose a threat to current ciphers via quantum cryptanalysis. Adversaries utilize a "store now, decrypt later" strategy—capturing high-value encrypted data streams today to decrypt them once large-scale quantum systems running quantum algorithms become operational.


Vernam's exclusive-or cipher

Modern digital stream ciphers rely on the logical Exclusive-OR (XOR, denoted ⊕\oplus) operation, as embodied in Vernam's cipher. XOR operates at the bit level according to truth table properties: matching bits yield 0, while differing bits yield 1 (0⊕0=00 \oplus 0 = 0, 1⊕1=01 \oplus 1 = 0, 1⊕0=11 \oplus 0 = 1, 0⊕1=10 \oplus 1 = 1).


Encrypting an image with xor

Combining binary plaintext image bits with a pseudorandom keystream using XOR generates an encrypted ciphertext image. XOR offers extreme execution speed and arbitrary stream processing, but requires that keystreams never be reused.


Stream cipher

A Stream Cipher uses a deterministic algorithm seeded by a secret key to generate a pseudo-random keystream. The generated keystream is XORed bit-by-bit against incoming plaintext. Keystreams must be unpredictable to unauthorized parties while remaining reproducible by authorized recipients possessing the matching seed key. Pseudo-Random Number Generators (PRNGs) designed for cryptography must yield cryptographically secure randomness; statistical PRNGs used for physical simulations are insecure for encryption. Weak keystream generation (e.g., RC4 implementation flaws) allows rapid cryptanalytic cracking.


Keystream from a one-way hash

Naively generating a keystream by hashing a secret key once produces a defective, static keystream that repeats identical bit blocks.


Improved keystream from a one-way hash

An improved keystream generator feeds the resulting hash value back into the input of the one-way hash function for every subsequent block, continuously generating unique pseudo-random keystream segments.

The only mathematically unbreakable stream cipher is the One-Time Pad (OTP). A One-Time Pad uses a non-repeating, truly random keystream equal in length to the plaintext message. Sender and receiver must possess identical pads, and each key page must be destroyed immediately after single use. During the Cold War, Soviet intelligence deployed decimal One-Time Pads. Plaintext numbers were encrypted against pad digits using non-carrying addition (Encryption=(P+K)(mod10)\text{Encryption} = (P + K) \pmod{10}) and decrypted using non-borrowing subtraction.

File encryption software solutions include OS-native full-disk encryption utilities (Microsoft BitLocker, macOS FileVault) and third-party file-level applications (PGP, GPG, PKZip).


Security boundaries while decrypting a file

File encryption applications maintain explicit security boundaries during decryption: user selection triggers a read-only executable binary, prompts for key input, processes ciphertext within the process memory space, and writes output to a temporary plaintext file. Proper file sanitization mandates overwriting plaintext storage locations after encryption. While single-pass overwriting suffices for modern magnetic drives, optical media requires physical destruction, and solid-state flash drives require wear-leveling-aware manufacturer sanitization commands.


DVD content protection

Digital Rights Management (DRM) enforces content access restrictions inside consumer electronics. DVD Content Scrambling Systems (CSS) process disc keys within player security hardware to restrict media playback. Modern web video streaming uses DRM architectures such as Widevine, combining hardware-rooted content decryption keys with browser copy-protection modules to prevent video piracy across platforms like Netflix and Amazon Prime.

Key Management, Public-Key Cryptography, Integrity, and Authentication

Key management is the critical foundation of operational cryptography: protecting system keys is simpler than protecting massive volumes of raw data, but presents major organizational challenges. Entities sharing a common secret key form a Cryptonet, where transitive trust binds all members. Key management encompasses four core challenges:

  1. Safely distributing keys to authorized recipients.

  2. Selecting keys possessing sufficient randomness and entropy.

  3. Handling keys in memory and storage to prevent interception.

  4. Protecting keys against physical or technical compromise.

Over time, encrypting large data volumes under a single key exposes ciphertext to cryptanalysis. Systems mitigate this through periodic Rekeying. The safe operational lifespan of a cryptographic key is its Cryptoperiod. Industry standards recommend a maximum 2-year cryptoperiod for rarely used keys, while heavily used keys require frequent rekeying to balance processing overhead against security risk.

Key distribution methods include physical out-of-band delivery (verbal memorization or secure paper coupons) and electronic key exchange algorithms. Generating symmetric bit keys from human-remembered passphrases requires conversion routines.


Using a passphrase for a file encryption key

A simple passphrase conversion routine truncates input strings that exceed algorithm key length specifications or pads short strings with trailing zero bits (0s).


Hashing a passphrase for a file encryption key

A superior approach processes text passphrases through a Cryptographic One-Way Hash Function, deriving a uniform, fixed-bit internal symmetric key regardless of passphrase length.

Effective key handling standards require strict engineering compliance:

  • Support passwords and high-entropy text passphrases.

  • Utilize the entropy across the entire input string without dropping characters.

  • Erase passphrases from volatile RAM immediately after internal key derivation.

  • Restrict unencrypted passphrase storage on persistent hard drives.

  • Suppress terminal screen echo during password entry unless explicitly toggled by the user.

  • Assign unique derived internal keys to individual files rather than reusing keys across file sets.

Key strength depends directly on entropy—larger character selection spaces and longer passphrases expand search spaces, exponentially increasing brute-force work factors. Complex substitution rules (e.g., mi$sIss1ppi) are often difficult to memorize without increasing entropy as effectively as longer, natural-language passphrases.


Reusing the same keystream

Reusing a stream cipher keystream generates catastrophic cryptanalytic vulnerabilities. If two distinct plaintexts (P1P_1 and P2P_2) are encrypted using the identical keystream (KK), XORing the resulting ciphertexts (C1=P1⊕KC_1 = P_1 \oplus K and C2=P2⊕KC_2 = P_2 \oplus K) cancels out the keystream entirely: C1⊕C2=(P1⊕K)⊕(P2⊕K)=P1⊕P2C_1 \oplus C_2 = (P_1 \oplus K) \oplus (P_2 \oplus K) = P_1 \oplus P_2


Eliminating both keystreams with xor

As demonstrated visually, XORing the ciphertext of a text message (SEND CASH) with the ciphertext of a graphic image (Smiley face) completely eliminates both keystreams, outputting an image containing both plaintexts overlaid on top of each other. Historical instances of keystream reuse allowed Allied intelligence to crack Soviet communications in the Venona Project and exposed vulnerabilities in the Point-to-Point Tunneling Protocol (PPTP).


Using a nonce to construct the encryption key

To prevent duplicate keystreams when using identical passphrases, systems introduce a Nonce (Number Used Once) or Initialization Vector (IV). The system combines the user's passphrase with a unique, time-stamped or randomized Nonce prior to running the one-way hash function. This derives a unique internal key and distinct keystream for every encrypted file. The unencrypted Nonce is stored alongside the ciphertext file header to allow proper decryption key derivation.

Advanced key management relies on structural key wrapping and key splitting techniques.


Wrapping a key: The KEK encrypts the CEK

Key Wrapping uses a Key Encryption Key (KEK) to encrypt a randomly generated Content Encryption Key (CEK). The CEK encrypts the underlying data file, while the wrapped CEK is attached directly to the ciphertext file header.


Key splitting with xor

Key Splitting divides a key into separate physical components using XOR logic (CEK⊕KEK=Split Key\text{CEK} \oplus \text{KEK} = \text{Split Key}). Reconstructing the operational key requires combining all split components, enforcing organizational control principles:

  • Separation of Duty: Mandates that a sensitive action requires authorization from two or more distinct individuals (e.g., dual-signatory checks or missile launch protocols).

  • Split Custody: Divides cryptographic key knowledge between multiple custodians so no single person possesses the complete key.


Decrypting a DVD sector

Commercial media protection incorporates multi-tiered key wrapping hierarchies. As shown in DVD sector decryption, a hardware Player Key decrypts a Wrapped Disk Key stored on the disc to yield the Disk Key. The Disk Key decrypts a Wrapped Title Key to yield the Title Key. Finally, the Title Key is XORed with a local Sector Key to decrypt individual sector data blocks.

Public-Key Cryptography (Asymmetric Cryptography) solves symmetric key distribution challenges by utilizing mathematically linked key pairs: a Public Key (distributed openly) and a Private Key (kept secret by the owner).


Constructing the public/private key pair

Constructing asymmetric key pairs uses random input seeds to calculate mathematically matching private and public keys.


Procedure for Diffie-Hellman secret sharing

The Diffie-Hellman (D-H) key exchange protocol allows two parties (Alice and Bob) to establish a shared secret over an insecure channel without transmitting the secret itself. Each party processes their own private key against the other party's public key, computing identical shared secrets.

Elliptic Curve Cryptography (ECC) performs asymmetric key operations over algebraic structures of elliptic curves, defined by equations such as y2=x3+ax+b(modp)y^2 = x^3 + ax + b \pmod{p}. ECC achieves equivalent security to RSA using substantially smaller key sizes, accelerating computation.

Quantum key distribution (QKD) leverages physics principles like Heisenberg's Uncertainty Principle to detect eavesdropping on fiber-optic and satellite channels. Conversely, quantum cryptanalysis running Shor's algorithm on large-scale quantum hardware can factor large integers efficiently, threatening standard public-key algorithms and necessitating transition to Post-Quantum Cryptography (PQC).

The Rivest-Shamir-Adleman (RSA) cryptosystem bases its security on the mathematical difficulty of factoring large composite integers into prime factors (N=p×qN = p \times q). RSA modular arithmetic equations follow standardized forms:

  • Encryption: C=Me(modN)C = M^e \pmod{N}

  • Decryption: M=Cd(modN)M = C^d \pmod{N} where MM represents plaintext data, CC represents ciphertext, ee is the public exponent, and dd is the secret private exponent.


Encapsulating a key with Alice's RSA public key

Because RSA modular exponentiation is computationally heavy on large datasets, practical implementations use RSA Key Encapsulation (Hybrid Cryptography): a random source generates a symmetric CEK to encrypt file data rapidly, and Alice's RSA Public Key encapsulates (encrypts) the small CEK.

RSA attacks target mathematical implementation parameters: prime factorization attacks, small plaintext cube-root exploits, timing attacks analyzing execution durations, and chosen-ciphertext attacks.

Encryption alone guarantees Confidentiality, but does not protect data Integrity against malicious alteration.


Bit-flipping attack on encryption with xor

In stream ciphers, adversaries execute Bit-Flipping Attacks. If an attacker knows the plaintext structure, altering specific ciphertext bits modifies corresponding plaintext bits upon decryption. Flipping the bit string for character '3' (00110011) in ciphertext alters decrypted plaintext directly to '7' (00110111) without tripping decryption errors.


Data encrypted with its checksum

Encrypting a simple linear checksum alongside data fails to prevent forgery.


An IOU with an adjustable check value

Adversaries exploit birthday attacks and text variation techniques, substituting synonym phrases within documents (e.g., swapping I, Bob, do declare for I, Bob, do hereby declare) to manipulate underlying text while preserving identical checksum results.


Encrypting a hash: two steps

To ensure integrity, systems generate a Cryptographic One-Way Hash of the message and encrypt the hash value.


Keying a hash: one step

A Keyed Hash (HMAC) improves efficiency by incorporating a secret key directly into the hashing operation in a single step, ensuring message integrity and origin authenticity.

Digital signatures provide Non-Repudiation, Message Integrity, and Origin Authentication using asymmetric key pairs.


Signing a check with a digital signature

To sign a digital document, the sender processes the document with their Private Key to append a digital signature block. Any party possessing the sender's corresponding Public Key can verify the signature.


Constructing an RSA digital signature

Constructing an RSA digital signature involves hashing the plaintext file to a fixed-size digest, then encrypting the hash using Bob's RSA Private Key (Signature=Hash(M)d(modN)\text{Signature} = \text{Hash}(M)^d \pmod{N}).


Verifying an RSA digital signature

Signature verification hashes the received plaintext document, decrypts the attached signature using Bob's RSA Public Key (Hash′=Signaturee(modN)\text{Hash}' = \text{Signature}^e \pmod{N}), and checks if the calculated hash matches the decrypted hash.

Asymmetric cryptography is vulnerable to Man-in-the-Middle (MITM) or "Bucket Brigade" attacks if public key distribution is unauthenticated.


Eve performs a man-in-the-middle attack

In a MITM attack, adversary Eve intercepts public key exchanges between Bob and Alice. Eve substitutes her own public key (EE) labeled with Alice's identity when transmitting to Bob, and presents her public key to Alice labeled as Bob. When Bob encrypts data intended for Alice, he encrypts it using Eve's key. Eve intercepts the ciphertext, decrypts it using her private key, inspects or alters the plaintext, re-encrypts it using Alice's real public key (AA), and forwards it to Alice without detection.

To prevent MITM attacks, systems bind public keys to subject identities using Public-Key Certificates issued by trusted Certificate Authorities (CAs).


Constructing a public-key certificate for Alice

A Certificate Authority builds a certificate by combining subject identification data ("Alice") and Alice's Public Key, signing the entire data structure using the CA's Private Key.


A certificate hierarchy that spans multiple enterprises

Public Key Infrastructure (PKI) deploys Certificate Hierarchies. Root CAs sign Intermediate Enterprise CAs, which sign Local CAs, which in turn issue operational end-user certificates. Clients verify end-user certificates by chaining signatures up to a trusted pre-installed Root CA certificate.


A web of trust

An alternative trust model is the Web of Trust (used in PGP/GPG), where individuals cross-sign each other's public keys based on direct personal verification without centralized Root CAs (e.g., Abe signs keys for Bob, Alice, and Carl; Carl signs keys for Emily and Tina).


Procedure for verifying a software update

Digital signatures authenticate software updates during distribution. Software vendors sign compiled update binaries using a private key. Client operating systems verify the signature against the vendor's embedded public key prior to installation.


A set of processes for trusted software update

Operating systems execute software update authentications through an Assured Pipeline pattern. The installation workflow isolates tasks across distinct process boundaries: Bob's GUI passes the downloaded update binary to an isolated Validation Process. The Validation Process reads the binary alongside the vendor's Public Key, verifies the digital signature, and writes a signature token. Only upon successful validation does the Update Process execute with elevated privileges, reading the validated update binary and applying modifications to core system files.