C and C++ Secure Coding


Course Number: SEC-126

Duration: 3 days (19.5 hours)

Format: Live, hands-on

Secure Coding Training Overview

Accelebrate's C and C++ Secure Coding training teaches developers the common security weaknesses that allow hackers to attack systems and the best practices needed to prevent these attacks. Attendees learn core programming issues of C and C++ and identify potential security pitfalls and solutions.

Location and Pricing

Accelebrate offers instructor-led enterprise training for groups of 3 or more online or at your site. Most Accelebrate classes can be flexibly scheduled for your group, including delivery in half-day segments across a week or set of weeks. To receive a customized proposal and price quote for private corporate training on-site or online, please contact us.

Objectives

All attendees will:

  • Handle security challenges in your C and C++ code
  • Identify vulnerabilities and their consequences
  • Learn the security best practices in C and C++

Prerequisites

All students must have C/C++ development experience.

Outline

Expand All | Collapse All

Cybersecurity Basics
  • What is security?
  • Threat and risk
  • Cybersecurity threat types
  • Consequences of insecure software
  • Constraints and the market
  • The dark side
Buffer Overflow
  • Assembly basics and calling conventions
    • x64 assembly essentials
    • Registers and addressing
    • Most common instructions
    • Calling conventions on x64
  • Memory management vulnerabilities
    • Memory management and security
    • Vulnerabilities in the real world
  • Buffer security issues
    • Buffer overflow on the stack
    • Buffer overflow on the heap
    • Pointer manipulation
    • Some typical mistakes leading to BoF
  • BoF protection best practices
    • Safe and unsafe functions
    • base_string and std::string
    • Some less-known dangerous functions
    • Lab – Fixing buffer overflow
    • Securing the toolchain
    • Compiler options and instrumentation
    • Stack smashing protection
    • Runtime protection
    • Address Space Layout Randomization (ASLR)
    • Non-executable memory areas
Common Software Security Weaknesses
  • Input validation
    • Input validation principles
  • Injection
    • Injection principles
    • Injection attacks
    • Code injection
  • Integer handling problems
    • Representing signed numbers
    • Integer visualization
    • Integer overflow
    • Lab – Integer overflow
    • Signed / unsigned confusion
    • Lab – Signed / unsigned confusion
    • Integer truncation
    • Lab – Integer truncation
    • Case study – Wannacry
    • Best practices
  • Other numeric problems
    • Division by zero
    • Working with floating-point numbers
  • Files and streams
    • Path traversal
    • Path traversal-related examples
    • Lab – Path traversal
    • Link and shortcut following
    • Virtual resources
    • Path traversal best practices
  • Format string issues
    • The problem with printf()
    • Lab – Exploiting format string
Time and State
  • Race conditions
    • Race condition in object data members
    • File race condition
    • Potential race condition
Common Software Security Weaknesses
  • Security features
    • Authentication
    • Password management
  • Errors
    • Error and exception handling principles
    • Error handling
    • Exception handling
  • Code quality
    • Type mismatch
    • Lab – Type mismatch
    • Function return values
    • Unreleased resource
    • Object-oriented programming pitfalls
    • Memory and pointers
Wrap Up
  • Secure coding principles
    • Principles of robust programming by Matt Bishop
    • Secure design principles of Saltzer and Schröder
  • And now what?
    • Further sources and readings
    • C and C++ resources

Training Materials:

All Secure Coding training attendees receive comprehensive courseware.

Software Requirements:

A VirtualBox virtual machine with all required software will be provided.



Learn faster

Our live, instructor-led lectures are far more effective than pre-recorded classes

Satisfaction guarantee

If your team is not 100% satisfied with your training, we do what's necessary to make it right

Learn online from anywhere

Whether you are at home or in the office, we make learning interactive and engaging

Multiple Payment Options

We accept check, ACH/EFT, major credit cards, and most purchase orders



Recent Training Locations

Alabama

Birmingham

Huntsville

Montgomery

Alaska

Anchorage

Arizona

Phoenix

Tucson

Arkansas

Fayetteville

Little Rock

California

Los Angeles

Oakland

Orange County

Sacramento

San Diego

San Francisco

San Jose

Colorado

Boulder

Colorado Springs

Denver

Connecticut

Hartford

DC

Washington

Florida

Fort Lauderdale

Jacksonville

Miami

Orlando

Tampa

Georgia

Atlanta

Augusta

Savannah

Hawaii

Honolulu

Idaho

Boise

Illinois

Chicago

Indiana

Indianapolis

Iowa

Cedar Rapids

Des Moines

Kansas

Wichita

Kentucky

Lexington

Louisville

Louisiana

New Orleans

Maine

Portland

Maryland

Annapolis

Baltimore

Frederick

Hagerstown

Massachusetts

Boston

Cambridge

Springfield

Michigan

Ann Arbor

Detroit

Grand Rapids

Minnesota

Minneapolis

Saint Paul

Mississippi

Jackson

Missouri

Kansas City

St. Louis

Nebraska

Lincoln

Omaha

Nevada

Las Vegas

Reno

New Jersey

Princeton

New Mexico

Albuquerque

New York

Albany

Buffalo

New York City

White Plains

North Carolina

Charlotte

Durham

Raleigh

Ohio

Akron

Canton

Cincinnati

Cleveland

Columbus

Dayton

Oklahoma

Oklahoma City

Tulsa

Oregon

Portland

Pennsylvania

Philadelphia

Pittsburgh

Rhode Island

Providence

South Carolina

Charleston

Columbia

Greenville

Tennessee

Knoxville

Memphis

Nashville

Texas

Austin

Dallas

El Paso

Houston

San Antonio

Utah

Salt Lake City

Virginia

Alexandria

Arlington

Norfolk

Richmond

Washington

Seattle

Tacoma

West Virginia

Charleston

Wisconsin

Madison

Milwaukee

Alberta

Calgary

Edmonton

British Columbia

Vancouver

Manitoba

Winnipeg

Nova Scotia

Halifax

Ontario

Ottawa

Toronto

Quebec

Montreal

Puerto Rico

San Juan