Cs2610

547 flashcardsby Leqenado
Study these flashcardsFree · spaced repetition · iPhone, Android, Mac & web

First 300 of 547 cards

1
[1] What does information security protect?
Information security protects information against unauthorized access or disclosure. It also prevents unauthorized modification and disruption or destruction.
2

[1] What forms of information need protection?
Digital files and databases • email and network communications • printed documents and records • personal and organizational information.
3

[1] Why does information security matter to individuals and organizations?
It protects sensitive personal information and business assets. It keeps operations running and supports government and national security. Large breaches such as Equifax can expose identity and financial data at scale.
4

[1] What are the three goals of the CIA triad?
Confidentiality: only authorized access. Integrity: correct and complete information without unauthorized changes. Availability: authorized users can access information when needed.
5

[1] What must work together to protect the CIA triad?
Hardware and software controls must work with policies and procedures and people. A technical tool alone cannot cover every security weakness.
6

[1] What is confidentiality and how can it be violated?
Confidentiality limits information access to authorized parties. Stolen passwords or intercepted traffic or sending records to the wrong person can expose confidential information.
7

[1] Which controls help protect confidentiality?
Encryption protects readable content. Authentication verifies identities. Access controls restrict permitted access. Data classification determines how sensitive information must be handled.
8

[1] What is integrity and how does it differ from confidentiality?
Integrity preserves data correctness and completeness and prevents unauthorized modification. Confidentiality controls who can read data. A medical record can remain secret yet lose integrity if its treatment information is changed.
9

[1] What are data at rest, data in transit, and data in use?
At rest: stored on a device or medium. In transit: moving between systems. In use: actively processed or accessed. Integrity protection is needed in all three states.
10

[1] What can damage data integrity?
Unauthorized changes • accidental edits • malware corruption • data loss caused by system malfunction.
11

[1] How do access controls, cryptography, version control, and logs support integrity?
Access controls limit who can modify data. Hashes and signatures detect changes when verified through a trusted reference. Version control preserves change history. Audit logs help identify what changed and who acted.
12

[1] What is availability and what threatens it?
Availability means authorized users can obtain needed information and services. Power failures and denial-of-service attacks and ransomware can prevent access.
13

[1] How do redundancy, failover, and firewalls help availability?
Redundancy supplies backup components or resources. Failover moves service to a working alternative. Firewalls can filter unwanted traffic that could disrupt service.
14

[1] How does a vulnerability differ from a threat?
A vulnerability is a weakness in a system. A threat is a potentially harmful event or actor that could exploit that weakness. An unpatched service is a vulnerability. An attacker exploiting it is a threat.
15

[1] What are natural, accidental, and malicious threats?
Natural: fire or earthquake. Accidental: human mistakes or software errors. Malicious: intentional attacks such as phishing or malware or distributed denial of service.
16

[1] Why is perfect security impractical?
Security competes with cost and time and available resources and usability. Systems retain weaknesses. The goal is to reduce and manage risk through appropriate protections.
17

[1] How do a data breach, data loss, and data exfiltration differ?
A breach exposes data to an unauthorized party. Data loss makes data unavailable. Exfiltration transfers data without authorization. One incident may cause all three.
18

[1] What are common consequences of a security breach?
Identity theft • financial loss • reputation damage • loss of access to systems or information.
19

[1] What security lesson does the 2021 T-Mobile breach illustrate?
An unprotected router let an attacker reach servers holding customer data and offer stolen information for sale. One exposed entry point can cause lasting exposure and major costs: the slides cite a \$350 million settlement and \$150 million in security improvements.
20

[1] What is a threat actor and what can motivate one?
A threat actor is a person or group that exploits vulnerabilities. Motives include fun and profit and disruption and blackmail or revenge and political goals.
21

[1] How do insider and external threats differ?
An insider already has an organizational relationship or access that can be abused. An external actor attacks from outside that trusted relationship.
22

[1] How do white-hat, gray-hat, and black-hat hackers differ?
White-hat hackers test with authorization. Gray-hat hackers find vulnerabilities without permission and may report them. Black-hat hackers maliciously exploit systems without permission.
23

[1] What is a script kiddie?
An attacker with limited technical skill who relies on tools or scripts written by others.
24

[1] What makes an advanced persistent threat an APT?
It is highly skilled and well funded and maintains long-term access to valuable targets. Persistence and sustained targeting distinguish it from a brief opportunistic attack.
25

[1] How do state actors, hacktivists, criminal syndicates, and competitors differ?
State actors work for government interests. Hacktivists pursue social or political causes. Criminal syndicates organize attacks for profit. Competitors seek advantage by harming rival organizations.
26

[1] What is an attack vector and what are common examples?
An attack vector is a path used to exploit a weakness. Examples include direct access and wireless links and vulnerable or unsupported software and messaging and supply chains and social media and removable media and cloud services.
27

[1] How does an attack surface differ from an attack vector?
The attack surface is the collection of exposed entry or interaction points. A vector is a specific method used through one of those points. Reducing exposed services and weaknesses shrinks the surface.
28

[1] How can an organization reduce its attack surface?
Patch systems • remove unused services and open ports • replace default passwords • protect wireless connections • restrict access • train users. Each action removes or strengthens a potential entry point.
29

[1] What is social engineering trying to make a victim do?
It manipulates people into compromising security: revealing secrets or clicking malicious links or sending money or downloading malicious software.
30

[1] What are the three broad strategies of social engineering?
Social-based attacks exploit human emotions or trust. Physical-based attacks use proximity. Technical-based attacks use technology such as deceptive websites or DNS manipulation.
31

[1] How do authority, familiarity, intimidation, and trust help social engineers?
Authority invokes a superior's power. Familiarity makes the request seem known. Intimidation creates fear. Trust makes the victim accept the claimed relationship or identity without adequate verification.
32

[1] How do consensus, scarcity, and urgency manipulate a victim?
Consensus says others already comply. Scarcity suggests a limited opportunity. Urgency demands immediate action. Each pressures the victim to act before checking the request.
33

[1] How do dumpster diving, shoulder surfing, and tailgating differ?
Dumpster diving searches discarded material for information. Shoulder surfing observes sensitive input or screens. Tailgating follows an authorized person into a restricted area.
34

[1] What is a watering-hole attack?
The attacker compromises a website frequently visited by the intended victims. Visiting that familiar site can expose them to malicious content or software.
35

[1] How do typosquatting and pharming differ?
Typosquatting uses a deceptive domain resembling a commonly mistyped legitimate name. Pharming redirects users to a fraudulent destination by manipulating name resolution such as DNS.
36

[1] How do phishing, vishing, and smishing differ?
Phishing uses fraudulent messages to steal information or induce harmful actions. Vishing uses phone calls. Smishing uses SMS or text messages.
37

[1] How do general phishing, spear phishing, and whaling differ?
General phishing targets many unrelated recipients. Spear phishing targets a specific person or group. Whaling is targeted phishing against high-value people such as executives.
38

[1] What is business email compromise, or BEC?
An attacker impersonates a trusted person or organization through email to deceive employees. Common goals include fraudulent payments or disclosure of sensitive information.
39

[1] What is malware and what are its main attack purposes?
Malware is software designed to compromise confidentiality or integrity or availability. It may spread itself or block access or spy or mislead users or hide malicious activity. Phishing is a common delivery method.
40

[1] How does a virus differ from a worm?
A virus attaches to a host file or program and spreads when that host executes. A worm self-replicates across networks without requiring a user to run an infected host program.
41

[1] What is fileless malware?
Malicious code that operates primarily in memory or abuses existing system tools instead of relying on a conventional malicious file. It can be harder to find with file-focused detection.
42

[1] What damage can viruses and worms cause?
They can steal or modify or destroy data. Worms may exploit network vulnerabilities to install other malware and backdoors on additional devices.
43

[1] How do a bot, a command-and-control server, and a botnet relate?
A bot is a compromised device under remote control. A command-and-control server sends instructions and receives results. A botnet is a group of bots coordinated for large-scale attacks.
44

[1] What does cryptomining malware do?
It uses the victim's computing resources to mine cryptocurrency for the attacker. This consumes processing power and electricity without authorization.
45

[1] What is ransomware?
Malware that denies access to files or systems and demands payment to restore access. It directly threatens availability and may also be associated with stolen-data extortion.
46

[1] How do spyware and keyloggers differ?
Spyware secretly collects information such as browsing activity or financial details or webcam output. A keylogger specifically records keyboard input and may capture passwords or payment information.
47

[1] Why can bloatware be a security problem?
Unwanted preinstalled software consumes resources and can introduce vulnerabilities. Some bloatware may also collect data or include spyware.
48

[1] How do a Trojan and a remote access Trojan differ?
A Trojan disguises harmful functions as legitimate software. A remote access Trojan specifically gives an attacker remote control to steal data or change settings or install more malware.
49

[1] What is a potentially unwanted program, or PUP?
Software users may not knowingly want that is often bundled with another program. It may install adware or cause unwanted behavior even when it is not designed to cause direct damage.
50

[1] How do a backdoor, a logic bomb, and a rootkit differ?
A backdoor bypasses normal authentication. A logic bomb activates when a condition is met. A rootkit hides malicious activity while enabling privileged access.
51

[1] How do kernel and application rootkits differ?
A kernel rootkit targets the operating system kernel. An application rootkit modifies application files. Either can hide malware or backdoors and interfere with removal.
52

[1] What is a security control?
A mechanism that protects the confidentiality or integrity or availability of systems and data.
53

[1] How do technical, managerial, operational, and physical controls differ?
Technical controls use technology such as firewall rules. Managerial controls establish governance and policies. Operational controls are performed by people such as training. Physical controls protect facilities and equipment such as cameras or locks.
54

[1] How do preventive, deterrent, and directive controls differ?
Preventive controls block incidents such as door locks. Deterrent controls discourage violations such as warning signs. Directive controls prescribe expected behavior such as an acceptable use policy.
55

[1] How do detective and corrective controls differ?
Detective controls identify incidents such as alarms or motion detectors. Corrective controls restore normal operation such as recovering files from backups after ransomware.
56

[1] How do the slides distinguish passive and active security controls?
Passive controls reduce or discourage incidents through preventive or deterrent or directive measures. Active controls detect incidents and respond through detective or corrective measures.
57

[2_1] How do identification, authentication, and authorization differ?
Identification claims an identity. Authentication verifies the claim. Authorization determines which resources and actions that identity may access. IAM manages these functions and the identities behind them.
58

[2_1] What can count as a user or identity in an IAM system?
A human or application or process or device. Identifiers may include usernames and certificates and tokens and SSH keys and smart cards.
59

[2_1] How does identity proofing differ from routine authentication?
Identity proofing verifies who a person is during enrollment such as checking identification when opening a bank account. Authentication later verifies that a login attempt belongs to the enrolled identity.
60

[2_1] What are identity attributes?
Characteristics associated with an identity such as name or email address or location or credentials. Access policies can use these attributes when making decisions.
61

[2_1] What are the five authentication factor categories?
Knowledge: something you know. Possession: something you have. Inherence: something you are. Location: where you are. Behavior: how you act.
62

[2_1] How can location and behavior provide authentication evidence?
Location may be checked through GPS coordinates or an IP address. Behavior may involve a drawn pattern or hand gesture or typing pattern. These supply context or evidence beyond knowledge and possession.
63

[2_1] Which authentication factors do a password, a security token, and a fingerprint represent?
Password: knowledge. Security token: possession. Fingerprint: inherence. A physical biometric is something you are.
64

[2_1] What does an authentication protocol define?
The messages and rules used to verify an identity. Examples include PAP and CHAP and Kerberos and EAP and IEEE 802.1X and RADIUS and TACACS+.
65

[2_1] What are a subject and an object in access control?
The subject requests access such as a user or process. The object is the resource being accessed such as a file or database. Authorization policy determines the subject's permitted actions on the object.
66

[2_1] Which five access control models are introduced in IAM?
Discretionary access control • mandatory access control • role-based access control • attribute-based access control • rule-based access control.
67

[2_1] What distinguishes single-factor authentication, 2FA, and MFA?
Single-factor uses one factor category. Two-factor uses two different categories. MFA uses two or more different categories. Password plus phone approval and smart card plus PIN are examples of 2FA.
68

[2_1] Why do two passwords fail to provide two-factor authentication?
Both are knowledge factors. MFA requires evidence from different categories such as knowledge plus possession or inherence.
69

[2_1] How do static and dynamic knowledge-based authentication differ?
Static KBA uses previously selected questions and answers such as birthplace. Dynamic KBA generates questions from records such as previous addresses. Both depend on personal information that an attacker may discover.
70

[2_1] What is a one-time password in authentication?
An authentication code intended for one use. It is commonly a 6–10 digit code generated by software or hardware or delivered by SMS or email or phone call. It often supplies an additional authentication factor.
71

[2_1] How do TOTP and HOTP differ?
TOTP combines a shared secret with time and commonly changes every 30 seconds. HOTP combines a shared secret with an event-advanced counter and is not inherently time-expiring. The server tracks accepted counters to prevent reuse.
72

[2_1] How can an authenticator app generate codes without receiving each code from a server?
During setup the app and server share a secret key. Both use that secret with the same time or counter input to independently calculate matching OTPs.
73

[2_1] How does push authentication work?
The authentication server sends a login approval request to a registered device. The user approves or denies it. Control of that device acts as a possession factor.
74

[2_1] How does a hardware OTP token differ from an OTP delivered by SMS or email?
A hardware token generates codes locally from a secret shared with the server. It does not depend on delivery through a phone or email channel. RSA SecurID is the lecture example.
75

[2_1] What are static recovery codes and how should they be used?
Pre-generated one-time codes stored securely for future use. They provide backup access when the normal authenticator or network is unavailable. Each code should be consumed once.
76

[2_1] What is a trusted platform module, or TPM?
A protected cryptographic processor typically on a motherboard. It stores keys and supports device authentication and measured or trusted boot. It helps detect unauthorized firmware or software changes.
77

[2_1] How can a TPM support full-disk encryption?
It can protect the keys used to unlock an encrypted drive and condition release on the device's trusted state. Full-disk encryption covers operating system and user files. BitLocker with a TPM is the lecture example.
78

[2_1] What is a hardware security module, or HSM?
A dedicated appliance or expansion card that protects cryptographic keys and performs operations such as key generation and encryption. It is commonly used in enterprise servers and payment systems.
79

[2_1] How do a TPM, an HSM, and FIPS 140 relate?
TPMs and HSMs provide hardware-protected cryptographic functions. A TPM typically serves one device while an HSM often serves enterprise workloads. FIPS 140 specifies security requirements for cryptographic modules.
80

[2_1] What are examples of physical and behavioral biometrics?
Physical biometrics include fingerprints and facial features and iris or retina patterns and palm or vein patterns. Behavioral biometrics include voice and gait and signatures and typing patterns.
81

[2_1] What are the convenience and security tradeoffs of biometrics?
Users can authenticate with a physical or behavioral characteristic instead of memorizing or carrying another credential. Such traits can be harder to copy than a password but systems can still falsely accept or reject people. Biometrics are not infallible.
82

[2_1] What do false acceptance rate and false rejection rate measure?
FAR measures impostor attempts incorrectly accepted: false accepts ÷ impostor attempts. FRR measures genuine attempts incorrectly rejected: false rejects ÷ genuine attempts. FAR is Type II and FRR is Type I in the slide convention.
83

[2_1] How does changing a biometric matching threshold affect FAR and FRR?
A stricter acceptance threshold generally lowers false accepts but increases false rejects. A looser threshold generally lowers false rejects but increases false accepts.
84

[2_1] What is the crossover error rate or equal error rate of a biometric system?
CER or EER is the error rate where FAR equals FRR. A lower CER indicates better matching accuracy under that evaluation. The slides cite example target thresholds of FRR 3% and FAR 0.01%.
85

[2_1] How does Password Authentication Protocol (PAP) authenticate a client and why is it weak?
1. The client sends credentials. 2. The server returns ACK or NAK. PAP normally authenticates at session establishment and does not itself encrypt credentials. An unprotected channel exposes the password.
86

[2_1] What are the three steps of Challenge Handshake Authentication Protocol (CHAP)?
1. Server sends a random challenge. 2. Client returns a hash-based response using the challenge and shared secret. 3. Server computes its expected response and accepts or rejects. The shared secret is not transmitted.
87

[2_1] How does CHAP improve on PAP?
CHAP proves knowledge of a shared secret through challenge-response instead of sending it directly. A fresh challenge limits simple response replay. CHAP can repeat authentication during a session.
88

[2_1] What is Kerberos and why does it support single sign-on?
Kerberos is ticket-based network authentication. A user authenticates and then presents tickets to obtain services without repeatedly submitting a password. It commonly appears in Windows domains and uses port 88.
89

[2_1] What are a Kerberos realm and KDC?
A realm is an administrative domain using Kerberos. Its Key Distribution Center is a trusted service containing the Authentication Server and Ticket-Granting Server.
90

[2_1] How do the Kerberos Authentication Server and Ticket-Granting Server differ?
The AS authenticates the client and issues a ticket-granting ticket. The TGS accepts that TGT to issue a ticket for a requested service.
91

[2_1] What is the Kerberos ticket flow from login to service access?
1. Client authenticates to AS. 2. AS returns a TGT. 3. Client presents TGT and service request to TGS. 4. TGS issues a service ticket. 5. Client presents it to the service. 6. Service validates it and grants access.
92

[2_1] How does a Kerberos TGT differ from a service ticket?
A TGT lets the client request tickets from the TGS. A service ticket is intended for a particular service and has a limited validity period. Neither should be treated as a reusable plaintext password.
93

[2_1] What is EAP and what are its four message types?
Extensible Authentication Protocol is a framework for carrying different authentication methods. Request asks for information. Response supplies it. Success and Failure report the authentication result.
94

[2_1] Which certificates does EAP-TLS require?
Both a server certificate and a client certificate. This supports certificate-based mutual authentication.
95

[2_1] How do EAP-TTLS and PEAP protect client authentication?
Both establish a TLS tunnel using a server certificate. The client authenticates inside the tunnel without requiring a client certificate. EAP-TTLS can carry methods such as PAP. PEAP tunnels EAP messages.
96

[2_1] What distinguishes EAP-FAST from the other tunneled EAP methods?
EAP-FAST can establish a protected tunnel using a server-issued Protected Access Credential or PAC. It can support certificates but does not always require them.
97

[2_1] How can you remember the main EAP method requirements?
EAP-TLS: client and server certificates. EAP-TTLS and PEAP: server certificate with tunneled client authentication. EAP-FAST: PAC-based tunnel establishment can avoid certificate requirements.
98

[2_1] Which of the four compared EAP methods support mutual authentication?
EAP-TLS and EAP-TTLS and EAP-FAST and PEAP all support it when configured correctly. The server is authenticated through the chosen method and the client proves its identity using a certificate or protected inner credentials.
99

[2_1] What does IEEE 802.1X control?
Port-based network access. It carries authentication exchanges so a wired or wireless device gains network access only after successful authentication.
100

[2_1] What are the three IEEE 802.1X roles?
Supplicant: endpoint requesting access. Authenticator: switch or access point controlling the port and relaying messages. Authentication server: verifies credentials and decides whether to allow access.
101

[2_1] What is the IEEE 802.1X authentication sequence?
The supplicant requests access and supplies identity. The authenticator relays it to the authentication server. Server challenges and client responses pass through the authenticator. The server returns accept or reject and the authenticator enforces the result.
102

[2_1] What does AAA stand for?
Authentication verifies identity. Authorization determines permitted access. Accounting records activity and resource use.
103

[2_1] What roles do the RADIUS client and RADIUS server play?
In Remote Authentication Dial-In User Service the client is a network access server such as an AP or switch. It relays user authentication requests. The central RADIUS server authenticates and authorizes access.
104

[2_1] Which ports does RADIUS use?
UDP 1812 for authentication and authorization. UDP 1813 for accounting.
105

[2_1] What do RADIUS Access-Accept, Access-Reject, and Access-Challenge mean?
Accept permits access. Reject denies it. Challenge requests additional authentication information before a final decision. Challenge-response can support additional factors.
106

[2_1] How does a RADIUS login proceed?
The user connects to the NAS. The NAS sends an access request to the RADIUS server. The server may challenge for more information. A final accept starts the session or a reject denies it. Accounting can record session activity.
107

[2_1] What is TACACS+ commonly used for?
Terminal Access Controller Access-Control System Plus provides centralized AAA for administrative access to devices such as routers and switches. It separates authentication and authorization and accounting and uses TCP port 49.
108

[2_1] What responses can a TACACS+ authentication server return?
Accept for valid authentication. Reject for failed authentication. Error for an authentication-system or communication failure.
109

[2_1] How does TACACS+ packet protection differ from traditional RADIUS protection?
TACACS+ protects the packet body while its header remains visible. Traditional RADIUS protects the password field rather than the entire packet body. Neither comparison means all transport metadata is hidden.
110

[2_1] When would you choose RADIUS versus TACACS+ in the lecture examples?
RADIUS commonly authenticates users joining a network. TACACS+ commonly controls administrator access to network equipment and can authorize individual administrative actions. RADIUS uses UDP while TACACS+ uses TCP.
111

[2_2] What is SAML and where is it commonly used?
Security Assertion Markup Language is an XML-based standard for exchanging authentication and authorization information. It commonly supports enterprise web single sign-on between an identity provider and service providers.
112

[2_2] What are the three roles in SAML?
Principal: the user. Identity provider or IdP: authenticates the user and manages identity information. Service provider or SP: provides the application the user wants to access.
113

[2_2] What is a SAML assertion and why is it signed?
An assertion is an XML statement from the IdP about a user. Its digital signature lets the SP verify the trusted issuer and detect modification before relying on the information.
114

[2_2] What is a typical SAML sign-in sequence?
1. User requests the SP. 2. SP directs authentication to IdP. 3. IdP requests and verifies credentials. 4. IdP returns a signed assertion. 5. SP verifies it and grants or denies access.
115

[2_2] What are the three kinds of statements in a SAML assertion?
Authentication: when and how the user authenticated. Attribute: identity information as name–value pairs. Authorization decision: permitted resources or actions. The SP uses the assertion to make its access decision.
116

[2_2] What is OpenID intended to provide?
Web sign-in using one identity provider across multiple relying parties. The IdP authenticates the user and the relying party accepts its identity confirmation to support single sign-on.
117

[2_2] What is the basic OpenID login flow?
The user registers with an IdP and requests login at a relying party. The user authenticates to the IdP. The IdP confirms the identity to the relying party which then grants access.
118

[2_2] What problem does OAuth solve?
It lets a user delegate limited resource access to an application without giving that application the user's password. OAuth is an authorization framework using access tokens for HTTP-based services.
119

[2_2] What is the basic OAuth access flow?
1. User approves the client application's request. 2. Authorization server issues an access token. 3. Client presents the token to the resource server. 4. Resource server validates it and permits the authorized access.
120

[2_2] How do SAML, OpenID, and OAuth differ?
SAML commonly supplies enterprise SSO assertions. OpenID supplies web identity authentication. OAuth delegates permission to access resources. Permission to read data is different from proof of who logged in.
121

[2_2] What does an account policy govern?
How accounts are created and used and maintained and disabled and removed throughout their lifecycle.
122

[2_2] How do user, privileged, shared, guest, and service accounts differ?
User: ordinary individual access. Privileged: elevated system control. Shared: multiple users share credentials. Guest: temporary access. Service: used by an application or server rather than normal interactive login.
123

[2_2] Why do shared accounts make accountability harder?
Multiple people use the same credentials. An activity log naming that account may not establish which person performed the action.
124

[2_2] What do password complexity, history, and age policies control?
Complexity sets length and character requirements. History limits reuse of prior passwords. Age sets how long a password may be used before a required change.
125

[2_2] What is a password manager or vault?
Software that securely stores and manages passwords. It helps users keep distinct credentials without memorizing every password.
126

[2_2] How do geolocation, geotagging, and geofencing differ?
Geolocation estimates a device's position using sources such as GPS or IP. Geotagging associates geographic data with an item or device. Geofencing permits or restricts access according to a defined geographic boundary.
127

[2_2] How does an impossible-travel rule detect suspicious logins?
It compares successive login locations and times. If the implied trip could not plausibly occur in that interval the account may be compromised and the new login can be blocked or challenged.
128

[2_2] How can network location and time restrict account access?
IP or MAC-based network location identifies the connection point. Time-of-day rules specify allowed login periods. Policies can require both an approved network and an approved time.
129

[2_2] How do account auditing, disabling, and lockout differ?
Auditing reviews accounts and permissions. Disabling preserves an account but prevents access. Lockout temporarily blocks access after repeated failed logins and may require administrator action or a timeout to unlock.
130

[2_2] How does lockout help against password guessing?
It limits repeated failed attempts against an account. The lockout duration determines when automatic retry becomes possible. An administrator may instead need to unlock the account manually.
131

[2_2] Who decides access in discretionary access control or DAC?
The object's owner grants or removes permissions. An access control list records which subjects may perform which actions. DAC is common in operating-system file permissions.
132

[2_2] Who decides access in mandatory access control or MAC?
A central authority assigns subject clearances and object classification labels. Mandatory policy compares those labels to decide access. Individual owners cannot freely override the policy.
133

[2_2] What is a security domain or realm of security?
A collection of subjects and objects governed by a common security policy.
134

[2_2] What classification order is used in the slides' MAC example?
Top Secret > Secret > Confidential > Restricted > Unclassified. A subject's clearance and an object's classification are compared under the governing policy.
135

[2_2] What do Bell–LaPadula's no-read-up and no-write-down rules prevent?
No read up prevents a lower-cleared subject from reading higher-classified data. No write down prevents higher-classified information from being written to a lower level. These rules protect confidentiality.
136

[2_2] What additional requirement does Bell–LaPadula's discretionary security property impose?
Access must also satisfy the system's discretionary permissions such as its ACL. Satisfying the mandatory label rules alone does not automatically grant access.
137

[2_2] How does role-based access control or RBAC assign permissions?
Administrators assign permissions to job roles and users to roles. Users inherit the permissions of their assigned roles. This is centrally controlled rather than left to each object owner.
138

[2_2] What makes an access control model nondiscretionary?
A central authority or administrator controls access policy. Individual resource owners do not freely choose the governing permissions.
139

[2_2] What inputs does attribute-based access control or ABAC evaluate?
Subject attributes such as role or clearance. Object attributes such as sensitivity or owner. Environmental attributes such as time or location or threat level. A policy evaluates these together to allow or deny access.
140

[2_2] How does rule-based access control decide access?
It applies administrator-defined conditions such as source IP or time or device type or protocol or port. A firewall that allows HTTPS on TCP 443 and denies SSH on TCP 22 is an example.
141

[2_2] How can you distinguish DAC, MAC, RBAC, ABAC, and rule-based control in a scenario?
Owner chooses: DAC. Labels and clearances: MAC. Job role: RBAC. Combined subject and object and environment attributes: ABAC. Explicit administrator conditions such as IP or port: rule-based control.
142

[2_2] What do r, w, x, and a dash mean in Linux file permissions?
r permits reading. w permits writing or modification. x permits execution of a regular file. A dash means that permission is absent in that position.
143

[2_2] How do you interpret r-x, rw-, and rwx for a regular file?
r-x allows reading and executing. rw- allows reading and writing. rwx allows all three. Evaluate each position separately rather than treating the three characters as one permission.
144

[2_2] How do you read a Linux ls -l permission string?
The first character identifies file type. The next three permissions apply to the owner. The next three apply to the group. The final three apply to everyone else.
145

[2_2] What does -rwx--xr-x allow for a regular file?
Owner: read and write and execute. Group: execute only. Other users: read and execute. The initial dash marks a regular file.
146

[2_2] Where are Windows file permissions configured and what does Full Control include?
File Properties → Security. Full Control includes reading and writing and modifying and deleting plus changing permissions.
147

[2_2] How do Windows Modify, Read & Execute, Read, and Write permissions differ?
Modify permits reading and writing and deleting. Read & Execute permits viewing and running. Read permits viewing. Write permits creating or changing content. Full Control additionally includes changing permissions.
148

[2_2] What do privileged access management and least privilege aim to do?
PAM or PIM secures and monitors elevated accounts such as Administrator or root. Least privilege gives each user only the permissions needed for their job and limits unnecessary privileged access.
149

[2_2] Why do privileged accounts need stronger protection?
They can configure systems and networks and manage accounts and override security controls and shut systems down. Compromise therefore gives an attacker broad power.
150

[2_2] What is conditional access?
Access decisions based on current conditions such as user location or IP or device type or patch status or account risk. A policy may require 2FA before allowing a sensitive application.
151

[3_1] How do cryptography, cryptanalysis, and cryptology differ?
Cryptography designs ways to protect information. Cryptanalysis studies how to break cryptographic protection. Cryptology includes both. The historical roots of cryptography mean secret writing.
152

[3_1] Which four security goals can cryptography support?
Confidentiality • integrity • data-origin authentication • non-repudiation. Different primitives provide different goals. Encryption alone does not automatically provide all four.
153

[3_1] How do message authentication and non-repudiation differ?
Message authentication checks the claimed origin of a message. Non-repudiation provides evidence against a sender later denying it. A shared-key MAC does not distinguish which key holder created a tag. Digital signatures can support that distinction.
154

[3_1] How do the lock and seal analogies distinguish encryption from authentication?
A lock hides message content and represents encryption. A seal reveals unauthorized changes and represents an authentication tag or signature. A readable message can be authenticated without being encrypted.
155

[3_1] How do substitution and transposition ciphers differ?
Substitution replaces plaintext elements with different elements. Transposition rearranges their positions without adding or removing elements. Neither historical technique alone provides modern cryptographic security.
156

[3_1] How do monoalphabetic and polyalphabetic substitutions differ?
A monoalphabetic substitution always maps a particular plaintext letter to the same ciphertext letter. A polyalphabetic substitution can map it differently depending on position or the selected alphabet.
157

[3_1] How do you encrypt and decrypt with a shift cipher?
Represent A–Z as 0–25. Encrypt with C=(P+k) mod 26. Decrypt with P=(C−k) mod 26. Wrap around the alphabet at either end.
158

[3_1] What shift does the Caesar cipher use and what is its example ciphertext?
The Caesar cipher shifts each letter three positions forward. Using that rule converts cryptography to fubswrjudskb. Decryption shifts each letter three positions backward.
159

[3_1] Why does ROT13 use the same operation for encryption and decryption?
Its shift is 13 in a 26-letter alphabet. Applying it twice shifts by 26 and restores the original. For example cryptography becomes pelcgbtencul.
160

[3_1] How do you encrypt with a rail-fence transposition cipher?
Choose the rail count as the key. Write letters in a repeating diagonal down-and-up zigzag. Read each rail from top to bottom to form the ciphertext.
161

[3_1] What is the three-rail rail-fence result for RANSOMWARE?
The rails read ROR • ASMAE • NW. Concatenating them gives RORASMAENW. The procedure preserves the original letters but changes their positions.
162

[3_1] How do you encrypt with a columnar transposition cipher?
Write plaintext in rows whose width equals the keyword length. Rank keyword letters alphabetically. Read the columns from top to bottom in that ranked order. The keyword determines the permutation.
163

[3_1] How does keyword KITE encrypt SPYWARE in the lecture example?
Write rows SPYW and ARE. The keyword ranks are K=3 • I=2 • T=4 • E=1. Read E then I then K then T: W + PR + SA + YE = WPRSAYE.
164

[3_1] Which primitives provide symmetric and asymmetric confidentiality?
Symmetric confidentiality uses shared-key encryption such as AES with a secure mode. Asymmetric confidentiality uses public-key encryption such as RSA encryption or ElGamal.
165

[3_1] Which primitives provide symmetric and asymmetric integrity and authentication?
Symmetric integrity and authentication use message authentication codes such as CBC-MAC. Asymmetric integrity and authentication use digital signatures such as RSA signatures. Hash functions and random generators support these constructions.
166

[3_1] What other building blocks support cryptographic systems?
Cryptographic hashes • pseudorandom generators • key exchange • key management • password management. Strong encryption still depends on correct use of these supporting mechanisms.
167

[3_1] What roles do Alice, Bob, Eve, and Mallory represent?
Alice and Bob are intended communicating parties. Eve passively eavesdrops. Mallory actively observes and tampers. The goals are to hide content from Eve and detect Mallory's unauthorized changes.
168

[3_1] What are plaintext, ciphertext, a cipher, encryption, and decryption?
Plaintext is the original message. Ciphertext is its encrypted form. A cipher is the algorithm. Encryption maps plaintext to ciphertext. Decryption reverses that transformation using the required key. Messages are represented as bits.
169

[3_1] How do a key, key space, and key length differ?
A key selects the cipher's transformation. The key space is the set of possible keys. Key length is the number of key bits. An unrestricted k-bit key space contains 2^k possible keys.
170

[3_1] What is key stretching trying to accomplish?
A key derivation procedure adds computational work to processing a password or weak secret. This makes repeated guesses more expensive. It does not create new unpredictability merely by producing a longer output.
171

[3_1] How do symmetric and asymmetric key models differ?
Symmetric systems use a shared secret key for encryption and decryption. Asymmetric systems use a public key and a corresponding private key. Symmetric encryption is generally faster but requires secure shared-key distribution.
172

[3_1] What does Kerckhoffs's principle require?
A cryptosystem should remain secure even when its algorithms and design are public. Security should depend on the secret key. A suspected leaked key should be replaceable without redesigning the system.
173

[3_1] How do confusion and diffusion differ?
Confusion obscures the relationship between the key and ciphertext. Diffusion spreads plaintext structure across ciphertext bits. Changing one key or input bit should influence many output bits.
174

[3_1] What is the avalanche effect?
A small input change such as one plaintext or key bit causes many output bits to change. It helps resist analysis but does not alone prove the whole encryption scheme secure.
175

[3_1] What does confidentiality mean beyond making ciphertext look unreadable?
Seeing ciphertext should not reveal useful new information about the plaintext beyond permitted leakage such as length. An attacker should not reliably distinguish encryptions of two allowed candidate messages.
176

[3_1] How do ciphertext-only attacks (COA) and known-plaintext attacks (KPA) differ?
A ciphertext-only attacker has encrypted messages alone. A known-plaintext attacker also knows some corresponding plaintext–ciphertext pairs.
177

[3_1] How do chosen-plaintext attacks (CPA) and chosen-ciphertext attacks (CCA) differ?
A CPA attacker obtains encryptions of selected messages. A CCA attacker obtains decryptions of selected ciphertexts subject to the model's restrictions. A combined chosen-plaintext/ciphertext attack model or CPCA allows both kinds of access.
178

[3_1] What is a replay attack?
The attacker resends an intercepted valid message or ciphertext. Replaying does not require learning the plaintext or changing the message. Freshness checks such as nonces or counters are needed to reject duplicates.
179

[3_1] What does IND-CPA mean and what happens in its security game?
Indistinguishability under chosen-plaintext attack. The attacker selects equal-length M0 and M1. A challenger randomly chooses b and returns an encryption of Mb. The attacker may obtain chosen-message encryptions and tries to guess b better than random chance.
180

[3_1] What counts as breaking IND-CPA security?
An efficient attacker achieves a non-negligible advantage over the 1/2 success probability of guessing. Security requires every allowed efficient attacker to have at most negligible advantage. One successful attack strategy establishes insecurity.
181

[3_1] Why must the two challenge messages have equal length in IND-CPA?
Ordinary encryption can reveal plaintext length. Different-length candidates could be distinguished from ciphertext length alone. Equal lengths isolate information leakage beyond that expected limitation.
182

[3_1] Why are polynomial time and negligible advantage included in cryptographic definitions?
The definition focuses on feasible attacks. An astronomically slow strategy or an advantage such as 2^−128 does not constitute a practical break merely because it is theoretically nonzero.
183

[3_1] Why does deterministic encryption fail IND-CPA security?
The attacker requests an encryption of M0 and compares it with the challenge. A match identifies M0 and a mismatch identifies M1. Secure repeated-message encryption needs suitable fresh randomness or unique state.
184

[3_1] Do confusion and diffusion guarantee IND-CPA security?
No. A deterministic cipher may have excellent confusion and diffusion yet expose repeated messages. The complete encryption construction and its use of randomness or state must satisfy the security definition.
185

[3_1] What is symmetric encryption good at and what is its main setup problem?
It efficiently protects large amounts of data and is used within protocols such as HTTPS and IPsec. Both parties first need a secure way to obtain the same secret key.
186

[3_1] What are the three algorithms and correctness condition of symmetric encryption?
KeyGen produces K. Enc_K(M) produces C. Dec_K(C) recovers M. Correctness requires Dec_K(Enc_K(M))=M for every valid message and generated key. The algorithms must also be efficient and secure.
187

[3_1] How do stream and block ciphers differ?
A stream cipher combines plaintext with a generated keystream a bit or byte at a time. A block cipher transforms fixed-size blocks. Stream-like XOR encryption can handle continuous data efficiently.
188

[3_1] How does XOR-based stream encryption work?
Generate a keystream Z from secret key material. Encrypt with C=M⊕Z. Decrypt with M=C⊕Z using the same keystream. A ciphertext bit flip changes only the corresponding plaintext bit in this basic construction.
189

[3_1] What is a keystream generator and what is the lecture's historical example?
It expands secret key material into the bit stream used for stream encryption. A5/1 in legacy GSM is the lecture example. The keystream must not repeat where it protects different plaintexts.
190

[3_1] What is the XOR truth table?
0⊕0=0 • 0⊕1=1 • 1⊕0=1 • 1⊕1=0. XOR returns 1 exactly when its two input bits differ.
191

[3_1] Which XOR identities let you undo XOR encryption?
x⊕0=x and x⊕x=0. XOR is commutative and associative. Therefore x⊕y⊕x=y. To solve y⊕1=0 XOR both sides with 1 to obtain y=1.
192

[3_1] What conditions must a one-time-pad key satisfy?
It must be uniformly random and independent of the plaintext. It must be at least as long as the protected message and remain secret. Each key segment must be used only once.
193

[3_1] What are one-time-pad encryption and decryption formulas?
Encryption: C=M⊕K. Decryption: M=C⊕K. Apply XOR at each matching bit position. The plaintext and ciphertext and used key segment have the same bit length.
194

[3_1] How do you encrypt M=01000001 with OTP key K=11101100?
XOR each corresponding bit. 01000001 ⊕ 11101100 = 10101101. That result is the ciphertext C.
195

[3_1] Why does decrypting an OTP recover the original message?
C⊕K=(M⊕K)⊕K=M because K⊕K=0. For example 10101101 ⊕ 11101100 = 01000001.
196

[3_1] Why does a correctly used one-time pad provide perfect secrecy?
For any plaintext M and ciphertext C there is exactly one compatible key K=M⊕C. All keys are equally likely. Observing C therefore does not favor one possible plaintext over another of the same length.
197

[3_1] What information leaks if the same OTP key encrypts two messages?
C0⊕C1=(M0⊕K)⊕(M1⊕K)=M0⊕M1. The key cancels. Knowing one plaintext then reveals the other by XORing with this result.
198

[3_1] Why is the one-time pad usually impractical?
Communicating parties must securely distribute and store fresh random key material as long as all protected data. Reusing old material destroys its security. The slides cite reused Soviet wartime pads as a real example.
199

[3_2] How does a one-time pad differ from a reusable block-cipher scheme?
A one-time pad consumes fresh random secret bits as long as the message. A block-cipher scheme reuses a fixed-size secret key with a suitable mode and fresh IVs or unique nonces for different encryptions.
200

[3_2] How do bits, bytes, words, and hexadecimal digits relate?
A byte is 8 bits. A hexadecimal digit is 4 bits so two hex digits make one byte. A machine word is architecture-dependent such as 32 or 64 bits.
201

[3_2] How do you convert binary to hexadecimal?
Group bits into sets of four from the right and convert each group. Hex digits 0–9 represent values 0–9 and A–F represent 10–15. Example: 1100 0110 1000 0000 becomes 0xC680 or two bytes.
202

[3_2] What mathematical function does a block cipher implement for a fixed key?
A permutation of all n-bit blocks. Every plaintext block maps to exactly one ciphertext block and the inverse decryption maps it back. A k-bit key selects among 2^k possible key settings.
203

[3_2] How do block size and key size differ?
Block size determines how many bits one primitive operation transforms. Key size determines the size of the key space. AES has 128-bit blocks even when its key has 192 or 256 bits. IDEA uses 64-bit blocks.
204

[3_2] How are variable-length messages handled by block encryption?
Divide the message into blocks and use a mode of operation. Some modes require padding for an incomplete final block. Stream-like modes can use only the needed portion of their last keystream block.
205

[3_2] Why can a secure block-cipher primitive still fail as raw message encryption?
Its keyed permutation may look random to an efficient attacker yet remain deterministic. Repeated plaintext blocks produce repeated ciphertext blocks. A complete confidentiality scheme needs a secure mode and correct randomness or state.
206

[3_2] Why is DES considered insecure for modern use?
Its 56-bit key is vulnerable to brute force and its 64-bit block is small. The slides cite the EFF's 1998 key search taking 56 hours. Strong confusion and diffusion do not compensate for inadequate sizes.
207

[3_2] What are Data Encryption Standard (DES) block size, key size, and round structure?
DES uses a 64-bit block and 56 effective key bits. It applies initial permutation and 16 Feistel rounds followed by final permutation. The block splits into two 32-bit halves.
208

[3_2] What happens in one DES Feistel round?
Set the new left half to the old right half. Set the new right half to old left XOR f(old right and round key). The round function expands bits and applies key XOR and S-box substitutions and permutation.
209

[3_2] How does DES obtain confusion and diffusion?
S-box substitutions create confusion. Permutations and repeated Feistel rounds spread input influence to create diffusion and an avalanche effect. DES remains deterministic when used as a bare block cipher.
210

[3_2] How does standard triple-DES combine DES operations?
It uses encrypt–decrypt–encrypt: C=E_K3(D_K2(E_K1(M))). Its block size remains 64 bits. Repeated DES operations do not enlarge the block.
211

[3_2] What key material sizes do the three 3DES keying options use?
Three independent DES keys use 168 key bits. Two independent keys use 112. One repeated key uses 56 and collapses to ordinary DES under the EDE construction. These are key-material sizes rather than equal claims of attack strength.
212

[3_2] What are 3DES's remaining weaknesses?
It is slow and retains a 64-bit block size. Block collisions enable attacks such as Sweet32 at high data volumes. Longer key material does not solve the short-block problem.
213

[3_2] What are Advanced Encryption Standard (AES) key sizes and corresponding round counts?
128-bit key: 10 rounds. 192-bit key: 12 rounds. 256-bit key: 14 rounds. All three use 128-bit blocks. Round keys are derived from the original cipher key.
214

[3_2] What is the main sequence of AES round operations?
After an initial AddRoundKey the rounds apply SubBytes → ShiftRows → MixColumns → AddRoundKey. The final round omits MixColumns. Decryption applies corresponding inverse operations.
215

[3_2] What supports AES security and what does AES alone fail to provide?
Substitution and shifting and mixing produce confusion and diffusion. Adequate key and block sizes resist generic attacks. AES is a security assumption rather than a mathematical proof of unbreakability. Bare AES remains deterministic and needs a secure mode.
216

[3_2] What problems do block-cipher modes of operation solve?
They build encryption for arbitrary-length messages from a fixed-block primitive. Appropriate modes add randomness or unique state to avoid deterministic message leakage. The slides cover ECB and CBC and CFB and OFB and CTR.
217

[3_2] What are Electronic Codebook (ECB) encryption and decryption formulas?
Split into full blocks. Encrypt independently with C_i=E_K(M_i). Decrypt with M_i=D_K(C_i). Concatenate the results. ECB has no IV and no chaining between blocks.
218

[3_2] Does ECB need padding and can it run in parallel?
It needs complete blocks so ordinary variable-length use requires padding. Both encryption and decryption can run in parallel because each block is independent.
219

[3_2] What happens if one ciphertext bit changes in ECB?
The corresponding recovered plaintext block is scrambled through the cipher's avalanche effect. Other blocks are unaffected. There is no cross-block error propagation.
220

[3_2] Why does ECB leak patterns even with AES?
Equal plaintext blocks under one key produce equal ciphertext blocks. Repeated image regions or message structures remain visible as repeated encrypted blocks. AES-ECB is therefore not IND-CPA secure.
221

[3_2] Why is padding with only zeros or only ones ambiguous?
Actual message data may end with the same bits. The receiver cannot determine where data ends and padding begins without an additional length convention.
222

[3_2] How does one-zero padding remove ambiguity?
Append one 1 bit followed by enough 0 bits to reach a block boundary. Always add padding. An already aligned message receives an entire new padding block so unpadding can locate the final 1 marker.
223

[3_2] How do you calculate PKCS#7 padding?
For block size B bytes and message length L bytes compute p=B−(L mod B). Append p bytes each with value p. If L is already aligned then p=B and a full padding block is added.
224

[3_2] What PKCS#7 padding does HELLO need for AES?
HELLO occupies five bytes and AES blocks contain 16 bytes. Therefore p=16−5=11. Append eleven bytes of value 0x0B. Verify all padding bytes before removing them.
225

[3_2] How do you encrypt using Cipher Block Chaining (CBC)?
Pad into full blocks and choose a fresh unpredictable IV. Set C_0=IV. For each i compute C_i=E_K(M_i⊕C_(i−1)). Send IV followed by all ciphertext blocks.
226

[3_2] How do you decrypt using CBC?
Parse IV and ciphertext blocks. Set C_0=IV. Recover M_i=D_K(C_i)⊕C_(i−1). Concatenate the plaintext blocks and validate and remove padding.
227

[3_2] With IV=10 and E: 00→01 • 01→10 • 10→11 • 11→00, what CBC ciphertext encrypts 00/01/10/11?
XOR each plaintext block with the IV or previous ciphertext and then apply E. The successive XOR inputs are 10/10/01/01. The resulting ciphertext blocks are 11/11/10/10.
228

[3_2] With IV=10 and D: 00→11 • 01→00 • 10→01 • 11→10, what CBC plaintext decrypts from 11/11/10/10?
Decrypt each block then XOR with the IV or previous ciphertext: 10⊕10=00 • 10⊕11=01 • 01⊕11=10 • 01⊕10=11. The plaintext blocks are 00/01/10/11.
229

[3_2] Why is CBC encryption sequential but decryption parallelizable?
Encryption needs the previous ciphertext before computing the next block. Decryption uses ciphertext blocks that have already arrived so each D_K(C_i) and XOR can be computed independently. CBC requires padding.
230

[3_2] What does a one-bit error in CBC ciphertext block C_i do?
It scrambles plaintext block M_i and flips the same bit in M_(i+1). Later blocks are unaffected. If only the IV is altered the corresponding bits of the first plaintext block flip.
231

[3_2] What does IV reuse reveal in CBC?
Under the same key identical starting plaintext blocks produce identical starting ciphertext blocks up to the first difference. Fresh unpredictable IVs prevent this common-prefix leakage. CBC still needs separate integrity protection.
232

[3_2] What are full-block Cipher Feedback (CFB) encryption and decryption formulas?
Set C_0=IV. Encrypt with C_i=E_K(C_(i−1))⊕M_i. Decrypt with M_i=E_K(C_(i−1))⊕C_i. Both directions use the block cipher's encryption operation.
233

[3_2] Does CFB need padding and which direction can run in parallel?
No padding is needed when only the required final keystream portion is used. Encryption is sequential because each next step needs the previous ciphertext. Decryption can be parallelized once ciphertext blocks are available.
234

[3_2] What does a one-bit ciphertext error do in full-block CFB?
It flips the same bit in the corresponding plaintext block and scrambles the next plaintext block. Error propagation then stops. This differs from CBC which scrambles the current block and flips one bit in the next.
235

[3_2] What IV requirement supports CFB confidentiality?
Use a fresh unpredictable IV of the block size under the key. Reusing the IV repeats the first keystream block and leaks relationships between starting plaintexts. Proper CFB supplies confidentiality but no authentication tag.
236

[3_2] How does Output Feedback (OFB) generate its keystream and encrypt or decrypt?
Set Z_0=IV and repeatedly compute Z_i=E_K(Z_(i−1)). Encrypt with C_i=M_i⊕Z_i. Decrypt with M_i=C_i⊕Z_i. The feedback uses cipher output rather than ciphertext or plaintext.
237

[3_2] Does OFB need padding and can its keystream be generated in parallel?
No padding is needed. Keystream generation is sequential because each Z_i depends on Z_(i−1). It can be precomputed before the message arrives. Once available the independent XOR operations can run in parallel.
238

[3_2] How do ciphertext corruption and IV corruption differ in OFB?
A changed ciphertext bit changes only the matching plaintext bit. A changed IV alters the generated keystream and corrupts the recovered message throughout.
239

[3_2] Why must OFB not repeat an IV under the same key?
Repeating the IV repeats the entire keystream. XORing the two ciphertexts then reveals the XOR of their plaintexts just as in one-time-pad key reuse.
240

[3_2] How does Counter (CTR) mode encrypt and decrypt?
For each block form a unique nonce–counter input and compute Z_i=E_K(N∥i). Encrypt C_i=M_i⊕Z_i. Decrypt M_i=C_i⊕Z_i. Transmit the nonce so the receiver can regenerate the keystream.
241

[3_2] Why is CTR efficient for parallel or random-access processing?
Each nonce–counter block can be encrypted independently. Encryption and decryption can both run in parallel. Any block can be recovered without processing prior blocks. A partial final block uses only the needed keystream bytes and requires no padding.
242

[3_2] How do ciphertext corruption and nonce corruption differ in CTR?
A changed ciphertext bit flips only its matching plaintext bit. A changed nonce changes all counter inputs and therefore corrupts the keystream and recovered message throughout.
243

[3_2] What must never repeat in CTR mode under one key?
The full nonce–counter input to the block cipher. Use a unique nonce per message and prevent counter wrap or overlapping ranges. Repetition reuses the keystream and exposes C⊕C′=M⊕M′.
244

[3_2] How do an IV and a nonce differ?
An IV initializes a mode and its requirements depend on that mode. A nonce is a number used once and need not be random. CBC needs unpredictability while CTR principally needs unique nonce–counter inputs under the key.
245

[3_2] Must IVs and nonces be secret like encryption keys?
Usually no. They can be transmitted with ciphertext so the receiver can reproduce the computation. Their mode-specific freshness or unpredictability requirements still matter and unauthorized changes must be detected when integrity is needed.
246

[3_2] Why are large random IVs or nonces useful?
They make accidental repeats unlikely when generated correctly and used within appropriate volume limits. A 128-bit random value gives a large space. Randomness does not excuse deliberate reuse or failure to track counter exhaustion.
247

[3_2] Is CBC inherently more secure than CTR?
Properly constructed CBC and CTR can both provide strong confidentiality. Their misuse differs: CBC IV reuse leaks common prefixes while CTR nonce reuse repeats the keystream and can reveal whole message relationships. Neither alone authenticates data.
248

[3_2] Why does block-cipher encryption alone fail to provide integrity or origin authentication?
An attacker may change ciphertext and cause changed plaintext without being detected. Confidentiality does not prove who created the message or that it was unaltered. Use a MAC or an authenticated encryption construction.
249

[3_2] How can an attacker make a chosen change to a known CTR plaintext?
Use C′=C⊕M⊕M_target at the targeted positions. On decryption the original M cancels and M_target appears. The attacker needs the relevant plaintext and ciphertext but does not need the secret encryption key.
250

[3_2] In CTR, how can ciphertext byte 0x57 for digit 1 (0x31) be changed to decrypt as 9 (0x39)?
The change mask is 0x31⊕0x39=0x08. XOR the original ciphertext byte with it: 0x57⊕0x08=0x5F. The corresponding plaintext digit changes from 1 to 9 without knowing the secret key.
251

[3_2] Why does garbled plaintext after a CBC modification fail to prove authenticity?
The receiver cannot conclude from gibberish alone that the sender did not send it. Some modifications are also predictable. A cryptographic verification tag is needed to reliably reject unauthorized changes.
252

[3_3] What does a cryptographic hash function do?
It maps an arbitrary-length message M to a fixed-length digest H(M). The digest acts as a compact fingerprint. Different input lengths still produce the same output length for a selected hash algorithm.
253

[3_3] What can comparing two file hashes establish?
Different hashes prove the files differ. Matching hashes are strong evidence of equality when a secure hash is used but not mathematical proof because collisions exist. Compare against a trusted reference digest.
254

[3_3] What functional properties should a cryptographic hash have?
It is deterministic and efficient. It should resist preimage and second-preimage and collision attacks. A small input change should produce a substantially different digest through the avalanche effect.
255

[3_3] How do preimage, second-preimage, and collision resistance differ?
Preimage: given a digest find any message hashing to it. Second preimage: given one message find a different message with its digest. Collision: find any two different messages with the same digest.
256

[3_3] What digest lengths do MD5 and SHA-1 produce and why are they unsuitable for collision resistance?
MD5 produces 128 bits and SHA-1 produces 160 bits. Practical collision attacks broke their collision-resistance goals. The slides associate MD5 with 2004 attacks and SHA-1 with the 2017 demonstrated collision.
257

[3_3] How do the named SHA-2 and SHA-3 variants relate to digest length?
SHA-256 and SHA-384 and SHA-512 produce 256 and 384 and 512 bits. SHA3-256 and SHA3-384 and SHA3-512 produce the corresponding lengths using the different Keccak design. SHA-3 does not imply SHA-2 must be abandoned.
258

[3_3] Why is a bare secret-prefix hash such as H(K∥M) risky with SHA-256?
Length extension can let an attacker extend a known hash to cover added data without knowing the original secret. Proper HMAC avoids this construction's weakness. The warning does not apply identically to every SHA-2 variant.
259

[3_3] What is a birthday attack against an n-bit hash?
A collision search that exploits the large number of pairs among sampled messages. Generic collision work is about 2^(n/2) while generic preimage work is about 2^n. Collision resistance therefore requires more output bits than equivalent preimage resistance.
260

[3_3] Is replacing a particular published program with one having the same digest a collision or second-preimage problem?
If the genuine program is fixed first it is a second-preimage problem. Finding any two programs with matching hashes is a collision problem. The two attack goals have different difficulty.
261

[3_3] Why does sending a message together with its unkeyed hash fail to stop an active attacker?
The attacker can replace the message and recompute the hash. The receiver sees a consistent pair. Integrity requires protecting the reference hash or using a secret-key MAC or digital signature.
262

[3_3] When can a published download hash help detect tampering?
When the expected digest is obtained through a trusted channel the attacker cannot change. Compute the downloaded file's hash and compare it with that reference. A mismatch detects a changed or corrupted download.
263

[3_3] How do spoofing and tampering differ?
Spoofing creates a message pretending to come from another sender. Tampering changes a legitimate message. A MAC helps detect both when the attacker does not possess the shared secret key.
264

[3_3] What does a message authentication code or MAC provide?
A keyed tag supplies integrity and data-origin authentication among parties sharing the key. It does not encrypt the message and does not provide non-repudiation because either key holder could generate the tag.
265

[3_3] How do you send and verify a MAC-protected message?
Generate a shared key K. Sender computes T=MAC_K(M) and sends M with T. Receiver recomputes the tag over the received message and compares. Accept only if verification succeeds.
266

[3_3] What does EU-CPA security require for a MAC?
Even after obtaining tags on chosen messages an efficient attacker should have only negligible probability of producing a valid tag for a new message that was not queried. This is existential unforgeability under chosen-message access.
267

[3_3] Does a valid MAC by itself stop replay?
No. An attacker can resend a previously valid message and tag. Include and verify freshness information such as a sequence number or nonce to distinguish a new message from a replay.
268

[3_3] What is the simplified nested-MAC formula used in the course?
NMAC_(K1,K2)(M)=H(K1∥H(K2∥M)). The course uses two independent secret keys each the length of the hash output. Its two-key setup motivates HMAC's single-key construction.
269

[3_3] How is an HMAC key normalized?
Use the hash's input block size B. If K exceeds B bytes first hash it. Then zero-pad the resulting key or any shorter key to B bytes to obtain K′. Do not confuse block size with digest size.
270

[3_3] What is the HMAC formula and what are ipad and opad?
HMAC_K(M)=H((K′⊕opad)∥H((K′⊕ipad)∥M)). ipad repeats byte 0x36 and opad repeats byte 0x5C across the hash input block. The nested passes use different derived key masks.
271

[3_3] What are SHA-256's input block size and full HMAC tag size?
SHA-256 processes 64-byte input blocks and produces a 32-byte digest. HMAC-SHA256 therefore normalizes its key to 64 bytes and produces a full 256-bit tag. These are two different sizes.
272

[3_3] How is an HMAC named and who can verify it?
It is named for its hash such as HMAC-SHA256 or HMAC-MD5. A verifier needs the shared secret key to recompute the tag. HMAC is deterministic and efficient but does not hide the message.
273

[3_3] What does authenticated encryption add to ordinary encryption?
It provides confidentiality together with integrity and authenticity. It combines protection against reading messages with reliable rejection of unauthorized modifications.
274

[3_3] What are the sender's encrypt-then-MAC steps?
1. Encrypt M using K_enc to obtain C. 2. Compute T=MAC_K_mac(C). 3. Send C and T. Authenticate all encryption inputs that need integrity such as the IV or nonce along with the ciphertext.
275

[3_3] What are the receiver's encrypt-then-MAC steps?
1. Verify the tag on the received ciphertext and associated authenticated inputs. 2. Reject on failure. 3. Decrypt only after successful verification. This detects tampering before processing plaintext.
276

[3_3] What is ciphertext integrity?
An attacker cannot create a new accepted ciphertext without authorization. Encrypt-then-MAC can provide it by authenticating ciphertext before decryption with an independent secure MAC key.
277

[3_3] What are the sender's MAC-then-encrypt steps?
1. Compute T=MAC_K_mac(M). 2. Encrypt M∥T using K_enc. 3. Send the resulting ciphertext. The tag itself is hidden inside the encrypted content.
278

[3_3] What must a MAC-then-encrypt receiver do before checking integrity?
Decrypt the ciphertext and parse the recovered message and tag. Then verify the MAC on the plaintext. Tampering is detected only after decryption so the decryption path can become an attack surface.
279

[3_3] Why is encrypt-then-MAC generally easier to use safely than MAC-then-encrypt?
It can reject altered ciphertext before decryption. MAC-then-encrypt may leak information through padding errors or response timing. Arbitrary secure encryption and MAC components do not automatically make every MAC-then-encrypt combination secure.
280

[3_3] What is a padding oracle?
A system whose observable behavior reveals whether decrypted padding was valid. Differences in errors or timing can let an attacker learn plaintext through repeated modified ciphertexts. Authentication before decryption helps prevent this exposure.
281

[3_3] Why should encryption and authentication use different keys?
Reusing one key across functions can cause unexpected interactions. Derive independent keys for encryption and for each communication direction's MAC as required by the protocol.
282

[3_4] How do public-key encryption and digital signatures fit the primitive categories?
Public-key encryption supplies asymmetric confidentiality. Digital signatures supply asymmetric integrity and origin authentication. Their symmetric counterparts are shared-key encryption and MACs.
283

[3_4] Whose public and private keys protect a message sent confidentially to Bob?
The sender encrypts with Bob's public key. Bob decrypts with his private key. Bob's private key must remain secret while the sender must obtain an authentic copy of his public key.
284

[3_4] What tradeoff does public-key encryption make compared with symmetric encryption?
It avoids requiring a pre-shared secret for encryption but uses more expensive operations. A public key may be distributed openly while the matching private key remains with its owner.
285

[3_4] What are the public-key encryption algorithms and correctness condition?
KeyGen creates matching PK and SK. Enc_PK(M) creates C. Dec_SK(C) recovers M. Correctness requires Dec_SK(Enc_PK(M))=M. Secure encryption must also prevent efficient message recovery and support the intended indistinguishability goal.
286

[3_4] What is a trapdoor one-way function?
A function that is easy to compute but hard to reverse without special secret information. The secret trapdoor makes reversal efficient for the intended private-key holder.
287

[3_4] Which mathematical problems underlie RSA, Diffie–Hellman, ElGamal, and ECC?
RSA is associated with integer factorization. Diffie–Hellman and ElGamal use discrete-logarithm-related problems. Elliptic-curve cryptography uses problems such as the elliptic-curve discrete logarithm problem.
288

[3_4] How do you generate a textbook RSA key pair?
1. Choose distinct large primes p and q. 2. Compute n=pq and φ(n)=(p−1)(q−1). 3. Choose e with gcd(e,φ(n))=1. 4. Compute d=e^−1 mod φ(n). Publish (e,n) and keep d and the factors secret.
289

[3_4] What does it mean for e to have a modular inverse d?
ed≡1 mod φ(n). Such an inverse exists when gcd(e,φ(n))=1. Use the extended Euclidean algorithm to find d. For example 3×27=81≡1 mod 40.
290

[3_4] What are textbook RSA encryption and decryption formulas?
For a message representative 0≤M<n compute C=M^e mod n. Recover M=C^d mod n. These raw formulas illustrate the mathematics and require secure encoding for real encryption.
291

[3_4] How do you obtain the RSA keys when p=5, q=11, and e=3?
n=5×11=55. φ(n)=4×10=40. gcd(3,40)=1. Since 3×27=81≡1 mod 40 choose d=27. The public key is (3,55) and the private exponent is 27.
292

[3_4] With RSA n=55, e=3, and d=27, how do you encrypt and decrypt M=6?
Encrypt: C=6^3 mod 55=216 mod 55=51. Decrypt: M=51^27 mod 55=6. Use modular exponentiation instead of constructing the entire huge power.
293

[3_4] Why does textbook RSA decryption undo encryption?
ed=1+k(p−1)(q−1). Fermat's little theorem gives M^(ed)≡M mod p and mod q. The Chinese remainder theorem combines these congruences to give M^(ed)≡M mod n.
294

[3_4] What do Fermat's little theorem and the Chinese remainder theorem contribute to RSA correctness?
For prime p and a not divisible by p Fermat gives a^(p−1)≡1 mod p. CRT says matching residues modulo distinct primes p and q determine the same residue modulo pq. Zero residues are handled directly.
295

[3_4] Which algorithms make RSA computations practical?
Primality tests find suitable random primes. Extended Euclid computes the inverse d. Repeated squaring performs fast modular exponentiation. The slides list e=3 and e=65537 as exponent examples. Small classroom primes are only demonstrations.
296

[3_4] Why is raw RSA not IND-CPA secure and how is this addressed?
Raw RSA is deterministic so a public-key holder can encrypt guessed messages and compare them. RSA-OAEP adds randomized encoding to provide a secure public-key encryption construction under its assumptions.
297

[3_4] Why would factoring the RSA modulus compromise the private key?
From p and q an attacker computes φ(n) and then d=e^−1 mod φ(n). Keeping the factors secret is therefore essential. The course's RSA security assumption concerns the difficulty of this problem with properly chosen large parameters.
298

[3_4] What distinguishes ElGamal encryption from textbook RSA?
ElGamal uses fresh randomness and discrete-logarithm-related assumptions. The same plaintext can produce different ciphertexts. Its two-component ciphertext has roughly twice the message-representation size in the simplified comparison.
299

[3_4] What is the key-size advantage of elliptic-curve cryptography?
Appropriate elliptic-curve schemes can provide comparable security with smaller keys than RSA. Their hardness assumption involves elliptic-curve problems rather than integer factorization. Smaller keys can help constrained devices.
300

[3_4] What are the steps of hybrid encryption?
1. Generate a fresh symmetric key K. 2. Encrypt the message with a suitable symmetric scheme using K. 3. Protect K with the recipient's public-key scheme. 4. Send both protected key material and encrypted message.

247 more cards in OutLearn. Open the full deck

Study all 547 cards for free