Wiki: Building your first malicious chrome extension ๐
For agents: Markdown version ยท Wiki index ยท Explore
- Speaker: Alon Kiriati
- Event: Reversim Summit 2019
- Video: https://www.youtube.com/watch?v=2rZBx2iy-EE
- Transcript: /transcripts/2019/74-2rZBx2iy-EE.md
- Language: Hebrew ยท Type: talk ยท Level: intermediate
- Topics: Frontend, Security, JavaScript
Written by an LLM from machine transcripts. It can contain errors. Check the transcript before you quote it.
Summary
The speaker demonstrates how easy it is to build a browser extension and highlights the hidden dangers of malicious extensions. By building a simple currency converter extension, the speaker shows how background scripts and content scripts can be used to inject affiliate tags, log keystrokes, and capture screenshots. Finally, the audience learns best practices for securing their browsers, such as limiting extension permissions and auditing installed tools.
Key points
- 3:24 Building a basic browser extension is extremely easy and has a very short learning curve.
- 6:33 An extension consists of a zipped folder containing a manifest.json file alongside HTML and JavaScript files.
- 7:36 The extension architecture is split into separate contexts, including the popup UI, background scripts, and content scripts.
- 14:29 The seemingly helpful currency converter extension secretly injects affiliate marketing tags into e-commerce URLs.
- 16:38 Malicious background and content scripts can easily perform keylogging and capture browser screenshots without user awareness.
- 19:45 Extensions can start out legitimate and be weaponized later through automatic updates or after being sold to malicious actors.
- 28:16 Google continuously updates its store review policies, blocking code obfuscation and requiring two-factor authentication for developers.
- 31:21 Users must treat browser extensions like standalone software by auditing permissions and uninstalling unused tools.
Takeaways
- Audit your installed browser extensions regularly and remove any that are no longer needed.
- Be cautious of extension permissions, as requesting access to read and change data on all websites poses a high security risk.
- Isolate sensitive tasks and corporate accounts by using separate browser profiles.
Questions this talk answers
- How do browser extensions communicate between content scripts and background scripts?
- What security risks are associated with installing browser extensions that request broad permissions?
- How can extension developers update their code after installation without user intervention?
Technologies
JavaScript, HTML, Firebase, Git, GitHub, Amazon, Chrome
Tags
browser extensions, chrome, malware, privacy, security, web development