ELF44 (444ԀԀ77,8LL9L9/lib/ld-linux.so.2%8  # /5!%, "&7$6)1+0-234('*.  L9)8?`hE`1 K܋"]L"n\"| "L(::U<h:H:i 9(<>(܊8:(=D̋>K>e, vx:X:,)E:0:.l Il3yE|QiåC\ |'| @:!@:@:! \99 :__gmon_start__libg++.so.2.7.2_DYNAMIC_GLOBAL_OFFSET_TABLE__init_fini__builtin_vec_new__builtin_delete__builtin_new__builtin_vec_delete__ls__7ostreamPCc__ctype_b__ctype_tolowerwrite__7ostreamPCciget__7istreamRc_vt.3ios_vt.7ostream.3ios__ls__7ostreamicerrexit__strtod_internal__ls__7ostreamccoutstrchrstrcmpatexitlibstdc++.so.2.7.2__11fstreambasei_vt.7istream.3ios_vt.8ifstream.3ios__11fstreambaseiPCciiopen__11fstreambasePCcii_vt.8iostream.3ios_vt.7fstream.3iosclose__11fstreambase_._7fstream_._8ifstreamgetline__7istreamPcicread__7istreamPcihex__FR3ios__ls__7ostreamlendl__FR7ostreamlibm.so.6libc.so.6__libc_init_firstbsearchqsort__strtol_internalstrcpystrncpystrtok_environ__environenviron_start_etext_edata__bss_start_endH99:(: 0: @:1H:X:h:x::: 8-88!8(88'8,8*8+888 8)8$8.9/9%9# 99999 9 $9 (9,9094989"<9&@9D9US[OtP]]58%8%8h%8h%8h%8h%8h %8h(%8h0%8h8p%8h@`%8hHP%8hP@%8hX0%8h` %8hh%8hp%9hx%9h%9h% 9h%9h%9h%9h%9h% 9hp%$9h`%(9hP%,9h@%09h0%49h %89h%<9h%@9h%D9h1tR4X^D@:PPRVh` X:PPUS8=8tЃ;u]ÍvUÐUVSu uh7w2h71vh7b.9h|h7l.tSh7^-Pkhh7A.tSh73-P@vhh7.tSh7-PvSh7,P CFM1e[^ÍvUWVS]hS)(hS(hS(hS( hS'hS'hS'hS' hS'hS'S~1hS?-hS2-ǃ$hS"-7Ѓ~/hh9tPS2-P jEhAS,t2hHhmh:.P%PjhS,tNhh:Pfhhh:PP=jvhS5,tSh,Pj{v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:Bv:ÐUU :E:E:E :E ::UU :E:E:E:E:E:E:E :E ::UVS]u @'uA'E'E'E'EUP)‰f'ffUjS|t@h:@t PtS*e[^ÐUS8=8tЃ;u]ÍvUÐUS[O]{]]compilebinaryasciia|ascii=bb|binary=bc|compile=s:m|man|manual=bmod=i:25wrap=i:75author=bversion=bexample=bhelp=babcError: only one of the opts -a, -b, or -c can be usedat one time.authorcraig@ccrma.stanford.edu, April 1997Written by Craig Stuart Sapp, versionlast edited: Thu Oct 22 14:17:23 PDT 1998 Oct 22 1998compiled: helpexamplemanualError: you must specify an output file when using the -c optionError: you must specify at least one file on the command-lineError opening output file: Error opening file: Error: output file was not opened# display bytes a hexadecimal values and any associated ascii characters binasc filename # display bytes only as associated ascii characters (suppressing spaces) binasc -a filename # display bytes only as hexadecimal values binasc -b filename # compile the numeric values of the input into bytes in output binasc -c filename wrapError invalid colmn wrap specifiedmodError invalid byte count specifiedEnd of the file right away! at token: Error on line extra quote in decimal numbercannot have more than two minus signs in numberminus sign must immediately follow quote markcannot have decimal marker before quoteextra period in decimal numbercannot have endian specified after quoteextra "u" in decimal numberdecimal numberinvalid byte specificaton before quote in cannot have numbers before quote in decimal number)Invalid character in decimal number (character number there must be a quote to signify a decimal numberthere must be a decimal number after the quoteonly floating-point numbers can use 8 bytesfloating-point numbers can be only 4 or 8 bytesDecimal number out of range from -128 to 127Decimal number out of range from 0 to 255negative decimal numbers cannot be stored in 3 bytesinvalid byte count specification for decimal numberSize of hexadecimal number is too large. Max is ff.Invalid character in hexadecimal number.character byte must start with '+' sign: character byte word is too long -- specify only one characterextra comma in binary numberInvalid character in binary number (character is cannot start binary number with a commacannot end binary number with a commatoo many digits in binary numbertoo many digits to left of commatoo many digits to right of comma [-a | -b | -c output] input(s) Options: -a = output only non-space printable asci words -b = output only hexadecimal ascii numbers for each byte -c output = compiled binary file using ascii number of input -m = display the man page for the program no options = combination of -a and -b options. --options = list of all options, aliases and defaults For converting/compiling a binary file to/from an ASCII listing of individual bytes of the file. Usage: 2e 73 6e 64 ; the magic number which identifies the type of the file ; . s n d ; character equivalents of the magic number digits 00 00 00 32 ; the byte offset of the data (50 bytes precede the data) ; i.e., the header contains 50 bytes 00 00 00 0a ; the number of bytes in the data (10 bytes). 00 00 00 03 ; the NeXT/sun data format (3 = 16-bit Linear sound) 00 00 ac 44 ; the sampling rage, which is 44100 samples/sec here 00 00 00 01 ; the number of channels (1 = monophonic soundfile) ; next comes a sound file comment: 54 68 69 73 20 69 73 20 61 20 62 6c 61 6e 6b 20 73 6f 75 6e 64 66 69 6c 65 2e ; T h i s i s a b l a n k s o u n d f i l e . ; finally the individual sample data: 00 00 ; first 16-bit sample (big-endian) 00 00 ; second 16-bit sample (big-endian) 00 00 ; third 16-bit sample (big-endian) 00 00 ; fourth 16-bit sample (big-endian) 00 00 ; fifth 16-bit sample (big-endian) ; end of example soundfile. Here is a more succinct version of the previous example: +. +s +n +d ; magic number (characters .snd) 4*50 ; header bytes (the decimal number 50 filling 4 bytes) 4*10 ; sample count 4*3 ; format 4*44100 ; srate 4*1 ; channels ; comment: +T +h +i +s + +i +s + +a + +b +l +a +n +k + +s +o +u +n +d +f +i +l +e +. ; sample data shown in various input possibilities 00 00 ; sample 1: hexadecimal digits *0 *0 ; sample 2: decimal digits 2*0 ; sample 3: decimal number 0 filling up two bytes 0000,0000 0,0 ; sample 4: binary digits 2u*0 ; sample 5: decimal digits filling two bytes, but ; using little endian byte ordering (backward). ; end of example soundfile. The simplest view of the previous example: 2e 73 6e 64 00 00 00 32 00 00 00 0a 00 00 00 03 00 00 ac 44 00 00 00 01 54 68 69 73 20 69 73 20 61 20 62 6c 61 6e 6b 20 73 6f 75 6e 64 66 69 6c 65 2e 00 00 00 00 00 00 00 00 00 00 example 2 Just for fun, here is a WAVE format soundfile with the same contents as the previous examples (5 zero-valued samples). Notice that most data fields in the file are little-endian forms of numbers (since Intel computers are little-endian). 52 49 46 46 2e 00 00 00 57 41 56 45 66 6d 74 20 10 00 00 00 01 00 01 00 44 ac 00 00 88 58 01 00 02 00 10 00 64 61 74 61 0a 00 00 00 00 00 00 00 00 00 00 00 00 00 Which is equivalent to: ; This is a WAVE formated soundfile with 5 zero samples. +R +I +F +F ; RIFF chunk descriptor 4u.46 ; size of the chunk in bytes +W +A +V +E ; format is the type of RIFF that follows +f +m +t + ; the fmt sub chunk 4u*16 ; number of bytes total in sub-chuck which follow 2u*1 ; audio format (PCM Linear) 2u*1 ; number of channels 2u*44100 ; sampling rate 44100 = ac 44, 2u.44100 = 44 ac 4u*88200 ; byte rate = srate * channels * bitspersample / 8. 2u*2 ; block align (bytes per sample / 8) 2u*16 ; bits per sample +d +a +t +a ; data subchunk 4u*10 ; size of data subchunk in bytes which follows 2u*0 ; sample 1 2u*0 ; sample 2 2u*0 ; sample 3 2u*0 ; sample 4 2u*0 ; sample 5 ; end of example wave file. Note that you can reverse the process of the binasc program unless you specify the -a option: binasc file1 > file2 binasc -c file2 > file3 ; file1 and file3 should be the same binasc -b file1 > file2 binasc -c file2 > file3 ; file1 and file3 should be the same binasc -a file1 > file2 binasc -c file2 > file3 ; this results in an error binasc: binary/ascii file viewing/creation 1. Displaying ASCII codes for bytes in a file. The binasc program can convert a file into an ASCII list of hexadecimal numbers which represent each byte in the input file as well as display any printable ascii characters associated with the hexadecimal numbers. Example output given below shows beginning of the output from the binasc program when it is run on the binasc program file. Note that the lines come in pairs, first the line describing the bytes, then a comment line displaying any ASCII printable bytes. 7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00 02 00 03 00 01 00 00 00 ac ; E L F 8c 04 08 34 00 00 00 68 5e 00 00 00 00 00 00 34 00 20 00 05 00 28 00 16 00 ; 4 h ^ 4 ( 15 00 06 00 00 00 34 00 00 00 34 80 04 08 34 80 04 08 a0 00 00 00 a0 00 00 ; 4 4 4 00 05 00 00 00 04 00 00 00 03 00 00 00 d4 00 00 00 d4 80 04 08 d4 80 04 08 ; 13 00 00 00 13 00 00 00 04 00 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 ; 80 04 08 00 80 04 08 78 5a 00 00 78 5a 00 00 05 00 00 00 00 10 00 00 01 00 ; x Z x Z 00 00 78 5a 00 00 78 ea 04 08 78 ea 04 08 2c 02 00 00 38 03 00 00 06 00 00 ; x Z x x , 8 00 00 10 00 00 02 00 00 00 04 5c 00 00 04 ec 04 08 04 ec 04 08 a0 00 00 00 ; \ a0 00 00 00 06 00 00 00 04 00 00 00 2f 6c 69 62 2f 6c 64 2d 6c 69 6e 75 78 ; / l i b / l d - l i n u x 2e 73 6f 2e 32 00 00 25 00 00 00 38 00 00 00 00 00 00 00 0d 00 00 00 20 00 ; . s o . 2 % 8 There are two other main viewing options for the binasc command: -a for displaying only ASCII printable bytes, and -b for displaying only the hexadecimal numbers for the bytes. the -a option will display only the ascii-printable characters in a file. Multiple spaces (unprintable characters) are suppressed in the output. The -a option is a good way to search for text in a binary file. Here is an example output using the same file as in the example show above: ELF 4 h^ 4 ( 4 4 4 xZ xZ xZ x x , 8 \ /lib/ld-linux.so.2 % 8 # / 5 ! % , " ( < > ( 8 @ ( = D > K > e , v 0 , ) E . l I l 3 y E | Q i a C \ | ' | ! ! __gmon_start__ libg++.so.2.7.2 _DYNAMIC _GLOBAL_OFFSET_TABLE_ _init _fini __builtin_vec_new __builtin_delete __builtin_new __builtin_vec_delete __ls__7ostreamPCc __ctype_b __ctype_tolower write__7ostreamPCci get__7istreamRc _vt.3ios _vt.7ostream.3ios __ls__7ostreami cerr exit __strtod_internal __ls__7ostreamc cout strchr strcmp atexit libstdc++.so.2.7.2 __11fstreambasei _vt.7istream.3ios _vt.8ifstream.3ios __11fstreambaseiPCcii open__11fstreambasePCcii _vt.8iostream.3ios _vt.7fstream.3ios close__11fstreambase _._7fstream _._8ifstream getline__7istreamPcic read__7istreamPci hex__FR3ios __ls__7ostreaml endl__FR7ostream libm.so.6 libc.so.6 __libc_init_first bsearch qsort __strtol_internal strcpy strncpy strtok _environ __environ environ _start Alternatively, with the -b option, you can print out only the ASCII codes for the binary numbers associated with each byte in the file. Unlike the unix od command, the bytes are not grouped into two-byte words when displayed as hexadecimal numbers (which will switch order of the bytes in the output display on little-endian computers). Here is example output when using the -b option using the same file as in previous examples: 7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00 02 00 03 00 01 00 00 00 ac 8c 04 08 34 00 00 00 68 5e 00 00 00 00 00 00 34 00 20 00 05 00 28 00 16 00 15 00 06 00 00 00 34 00 00 00 34 80 04 08 34 80 04 08 a0 00 00 00 a0 00 00 00 05 00 00 00 04 00 00 00 03 00 00 00 d4 00 00 00 d4 80 04 08 d4 80 04 08 13 00 00 00 13 00 00 00 04 00 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 80 04 08 00 80 04 08 78 5a 00 00 78 5a 00 00 05 00 00 00 00 10 00 00 01 00 00 00 78 5a 00 00 78 ea 04 08 78 ea 04 08 2c 02 00 00 38 03 00 00 06 00 00 00 00 10 00 00 02 00 00 00 04 5c 00 00 04 ec 04 08 04 ec 04 08 a0 00 00 00 a0 00 00 00 06 00 00 00 04 00 00 00 2f 6c 69 62 2f 6c 64 2d 6c 69 6e 75 78 2e 73 6f 2e 32 00 00 25 00 00 00 38 00 00 00 00 00 00 00 0d 00 00 00 20 00 00 00 15 00 00 00 00 00 00 00 07 00 00 00 0b 00 00 00 23 00 00 00 01 00 00 00 1d 00 00 00 14 00 00 00 16 00 00 00 0c 00 00 00 00 00 00 00 2f 00 00 00 0e 00 00 00 00 00 00 00 00 00 00 00 35 00 00 00 19 00 00 00 21 00 00 00 1f 2. Creating files by byte description With the binasc program, you can convert an ascii file with the binary numbers back into actual bytes by using the -c option. When using the -c option, you must specify an output file with the -o option. Byte numbers can be of various formats as described below. binasc comments A semi-colon (;) marks the beginning of a comment which extends to the end of a line. A space (or tab) character must precede the semi-colon when the comment follows a number on a line. binasc hexadimal numbers hexadecimal numbers specify one byte and must contain no more than 2 digits and range from 00 to ff (0 to 255 in decimal notation, or -128 to 127 in signed decimal notation.): example of valid hexadecimal numbers: 7f 45 4c 46 1 1 1 0 0 8c 04 08 34 0 0 0 8 e 15 00 06 10 0 0 4 0 0 binasc binary numbers Binary numbers can be specified by numbers longer than three characters, or numbers containing a comma. The binary number is allowed to have up to 8 digits (bits) since the binary number represents one byte in the output file. An optional comma is expected to split the number into two equal parts with 4 bits on each side of the comma For example 0010 is the binary number which is equal to the decimal number 4. 0010 is equivalent to 0,0010 or 0000,0010. Note that 10 is the hexadecimal number equal to the decimal number 16 and is not the binary number equal to the decimal number 2. Here are some binary numbers examples: binary decimal invalid reason 0,0 = 0 ,0 cannot start or end with comma 0000,0000 = 0 0000, 0000 cannot have spaces around comma 00000000 = 0 1001010110 maximum of 8 binary digits 1,1 = 17 10011,1000 max of 4 digits each side of comma 0001,0001 = 17 010 = 2 10 interpreted as a hexadecimal number 0,101 = 5 00000101 = 5 101 = 5 binasc decimal numbers binasc decimal numbers, unlike hexadecimal or binary numbers, can fill slots of 1-4 bytes for integers, or 4 and 8 bytes for floating-point decimal numbers. Decimal numbers may also be either positive or negative unlike the hexadecimal or binary number input. A decimal number starts with a quote character. There are two specifications which can be given just before the quote: 1. a number in the range from 1 to 4 which specifies how many bytes an integer decimal number is to be stored in. Floating-point numbers can be either 4 or 8 bytes in size. The default size for floating-point numbers is 4 bytes if no size is specified. 2. the symbol u can be given before the quote character in a decimal number to indicate the direction into which the bytes for the number will be placed in the file. No letter u means that the most significan byte is written first (big-endian)., while the letter u indicates to write the bytes in reverse order (little-endian). For example, the decimal number 1234 can be represented by the two-byte hexadecimal number 0x04d2. In big-endian storage the 04 byte is written first, then the d2 byte. in little-endian storage the d2 byte is written first then the 04 byte. 1234 = 0x04d2 big endian: 04 d2 little endian: d2 04 When a byte size is not specified before the quote character (* here), the default is 1 for integers and 4 for floating-point. When not speifying a byte size, valid decimal numbers are in the range from 0 to 255, or -128 to 127 if signed, i.e., the range for one-byte decimal numbers is from -128 to 255, and you have to know the representation later (signed or unsigned). If you specifically specify a byte size of 1, then you can give any integer number value which may be truncated to fit into one byte. The maxmum integer decimal number which can fill 4 bytes is 4294967294 or so. (hexadecimal 0xffffffff). If a decimal number includes a period character (.) it is assumed to be a floating-point number. Floating-point numbers can be either 4 or 8 bytes. Integer numbers can be between 1 and 4 bytes, but 3-byte integers can only be positive. Examples of decimal numbers: valid invalid examples examples reason *0 = 0 123 does not start with a quote *255 = 255 1*256 = 0 (truncated) *256 exceeds one byte in size 2*256 = 256 4*44100 = 44100 4u*453 = 453 (but bytes are written small to large order) u4*453 = 453 (same as above) 2*-5 = -5 (short int) 2* -5 cannot have a space around quote *3.1415 = 3.1415 (4-byte storage, float in c) 8*3.1415 = 3.1415 (8-byte storage, double in c) binasc ascii bytes ASCII characters can be input by preceding each with a plus (+). Each character is a separate word. For example, to place the characters cat into a file, the input would be +c +a +t. example 1 The following file will compile into a NeXT/Sun soundfile with five zero-valued sound samples. This example has lots of comments. vlError: default string cannot be nullError: no "=" in option definition: |Error: must specify an option name in definition: " from definition: option name "is already defined in definition: Error: unknown error in definition: ' in defintion: Error: unknown option type 'Unknown error in definition: does not exist.Error: argument options".Error: unknown option "Error: boolean variable cannot have any options: " cannot have aguments Error: option "Error: last option requires a parameter Maximum is Error: accessing invalid array location Error: Maximum size allowed for array exceeded.lPL9ŠҊ"2BRbr‹ҋ"2BRbrRr| ` `d  8T`GCC: (GNU) 2.7.2.3GCC: (GNU) 2.7.2.3GCC: (GNU) 2.7.2.3GCC: (GNU) 2.7.2.3GCC: (GNU) 2.7.2.3GCC: (GNU) 2.7.2.3GCC: (GNU) 2.7.2.301.0101.0101.0101.0101.0101.0101.01.symtab.strtab.shstrtab.interp.hash.dynsym.dynstr.rel.got.rel.bss.rel.plt.init.plt.text.fini.rodata.data.ctors.dtors.got.dynamic.bss.comment.noteԀ#|) dd19 B XK TT  T`` ,Z _ Ne``[k||[DLs7y8 8 8L9L9 x