[perldocjp-cvs 306] CVS update: docs/perl/5.10.0

Back to archive index

argra****@users***** argra****@users*****
2008年 10月 31日 (金) 17:02:59 JST


Index: docs/perl/5.10.0/perlsec.pod
diff -u docs/perl/5.10.0/perlsec.pod:1.3 docs/perl/5.10.0/perlsec.pod:1.4
--- docs/perl/5.10.0/perlsec.pod:1.3	Mon Jun 30 04:09:58 2008
+++ docs/perl/5.10.0/perlsec.pod	Fri Oct 31 17:02:59 2008
@@ -153,14 +153,11 @@
 =end original
 
 は汚染性がチェックされません。
-This requires extra carefulness
-unless you want external data to affect your control flow.
+これは、あなたの制御フローが外部データに影響されたいと思わないなら、
+さらなる慎重さを要求します。
 これらのシンボリックな値が何かを注意深く制限しないと、POSIX::system のような
-あなたの Perl コードの
-people are able
-to call functions B<outside> your Perl code, such as POSIX::system,
-in which case they are able to run arbitrary external code.
-(TBT)
+あなたの Perl コードの B<外側> の関数を呼び出すことを可能にし、この場合
+任意の外部コードを実行できるようになります。
 
 =item *
 
@@ -185,10 +182,9 @@
 
 効率上の理由から、Perl はデータが汚染されているかどうかについて保守的な
 見方をします。
-If an expression contains tainted data,
-any subexpression may be considered tainted, even if the value
-of the subexpression is not itself affected by the tainted data.
-(TBT)
+汚染されているデータが式に含まれている場合、たとえ副式の値自身は汚染された
+データに影響を受けない場合でも、全ての副式も汚染されたものとして
+扱います。
 
 =begin original
 
@@ -568,11 +564,9 @@
 取り除かれ、環境変数 C<PERL5LIB> と C<PERLLIB> は Perl から無視されます。
 それでも、L<perlrun> で説明されている C<-I> コマンドラインオプションを
 使うことで、プログラムの外部から C<@INC> を調整出来ます。
-The two environment variables are ignored because
-they are obscured, and a user running a program could be unaware that
-they are set, whereas the C<-I> option is clearly visible and
-therefore permitted.
-(TBT)
+二つの環境変数は不明確で、プログラムを実行している
+ユーザーはこの変数が設定されていることに気付かないかもしれないので
+無視されますが、一方 C<-I> オプションは明確に見えるので許可されます。
 
 =begin original
 
@@ -1072,6 +1066,8 @@
 
 =head2 Algorithmic Complexity Attacks
 
+(アルゴリズム的複雑性攻撃)
+
 =begin original
 
 Certain internal algorithms used in the implementation of Perl can
@@ -1099,11 +1095,9 @@
 
 =end original
 
-Hash Function - the algorithm used to "order" hash elements has been
-changed several times during the development of Perl, mainly to be
-reasonably fast.
+ハッシュ関数 - ハッシュ要素を「並べる」ために使われるアルゴリズムは
+Perl の開発中に(主として高速化のために)数回変更されています。
 Perl 5.8.1 ではセキュリティの側面も考慮されています。
-(TBT)
 
 =begin original
 
@@ -1116,13 +1110,12 @@
 
 =end original
 
-In Perls before 5.8.1 one could rather easily generate data that as
-hash keys would cause Perl to consume large amounts of time because
-internal structure of hashes would badly degenerate.  In Perl 5.8.1
-the hash function is randomly perturbed by a pseudorandom seed which
-makes generating such naughty hash keys harder.
-See L<perlrun/PERL_HASH_SEED> for more information.
-(TBT)
+5.8.1 以前の Perl では、ハッシュの内部構造が悪化するために Perl が
+大量の時間を消費することになるようなハッシュキーとなるデータを
+かなり簡単に生成できました。
+Perl 5.8.1 で、そのようなよくないハッシュキーを生成するのをより難しく
+するために、ハッシュ関数は擬似乱数の種によってランダムに攪拌されます。
+さらなる情報については L<perlrun/PERL_HASH_SEED> を参照してください。
 
 =begin original
 
@@ -1136,14 +1129,13 @@
 
 =end original
 
-The random perturbation is done by default but if one wants for some
-reason emulate the old behaviour one can set the environment variable
-PERL_HASH_SEED to zero (or any other integer).  One possible reason
-for wanting to emulate the old behaviour is that in the new behaviour
-consecutive runs of Perl will order hash keys differently, which may
-confuse some applications (like Data::Dumper: the outputs of two
-different runs are no more identical).
-(TBT)
+ランダムな攪拌はデフォルトで実行されますが、もし何らかの理由で古い振る舞いを
+エミュレートしたい場合は、PERL_HASH_SEED 環境変数に 0 (あるいはその他の
+任意の整数) を設定できます。
+古い振る舞いをエミュレートしたい理由の可能性の一つとしては、新しい
+振る舞いでは、Perl を何回も実行するとハッシュキーの順序が毎回異なるので、
+これによって混乱するアプリケーションがあるからです (例えば Data::Dumper:
+2 回実行した結果が同一になりません)。
 
 =begin original
 
@@ -1154,11 +1146,9 @@
 
 =end original
 
-B<Perl has never guaranteed any ordering of the hash keys>, and the
-ordering has already changed several times during the lifetime of
-Perl 5.  Also, the ordering of hash keys has always been, and
-continues to be, affected by the insertion order.
-(TBT)
+B<Perl はハッシュキーの順序について何の保障もありません> し、Perl 5 の
+間でも既に何度か変更されています。
+また、ハッシュキーの順序は、今までもこれからも、挿入順に影響を受けます。
 
 =begin original
 
@@ -1172,14 +1162,14 @@
 
 =end original
 
-Also note that while the order of the hash elements might be
-randomised, this "pseudoordering" should B<not> be used for
-applications like shuffling a list randomly (use List::Util::shuffle()
-for that, see L<List::Util>, a standard core module since Perl 5.8.0;
-or the CPAN module Algorithm::Numerical::Shuffle), or for generating
-permutations (use e.g. the CPAN modules Algorithm::Permute or
-Algorithm::FastPermute), or for any cryptographic applications.
-(TBT)
+また、ハッシュ要素の順序はランダム化されますが、この「擬似整列」は
+以下のことに B<使うべきではありません>: リストをランダムに
+シャッフルするようなアプリケーション
+(Perl 5.8.0 から標準モジュールとなっている L<List::Util> の
+List::Util::shuffle() や、CPAN モジュールである
+Algorithm::Numerical::Shuffle を使ってください)、 順列の生成 
+(CPAN モジュールである Algorithm::Permute や Algorithm::FastPermute を
+使ってください)、あらゆる暗号アプリケーション。
 
 =item *
 
@@ -1196,15 +1186,14 @@
 
 =end original
 
-Regular expressions - Perl's regular expression engine is so called NFA
-(Non-deterministic Finite Automaton), which among other things means that
-it can rather easily consume large amounts of both time and space if the
-regular expression may match in several ways.  Careful crafting of the
-regular expressions can help but quite often there really isn't much
-one can do (the book "Mastering Regular Expressions" is required
-reading, see L<perlfaq2>).  Running out of space manifests itself by
-Perl running out of memory.
-(TBT)
+正規表現 - Perl の正規表現エンジンは NFA (Non-deterministic Finite Automaton:
+非決定性有限オートマトン)と呼ばれ、これは他のものに比べて、もし正規表現が
+複数の方法でマッチングする場合、かなり簡単に大量の時間と空間を
+消費することを意味します。
+正規表現を注意深く構築することは助けになりますが、かなりの場合これは
+不十分です ("Mastering Regular Expressions" という本を読む必要があります;
+L<perlfaq2> を参照してください)。
+空間の不足は Perl がメモリ不足になることで明らかになります。
 
 =item *
 
@@ -1219,13 +1208,14 @@
 
 =end original
 
-Sorting - the quicksort algorithm used in Perls before 5.8.0 to
-implement the sort() function is very easy to trick into misbehaving
-so that it consumes a lot of time.  Nothing more is required than
-resorting a list already sorted.  Starting from Perl 5.8.0 a different
-sorting algorithm, mergesort, is used.  Mergesort is insensitive to
-its input data, so it cannot be similarly fooled.
-(TBT)
+ソート - 5.8.0 以前の Perl で sort() 関数を実装するために使われていた
+クイックソートアルゴリズムは、大量の時間を消費するような策略がとても
+簡単です。
+既にソートされているリストを再ソートさせる以上のことは不要です。
+Perl 5.8.0 から、異なったソートアルゴリズムであるマージソートが
+使われています。
+マージソートは入力データによって影響を受けないので、同じような策略は
+不可能です。
 
 =back
 
@@ -1236,9 +1226,8 @@
 
 =end original
 
-See L<http://www.cs.rice.edu/~scrosby/hash/> for more information,
-and any computer science textbook on the algorithmic complexity.
-(TBT)
+さらなる情報については L<http://www.cs.rice.edu/~scrosby/hash/> および、
+アルゴリズム的複雑性に関する情報工学の教科書を参照してください。
 
 =head1 SEE ALSO
 


perldocjp-cvs メーリングリストの案内
Back to archive index