Add example usage to -h help section v1.00
authorTJ <hacker@iam.tj>
Sat, 9 Apr 2016 09:50:05 +0000 (10:50 +0100)
committerTJ <hacker@iam.tj>
Sat, 9 Apr 2016 09:50:05 +0000 (10:50 +0100)
firmware_extractor.c

index cf7395c..3815198 100644 (file)
@@ -13,6 +13,46 @@ static const char *help = \
 "For routers using the Broadcom CFE ((Customer Premises Equipment) CPE Firmware Environment) and firmware update files.\n\n"
 
 "Extracts ROMD and LZW payloads from firmware files.\n\n"
+
+"The program will list and optionally extract/decompress the payloads:\n\n"
+"$ ./fwex -d /tmp/zyxel/V100AAKL14C0.bin\n"
+"Broadcom Consumer Router Firmware payload extractor\n"
+"Version: 1.00\n"
+"Copyright 2015-2016 TJ <hacker@iam.tj>\n"
+"Licensed on the terms of the GNU General Public License version 2 or later\n"
+"Includes FFMPEG LZW library code with Broadcom CMS modifications\n"
+"\n"
+"Found ROMD payload 0\n"
+"  written to /tmp/zyxel/V100AAKL14C0.bin.00.bin\n"
+"Image Offset:  0x00020000 (131072)\n"
+"0000 Tag Version: 6\n"
+"0004 Signature 1: MSTC_6006 (Model: 6006)\n"
+"0018 Signature 2: ver. 2.0\n"
+"0026 Chip ID: 63268\n"
+"002c Board ID: 963168VX\n"
+"003c Big Endian: Yes\n"
+"003e Image Len: 25952256 (0x018c0000)\n"
+"008e External Version: 1.00(AAKL.14)C0\n"
+"00ae Internal Version: 1.00(AAKL.14)C0\n"
+"00ce Image Next: 1\n"
+"00d8 Image Validation Token: 0x1c633f00\n"
+"00ec Tag Validation Token:   0xbdde4316\n"
+"     Calculated Image CRC32: 0x1c633f00\n"
+"     Calculated Tag   CRC32: 0xbdde4316\n"
+"\n"
+"Found LZW compressed payload 1\n"
+"  compressed: 23265 decompressed: 80030 bytes\n"
+"  written to /tmp/zyxel/V100AAKL14C0.bin.01.bin\n"
+"Image Offset:  0x018e0020 (26083360)\n"
+"0000 Image Next: 0\n"
+"0001 Image Type: IMGDEF (0)\n"
+"0003 Image Signature: 0\n"
+"0005 Image Len: 23305 (0x00005b09)\n"
+"0018 Image Validation Token: 0xd78f9ceb\n"
+"001c Tag Validation Token:   0x8681f430\n"
+"     Calculated Image CRC32: 0xd78f9ceb\n"
+"     Calculated Tag CRC32:   0x8681f430\n"
+"\n"
 ;
 
 #include <stdio.h>