Reverse Engineering & Binary Analysis Basics · Урок

Извлечение и анализ файловых систем из прошивок

Извлекайте, идентифицируйте и монтируйте встроенные файловые системы, скрытые в образах прошивок, чтобы восстановить содержащиеся в них бинарные файлы, конфигурации и ключи.

Урок 4 из 413 шагов

«Извлечение и анализ файловых систем из прошивок» — бесплатный урок Reverse Engineering & Binary Analysis Basics на CoddyKit. Это урок 4 из 4. Ты можешь прочитать весь урок бесплатно ниже — а потом практиковать его прямо в браузере с встроенным редактором кода и ИИ-репетитором 24/7. Это часть пути обучения Reverse Engineering & Binary Analysis Basics, и твой прогресс синхронизируется между веб-версией и приложением CoddyKit. Курс Reverse Engineering & Binary Analysis Basics содержит 4 уроков всего.

Части этого урока еще не переведены и отображаются на английском.

Inside the Firmware Blob

You can analyze firmware images, emulate embedded binaries, and use hardware-assisted debugging. Most firmware is more than code: it embeds entire filesystems holding executables, web pages, and secrets.

Extracting them is often where the real findings live.

Firmware Layout

A typical image is a stack of regions:

  • Bootloader
  • Kernel
  • One or more root filesystems
  • Configuration / NVRAM areas

Each region may use a different format and compression.

Identifying Contents with binwalk

binwalk scans for known magic signatures and reports what is inside and where.

binwalk firmware.bin
# 0x40   uImage header
# 0x1A00 Squashfs filesystem, gzip

Carving Out Sections

Once you know offsets, you can extract a region. binwalk can do this automatically, or you can carve with dd.

binwalk -e firmware.bin
# or carve manually:
dd if=firmware.bin of=rootfs.sqsh bs=1 skip=6656

Common Embedded Filesystems

Embedded devices favor compact, sometimes read-only filesystems:

  • SquashFS (compressed, read-only)
  • JFFS2 / UBIFS (flash-aware)
  • CramFS (older, read-only)

Each needs the matching tool to unpack.

Unpacking SquashFS

SquashFS is the most common. Extract it with unsquashfs to get a normal directory tree.

unsquashfs rootfs.sqsh
# creates ./squashfs-root with /bin /etc /www ...

What to Look For

Inside the root filesystem, hunt for high-value files:

  • /etc/passwd and hardcoded credentials
  • Web admin scripts in /www
  • TLS keys and certificates
  • Startup scripts revealing services
grep -rIn 'password' squashfs-root/etc 2>/dev/null

Finding Hardcoded Secrets

Vendors frequently embed backdoor accounts or API keys. Scan strings across the whole tree and inspect config files.

These secrets are the most common firmware vulnerability you will report.

Connecting to Your Other Skills

Extracted binaries feed back into your earlier work: emulate a recovered service binary, or attach hardware-assisted debugging to a running device executing that same code.

Filesystem extraction unlocks the targets for those techniques.

When Extraction Fails

If binwalk finds nothing, the image may be encrypted or use a proprietary container.

  • Check entropy: uniformly high suggests encryption
  • Look for the bootloader's decryption routine
  • Try vendor update tools or known keys

Repacking After Modification

For dynamic testing you sometimes patch a filesystem and put it back. Repack with the matching tool and fix the firmware header checksum, or the device rejects the image.

Always work on copies and keep the pristine original for reference.

mksquashfs squashfs-root rootfs_new.sqsh -comp gzip

Quick Check

Which tool is commonly used to scan a firmware image for embedded filesystems and other known structures by their signatures?

Recap

You can now mine firmware for its real contents:

  • Map the layout, then identify regions with binwalk
  • Carve sections and unpack SquashFS/JFFS2/UBIFS
  • Hunt for credentials, keys, and admin scripts
  • Feed recovered binaries into emulation and debugging
Можно начать бесплатно

Изучай Assembly с ИИ-репетитором — бесплатно

Пиши и запускай код прямо в браузере, получай мгновенную помощь от ИИ-репетитора 24/7 и продолжи учиться на сайте или в приложении.

Курсы
12
Уроки
48

Часто задаваемые вопросы

Урок «Извлечение и анализ файловых систем из прошивок» бесплатный?

Да — полный текст урока «Извлечение и анализ файловых систем из прошивок» бесплатно доступен здесь в веб-версии. Чтобы практиковать его интерактивно (встроенный редактор кода и ИИ-репетитор 24/7) и разблокировать остальной курс Reverse Engineering & Binary Analysis Basics, подпишись на CoddyKit PRO. Курс Reverse Engineering & Binary Analysis Basics содержит 4 уроков всего.

Чему я научусь в уроке «Извлечение и анализ файловых систем из прошивок»?

Извлекайте, идентифицируйте и монтируйте встроенные файловые системы, скрытые в образах прошивок, чтобы восстановить содержащиеся в них бинарные файлы, конфигурации и ключи. Ты практикуешь Reverse Engineering & Binary Analysis Basics с помощью реального кода, который запускаешь прямо в браузере, и ИИ-репетитор 24/7 отвечает на твои вопросы во время урока.

Нужен ли мне опыт, чтобы начать Reverse Engineering & Binary Analysis Basics?

Предыдущий опыт не требуется. Reverse Engineering & Binary Analysis Basics на CoddyKit структурирован для всех уровней — от новичков до продвинутых, поэтому ты можешь начать отсюда или с самого начала и учиться в своем темпе. Это урок 4 из 4.

Сколько времени занимает урок «Извлечение и анализ файловых систем из прошивок»?

Большинство уроков CoddyKit занимают около 5–10 минут. Каждый из них компактный и интерактивный, поэтому ты постоянно делаешь прогресс и продолжаешь с того же места в веб-версии и приложении.

Можно ли писать и запускать код в этом уроке Reverse Engineering & Binary Analysis Basics?

Да. Каждый урок Reverse Engineering & Binary Analysis Basics включает встроенный редактор кода, поэтому ты пишешь и запускаешь реальный код прямо в браузере и получаешь моментальную обратную связь от AI — локальная установка не требуется.

Все уроки этого курса

  1. Анализ образов прошивок
  2. Эмуляция встроенных двоичных файлов
  3. Отладка с аппаратной поддержкой
  4. Извлечение и анализ файловых систем из прошивок
← Назад к Reverse Engineering & Binary Analysis Basics