Browse Prior Art Database

Metamodel definition based Universal Binary Resource Analyzer

IP.com Disclosure Number: IPCOM000011913D
Original Publication Date: 2003-Mar-26
Included in the Prior Art Database: 2003-Mar-26
Document File: 3 page(s) / 26K

Publishing Venue

IBM

Abstract

Disclosed is a system for analyzing binary resources of various structures in unified way. It consists of a meta-model definition and an analysis engine. The meta-model is defined using DTD and rules. The engine takes a resource model written in XML based on the meta-model, and analyzes a binary resource based on the model.

This text was extracted from a PDF file.
At least one non-text object (such as an image or picture) has been suppressed.
This is the abbreviated version, containing approximately 51% of the total text.

Page 1 of 3

THIS COPY WAS MADE FROM AN INTERNAL IBM DOCUMENT AND NOT FROM THE PUBLISHED BOOK

JP820020980 Koichiro Kato/Japan/IBM Mayumi Takahashi, Masao Nishimoto, Tadahiko Nakamura

Metamodel definition based Universal Binary Resource Analyzer

    Disclosed is a system for analyzing binary resources of various structures in unified way. It consists of a meta-model definition of binary resources, and an analysis engine based on the definition. The single engine can analyze any binary resources as long as their models comply with the meta-model.

(1) Meta-model Definition

DTD

<?xml version='1.0' encoding="UTF-8"?> <!ELEMENT RESOURCE (FIELD+ ¦ FIELDBODY* ¦ ARRAYBODY* ) > <!ATTLIST RESOURCE order (big-endian ¦ little-endian) "big-endian"> <!ATTLIST RESOURCE type CDATA #IMPLIED> <!ELEMENT FIELD (FIELD* ¦ DEFINE*) > <!ATTLIST FIELD body IDREF #IMPLIED > <!ATTLIST FIELD condkey CDATA #IMPLIED > <!ATTLIST FIELD condvalue CDATA #IMPLIED > <!ATTLIST FIELD length CDATA #IMPLIED > <!ATTLIST FIELD name ID #REQUIRED > <!ATTLIST FIELD termkey CDATA #IMPLIED > <!ATTLIST FIELD termvalue CDATA #IMPLIED > <!ATTLIST FIELD type (byte¦short¦char¦int¦float¦long¦double¦array¦union¦bit¦unknown) #IMPLIED > <!ATTLIST FIELD order (big-endian¦little-endian) #IMPLIED> <!ELEMENT DEFINE EMPTY>
<!ATTLIST DEFINE name CDATA #REQUIRED > <!ATTLIST DEFINE mask CDATA #IMPLIED > <!ATTLIST DEFINE value CDATA #IMPLIED >
<!ELEMENT FIELDBODY (FIELD+) >
<!ATTLIST FIELDBODY name ID #REQUIRED >
<!ELEMENT ARRAYBODY (FIELD+) > <!ATTLIST ARRAYBODY name ID #REQUIRED >

Rules

"." is not allowed within a "name" "order" specifies byte order "length" specifies field length, which is the number of elements ("array"), bits ("bit"), or bytes Default length for each type is:

  type Default length byte 1
short 2
char 2
int 4
float 4
long 8 double 8

"condkey", "condvalue", "termkey", "termvalue", "length" are specified using expression

When a string is specified for "condvalue", "termvalue", its encoding can be specified as "'string', encoding"

FIELD type

"byte", "short", "int", "float", "double" are primitive types, and "float" and "double" conform to IEEE 754. When the end of "array" is defined by some condition, its condition can be specified by "termkey" and "termvalue". Each member of "union" is defined by "condkey" and "condvalue". When "condvalue" is omitted, it is treated as a default member. "bit" field can have "DEFINE" elements. Each "DEFINE" elements defines a name for the specified value of the field.

    "unknown" can be used to skip unnecessary data. "FIELDBODY" and "ARRAYBODY" can be used to specify the subordinate fields for a field and an array, respectively. They are designated by "body".

1

Page 2 of 3

"mask" of "DEFINE" is used as an "AND" mask to the "bit" field, if specified.

Expression

Expression consists of constant, qualified IDREF, arithmetic and logical expressions

Constant numeric, literal, logical ("true", "false") Operator

+ - * / % & ¦ ! ^ << >> == != ¦¦ && < > ? : ( ) [ ]...