Security, privacy and the ethics of data

A-Level Computer Science · Databases and Data Security

Three words that are not synonyms

Security is protecting data from unauthorised access, alteration or loss. Privacy is the right of an individual to control data about themselves. Integrity is the data being accurate and consistent. A system can be secure but still invade privacy, and can be private but hold inaccurate data.

Threats

Malware (virus, worm, trojan, ransomware, spyware), phishing and other social engineering, brute-force attacks on weak passwords, SQL injection through unvalidated input, interception on unencrypted networks, and accidental loss or deletion by staff — which is far more common than deliberate attack.

Countermeasures, matched to the threat

Firewall filters traffic; encryption makes intercepted data unreadable without the key; access rights limit what each user can see; two-factor authentication defeats a stolen password; input validation and parameterised queries stop SQL injection; regular patched updates close known holes; and backup is the only defence against ransomware and accidental deletion. Marks come from matching the measure to the specific threat, not from listing measures.

Encryption

Symmetric encryption uses one key for both operations: fast, but the key must be shared securely, which is the hard part. Asymmetric uses a public key to encrypt and a private key to decrypt, solving key distribution at the cost of speed. In practice asymmetric is used to exchange a symmetric key, then symmetric does the bulk work. A digital signature reverses the roles to prove who sent a message.

The ethical questions

Data protection principles: collect only what is needed, keep it accurate, keep it no longer than necessary, keep it secure, and let people see what is held about them. Beyond the law, the exam asks about the ethics: whether an employer should monitor staff, whether an algorithm trained on biased data should decide who gets a loan, and who is responsible when automated software causes harm.

Worked example: matching measures to each threat

A clinic keeps patient records on an internal server. Three incidents happen in one year:

(i) an employee clicks a link in an email impersonating a bank and enters the system password;
(ii) all files are encrypted and the attacker demands a ransom;
(iii) a receptionist looks at a neighbor's medical record.

For each incident, state a suitable measure and explain why.

Solution

(i) Phishing to steal a password.

Main measure: two-factor authentication. An attacker who has the password still cannot log in because they lack the one-time code on the employee's phone. This is the only measure that neutralizes the consequences of a leaked password.

Additional: training to recognize fake emails, and mail filters. But note that training reduces the probability rather than eliminating it; people will still click by mistake, so the technical measure must withstand that.

(ii) Ransomware.

Main measure: regular backups, stored outside the internal network (offline or append-only), and a restore procedure that has been tested. This is the ONLY real line of defense: with a copy, the clinic recovers and does not pay the ransom.

Important detail: the copy must be out of reach of the infected machine. If you back up to a network drive that is always connected, the ransomware encrypts the copy as well; this mistake happens very often in practice.

Additional: up-to-date anti-malware software and operating system patches to reduce the chance of infection in the first place.

(iii) A receptionist viewing a neighbor's record.

This is not a security incident in the usual sense; the person logged in legitimately. It is a privacy and access rights problem.

Measure: role-based access control; a receptionist only needs to see the name, appointments and contact details, not diagnoses. Together with an access log recording who viewed which record, reviewed regularly, so that abuse of access is detected.

General lesson. Three incidents need three completely different measures. Answering "install a firewall and antivirus software" for all three loses almost all the marks, because a firewall cannot stop an employee typing a password into a fake page, and it cannot stop someone with access from viewing what they should not.

Common mistake

Confusing security with privacy. A system with strong encryption that nobody can break into can still violate privacy if it collects too much data or lets too many people in the organization see it. The ethics question is always in the second half.

Key takeaway

Match the measure to the specific threat rather than listing. Remember that off-network backup is the only line of defense against ransomware, two-factor authentication is the line of defense against a leaked password, and access rights are a privacy matter, not a firewall matter.

← SQL and the DBMS · All A-Level Computer Science lessons · Practice A-Level Computer Science questions (free, instant scoring) · Abstract data types: stacks, queues and linked lists →