Report MitraStar signiture_1 sub-field Model ID
authorTJ <hacker@iam.tj>
Fri, 8 Apr 2016 12:27:43 +0000 (13:27 +0100)
committerTJ <hacker@iam.tj>
Fri, 8 Apr 2016 12:27:43 +0000 (13:27 +0100)
firmware_header_dump.c

index 5e1f99e..33cffb9 100644 (file)
@@ -1,7 +1,7 @@
 static const char *title =\
 "Broadcom Consumer Router Firmware Header Dump"
 ;
-static const float VERSION = 1.01f;
+static const float VERSION = 1.03f;
 
 static const char *copyright = \
 "Copyright 2015-2016 TJ <hacker@iam.tj>\n"
@@ -185,7 +185,7 @@ main(int argc, char **argv)
          if (!count) {
            printf("Image Offset:  0x%08x\n", offset);
            printf("%04lx Tag Version: %s\n"
-                  "%04lx Signature 1: %s\n"
+                  "%04lx Signature 1: %s (Model: %s)\n"
                   "%04lx Signature 2: %s\n"
                   "%04lx Chip ID: %s\n"
                   "%04lx Board ID: %s\n"
@@ -207,7 +207,7 @@ main(int argc, char **argv)
                   "     Calculated Tag   CRC32: 0x%08x\n"
                   "\n",
                   offsetof(struct _FILE_TAG, tagVersion), pfile->tagVersion,
-                  offsetof(struct _FILE_TAG, signiture_1), pfile->signiture_1,
+                  offsetof(struct _FILE_TAG, signiture_1), pfile->signiture_1, pfile->signiture_1 + strlen(pfile->signiture_1) + 1,
                   offsetof(struct _FILE_TAG, signiture_2), pfile->signiture_2,
                   offsetof(struct _FILE_TAG, chipId), pfile->chipId,
                   offsetof(struct _FILE_TAG, boardId), pfile->boardId,