Bug 1254032 - 8.1.1 advice on using getpid to avoid fork problems is dangerously wrong
Summary: 8.1.1 advice on using getpid to avoid fork problems is dangerously wrong
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora Documentation
Classification: Fedora
Component: defensive-coding-guide
Version: devel
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Florian Weimer
QA Contact: Fedora Docs QA
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-08-17 00:22 UTC by Steven Stewart-Gallus
Modified: 2019-11-07 15:29 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-11-07 15:29:54 UTC
Embargoed:


Attachments (Terms of Use)

Description Steven Stewart-Gallus 2015-08-17 00:22:22 UTC
Description of problem:

If one forks a process, the original process dies and then the second one forks again the last forked process can have the same pid as the original and so getpid will not detect a change.  This was a widely noted weakness in LibreSSL (see https://www.agwa.name/blog/post/libressls_prng_is_unsafe_on_linux.)

How reproducible:

This is very probably systematically reproducible in possibly affected libraries but in practise should never really happen.

Comment 1 Petr Bokoc 2019-11-07 15:29:54 UTC
I'm closing this bug as part of a Bugzilla cleanup effort. The most likely reason is that the bug has been opened either against a component we no longer publish, or against Release Notes for an EOL release.


Note You need to log in before you can comment on or make changes to this bug.