Threats target people, code, and uptime.

Learning Objectives

By the end of this chapter, you will be able to:

  • Classify malware: virus, worm, Trojan, ransomware, spyware, botnet.
  • Explain phishing and variants: spear, smishing, vishing.
  • Describe hacking, cybervandalism, data breaches, card and identity fraud.
  • Explain spoofing, pharming, sniffing, man in the middle, insider, and software flaw attacks.
  • Explain DoS and DDoS and distinguish them.
  • Relate each threat to the six security dimensions and to Nepali cases.

1. Threat map

flowchart TB
  T[Threats] --> M[Malicious code]
  T --> P[Phishing and social engineering]
  T --> H[Hacking and vandalism]
  T --> B[Data breach and fraud]
  T --> S[Spoofing and pharming]
  T --> N[Sniffing and MITM]
  T --> I[Insider and software flaws]
  T --> D[DoS and DDoS]
  M --> V[Virus - needs host file]
  M --> W[Worm - spreads alone]
  M --> JT[Trojan - disguised]
  M --> R[Ransomware - encrypts]

Figure 1: Taxonomy of major e-commerce threats

2. Malicious code

Type How it spreads Effect on e-commerce
Virus Attaches to a file, runs when opened Corrupts systems, steals data
Worm Self replicates over network without user action Rapid outages, bandwidth consumed
Trojan Hides in pirated app or cracked software Opens backdoor, steals credentials
Ransomware Encrypts files, demands payment in wallet or crypto Locks order DB, halts fulfillment
Spyware and keylogger Silent install via malicious download Records passwords, card numbers
Botnet Infected devices controlled remotely Sends spam, launches DDoS
PUP and adware Bundled without clear consent Hijacks browser, injects ads, degrades trust

Exposure often comes from pirated software and sideloaded APKs. One infected admin device leaks the CMS password.

3. Phishing and social engineering

Phishing tricks people, not firewalls. The attacker impersonates a bank, wallet, or courier and asks for OTP, PIN, or login.

  • Bulk phishing. Mass email or SMS with a lookalike link.
  • Spear phishing. Targeted message to one employee, often the accountant, using real names and invoices.
  • Smishing. SMS or Messenger variant. Common text in Nepal: your KYC will expire, click to update.
  • Vishing. Voice call pretending to be bank staff asking for OTP.

Illustrative smishing message (the example domain is reserved and is not a real wallet site):

Your wallet KYC expired. Update within 24 hours to avoid a block: http://wallet-update.example/login

Checklist: urgency, threat of block, non official domain, request for login or OTP, http not https. The correct action is to ignore the link, open the official app directly, and report the message.

4. Hacking and cybervandalism

  • Hacking. Unauthorized access to a system. Black hat for crime, white hat with permission to test, grey hat without permission but claiming good intent.
  • Cybervandalism. Defaces or destroys a site, replacing the homepage or catalog images. Hacktivism does it for a cause.

Defacement hits integrity and availability.

5. Data breaches, card fraud, and identity fraud

A breach exposes names and tokens. Causes include weak passwords and phishing.

Card fraud uses stolen details. Merchants bear chargebacks. Identity fraud uses leaked KYC details to open wallet or loan accounts in another person’s name.

6. Spoofing, pharming, and spam sites

  • Spoofing. Forged sender address, fake shop domain such as daraz-deal.com, or fake courier email.
  • Pharming. DNS tampering redirects a correct name to a fake server. The user types the right address but lands on the attacker’s copy.
  • Spam sites. Promise cheap goods or prizes to harvest data or take payment without delivery.

7. Sniffing and man in the middle

Sniffing is capturing network traffic. It can expose passwords or other information sent without encryption. In a man-in-the-middle attack, an attacker intercepts communication between two parties and may read or alter it while pretending to each party to be the other.

For example, an attacker controlling an untrusted Wi-Fi network might try to intercept a customer’s connection to a shop. HTTPS with a valid certificate protects the connection against interception and tampering; users should not ignore certificate warnings. A VPN can also protect traffic between a device and its VPN provider, but it does not replace HTTPS or make an untrusted provider safe.

8. Insider and software flaws

Insiders misuse legitimate access. Detection is hard. Controls include least privilege and logged access.

Software flaws open the door:

  • SQL injection. Attacker types database commands into a login or search field. Weak input handling runs the commands.
  • Unpatched software. Known bugs in CMS plugins and libraries attract automated scans within hours of disclosure.
  • Zero day. Flaw unknown to the vendor, no patch yet, so isolation and WAF rules buy time.

9. DoS and DDoS

A denial of service attack floods a site so real customers cannot connect. A distributed denial of service uses thousands of bots, usually a botnet, so blocking one IP does nothing.

10. Mobile and social platforms

  • Social networks. Cloned seller pages, hacked Messenger accounts that ask friends for urgent transfers, and fake giveaways that collect phone numbers for later phishing.

11. Which dimension does each threat violate?

Threat Primary dimension violated
Malware, ransomware, SQL injection, vandalism Integrity, availability
Data breach, sniffing, spyware Confidentiality, privacy
Phishing, spoofing, pharming, identity fraud Authenticity, confidentiality
Card fraud with denial Nonrepudiation
DoS and DDoS Availability

Nepal Cases

  • Phishing, smishing, and vishing that impersonate banks, wallets, and telecom operators remain the most reported incidents. The goal is OTP or PIN.
  • Hacked Facebook and Messenger accounts message friends for urgent transfers. Fake seller pages take advance payment and disappear.
  • NIC Asia SWIFT fraud in 2074 BS moved funds via fake messages. Most funds were recovered.
  • Foodmandu leak in 2077 BS exposed names and phones used for phishing.

Worked Example: Cost of a phishing campaign against a wallet user base

In 2081 BS, a campaign sends 200,000 smishing messages. Assume 2 percent click, 10 percent of clickers enter OTP, average stolen amount NPR 4,500, and 30 percent of theft is reversed by the PSP.

  • Clicks: 4,000. Entries: 400. Gross theft: 400 x 4,500 = NPR 1,800,000. Net after reversals: 1,800,000 x 0.7 = NPR 1,260,000.
  • Lesson: even low success rates can make a campaign costly to users. Open the official app directly and never share an OTP; these steps reduce this phishing risk but do not prevent every type of fraud.

Self-Check Choose three threats: one that attacks people, one that attacks code, one that attacks availability. Name the dimension each violates and one control that reduces it.

Self-check

What distinguishes phishing from a denial-of-service attack?

Try This A store runs a CMS with a known flaw. Patching takes 3 hours and avoids an expected breach cost of NPR 600,000 with 8 percent chance this month. Delaying patch saves 3 hours at NPR 1,500 per hour engineer cost. Calculate expected loss if unpatched and decide whether to patch now. Show your arithmetic.

Answer sketch The expected unpatched loss is 600,000 × 0.08 = NPR 48,000. Patching costs 3 × 1,500 = NPR 4,500. Under the exercise's assumption that the patch eliminates this risk, patching saves an expected NPR 43,500 after labour cost. Actual decisions should also consider testing, downtime, and remaining risks.

Summary

Malware damages or steals via viruses, worms, Trojans, ransomware, spyware, and botnets. Phishing steals credentials by impersonation. Hacking and vandalism break or deface systems. Breaches and fraud turn leaked data into money. Spoofing and pharming fake identity. Sniffing and man in the middle read the wire. Insiders and flawed software bypass perimeter controls. DoS and DDoS remove availability. In Nepal, phishing via SMS and Messenger, pirated software, and past breaches drive most loss.

Key Takeaways

  • Malware varies by spread: virus needs a host, worm spreads alone, Trojan hides in useful software.
  • Phishing attacks judgment under time pressure; verify domain and never share OTP.
  • Patching and input validation stop most technical intrusions.
  • DDoS needs upstream mitigation; no local firewall alone suffices.
  • Map each threat to a dimension to choose the right defence layer.

Discussion

  1. How could a fake payment message lead to account theft, and how should a customer verify it?
  2. Compare the risks of an insider misusing access and an attacker exploiting an unpatched plugin. What control helps with each?
  3. Your shop receives a sudden flood of requests during a sale. How would you distinguish a DDoS attack from legitimate demand and respond without unnecessarily blocking customers?

Exercises

Short answer

  1. Distinguish virus, worm, and Trojan with one line each.
  2. Name three phishing variants and one sign for each.
  3. Define DDoS and explain the role of a botnet.
  4. What is SQL injection and why does it succeed?

Long answer

  1. Explain major e-commerce threats with one Nepali or global example for each.
  2. Describe phishing in detail with a message example and a five-point checklist to detect it.
  3. Discuss why insider and unpatched software threats are hard to prevent and how a small shop with limited staff should control them.