File: prctl.2

package info (click to toggle)
manpages-ja 0.5.0.0.20080615-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 20,508 kB
  • ctags: 1
  • sloc: sh: 13,690; perl: 157; makefile: 114
file content (254 lines) | stat: -rw-r--r-- 8,949 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
.\" Hey Emacs! This file is -*- nroff -*- source.
.\"
.\" Copyright (C) 1998 Andries Brouwer (aeb@cwi.nl)
.\" and Copyright (C) 2002 Michael Kerrisk <mtk.manpages@gmail.com>
.\" and Copyright Guillem Jover <guillem@hadrons.org>
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of this
.\" manual under the conditions for verbatim copying, provided that the
.\" entire resulting derived work is distributed under the terms of a
.\" permission notice identical to this one.
.\"
.\" Since the Linux kernel and libraries are constantly changing, this
.\" manual page may be incorrect or out-of-date.  The author(s) assume no
.\" responsibility for errors or omissions, or for damages resulting from
.\" the use of the information contained herein.  The author(s) may not
.\" have taken the same level of care in the production of this manual,
.\" which is licensed free of charge, as they might when working
.\" professionally.
.\"
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.
.\"
.\" Modified Thu Nov 11 04:19:42 MET 1999, aeb: added PR_GET_PDEATHSIG
.\" Modified 27 Jun 02, Michael Kerrisk
.\" 	Added PR_SET_DUMPABLE, PR_GET_DUMPABLE,
.\"	PR_SET_KEEPCAPS, PR_GET_KEEPCAPS
.\" Modified 2006-08-30 Guillem Jover <guillem@hadrons.org>
.\"	Updated Linux versions where the options where introduced.
.\"	Added PR_SET_TIMING, PR_GET_TIMING, PR_SET_NAME, PR_GET_NAME,
.\"	PR_SET_UNALIGN, PR_GET_UNALIGN, PR_SET_FPEMU, PR_GET_FPEMU,
.\"	PR_SET_FPEXC, PR_GET_FPEXC
.\"
.\" Japanese Version Copyright (c) 1998-1999 HANATAKA Shinya
.\"         all rights reserved.
.\" Translated 1999-04-03, HANATAKA Shinya <hanataka@abyss.rim.or.jp>
.\" Updated 2002-12-20, Kentaro Shirakata <argrath@ub32.org>
.\" Updated 2005-09-06, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
.\" Updated 2005-10-07, Akihiro MOTOKI
.\" Updated 2007-01-08, Akihiro MOTOKI, LDP v2.43
.\" Updated 2007-10-12, Akihiro MOTOKI, LDP v2.66
.\"
.TH PRCTL 2 2007-07-27 "Linux" "Linux Programmer's Manual"
.SH ̾
prctl \- ץԤʤ
.SH 
.nf
.B #include <sys/prctl.h>
.sp
.BI "int prctl(int " option ", unsigned long " arg2 ", unsigned long " arg3 ,
.BI "          unsigned long " arg4 ", unsigned long " arg5 );
.fi
.SH 
.BR prctl ()
ưϺǽΰˤäƷꤵ (ͤ
\fI<linux/prctl.h>\fP Ƥ)
ĤΥѥ᡼ϺǽΰˤäѲ롣
ܤΰȤưʲΤΤǤ:
.TP
.B PR_SET_PDEATHSIG
(Linux 2.1.57 ʹ)
ƥץ˴ʥ (parent process death signal)  \fIarg2\fP ꤹ
(Ǥ륷ʥͤϰϤ 1..maxsig Ǥꡢ0 ΤβǤ)
ƤӽФץοƥץݤˡꤷͤ
ʥȤΤ롣ͤ
.BR fork (2)
˲롣
.TP
.B PR_GET_PDEATHSIG
(Linux 2.3.15 ʹ)
ƥץ˴ʥθߤͤɤ߼
(int *) \fIarg2\fP ˳Ǽ롣
.TP
.B PR_SET_DUMPABLE
(Linux 2.3.20 ʹ)
ǥեȤο񤤤Ǥϥפ褦ʥʥȤˡ
פ뤫ɤꤹե饰ꤹ
(̾盧Υե饰ϡǥեȤǤϥåȤƤ뤬
set-user-ID 뤤 set-group-ID ץब¹Ԥ줿ꡢ
ޤޤʥƥॳˤäƥץ UID  GID 줿Ȥ
ꥢ)
2.6.12 ΥͥǤϡ
.I arg2
 0 (ץϥԲ) 뤤 1 (ץϥײǽ) 
ɤ餫ǤʤФʤʤ
2.6.13  2.6.17 ޤǤΥͥǤϡ 2 ǧƤ
ͤꤹȡ̾ϥפʤХʥ꤬ root 
ɤ߹߲ǽʷǥפ줿
ƥͳ顢εǽϺ줿
.\" See http://marc.theaimsgroup.com/?l=linux-kernel&m=115270289030630&w=2
.\" Subject:    Fix prctl privilege escalation (CVE-2006-2451)
.\" From:       Marcel Holtmann <marcel () holtmann ! org>
.\" Date:       2006-07-12 11:12:00
.RB ( proc (5)

.I /proc/sys/fs/suid_dumpable
⻲)
.TP
.B PR_GET_DUMPABLE
(Linux 2.3.20 ʹ)
ƤӽФץˤײǽե饰
ߤξ֤ (ؿ֤ͤȤ) ֤
.\" [׽] Linux 2.6.13 ʹߤǤϡײǽե饰 2 Ȥ뤳Ȥ
.\" Ǥ뤬2.6.13 Ǥ PR_GET_DUMPABLE ϥײǽե饰 0 ʳ
.\" ͤξ 1 ֤Ǥ롣 2.6.14 ǽ줿
.TP
.B PR_SET_KEEPCAPS
(Linux 2.2.18 ʹ)
ץΡֻݻץե饰ꤹ롣
Υե饰ϡץμ UID¸ UID¸ set-user-ID ΤʤȤ
Ĥ 0 Ǥä֤顢Ƥ 0 ʳѹ줿Ȥ
ץμ¸Ļʽ礬ꥢ뤫ɤꤹ롣
(ǥեȤǤϡλʽϥꥢ롣)
.I arg2
 0 (ʤ򥯥ꥢ) 뤤 1 (ʤݻ) 
ɤ餫ǤʤФʤʤ
.TP
.B PR_GET_KEEPCAPS
(Linux 2.2.18 ʹ)
ƤӽФץˤֻݻץե饰
ߤξ֤ (ؿ֤ͤȤ) ֤
.TP
.B PR_SET_TIMING
(Linux 2.6.0-test4 ʹ)
(̾ΡŪ˻ȤƤ) Ūʥץߥ󥰤Ѥ뤫
Τʥॹפ˴Ťץߥ󥰤Ѥ뤫ꤹ롣
\fIarg2\fP ˻Ǥͤ \fBPR_TIMING_STATISTICAL\fP 
\fBPR_TIMING_TIMESTAMP\fP Ǥ롣
.TP
.B PR_GET_TIMING
(Linux 2.6.0-test4 ʹ)
߻Υץߥ󥰤ˡ֤
.TP
.B PR_SET_NAME
(Linux 2.6.9 ʹ)
ƤӽФץΥץ̾ \fIarg2\fP ǻꤵ줿Τꤹ롣
.TP
.B PR_GET_NAME
(Linux 2.6.11 ʹ)
ƤӽФץΥץ̾ \fIarg2\fP ˳Ǽ롣
.TP
.B PR_GET_ENDIAN
(Linux 2.6.18 ʹߡPowerPC Τ)
ƤӽФץΥǥ (endian-ness) ֤
.TP
.B PR_SET_ENDIAN
(Linux 2.6.18 ʹߡPowerPC Τ)
ƤӽФץΥǥ (endian-ness) 
\fIarg2\fP ǻꤵ줿ͤꤹ롣
Ǥͤ
.BR PR_ENDIAN_BIG ,
.BR PR_ENDIAN_LITTLE ,
.B PR_ENDIAN_PPC_LITTLE
(PowerPC ȥ륨ǥ)
Τ줫ĤǤ롣
.TP
.B PR_SET_UNALIGN
(ia64 Ǥ Linux 2.3.48 ʹ;
parisc Ǥ Linux 2.6.15 ʹ;
PowerPC Ǥ Linux 2.6.18 ʹ;
Alpha ǤϡLinux 2.6.22 ʹ;
ΥƥΤ)
unaligned ӥåȤ \fIarg2\fP ǻꤵ줿ͤꤹ롣
Ǥͤ \fBPR_UNALIGN_NOPRINT\fP (unaligned ʥ桼ۤä
)  \fBPR_UNALIGN_SIGBUS\fP (unaligned ʥ桼ä
.B SIGBUS
) Ǥ롣
.TP
.B PR_GET_UNALIGN
(Сȥƥξ
.B PR_SET_UNALIGN
)
unaligned ӥåȤͤ \fIarg2\fP ֤
.TP
.B PR_SET_FPEMU
(Linux 2.4.18  2.5.9 ʹߡia64 Τ)
ưߥ졼 (floating-point emulation) ӥåȤ
\fIarg2\fP ǻꤵ줿ͤꤹ롣
Ǥͤ \fBPR_FPEMU_NOPRINT\fP (ư̿ᥢۤä
ߥ졼Ȥ)  \fBPR_FPEMU_SIGFPE\fP (ư̿򥨥ߥ졼Ȥ

.B SIGFPE
) Ǥ롣
.TP
.B PR_GET_FPEMU
(Linux 2.4.18  2.5.9 ʹߡia64 Τ)
ưߥ졼ӥåȤͤ \fIarg2\fP ֤
.TP
.B PR_SET_FPEXC
(Linux 2.4.21  2.5.32 ʹߡPowerPC Τ)
ư㳰⡼ (floating-point exception mode) 
\fIarg2\fP ǻꤵ줿ͤꤹ롣
ǤΤϰʲͤǤ:
\fBPR_FP_EXC_SW_ENABLE\fP (FPEXC ư㳰ͭˤ)
\fBPR_FP_EXC_DIV\fP (0 )
\fBPR_FP_EXC_OVF\fP (Сե)
\fBPR_FP_EXC_UND\fP (ե)
\fBPR_FP_EXC_RES\fP (Τʷ (inexact result))
\fBPR_FP_EXC_INV\fP (̿ (invalid operation))
\fBPR_FP_EXC_DISABLED\fP (ư㳰̵ˤ)
\fBPR_FP_EXC_NONRECOV\fP (async non-recoverable exception mode)
\fBPR_FP_EXC_ASYNC\fP (async recoverable exception mode)
\fBPR_FP_EXC_PRECISE\fP (precise exception mode)
.TP
.B PR_GET_FPEXC
(Linux 2.4.21  2.5.32 ʹߡPowerPC Τ)
ư㳰⡼ɤͤ \fIarg2\fP ֤
.SH ֤
.I option

.B PR_GET_DUMPABLE
ޤ
.B PR_GET_KEEPCAPS
ξ 0 ޤ 1 ֤
.I option
¾ξ 0 ֤
顼ξ \-1 ֤졢
.I errno
Ŭڤͤꤵ롣
.SH 顼
.TP
.B EINVAL
.I option
ͤǤʤޤ
.I option

.B PR_SET_PDEATHSIG

.I arg2
 0 Ǥ⥷ʥֹǤʤ
.SH С
.BR prctl ()
ƥॳ Linux 2.1.57 Ƴ줿
.\" 饤֥ꡦ󥿥ե glibc 2.0.6 ɲä줿
.SH 
Υ Linux ͭǤ롣
IRIX ˤ
.BR prctl ()
ƥࡦ뤬뤬 (MIPS ƥˤ
irix_prctl Ȥ Linux 2.1.44 ƱͤƳ줿)
Υץȥפ
.sp
.BI "ptrdiff_t prctl(int " option ", int " arg2 ", int " arg3 );
.sp
Ǥ롣桼Υץ륪ץ
ץλѤǤץå륪ץ
Υץ(block)Ƥ뤫ɤĴ٤륪ץ
åκͤμԤʤץʤɤ롣
.SH Ϣ
.BR signal (2),
.BR core (5)