Logevents v111003 analysis/zz-iatdemo-B1.0 s_le-summary.html C:\project-iat\inst\perl.exe 5.006001

Logevents is a web based analysis tool used to analyze source code for SV CV attributes, insert log events, save the newly modified source, and perform a DIFF between the orginal source and the resulting source code. The classification markings appear in the web page title, top, bottom, and after each access of an s_ file.

Description This is the companion report to codegen which is the same as this report except that files not instrumented are not shown. It reduces the noise. Also le-sumamry does not perform the actual instrumentation. Running this report will instrument the source code with log events. Examine the keywords and verify that the number of LE SV items is as expected. Scroll or select the link into the details area and look for potential problems. Continue to examine the translate file. Finally examine the DIFF report and verify that the software includes only introduction of executable log event code and modifications of the original log event comments. Even though there is a DIFF, select several source and result files in the details and DIFF areas to verify that the code modifications occurred as exepected. Verify that the categories of hyper links work by click on each type (source, result, TOC, xx-xxx). The datareduction report and source code reports must be in place for the TOC and xx-xxx links to work.
AnalysisComment
KeywordsThis analysis shows the user selected keywords that were extracted from the original source code. There are also predefined keywords that are seperately reported by the tool in the Problems and Details analysis.
DetailsThis analysis shows the details from the original source code that are extracted from the search requests and internal error, warning, and caution settings. It also includes software metrics on a module basis.
CompareThis analysis shows a DIFF between the original source code and the new instrumented code.

Other Analysis Reports . Original Source Code . Instrumented Source Code . Help

12/09/2003 13:47:16


Settings

Description 14

Master Directories
Project Instrumentation Test
Source Result Analysis
Metrics

Report Markings
Report Marking
Highest Code Classification
Lowest Code Classification
Classified Keywords

Headers
C Header
H Header
asm Header

File Controls
Assembly Extensions
Access Files
Ignore Files
Paths
File Path
Src Paths (websever /~iat no websever ../../)
URL (websever /~iat no websever ../../ dos is blank)

Source Dir Path
Result Dir Path
Analysis Dir Path(no websever setting ../ft-red-B1B2D6_Ry)
Analysis Report Name
Files
toc file bfw file hmi file
toc html bfw html

General Settings
CPCs
1 2 3 4 5 6 7 Colors

Log Event Patterns
SV Events case Insensitive
Filter SV Events case Insensitive (e.g. traffic)
Filter Files case Insensitive
DB Events case Sensitive
HMI Events case Sensitive
LOC Events case Sensitive
Filter LOC Events (e.g. traffic)

Table Driven Functions used by uncalled functions detector


Fixed Keywords case insensitive
C
H
Assembly

Keywords case insensitive
find 1
find 2
find 3
find 4
find 5

ignore lines

Keyword Window

Hamming Patterns


Log Events
SV Start DB Start HMI Start LOC Start
Instrument Source LE Summary Auto Trace Fix LE English

Show in Details Report
Abstract SV REQUIRED Full Header All SourceCode Only SVCV src
Comments CV REQUIRED Rquirements Functions Show Only Affected Files Analyze Only LE SV

Reports
Control Menu Keywords Stats Metrics Ham Values Details Problem Summaries Problem Descriptions Compare

Reports - Automatic Detectors Default Problems Locked Files Date (e.g. 01/05/2003)
Fatal Printf C Headers H Headers ASM Headers
Class SV Marking CV Marking Keywords Code Keywords Prologues
No Curly Braces ifdef Switch Default's Default Error Case Break
Nested Switches Stacked Cases Calling Rules No Error Exit ?: operator
Func/File LOC/File Line Length < 5 LOC/Func > 100 LOC/Func
Uncalled Func's Dead Code Fuzzy Log Events ++/-- in if, else, while do Loops
malloc free Re-Casting goto No Func Header

Regression noise reduction for Automatic Detectors - must run regression.pl first
new files
mod files

Metrics Baseline Accessed
Metrics Saved (enable stats)

Hide Controls Show Checked Summary Checked Details Not Checked All


Keyword Stats

Good General Practices

  • use new and delete instead of malloc and free
  • do not use ?:
  • if a func has no parameters, use () instead of (void)
  • do not use goto
  • avoid declaring member variable with 'mutable' keyword
  • avoid declaring local variables with 'register' keyword
  • avoid declaring local variables with 'static' keyword
  • avoid do statements - potential endless loops
  • look for unusual and pertinent keywords
  • consistency is nice but not mandated
  • provide if with else
  • Good Security Practices

  • the bad fixed keywords are shown elsewhere
  • terminate case with break;
  • for each switch, provide default:
  • default: with security critical data should transfer to SwError
  • if else sequences with security critical data terminate in SwError
  • s_ files with if else sequences in many cases terminate in SwError
  • terminate other as identified if else sequences with SwError
  • look for undefined error codes in SwError
  • look for multiple uses of the same error codes
  • malloc should not be used on security critical data
  • if malloc is used on security critical data crypto zeroize before free
  • Number Sort

    36LE SV 6LOC EVENT 2DEBUG EVENT 1HMI EVENT

    Alpha Sort

    2DEBUG EVENT 1HMI EVENT 36LE SV 6LOC EVENT

    Keywords Not Found

    nnoonnee nnoonnee
    nnoonnee nnoonnee


    Details Report

    1 1 Source: source/zz-iatdemo/zz-iatdemo-B1.0/pwr/anylogevents.c
     1-15 function_lefirst
    1-24 /* LE SV TOC-001 completed the orange portion of req 1*/ 1-37 function_lea
    1-61 /* LE SV TOC-001 completed the blue portion of req 1*/ 1-65 /* LE SV TOC-002 completed req 2*/ 1-73 function_leb
    1-91 /* LE SV TOC-003 starting req 3 - this is a huge loop 3*/ 1-96 /* LE SV TOC-003 req 3 - but you can log in loop and filter during test */ 1-98 /* LE SV TOC-003 finished req 3 - so its ok to bracket huge loops */ 1-107 /* LE SV TOC-004 starting req 4 - this is a realtime loop */ 1-112 /* LE SV TOC-004 req - but you can log in loop and filter during test 3*/ 1-114 /* LE SV TOC-004 finished req 4 - so its ok to bracket real time loops */ 1-132 /* LE SV TOC-004 completed req 4 its ok to no place a req in the exact spot where its completed */ 1-133 /* LE SV TOC-005 completed req 5 stuff */ 1-150 /* LE SV TOC-006 completed req 6 */ 1-151 /* LE SV TOC-007 completed req 7 */ 1-152 /* LE SV TOC-008 completed req 8 */ 1-167 /* LE SV TOC-010 this is divide by zero error */ 1-176 function_led
    1-208 /* LE SV TOC-011 completed req 11 stuff */ 1-209 /* LE SV TOC-012 completed req 12 stuff */ 1-210 /* LE SV TOC-013 completed req 13 stuff */ 1-211 /* LE SV TOC-014 completed req 14 stuff */ 1-217 function_lee
    1-231 /* LE SV TOC-015 started req 15 stuff - pick start or end but not both */ 1-232 /* LE SV TOC-016 started req 16 stuff - pick start or end but not both */ 1-233 /* LE SV TOC-017 started req 17 stuff - pick start or end but not both */ 1-251 . . . HMI EVENT 1 . HMI_CALL . HMI HMI_CALL (Happy Face); 1-270 . . . LOC EVENT 1 . any + loc . log = any + loc(aslong_as_there_is_semicolon); 1-283 . . . LOC EVENT 2 . any + loc . log = any + loc; 1-290 . . . LOC EVENT 3 . any+loc . log = any+loc; 1-297 . . . LOC EVENT 4 . any-loc . log = any-loc*(some+more+stuff); 1-304 . . . LOC EVENT 5 . any*loc . log = any*loc; 1-311 . . . LOC EVENT 6 . any/loc . log = any/loc(nice_broad_pattern); 1-318 . . . DEBUG EVENT 1 . . . PURGE_BUFFER 1-325 . . . DEBUG EVENT 2 . . . PURGE_BUFFER 1-330 /* LE SV TOC-015 completed req 15 stuff */ 1-331 /* LE SV TOC-016 completed req 16 stuff */ 1-332 /* LE SV TOC-017 completed req 17 stuff */ 1 1 Result: result/source/zz-iatdemo/zz-iatdemo-B1.0/pwr/anylogevents.c


    2 3 Source: source/zz-iatdemo/zz-iatdemo-B1.0/pwr/badcoding.c 2-16 function_first
    2-20 /* LE SV TOC-001 this is a real rocket scientist - will not compile here */ 2-30 function_a
    2-34 Possible Compile Error: LE In Header 2-34 . --| /* LE SV TOC-001 this is a real rocket scientist - will not compile here */ 2-45 /* LE SV TOC-001 this is a real rocket scientist - will not compile here */ 2-45 long D; FATAL Compile Error: LE breaks long path 2-59 function_b
    2-93 /* LE SV TOC-008 split the if block */ 2-93 { FATAL Compile Error: Missing curly brace LE breaks path 2-116 /* LE SV TOC-002 this is paraphrase of req 2 */ 2-117 /* LE SV TOC-003 this is paraphrase of req 3 */ 2-141 function_c
    2-158 /* LE SV TOC-007 req 7 about item 7 stuff AUTO COMMENT */ // too lazy to paraphrase req 2-233 /* LE SV TOC-008 we really should log all error calls but NOT HERE */ 2-262 /* LE SV TOC-008 we really should log all error calls */ 2-298 /* LE SV TOC-008 we really should log all error calls */ 2-298 { FATAL Compile Error: Missing curly brace LE breaks path 2-303 /* LE SV TOC-008 we really should log all error calls */ 2-375 function_d
    2-509 function_e
    2 3 Result: result/source/zz-iatdemo/zz-iatdemo-B1.0/pwr/badcoding.c



    Difference Report - DIFF

    This is a standard gnu DIFF report. Additions to the second file appear in green while deletions from the second file or additions to the first file appear in red. This DIFF report will traverse the entire directory tree structure. You must duplicate the tree structure of the source by copying the source into the result prior to executing this script.

    1 1 Source: source/zz-iatdemo/zz-iatdemo-B1.0/pwr/anylogevents.c
    1 1 Result: result/source/zz-iatdemo/zz-iatdemo-B1.0/pwr/anylogevents.c

    source/zz-iatdemo/zz-iatdemo-B1.0/pwr/anylogevents.c result/source/zz-iatdemo/zz-iatdemo-B1.0/pwr/anylogevents.c

    25a26
    > LogSvEvent((int)1001); /*12/09/2003 13:47:14*/
    62a64
    > LogSvEvent((int)1002); /*12/09/2003 13:47:14*/
    66a69
    > LogSvEvent((int)1003); /*12/09/2003 13:47:14*/
    92a96
    > LogSvEvent((int)1004); /*12/09/2003 13:47:14*/
    97a102
    > LogSvEvent((int)1005); /*12/09/2003 13:47:14*/
    99a105
    > LogSvEvent((int)1006); /*12/09/2003 13:47:14*/
    108a115
    > LogSvEvent((int)1007); /*12/09/2003 13:47:14*/
    113a121
    > LogSvEvent((int)1008); /*12/09/2003 13:47:14*/
    115a124
    > LogSvEvent((int)1009); /*12/09/2003 13:47:14*/
    133a143
    > LogSvEvent((int)1010); /*12/09/2003 13:47:14*/
    134a145
    > LogSvEvent((int)1011); /*12/09/2003 13:47:14*/
    151a163
    > LogSvEvent((int)1012); /*12/09/2003 13:47:14*/
    152a165
    > LogSvEvent((int)1013); /*12/09/2003 13:47:14*/
    153a167
    > LogSvEvent((int)1014); /*12/09/2003 13:47:14*/
    168a183
    > LogSvEvent((int)1015); /*12/09/2003 13:47:14*/
    209a225
    > LogSvEvent((int)1016); /*12/09/2003 13:47:14*/
    210a227
    > LogSvEvent((int)1017); /*12/09/2003 13:47:14*/
    211a229
    > LogSvEvent((int)1018); /*12/09/2003 13:47:14*/
    212a231
    > LogSvEvent((int)1019); /*12/09/2003 13:47:14*/
    232a252
    > LogSvEvent((int)1020); /*12/09/2003 13:47:14*/
    233a254
    > LogSvEvent((int)1021); /*12/09/2003 13:47:14*/
    234a256
    > LogSvEvent((int)1022); /*12/09/2003 13:47:14*/
    251a274
    > LogSvEvent((int)8001); /* anylogevents.c HMI_CALL 12/09/2003 13:47:14 */
    270a294
    > LogSvEvent((int)7001); /* anylogevents.c any + loc 12/09/2003 13:47:14 */
    283a308
    > LogSvEvent((int)7002); /* anylogevents.c any + loc 12/09/2003 13:47:14 */
    290a316
    > LogSvEvent((int)7003); /* anylogevents.c any+loc 12/09/2003 13:47:14 */
    297a324
    > LogSvEvent((int)7004); /* anylogevents.c any-loc 12/09/2003 13:47:14 */
    304a332
    > LogSvEvent((int)7005); /* anylogevents.c any*loc 12/09/2003 13:47:14 */
    311a340
    > LogSvEvent((int)7006); /* anylogevents.c any/loc 12/09/2003 13:47:14 */
    318a348
    > LogSvEvent((int)5001); /* anylogevents.c PURGE_BUFFER 12/09/2003 13:47:14 */
    325a356
    > LogSvEvent((int)5002); /* anylogevents.c PURGE_BUFFER 12/09/2003 13:47:14 */
    331a363
    > LogSvEvent((int)1023); /*12/09/2003 13:47:14*/
    332a365
    > LogSvEvent((int)1024); /*12/09/2003 13:47:14*/
    333a367
    > LogSvEvent((int)1025); /*12/09/2003 13:47:14*/


    2 3 Source: source/zz-iatdemo/zz-iatdemo-B1.0/pwr/badcoding.c
    2 3 Result: result/source/zz-iatdemo/zz-iatdemo-B1.0/pwr/badcoding.c

    source/zz-iatdemo/zz-iatdemo-B1.0/pwr/badcoding.c result/source/zz-iatdemo/zz-iatdemo-B1.0/pwr/badcoding.c

    21a22
    > LogSvEvent((int)1026); /*12/09/2003 13:47:14*/
    46a48
    > LogSvEvent((int)1027); /*12/09/2003 13:47:14*/
    94a97
    > LogSvEvent((int)1028); /*12/09/2003 13:47:14*/
    117a121
    > LogSvEvent((int)1029); /*12/09/2003 13:47:14*/
    118a123
    > LogSvEvent((int)1030); /*12/09/2003 13:47:14*/
    159c164,165
    < /* LE SV TOC-007 */ // too lazy to paraphrase req
    ---
    > /* LE SV TOC-007 req 7 about item 7 stuff AUTO COMMENT */ // too lazy to paraphrase req
    > LogSvEvent((int)1031); /*12/09/2003 13:47:14*/
    234a241
    > LogSvEvent((int)1032); /*12/09/2003 13:47:14*/
    263a271
    > LogSvEvent((int)1033); /*12/09/2003 13:47:14*/
    299a308
    > LogSvEvent((int)1034); /*12/09/2003 13:47:14*/
    304a314
    > LogSvEvent((int)1035); /*12/09/2003 13:47:14*/


    done
    12/09/2003 13:47:16 start
    12/09/2003 13:47:17 end