CWE-361 - 7PK - Time and State

Improper management of time and state.

  • In an environment that supports simultaneous or near-simultaneous computation by multiple systems, processes, or threads.

Distributed computation is about time and state.

  • for more than one component to communicate, state must be shared, and all that takes time.

Programmers anthropomorphize their work.

  • They think about one thread of control carrying out the entire program in the same way they would if they had to do the job themselves.

Modern computers switch between tasks very quickly.

  • In multi-core, multi-CPU, or distributed systems, two events may take place at exactly the same time.

Unexpected interactions between threads, processes, time, and information.

  • These interactions happen through shared state: semaphores, variables, the file system, and, basically, anything that can store information.

Last updated