G3 Computing Textbook Chapter 11
G3 Computing Textbook Chapter 11
CHAPTER
439
440
441
11.1 Defining Security and Privacy
LEARNING OUTCOMES
4.3.1 Compare and contrast security and privacy in terms of what kind of data is being protected,
what the data is being protected from and how that protection is enforced.
As technology is an integral part of our daily lives, learning how to protect our digital information has
become crucial. Related to the protection of digital information are the concepts of security and privacy.
Security is the practice of protecting the confidentiality, integrity and availability of data. These three
principles are defined in Table 11.1 and described further in sections 11.1.1 to 11.1.3. Security is applicable
to all kinds of data in general, from private messages to public websites, and it is about protecting such
kinds of data from unauthorised access, unauthorised modifications, or disruptions in typical use. We can
think of security as the padlock on the door of a house, keeping intruders out.
Principle Definition
442
442
ER MS
The following table compares
security and privacy in terms KEY T
of what kind of data is being Security
protected, what the data The practice of protecting the confidentiality, integrity and availability of
is being protected from data
and how that protection is
enforced. Personal Data
Any data related to a person that may allow that person to be identified
Privacy
The practice of protecting the confidentiality and control of personal data
443
11.1.1 Confidentiality
11.1.2 Integrity
11.1.3 Availability
444
ER MS
KEY T
Availability
The ability to access data in a timely and uninterrupted fashion
Confidentiality
The protection of data from unauthorised access
Data corruption
The introduction of errors and inconsistencies into data
Denial-of-service attack
A type of attack where a server is overwhelmed with excessive requests such that it cannot respond or
responds very slowly to legitimate requests
Integrity
The protection of data from unauthorised modification
U
DID YO
KNOW?
The effects of data corruption on availability can vary depending on the amount and type of
corrupted data.
If the corrupted data is not needed to read other data, then the availability of only the corrupted
data itself is affected. This situation is more likely if the amount of corrupted data is small. This is like
having smudged cells in a printed table of data – only the smudged data is affected.
445
U
DID YO
KNOW?
On the other hand, if the corrupted data is related to other data, then the availability of both the
corrupted data and its related data may be affected. This is because the corrupted data may contain
information that is required to read or interpret the related data. This situation is more likely if the
amount of corrupted data is large. This is like having smudged headers in a printed table of data.
While the cells of the table are still readable, it is not possible to interpret what the contents mean,
so the data stored in the table is meaningless and effectively unusable.
Figure 11.3 Data in the entire table is effectively unusable due to the smudged header
For example, Figure 11.4 shows a typical error message that a user may get when trying to open a
corrupted file in a word processor.
When availability is disrupted, undesirable consequences may occur. For example, in business, interruptions
to key systems or data may require halting operations, leading to financial losses. In an emergency, the
inability to access critical information can interfere with the response, endangering lives.
446
QUICK .1
C K 1 1
CHE
1. In each of the following scenarios, identify which of confidentiality, integrity or availability,
has been the most significantly compromised:
b) A passenger on a crowded train reads the contents of an email over the shoulder of another passenger who
is using their phone.
c) A photo sharing site adds a watermark to uploaded photos without the owner’s permission.
2. To use a photo storage service, a user is required to provide their email address and let the service share
the email address with other companies without informing the user. In return, the service lets the user view
their photos online and prevents the photos from being accessed or modified by anyone else.
b) Suggest and explain one way in which the service has poor privacy.
11.2 Threats
LEARNING OUTCOMES
4.3.2 Explain how human actions threaten security and privacy by causing data corruption
(through physical or non-physical means) or exposure of private data.
4.3.7 Explain how adware threatens security and privacy by installing itself without the user’s
knowledge and displaying unwanted advertisements.
4.3.8 Explain how spyware threatens security and privacy by secretly collecting personal
information and transmitting this information to attackers without the user’s knowledge.
4.3.9 Explain how cookies are typically not malicious but can threaten privacy by tracking a user’s
browsing history across multiple web sites.
4.3.10 Explain how phishing threatens security and privacy by using emails and fake websites that
appear to be from reputable companies to steal personal information.
4.3.11 Explain how pharming threatens security and privacy by intercepting requests to legitimate
websites and redirecting them to fake websites while still appearing to use the same address
as the legitimate website.
There are many common threats to the security and privacy of data.
447
11.2.1 Human Actions
Human actions can threaten security, specifically the integrity of data, by causing data corruption. This
may be malicious or accidental and can happen through either physical or non-physical means, as shown
by the examples in Table 11.3:
Non-physical
Table 11.3 Examples of how human actions can threaten data integrity
Human actions can also threaten privacy through the malicious or accidental exposure of private data.
For example, privacy is compromised when an email containing personal data is sent to unauthorised
recipients.
11.2.2 Adware
Adware is a type of malicious software (also known as malware) that installs itself without the user’s
knowledge and displays unwanted advertisements. The advertisements may appear as separate “pop-up”
windows or be injected into web pages.
U
On its own, displaying unwanted advertisements
DID YO
KNOW?
may not threaten security or privacy. However,
by installing itself without the user’s knowledge,
adware threatens the computer’s integrity
and may leave open the door for other forms
of malware to be installed. To display relevant
advertisements, many examples of adware collect Another definition of “adware” is advertising-
data on the user’s habits without permission (like supported software that is installed knowingly
spyware; see section 11.2.3). The advertisements by the user. The software is usually free-of-
they display may also promote phishing sites charge but shows advertisements to make
(see section 11.2.5) and scams to steal personal money. Note that this is not the definition of
data. In this way, adware can also be considered “adware” used in this textbook.
a threat to security and privacy.
448
ER MS
KEY T
Adware
A type of malware that installs itself without
the user’s knowledge and displays unwanted
advertisements
11.2.3 Spyware
U MS
DID YO KEY T
ER
KNOW? Spyware
A type of hidden malware
that secretly collects personal
Certain kinds of malware are designed to widen the damage information about its users and
they cause by making multiple copies of themselves. transmits this information to
attackers without the users’
For instance, a “virus” attaches itself to a normally harmless knowledge
program or file and modifies it. When the modified program
is run or a modified file is opened by a user, the virus attaches
copies of itself to any other programs or files it can find, thus
“infecting” them.
449
11.2.4 Cookies
ERMS
KEY T
Cookies are small pieces of data stored by the web browser
when a user visits a website. Each time a user visits a website
that uses cookies, the web browser checks whether it has a
relevant cookie and if so, it sends the information contained in Cookies
that cookie back to the website. The website is thus aware that Small pieces of data stored by the
the user is a repeat visitor and, in some cases, will customise web browser when a user visits a
what appears on the page for the user. On the other hand, if website
no relevant cookie is found, the website may request for a new
cookie to be created.
11.2.5 P is ing
ER MS
Phishing is the use of emails, messages and fake
websites that appear to be from reputable companies KEY T
to steal personal data such as passwords and credit Phishing
card numbers from users. In this way, phishing is a The use of emails, messages and
threat to both security (specifically the confidentiality fake websites that appear to be from
of data) and privacy. Figure 11.7 shows some examples reputable companies to steal personal
of phishing websites, messages and emails. data from users
450
U
DID YO
N O W ?
K
Phishing is a play on the word “fishing”. The idea is that bait is thrown out with the hope that
while most fish might ignore the bait, some will be tempted into biting. Similarly, phishing
emails are sent to many recipients in the hope that some recipients will eventually fall for the
scam and give away their personal data.
11.2.6 P arming
ER MS
Pharming is a more serious form of phishing. In
pharming, the attacker will attempt to intercept KEY T
requests sent from a computer to a legitimate Pharming
website and redirect the user to a fake website The interception of requests sent from a
to steal personal data or credit card details. Like computer to a legitimate website and the
phishing, pharming is a threat to both security redirection of those requests to a fake website to
(specifically the confidentiality of data) and steal personal data
privacy.
For example, when victims of pharming enter the web address of their bank into a web browser, they would
be presented with a website that appears to be genuine but is provided by the attacker’s web server. When
they try to log in to the fake website, their usernames, passwords and account details would be recorded
by the attacker, who can then use these details to access the victims’ bank account on the bank’s actual
website.
For pharming to be successful, the attacker must either have malware running on the victim’s computer or
have taken control of a network device such as a router or server. This can occur as the software that runs
on such devices is also susceptible to bugs.
451
I G
N A
I MAEME
G
M
Can you guess which website is the real one?
QUICK
EC K 11.2
CH
1. In each of the following scenarios, identify the common threat to the security and/or privacy of data that is
being depicted:
a) After visiting a shopping website, a user notices that advertisements for the exact items they viewed are
appearing in other unrelated websites.
b) A user notices that pop-up advertisements for a gambling website appear whenever their computer is
started.
c) A user visits their bank’s website and notices that the website looks suspicious even though the URL is correct.
d) A user notices that a link in an email that appears to be from their bank goes to a URL that misspells the
bank’s name.
f) A user notices unexpected network activity and their computer running more slowly whenever it is connected
to the Internet.
452
11.3 Defences
LEARNING OUTCOMES
4.3.3 Explain how anti-malware programs enforce security and privacy by preventing malware
from running and removing malware that may be present on a computer.
4.3.4 Explain how firewalls enforce security and privacy by using either hardware or software to
monitor packets and decide which packets should be permitted or blocked based on a set of
configurable rules.
4.3.5 Explain how encryption enforces security and privacy by making encrypted data appear
meaningless without the corresponding secret key.
4.3.6 Explain how the Personal Data Protection Act (PDPA) enforces privacy by legally requiring
organisations to do the following when collecting personal data:
• seek consent from the individual;
• disclose the purpose for collecting data when seeking consent; and
• retain the data for only as long as necessary to fulfil the stated purpose
4.3.12 Describe good computing practices that can mitigate the threats posed by adware, spyware,
cookies, phishing, pharming and human actions.
Multiple forms of defence are available to repel threats and enforce the security and privacy of data.
U
DID YO
N O W ?
K
Multiple forms of defence are needed so threats that manage to overcome weaknesses in one form
of defence can be stopped by the other forms of defence that are present. This is sometimes called
“defence in depth” or the “Swiss cheese model”.
We can imagine each form of defence as a slice of Swiss cheese, with holes that represent weaknesses
in random locations and sizes. As more slices of Swiss cheese (each representing a different form of
defence) are stacked together, it becomes more unlikely for the holes to line up such that a threat
can pass through and cause damage.
Figure 11.9 Threats (red lines) are stopped from passing through multiple layers of defence
453
11.3.1 Anti- al are Programs
Adware and spyware are examples of malware that need to run on a user’s computer to compromise
security and/or privacy. Anti-malware programs can be used to:
U
DID YO
KNOW?
Malware programs that pretend to be legitimate
software are called “Trojan horses”, named after the
story in Greek mythology where Greeks used a wooden
horse to infiltrate the city of Troy and carry out a
surprise attack.
Computers that are connected to a network are naturally more susceptible to intrusion as unauthorised
access can occur even without the physical presence of an intruder. Hence, computers connected to a
network usually require another layer of defence called a firewall. Just like how a fireproof barrier prevents
fire from spreading and destroying valuable property, a firewall prevents harmful contents from passing
through it to reach other computers connected to the network.
A firewall can be either a device or a computer program. It works by monitoring each piece of data that is
transmitted through a network. Then the data would be either blocked or allowed to pass through, based
on a set of rules configured by an administrator.
454
Figure 11.10 A firewall protects a network from external threats
When properly configured, a firewall can protect the computers within a network from unauthorised access.
For instance, a firewall can be configured to block the transmission of data (known as traffic) between any
unauthorised senders and/or receivers, especially requests for data coming from anonymous users on the
Internet. This prevents intruders from gaining access to the computers within a network.
As a firewall can also block traffic based on the type of application that is transmitting the data, it can also
stop certain malware such as adware and spyware from sending copies of themselves to other computers
through the network.
Conversely, however, configuring a firewall correctly can be a complex task and a misconfigured firewall
may unintentionally allow an intruder to gain access to computers on the network.
11.3.3 Encryption
Often, violations of privacy are not caused by the victim’s direct actions. Instead, these violations occur
indirectly due to the actions of third-party users or services. For instance, social networking sites such as
Facebook, X (formerly Twitter), Instagram and TikTok allow users to share photographs and information
quickly with their family and friends. However, most users may be unaware or do not consider the
repercussions of how such sites retain personal data or share personal data with third-parties.
To safeguard the personal data of users in Singapore, organisations are legally required to comply with the
Personal Data Protection Act (PDPA) that governs the collection, protection and use of personal data.
Specifically, when organisations collect personal data, they must:
455
Organisations are prohibited from using personal data for purposes unrelated to those stated at the time
of collection without obtaining further consent. They must also make reasonable efforts to keep personal
data accurate and up-to-date, as well as implement appropriate security measures to prevent unauthorized
access, disclosure, or misuse. To ensure compliance, organisations found to be in violation of the PDPA
may be required to pay heavy fines.
ER MS
KEY T
Personal Data Protection Act (PDPA)
A law that governs the collection,
protection and use of personal data in
Singapore
Besides technical and legal defences, there are several good computing practices that help to protect
against security and privacy threats.
U
Authentication is the process of DID YO
KNOW?
verifying the identity of a user and the
most common authentication method
is to ask for a secret password or phrase
that is known only to that user. Most
computer users are probably familiar A strong password should have the following elements:
with the process of entering a password
to use a computer or online account.
Such passwords are usually entered
together with a username that identifies
who the user is claiming to be.
456
11.3.5.2 Use ulti-Factor Aut entication
Passwords are only one form of authentication. In general, authentication may require users to prove their
identity by providing evidence from one or more of the following categories:
Each category of evidence that is used for authentication is called an authentication factor.
More stringent authentication systems often require evidence from more than one authentication factor.
For instance, some banks or organisations may issue a device called a security token to users who wish to
access their accounts online.
To access their account online, the user has to confirm their identity by providing a secret password or
personal identification number (PIN), followed by a one-time password (OTP) generated from the security
token or a mobile phone that the user owns. This kind of authentication that uses evidence from both
something the user knows and something the user owns is called two-factor authentication. Two-factor
authentication is stronger than using only a password as it is much more difficult for an intruder to both
guess a password and steal the user’s security token.
Biometrics is a type of authentication that is based on the measurement of human physical characteristics.
For example, biometrics is used to identify a user by fingerprint or voice. Other common characteristics
used in biometrics include the face, iris, retina, and deoxyribonucleic acid (DNA). Compared to passwords,
the use of biometric identification is more secure as the physical characteristics measured are typically
unique to the individual and cannot
be easily replicated.
ER MS
Figure 11.12 shows some of KEY T
the common human physical
Authentication
characteristics used in biometrics.
The process of verifying the identity of a user
Authentication factor
A category of evidence that is used for authentication: something
the user knows or owns, or something that is measured from a
physical part of the user
Biometrics
A type of authentication based on the measurement of human
physical characteristics
Security token
A device that is used specifically for authentication purposes
Two-factor authentication
A type of authentication that uses evidence from both something
the user knows and something the user owns
457
100 %
By using deceptive emails, messages and fake websites to steal personal data, phishing attacks typically
serve as the initial stage of many scams that aim to deceive unsuspecting individuals or organisations
and perpetuate further forms of fraud. Hence, it is important to learn how to identify phishing and scam
attempts.
The email or message claims to be from a The email or message uses a generic greeting
company or bank and asks for personal data such as “Dear Customer” or “Dear User”. This
or confidential information. Most companies is a sign that the email was sent automatically
or banks will never ask for such information and not by a person. Alternatively, the email
via email or chat. When in doubt, call the or message may get your name correct but
company or bank to verify. get other details of your identity (e.g., your
occupation or country of residence) wrong.
Errors
458
Suspicious Links
Urgent Requests
KNOW?
avoid being detected. For instance,
some scammers can obtain supposedly
private personal data from previous
cyberattacks and craft scam messages
that include personal details to
appear more convincing. To avoid
being deceived, be cautious of any
unexpected emails and messages, even
if they mention details that you would
not expect a stranger to know.
459
U
DID YO
KNOW? Reported Scam Cases
1. Add
2. Check
3. Tell
460
11.3.5.4 Update Soft are egularly
Malware programs such as adware and spyware can install themselves without the user’s knowledge by
exploiting bugs or unintended behaviour in otherwise legitimate programs that are already running on the
computer. For instance, a flawed web browser may have a bug that allows malware to be installed by just
visiting a website.
To avoid such situations, it is important to update software regularly so that bugs that were discovered
since the last update can be fixed. This is especially important for software that is used to interact with the
Internet, as data from untrusted online sources is more likely to be malicious and can be designed to take
advantage of known bugs.
Although cookies are not generally malicious, they can be used to keep track of user movements from
one website to another. For users who want to keep their movements on the Internet private, most web
browsers have settings that allow users to manually delete cookies or prevent cookies from being created
by untrusted websites. These settings can also be configured to disable cookies or allow only selected
websites to use cookies.
A backup is a copy of data that is made so it can be recovered if the original is lost. By making regular backups
of important files and information, it is possible to limit the damage to data integrity and availability caused
by data corruption or human actions. For instance, if multiple users accidentally overwrite each other’s
work when working on the same file, having a recent backup of the file will allow the overwritten data to be
restored. Ideally, backup copies should also be stored on a separate device from the original (e.g., backing
up local files on an online server), so if the original is lost due to device failure, the backup copy will not be
affected.
461
QUICK .3
C K 11
CHE
1. In each of the following scenarios, identify the defence against the security and privacy threats that is being
depicted:
a) A password needs to be entered each time to read a confidential document. Without entering the password,
the document appears as meaningless data.
b) A user has a monthly reminder to change their passwords and update the software installed on their
computer.
c) A website is fined for using the personal data of its users for tracking their movements on other sites without
informing the users beforehand.
e) A spyware program successfully runs but is not able to send its recorded data to the attacker’s server on the
Internet.
2. A user discovers malware running on a computer even though there is an anti-malware program that is also
running on the same computer. Suggest some reasons to explain how this is possible.
3. A website asks for the user’s consent to share their email address, with a notice that the purpose for collecting
the user’s email address will be provided afterwards. Explain whether the website complies with the PDPA.
4. You receive an unexpected email that advertises a free program from a website you have not heard of before.
The advertisement has links to download the program or to learn more about the product. The program seems
useful, but you do not have any anti-malware protection and want to be sure that the program is not malware.
What should you do?
A Click on the link to download and run the program to try it out.
B Click on the link to learn more about the product.
C Close the email and search trusted sites for more information.
D Reply to the email and ask for more information.
5. State whether each of the following is a measure that can be taken to avoid receiving phishing emails:
b) Use the same email address for schoolwork and online games.
462
11.4 Analysis
LEARNING OUTCOMES
4.3.13 Analyse the effects of anti-malware programs, firewalls, encryption and the PDPA against
the threats posed by adware, spyware, cookies, phishing, pharming and human actions.
Not all defences are equally effective against the different threats to security and privacy that we have
discussed. Table 11.4 summarises the effectiveness of anti-malware programs, firewalls, encryption and
the PDPA against the threats posed by adware, spyware, cookies, phishing, pharming and human actions.
463
Anti-Malware Firewalls Encryption PDPA
QUICK 1. 4
K 1
C HEC
1. A hardware firewall is installed at the gateway (e.g., the modem) between a home network and the Internet.
Which of the following definitely cannot be prevented by this firewall?
2. Which of the following scenarios involving unauthorized access cannot be effectively prevented by encryption
alone?
3. Human actions can cause data corruption or the exposure of private data. In each of the following scenarios,
identify which defence against security and privacy threats would be most effective against the threat being
depicted:
a) A company collects email addresses for the purpose of advertising their products, but later decides to share
the email addresses with another company without prior notice.
464
W
REVIE N
S TI O
QUE
1. Attackers may use spyware to monitor what you do on your computer. Which one of the following is not likely
to be a sign that your computer is affected by spyware?
2. A movie company uses the mobile phone numbers and email addresses of its customers to send electronic
tickets and to promote upcoming movies. As a result of unauthorised access, an attacker manages to access the
company’s collection of mobile phone numbers and email addresses and releases this data to the public.
Suggest how such an incident may negatively affect the company and its customers.
3. Siti receives an email message from a stranger claiming that she has won a cash prize from a lucky draw.
The stranger wants to know her bank account details to transfer the prize money to her. Suggest briefly what
Siti should do.
4. Recently, the customers of a bank received an email with “Transaction Advice” as the subject. The email
contained a hyperlink to a fake website which looked like the bank’s real website. Some customers did not pay
attention to the address of the hyperlink and tried to log in as usual. As a result, their personal information was
stolen.
c) Describe two ways in which the bank customers could have avoided getting their personal data stolen.
5. For each of the following threats, identify and explain whether unauthorised access is likely to occur. For each
threat where unauthorised access is likely to occur, suggest one preventive measure that can be taken.
a) Cookies
b) Spyware
465
ANSWER
2. a) The service protects the confidentiality and integrity of the stored photos as only the authorised user can
access or modify them. The service also protects the availability of the stored photos by providing the user
with timely and uninterrupted (i.e., reliable) access to the photos online.
b) To use the service, the user must give up some confidentiality and control of their personal data (i.e., their
email address) as the user cannot control who the service shares their email address with.
3. The website may not comply with the PDPA as it requires organisations to disclose the purpose for collecting
data when seeking consent and not afterwards.
4. C
5. a) Yes
b) No
c) Yes
d) No
2. D
3. a) PDPA
b) Anti-malware
c) Encryption
d) Firewalls
466
ANSWER
3. Siti should verify the authenticity of the source by checking that the sender is legitimate, and if necessary,
calling the organiser of the lucky draw and asking for proof of the lucky draw results. Even if the result is
legitimate, she should request to receive the cash prize in a manner that will not reveal her personal details to a
stranger. If there is any doubt, she should decline to reveal any personal details and ignore the message.
4. a) Phishing uses email hyperlinks that lead to a fake website with a different address from the real website,
while pharming uses website redirection to show a fake website that uses the same address as the real
website.
b) Phishing
c) Two possible ways (accept any of the following answers):
• The customers could have verified if the email hyperlink’s actual destination matched the real
address of the bank’s website before clicking on it.
• The customers could have contacted the bank directly to verify the identity of the sender and the
authenticity of the email.
5.
Part Threat Unauthorised access likely to Preventive measure
occur? Why?
a) Cookies No -
467