OSDN Git Service

(split) LDP: Update releases based on LDP 3.52 release
[linuxjm/LDP_man-pages.git] / release / man3 / mkstemp.3
index d3cf45f..3261efc 100644 (file)
@@ -81,10 +81,9 @@ _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE\ >=\ 500 || _XOPEN_SOURCE\ &&\ _XOP
 この部分がファイル名を他と重ならないようにする文字で置き換えられる。 \fItemplate\fP は書き換えられるため、文字列定数ではなく文字配列として
 宣言するようにしなければならない。
 
-The file is created with permissions 0600, that is, read plus write for
-owner only.  The returned file descriptor provides both read and write
-access to the file.  The file is opened with the \fBopen\fP(2)  \fBO_EXCL\fP flag,
-guaranteeing that the caller is the process that creates the file.
+ファイルは許可モード 0600 で作成され、所有者のみが読み書き可能である。返されるファイルディスクリプタで、このファイルへの読み書き両方のアクセスが
+可能である。 呼び出し者がそのファイルを作成するプロセスであることを保証するために、 ファイルは \fBopen\fP(2)  の \fBO_EXCL\fP
+フラグ付きでオープンされる。
 
 \fBmkostemp\fP() 関数は \fBmkstemp\fP() と同様だが、\fBopen\fP(2) に渡される
 フラグ O_APPEND\fB,\fP \fBO_SYNC\fP など) を \fIflags\fP で指定できる点が異なる
@@ -125,11 +124,10 @@ guaranteeing that the caller is the process that creates the file.
 
 \fBmkostemp\fP() と \fBmkostemps\fP(): glibc による拡張。
 .SH 注意
-In glibc versions 2.06 and earlier, the file is created with permissions
-0666, that is, read and write for all users.  This old behavior may be a
-security risk, especially since other UNIX flavors use 0600, and somebody
-might overlook this detail when porting programs.  POSIX.1\-2008 adds a
-requirement that the file be created with mode 0600.
+glibc バージョン 2.06 以前では、ファイルは許可モード 0666 で作成され、全てのユーザが読み書き可能であった。この古い動作は、
+セキュリティ上のリスクになり得る。特に、他の UNIX では許可モードとして 0600
+を使うため、プログラムを移植する際、この細かな違いを見落とす可能性があるからだ。 POSIX.1\-2008 では、ファイルを許可モード 0600
+で作成することが必須要件として追加された。
 
 より一般的には、 \fBmkstemp\fP()  の POSIX 規定ではファイルモードについて何も述べていない。 従って、アプリケーションは
 \fBmkstemp\fP()  (や \fBmkostemp\fP())  を呼び出す前にファイルモード生成マスク (\fBumask\fP(2)  参照)
@@ -140,6 +138,6 @@ glibc2 では POSIX.1 に準拠し \fI<stdlib.h>\fP に含まれている。
 .SH 関連項目
 \fBmkdtemp\fP(3), \fBmktemp\fP(3), \fBtempnam\fP(3), \fBtmpfile\fP(3), \fBtmpnam\fP(3)
 .SH この文書について
-この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.50 の一部
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.52 の一部
 である。プロジェクトの説明とバグ報告に関する情報は
 http://www.kernel.org/doc/man\-pages/ に書かれている。