tmpnam.3 (32eef9aeb1f39a1623cea55da147c89abbd5b9a5) tmpnam.3 (e125c135a88a6a1995006a1c03a8ebfcd7179c7c)
1.\" Copyright (c) 1988, 1991, 1993
2.\" The Regents of the University of California. All rights reserved.
3.\"
4.\" This code is derived from software contributed to Berkeley by
5.\" the American National Standards Committee X3, on Information
6.\" Processing Systems.
7.\"
8.\" Redistribution and use in source and binary forms, with or without

--- 168 unchanged lines hidden (view full) ---

177.Fn tempnam
178function
179may fail and set
180.Va errno
181for any of the errors specified for the library functions
182.Xr malloc 3
183or
184.Xr mktemp 3 .
1.\" Copyright (c) 1988, 1991, 1993
2.\" The Regents of the University of California. All rights reserved.
3.\"
4.\" This code is derived from software contributed to Berkeley by
5.\" the American National Standards Committee X3, on Information
6.\" Processing Systems.
7.\"
8.\" Redistribution and use in source and binary forms, with or without

--- 168 unchanged lines hidden (view full) ---

177.Fn tempnam
178function
179may fail and set
180.Va errno
181for any of the errors specified for the library functions
182.Xr malloc 3
183or
184.Xr mktemp 3 .
185.Sh SECURITY CONSIDERATIONS
186The
187.Fn tmpnam
188and
189.Fn tempnam
190functions are susceptible to a race condition,
191which allows malicious users
192to potentially overwrite arbitrary files in the system,
193depending on the level of privilege of the running program.
194It is strongly suggested that
195.Xr mkstemp 3
196be used in place of these functions.
197(See
198the FSA.)
185.Sh SEE ALSO
186.Xr mkstemp 3 ,
187.Xr mktemp 3
199.Sh SEE ALSO
200.Xr mkstemp 3 ,
201.Xr mktemp 3
202.Rs
203.%T "The FreeBSD Security Architecture"
204.%J "/usr/share/doc/{to be determined}"
205.Re
188.Sh STANDARDS
189The
190.Fn tmpfile
191and
192.Fn tmpnam
193functions
194conform to
195.St -isoC .

--- 34 unchanged lines hidden ---
206.Sh STANDARDS
207The
208.Fn tmpfile
209and
210.Fn tmpnam
211functions
212conform to
213.St -isoC .

--- 34 unchanged lines hidden ---