SlideShare a Scribd company logo
1 of 38
Static code analysis @RuneSundling | Rune.Sundling@gmail.com | rune-sundling.blogspot.com
Thank you!
Integrate in  dev. process Static code  analysis Tools
Overall, testing is far more valuable  than static analysis  - Bill Pugh
Static analysis, at best, might catch 5-10% of your software quality  problems  - Bill Pugh
Obstacles?
Obstacles? Marketing  budget
Obstacles? Will fix everything
Obstacles?
Obstacles?
Obstacles?
Obstacles?
Obstacles? Return on investment
Used effectively, static analysis  is cheaper than other techniques  for catching the same bugs  - Bill Pugh
If you are not using them [static  Analysis tools], then basically  you are negligent, and you should  prepare to be sued by the army  of lawyers that have  already hit the  beach - Gary McGraw
Combining inspections, static analysis,  and testing is cheaper than testing  by itself and leads to much  better defect removal  efficiency levels. - Capers Jones
At my company, sometimes I feel less  like Chief Architect, and more like  Chief Debugger or Chief Code Reader.  Sometimes I get to caught up in  trying to read code in order to  understand the big picture. This is  my own failing, as I often try to  use a microscope when I need a  telescope. - Scott Hanselman
Once I realized the depth and  breadth of the information I was  looking at it, I was like a kid  in a candy shop - Scott Hanselman
An average of 17% cost savings would have been possible if the static  analysis tool was used - Dejan Baca, BengtCarlsson, Lars Lundberg “Evaluating the Cost Reduction  of Static Code Analysis  for Software Security” (2008)
Types of bugs ,[object Object]
Bad practice
Input validation
Maintainability
Correctness
Security
Multithreaded correctness
Performance
Internationalization
Interoperability
Specific for tools,[object Object]
NDepend
Mono.Gendarme (free)
Smokey (free)
ReSharper
CodeRushDuplication detection ,[object Object],Security ,[object Object],Analysis Tool .NET) (free) Code style ,[object Object]

More Related Content

What's hot

Code Review
Code ReviewCode Review
Code Reviewrantav
 
Java Code Review Checklist
Java Code Review ChecklistJava Code Review Checklist
Java Code Review ChecklistMahesh Chopker
 
Code-Review-Principles-Process-and-Tools (1)
Code-Review-Principles-Process-and-Tools (1)Code-Review-Principles-Process-and-Tools (1)
Code-Review-Principles-Process-and-Tools (1)Aditya Bhuyan
 
Server Side Template Injection by Mandeep Jadon
Server Side Template Injection by Mandeep JadonServer Side Template Injection by Mandeep Jadon
Server Side Template Injection by Mandeep JadonMandeep Jadon
 
Code review guidelines
Code review guidelinesCode review guidelines
Code review guidelinesLalit Kale
 
DevSecOps: Securing Applications with DevOps
DevSecOps: Securing Applications with DevOpsDevSecOps: Securing Applications with DevOps
DevSecOps: Securing Applications with DevOpsWouter de Kort
 
Code Review: How and When
Code Review: How and WhenCode Review: How and When
Code Review: How and WhenPaul Gower
 
Improving Code Quality Through Effective Review Process
Improving Code Quality Through Effective  Review ProcessImproving Code Quality Through Effective  Review Process
Improving Code Quality Through Effective Review ProcessDr. Syed Hassan Amin
 
Code Review
Code ReviewCode Review
Code ReviewTu Hoang
 
Static code analysis
Static code analysisStatic code analysis
Static code analysisPrancer Io
 
Java Code Quality Tools
Java Code Quality ToolsJava Code Quality Tools
Java Code Quality ToolsAnju ML
 
Static Analysis with Sonarlint
Static Analysis with SonarlintStatic Analysis with Sonarlint
Static Analysis with SonarlintUT, San Antonio
 
Static Analysis Techniques For Testing Application Security - Houston Tech Fest
Static Analysis Techniques For Testing Application Security - Houston Tech FestStatic Analysis Techniques For Testing Application Security - Houston Tech Fest
Static Analysis Techniques For Testing Application Security - Houston Tech FestDenim Group
 
Code Review
Code ReviewCode Review
Code ReviewRavi Raj
 
Code review in practice
Code review in practiceCode review in practice
Code review in practiceEdorian
 

What's hot (20)

Code Review
Code ReviewCode Review
Code Review
 
Java Code Review Checklist
Java Code Review ChecklistJava Code Review Checklist
Java Code Review Checklist
 
Code-Review-Principles-Process-and-Tools (1)
Code-Review-Principles-Process-and-Tools (1)Code-Review-Principles-Process-and-Tools (1)
Code-Review-Principles-Process-and-Tools (1)
 
Server Side Template Injection by Mandeep Jadon
Server Side Template Injection by Mandeep JadonServer Side Template Injection by Mandeep Jadon
Server Side Template Injection by Mandeep Jadon
 
Code review guidelines
Code review guidelinesCode review guidelines
Code review guidelines
 
DevSecOps: Securing Applications with DevOps
DevSecOps: Securing Applications with DevOpsDevSecOps: Securing Applications with DevOps
DevSecOps: Securing Applications with DevOps
 
Code Review: How and When
Code Review: How and WhenCode Review: How and When
Code Review: How and When
 
Improving Code Quality Through Effective Review Process
Improving Code Quality Through Effective  Review ProcessImproving Code Quality Through Effective  Review Process
Improving Code Quality Through Effective Review Process
 
Code review
Code reviewCode review
Code review
 
Code Review
Code ReviewCode Review
Code Review
 
Static code analysis
Static code analysisStatic code analysis
Static code analysis
 
Java Code Quality Tools
Java Code Quality ToolsJava Code Quality Tools
Java Code Quality Tools
 
Static Code Analysis
Static Code AnalysisStatic Code Analysis
Static Code Analysis
 
Static Analysis with Sonarlint
Static Analysis with SonarlintStatic Analysis with Sonarlint
Static Analysis with Sonarlint
 
Effective code reviews
Effective code reviewsEffective code reviews
Effective code reviews
 
Effective code reviews
Effective code reviewsEffective code reviews
Effective code reviews
 
Parasoft fda software compliance part2
Parasoft fda software compliance   part2Parasoft fda software compliance   part2
Parasoft fda software compliance part2
 
Static Analysis Techniques For Testing Application Security - Houston Tech Fest
Static Analysis Techniques For Testing Application Security - Houston Tech FestStatic Analysis Techniques For Testing Application Security - Houston Tech Fest
Static Analysis Techniques For Testing Application Security - Houston Tech Fest
 
Code Review
Code ReviewCode Review
Code Review
 
Code review in practice
Code review in practiceCode review in practice
Code review in practice
 

Viewers also liked

Static Code Analysis
Static Code AnalysisStatic Code Analysis
Static Code AnalysisAnnyce Davis
 
[Meetup] Code Quality tools used at Wolox for Web developing.
[Meetup] Code Quality tools used at Wolox for Web developing.[Meetup] Code Quality tools used at Wolox for Web developing.
[Meetup] Code Quality tools used at Wolox for Web developing.Esteban Pintos
 
Static code analysis with sonar qube
Static code analysis with sonar qubeStatic code analysis with sonar qube
Static code analysis with sonar qubeHayi Nukman
 
Program understanding: What programmers really want
Program understanding: What programmers really wantProgram understanding: What programmers really want
Program understanding: What programmers really wantEinar Høst
 
Static Analysis and Code Optimizations in Glasgow Haskell Compiler
Static Analysis and Code Optimizations in Glasgow Haskell CompilerStatic Analysis and Code Optimizations in Glasgow Haskell Compiler
Static Analysis and Code Optimizations in Glasgow Haskell CompilerIlya Sergey
 
Continuous Integration and Quality Development
Continuous Integration and Quality DevelopmentContinuous Integration and Quality Development
Continuous Integration and Quality DevelopmentGareth Davies
 

Viewers also liked (8)

Static Code Analysis
Static Code AnalysisStatic Code Analysis
Static Code Analysis
 
[Meetup] Code Quality tools used at Wolox for Web developing.
[Meetup] Code Quality tools used at Wolox for Web developing.[Meetup] Code Quality tools used at Wolox for Web developing.
[Meetup] Code Quality tools used at Wolox for Web developing.
 
NDepend
NDependNDepend
NDepend
 
Static code analysis with sonar qube
Static code analysis with sonar qubeStatic code analysis with sonar qube
Static code analysis with sonar qube
 
Static code analysis
Static code analysisStatic code analysis
Static code analysis
 
Program understanding: What programmers really want
Program understanding: What programmers really wantProgram understanding: What programmers really want
Program understanding: What programmers really want
 
Static Analysis and Code Optimizations in Glasgow Haskell Compiler
Static Analysis and Code Optimizations in Glasgow Haskell CompilerStatic Analysis and Code Optimizations in Glasgow Haskell Compiler
Static Analysis and Code Optimizations in Glasgow Haskell Compiler
 
Continuous Integration and Quality Development
Continuous Integration and Quality DevelopmentContinuous Integration and Quality Development
Continuous Integration and Quality Development
 

Similar to Static code analysis

Agile Development From A Developers Perspective
Agile Development From A Developers PerspectiveAgile Development From A Developers Perspective
Agile Development From A Developers PerspectiveRichard Banks
 
Phil Koopman's ISSRE 2016 Keynote
Phil Koopman's ISSRE 2016 KeynotePhil Koopman's ISSRE 2016 Keynote
Phil Koopman's ISSRE 2016 Keynoteedgecaseresearch
 
Parasoft .TEST, Write better C# Code Using Data Flow Analysis
Parasoft .TEST, Write better C# Code Using  Data Flow Analysis Parasoft .TEST, Write better C# Code Using  Data Flow Analysis
Parasoft .TEST, Write better C# Code Using Data Flow Analysis Engineering Software Lab
 
Machine programming
Machine programmingMachine programming
Machine programmingDESMOND YUEN
 
1Sem-MTech-Design For Verification Notes-Unit2-Verification Tools
1Sem-MTech-Design For Verification Notes-Unit2-Verification Tools1Sem-MTech-Design For Verification Notes-Unit2-Verification Tools
1Sem-MTech-Design For Verification Notes-Unit2-Verification ToolsDr. Shivananda Koteshwar
 
Successful Software Projects - What you need to consider
Successful Software Projects - What you need to considerSuccessful Software Projects - What you need to consider
Successful Software Projects - What you need to considerLloydMoore
 
assertYourself - Breaking the Theories and Assumptions of Unit Testing in Flex
assertYourself - Breaking the Theories and Assumptions of Unit Testing in FlexassertYourself - Breaking the Theories and Assumptions of Unit Testing in Flex
assertYourself - Breaking the Theories and Assumptions of Unit Testing in Flexmichael.labriola
 
Static Analysis
Static AnalysisStatic Analysis
Static Analysisalice yang
 
Three Interviews About Static Code Analyzers
Three Interviews About Static Code AnalyzersThree Interviews About Static Code Analyzers
Three Interviews About Static Code AnalyzersAndrey Karpov
 
Quality assurance of large c++ projects
Quality assurance of large c++ projectsQuality assurance of large c++ projects
Quality assurance of large c++ projectscorehard_by
 
GNUCITIZEN Dwk Owasp Day September 2007
GNUCITIZEN Dwk Owasp Day   September 2007GNUCITIZEN Dwk Owasp Day   September 2007
GNUCITIZEN Dwk Owasp Day September 2007guest20ab09
 
The limits of unit testing by Craig Stuntz
The limits of unit testing by Craig StuntzThe limits of unit testing by Craig Stuntz
The limits of unit testing by Craig StuntzQA or the Highway
 
The Limits of Unit Testing by Craig Stuntz
The Limits of Unit Testing by Craig StuntzThe Limits of Unit Testing by Craig Stuntz
The Limits of Unit Testing by Craig StuntzQA or the Highway
 
Cinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patternsCinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patternsSteven Smith
 
The "Evils" of Optimization
The "Evils" of OptimizationThe "Evils" of Optimization
The "Evils" of OptimizationBlackRabbitCoder
 
TEA Presentation V 0.3
TEA Presentation V 0.3TEA Presentation V 0.3
TEA Presentation V 0.3Ian McDonald
 

Similar to Static code analysis (20)

Agile Development From A Developers Perspective
Agile Development From A Developers PerspectiveAgile Development From A Developers Perspective
Agile Development From A Developers Perspective
 
Phil Koopman's ISSRE 2016 Keynote
Phil Koopman's ISSRE 2016 KeynotePhil Koopman's ISSRE 2016 Keynote
Phil Koopman's ISSRE 2016 Keynote
 
Parasoft .TEST, Write better C# Code Using Data Flow Analysis
Parasoft .TEST, Write better C# Code Using  Data Flow Analysis Parasoft .TEST, Write better C# Code Using  Data Flow Analysis
Parasoft .TEST, Write better C# Code Using Data Flow Analysis
 
Machine programming
Machine programmingMachine programming
Machine programming
 
1Sem-MTech-Design For Verification Notes-Unit2-Verification Tools
1Sem-MTech-Design For Verification Notes-Unit2-Verification Tools1Sem-MTech-Design For Verification Notes-Unit2-Verification Tools
1Sem-MTech-Design For Verification Notes-Unit2-Verification Tools
 
Automated tests
Automated testsAutomated tests
Automated tests
 
Successful Software Projects - What you need to consider
Successful Software Projects - What you need to considerSuccessful Software Projects - What you need to consider
Successful Software Projects - What you need to consider
 
assertYourself - Breaking the Theories and Assumptions of Unit Testing in Flex
assertYourself - Breaking the Theories and Assumptions of Unit Testing in FlexassertYourself - Breaking the Theories and Assumptions of Unit Testing in Flex
assertYourself - Breaking the Theories and Assumptions of Unit Testing in Flex
 
Static Analysis
Static AnalysisStatic Analysis
Static Analysis
 
Ensuring code quality
Ensuring code qualityEnsuring code quality
Ensuring code quality
 
Three Interviews About Static Code Analyzers
Three Interviews About Static Code AnalyzersThree Interviews About Static Code Analyzers
Three Interviews About Static Code Analyzers
 
Quality assurance of large c++ projects
Quality assurance of large c++ projectsQuality assurance of large c++ projects
Quality assurance of large c++ projects
 
GNUCITIZEN Dwk Owasp Day September 2007
GNUCITIZEN Dwk Owasp Day   September 2007GNUCITIZEN Dwk Owasp Day   September 2007
GNUCITIZEN Dwk Owasp Day September 2007
 
The limits of unit testing by Craig Stuntz
The limits of unit testing by Craig StuntzThe limits of unit testing by Craig Stuntz
The limits of unit testing by Craig Stuntz
 
The Limits of Unit Testing by Craig Stuntz
The Limits of Unit Testing by Craig StuntzThe Limits of Unit Testing by Craig Stuntz
The Limits of Unit Testing by Craig Stuntz
 
Cinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patternsCinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patterns
 
AAA Automated Testing
AAA Automated TestingAAA Automated Testing
AAA Automated Testing
 
The "Evils" of Optimization
The "Evils" of OptimizationThe "Evils" of Optimization
The "Evils" of Optimization
 
10 Ways To Improve Your Code
10 Ways To Improve Your Code10 Ways To Improve Your Code
10 Ways To Improve Your Code
 
TEA Presentation V 0.3
TEA Presentation V 0.3TEA Presentation V 0.3
TEA Presentation V 0.3
 

More from Rune Sundling

Delivering software - process and infrastructure
Delivering software - process and infrastructureDelivering software - process and infrastructure
Delivering software - process and infrastructureRune Sundling
 
Distribuert utvikling på net platformen
Distribuert utvikling på net platformenDistribuert utvikling på net platformen
Distribuert utvikling på net platformenRune Sundling
 
Being able to code does not make you a good developer
Being able to code does not make you a good developerBeing able to code does not make you a good developer
Being able to code does not make you a good developerRune Sundling
 
Den ikke tekniske delen av å være konsulent, utvikler og profesjonell
Den ikke tekniske delen av å være konsulent, utvikler og profesjonellDen ikke tekniske delen av å være konsulent, utvikler og profesjonell
Den ikke tekniske delen av å være konsulent, utvikler og profesjonellRune Sundling
 
Objektorientering og design av kode
Objektorientering og design av kodeObjektorientering og design av kode
Objektorientering og design av kodeRune Sundling
 
Koblingen objekter mot database
Koblingen objekter mot databaseKoblingen objekter mot database
Koblingen objekter mot databaseRune Sundling
 

More from Rune Sundling (6)

Delivering software - process and infrastructure
Delivering software - process and infrastructureDelivering software - process and infrastructure
Delivering software - process and infrastructure
 
Distribuert utvikling på net platformen
Distribuert utvikling på net platformenDistribuert utvikling på net platformen
Distribuert utvikling på net platformen
 
Being able to code does not make you a good developer
Being able to code does not make you a good developerBeing able to code does not make you a good developer
Being able to code does not make you a good developer
 
Den ikke tekniske delen av å være konsulent, utvikler og profesjonell
Den ikke tekniske delen av å være konsulent, utvikler og profesjonellDen ikke tekniske delen av å være konsulent, utvikler og profesjonell
Den ikke tekniske delen av å være konsulent, utvikler og profesjonell
 
Objektorientering og design av kode
Objektorientering og design av kodeObjektorientering og design av kode
Objektorientering og design av kode
 
Koblingen objekter mot database
Koblingen objekter mot databaseKoblingen objekter mot database
Koblingen objekter mot database
 

Recently uploaded

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 

Recently uploaded (20)

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 

Static code analysis

  • 1. Static code analysis @RuneSundling | Rune.Sundling@gmail.com | rune-sundling.blogspot.com
  • 3. Integrate in dev. process Static code analysis Tools
  • 4.
  • 5.
  • 6. Overall, testing is far more valuable than static analysis - Bill Pugh
  • 7. Static analysis, at best, might catch 5-10% of your software quality problems - Bill Pugh
  • 10. Obstacles? Will fix everything
  • 15. Obstacles? Return on investment
  • 16.
  • 17. Used effectively, static analysis is cheaper than other techniques for catching the same bugs - Bill Pugh
  • 18. If you are not using them [static Analysis tools], then basically you are negligent, and you should prepare to be sued by the army of lawyers that have already hit the beach - Gary McGraw
  • 19. Combining inspections, static analysis, and testing is cheaper than testing by itself and leads to much better defect removal efficiency levels. - Capers Jones
  • 20. At my company, sometimes I feel less like Chief Architect, and more like Chief Debugger or Chief Code Reader. Sometimes I get to caught up in trying to read code in order to understand the big picture. This is my own failing, as I often try to use a microscope when I need a telescope. - Scott Hanselman
  • 21. Once I realized the depth and breadth of the information I was looking at it, I was like a kid in a candy shop - Scott Hanselman
  • 22. An average of 17% cost savings would have been possible if the static analysis tool was used - Dejan Baca, BengtCarlsson, Lars Lundberg “Evaluating the Cost Reduction of Static Code Analysis for Software Security” (2008)
  • 23.
  • 33.
  • 38.
  • 39.
  • 44.
  • 45.
  • 46. HP ..
  • 51. HP ..
  • 55. Demo
  • 58.
  • 59.
  • 62. Links & References # List of static code analysis tools http://en.wikipedia.org/wiki/List_of_tools_for_static_code_analysis # General: Defective Java: Mistakes that matter - Bill Pugh – Øredev 2010 http://vimeo.com/17157772 How and to who should you report static analysis results to http://codeintegrity.blogspot.com/2010/12/static-analysis-reporting-for-success.html Software Engineering Radio - Static Code Analysis (Episode 59, 2006) http://www.se-radio.net/2007/06/episode-59-static-code-analysis/
  • 63. Links & References # NDepend: Link http://www.ndepend.com/ Tips http://www.ndepend.com/Tips.aspx Metrics: http://www.ndepend.com/Metrics.aspx Hanselmanpodcast on static code analysis and NDependhttp://www.hanselman.com/blog/HanselminutesPodcast51StaticCodeAnalysisWithNDepend.aspx Success story on large project http://codebetter.com/patricksmacchia/2009/01/04/using-ndepend-on-large-project-a-success-story/ Hanselman/Caudwell NDepend metrics posterhttp://www.hanselman.com/blog/content/binary/NDepend%20metrics%20placemats%201.1.pdf Discussions with NHibernate contributor on value of these tools (read comments) http://codebetter.com/blogs/patricksmacchia/archive/2009/07/21/nhibernate-2-1-changes-overview.aspxhttp://ayende.com/blog/4072/answering-to-nhibernate-codebase-quality-criticismhttp://ayende.com/blog/4079/nhibernate-and-ndepend-skimming-the-surface
  • 64. Links & References Links to various NDepend analyses http://codebetter.com/blogs/patricksmacchia/archive/2009/01/11/lessons-learned-from-the-nunit-code-base.aspxhttp://codebetter.com/blogs/patricksmacchia/archive/2009/05/21/a-quick-analyze-of-the-net-fx-v4-0-beta1.aspxhttp://codebetter.com/blogs/patricksmacchia/archive/2009/04/26/the-big-picture-of-the-sharpdevelop-code-base.aspxhttp://codebetter.com/blogs/patricksmacchia/archive/2009/04/23/ndepend-and-the-quality-of-the-cruise-control-net-code-base.aspxhttp://codebetter.com/blogs/patricksmacchia/archive/2009/01/19/mono-vs-net-framework-public-api-compatibility.aspxhttp://codebetter.com/blogs/patricksmacchia/archive/2008/10/01/comparing-silverlight-and-the-net-framework.aspxhttp://codebetter.com/blogs/patricksmacchia/archive/2008/08/26/nhibernate-2-0-changes-overview.aspxhttp://codebetter.com/blogs/patricksmacchia/archive/2008/08/13/net-3-5-sp1-changes-overview.aspxspring.nethttp://unhandled-exceptions.com/blog/index.php/2010/07/21/analyzing-spring-net-with-ndepend3/ CQL examples http://codebetter.com/patricksmacchia/2008/05/11/write-active-conventions-on-your-code-base/ http://mookid.dk/oncode/archives/1052 http://blogs.lessthandot.com/index.php/Architect/DesigningSoftware/cql-from-visual-studio-with-ndepend-3
  • 65. Links & References # Visual Studio Code Analysis: Visual Studio Code Analysis and Code metrics forum http://social.msdn.microsoft.com/forums/en-US/vstscode/threads/ Rules http://msdn.microsoft.com/en-us/library/ee1hzekz.aspx How to write custom static code analysis rules and integrate them into VS2010 http://blogs.msdn.com/b/codeanalysis/archive/2010/03/26/how-to-write-custom-static-code-analysis-rules-and-integrate-them-into-visual-studio-2010.aspx Data flow analysis in VS2010 (Whatis not in FxCop) http://blogs.msdn.com/b/codeanalysis/archive/2010/04/14/data-flow-analysis-rules-in-visual-studio-2010.aspx Integrate VS2010 Code analysis in CI or MsBuild Part 1 Introduction - http://kentb.blogspot.com/2011/01/code-analysis-without-visual-studio.html Part 2 The steps - http://kentb.blogspot.com/2011/01/code-analysis-without-visual-studio_6701.html Visual Studio and ReSharper C# coding guidelines (VS Rule set, R# code style) http://csharpguidelines.codeplex.com/
  • 66. Links & References # FxCop: Download http://www.microsoft.com/downloads/en/details.aspx?FamilyID=917023F6-D5B7-41BB-BBC0-411A7D66CF3C Intro and integrate with CI http://www.developertutorials.com/tutorials/miscellaneous/continuous-code-analysis-fx-cop-805/ Share rules: http://stackoverflow.com/questions/3770696/how-to-share-fxcop-rules-amongst-all-developers How to manage big FxCop backlog (2007)http://msmvps.com/blogs/calinoiu/archive/2007/06/02/fxcop-backlog-tools-fxcop.aspx How to get the suppress-messages in code to work with FxCopgui http://blogs.msdn.com/b/codeanalysis/archive/2006/03/23/559149.aspx # StyleCop: Link http://stylecop.codeplex.com/ StyleCop on legacy projects http://blogs.msdn.com/b/sourceanalysis/archive/2008/11/11/introducing-stylecop-on-legacy-projects.aspx StyleCop in CI build http://blogs.msdn.com/b/sourceanalysis/archive/2008/05/24/source-analysis-msbuild-integration.aspx
  • 67. Links & References # ReSharper Link: www.jetbrains.com/resharper/ Code Quality Analysis http://www.jetbrains.com/resharper/features/code_analysis.html Structural Search Replace http://blogs.jetbrains.com/dotnet/2010/04/introducing-resharper-50-structural-search-and-replace/ ReSharper Settings Manager http://rsm.codeplex.com/ # List of rules from other tools: Fortify (HP): https://www.fortify.com/vulncat/en/vulncat/index.html
  • 68. Questions? @RuneSundling | Rune.Sundling@gmail.com | rune-sundling.blogspot.com