[Python-checkins] CVS: python/dist/src/Doc/lib libos.tex,1.66,1.67

Fred L. Drake fdrake@users.sourceforge.net
Tue, 09 Oct 2001 11:07:06 -0700


Update of /cvsroot/python/python/dist/src/Doc/lib
In directory usw-pr-cvs1:/tmp/cvs-serv18019/lib

Modified Files:
	libos.tex 
Log Message:
Improve the documentation for the os.P_* constants used with the os.spawn*()
functions to include information about how they affect the operation of
those functions when used as the "mode" parameter.
This closes SF bug #468384.

Added warnings to the os.tempnam() and os.tmpnam() functions regarding their
security problem.  These warning mirror the warnings added to the runtime
by Skip Montanaro.


Index: libos.tex
===================================================================
RCS file: /cvsroot/python/python/dist/src/Doc/lib/libos.tex,v
retrieving revision 1.66
retrieving revision 1.67
diff -C2 -d -r1.66 -r1.67
*** libos.tex	2001/10/04 22:44:26	1.66
--- libos.tex	2001/10/09 18:07:04	1.67
***************
*** 796,799 ****
--- 796,801 ----
  managing files created using paths returned by \function{tempnam()};
  no automatic cleanup is provided.
+ \warning{Use of \function{tempnam()} is vulnerable to symlink attacks;
+ consider using \function{tmpfile()} instead.}
  Availability: \UNIX, Windows.
  \end{funcdesc}
***************
*** 806,809 ****
--- 808,813 ----
  paths returned by \function{tmpnam()}; no automatic cleanup is
  provided.
+ \warning{Use of \function{tmpnam()} is vulnerable to symlink attacks;
+ consider using \function{tmpfile()} instead.}
  Availability: \UNIX, Windows.
  \end{funcdesc}
***************
*** 1012,1029 ****
  \end{funcdesc}
  
! \begin{datadesc}{P_WAIT}
! \dataline{P_NOWAIT}
  \dataline{P_NOWAITO}
! Possible values for the \var{mode} parameter to \function{spawnv()}
! and \function{spawnve()}.
  Availability: \UNIX{}, Windows.
  \versionadded{1.6}
  \end{datadesc}
  
! \begin{datadesc}{P_OVERLAY}
! \dataline{P_DETACH}
! Possible values for the \var{mode} parameter to \function{spawnv()}
! and \function{spawnve()}.  These are less portable than those listed
! above.
  Availability: Windows.
  \versionadded{1.6}
--- 1016,1049 ----
  \end{funcdesc}
  
! \begin{datadesc}{P_NOWAIT}
  \dataline{P_NOWAITO}
! Possible values for the \var{mode} parameter to the \function{spawn*()}
! family of functions.  If either of these values is given, the
! \function{spawn*()} functions will return as soon as the new process
! has been created, with the process ID as the return value.
  Availability: \UNIX{}, Windows.
  \versionadded{1.6}
  \end{datadesc}
  
! \begin{datadesc}{P_WAIT}
! Possible value for the \var{mode} parameter to the \function{spawn*()}
! family of functions.  If this is given as \var{mode}, the
! \function{spawn*()} functions will not return until the new process
! has run to completion and will return the exit code of the process the
! run is successful, or \code{-\var{signal}} if a signal kills the
! process.
! Availability: \UNIX{}, Windows.
! \versionadded{1.6}
! \end{datadesc}
! 
! \begin{datadesc}{P_DETACH}
! \dataline{P_OVERLAY}
! Possible values for the \var{mode} parameter to the
! \function{spawn*()} family of functions.  These are less portable than
! those listed above.
! \constant{P_DETACH} is similar to \constant{P_NOWAIT}, but the new
! process is detached from the console of the calling process.
! If \constant{P_OVERLAY} is used, the current process will be replaced;
! the \function{spawn*()} function will not return.
  Availability: Windows.
  \versionadded{1.6}