Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: REM Cost Reform

...

Threads that reference the stack of other threads can potentially overwrite important information on the stack, such as function pointers and return addresses. However, it would be difficult for an attacker to exploit this code from this error alone. The compiler will not generate warnings if the programmer decides to give another thread access to one thread's local variables, so a programmer may not catch a potential error at compile time. The remediation cost for this error is high because analysis tools have difficulty diagnosing problems with concurrency and race conditions.

Recommendation

Severity

Likelihood

Remediation Cost

Priority

Level

POS50-C

Medium

Probable

High

P4

L3

Detectable

Repairable

Priority

Level

POS50-C

Medium

Probable

No

No

P4

L3

Automated Detection

Tool

Version

Checker

Description

Helix QAC

Include Page
Helix QAC_V
Helix QAC_V

DF4926, DF4927, DF4928
Parasoft C/C++test
Include Page
Parasoft_V
Parasoft_V

CERT_C-POS50-a

Declare objects shared between POSIX threads with appropriate storage durations

Polyspace Bug Finder

Include Page
Polyspace Bug Finder_V
Polyspace Bug Finder_V

CERT C: Rule POS50-CChecks for automatic or thread local variable escaping from a POSIX thread (rule fully covered)


Bibliography

[Bryant 2003]Chapter 13, "Concurrent Programming"
[OpenMP]
 

...



...

Image ModifiedImage ModifiedImage Modified