Course contentsShow
← Security
Lesson 1288 of 3,05226. Application Security - Supply ChainFree lesson

Common Typosquatting Patterns

Character substitution, homoglyphs, missing characters, and other naming tricks used in typosquatting attacks.

Common Typosquatting Patterns

What you'll learn: You'll discover the specific naming tricks attackers use to create fake packages that look almost identical to legitimate ones.

Understanding the Patterns

Once an attacker decides to impersonate a popular package (the typosquatting attack technique we covered earlier), they need to choose a deceptive name. They rely on predictable human typing errors and visual similarities. Think of it like a con artist creating a fake Starbucks called "Starbucsk" or "5tarbucks" — close enough that rushed customers might not notice.

Character Substitution

Swapping letters that are close on the keyboard or look similar:

  • express → expres5 (s replaced with 5)
  • lodash → 1odash (l replaced with number 1)
  • react → raect (adjacent keys swapped)

Homoglyphs

Using characters from different alphabets that look identical:

  • requests → rеquests (Cyrillic 'е' instead of Latin 'e')
  • numpy → nսmpy (Armenian 'ս' instead of 'u')

These are nearly impossible to spot visually but are completely different packages.

Missing Characters

Dropping a single letter from common package names:

  • express → expres
  • tensorflow → tensorflw

Extra or Repeated Characters

Adding characters users might accidentally type:

  • django → djjango
  • axios → axioss

Hyphenation and Word Breaks

Breaking compound names differently:

  • my-package → mypackage or my_package
  • redis-client → redisclient

Key Takeaway: Typosquatters exploit predictable human errors through character substitution, look-alike symbols (homoglyphs), missing/extra characters, and punctuation variations. Always double-check package names character-by-character before installation, especially for critical dependencies.