From 8ab141e5e3b2be6735f742e49f9f5790d8040958 Mon Sep 17 00:00:00 2001 From: timmy Date: Wed, 3 Jan 2024 12:11:19 +0800 Subject: [PATCH 1/7] work on ssl --- library/ssl.po | 42 +++++++++++++++++++++++++++++------------- 1 file changed, 29 insertions(+), 13 deletions(-) diff --git a/library/ssl.po b/library/ssl.po index f04e8d87a8..1deb106613 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: Python 3.12\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2023-12-21 18:18+0000\n" -"PO-Revision-Date: 2024-01-02 10:14+0800\n" +"PO-Revision-Date: 2024-01-03 12:10+0800\n" "Last-Translator: Adrian Liaw \n" "Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-" "tw)\n" @@ -420,9 +420,9 @@ msgid "" "Cryptographically_secure_pseudorandom_number_generator>`_, to get the " "requirements of a cryptographically strong generator." msgstr "" -"請閱讀維基百科的\\ `密碼學安全偽隨機數產生器 (CSPRNG) `_\\ 文章來了解" -"密碼學安全偽隨機數產生器的需求。" +"請閱讀維基百科的\\ `密碼學安全偽隨機數產生器 (CSPRNG) `_\\ 文章來了" +"解密碼學安全偽隨機數產生器的需求。" #: ../../library/ssl.rst:314 msgid "" @@ -442,9 +442,9 @@ msgid "" "string (so you can always use ``0.0``). See :rfc:`1750` for more " "information on sources of entropy." msgstr "" -"將給定的 *bytes* 混進 SSL 隨機偽隨機數產生器中。 *entropy* 參數(float 值)是指" -"字符串中包含熵值的下限(因此你可以將其設為 ``0.0``\\ )。請參閱 :rfc:`1750` 了解" -"有關熵源的更多資訊。" +"將給定的 *bytes* 混進 SSL 隨機偽隨機數產生器中。 *entropy* 參數(float 值)是" +"指字符串中包含熵值的下限(因此你可以將其設為 ``0.0``\\ )。請參閱 :rfc:" +"`1750` 了解有關熵源的更多資訊。" #: ../../library/ssl.rst:326 msgid "Writable :term:`bytes-like object` is now accepted." @@ -461,8 +461,8 @@ msgid "" "``\"%b %d %H:%M:%S %Y %Z\"`` strptime format (C locale)." msgstr "" "回傳自紀元以來的秒數,給定的 ``cert_time`` 字串表示證書的 \"notBefore\" 或 " -"\"notAfter\" 日期,字串採用 ``\"%b %d %H:%M:%S %Y %Z\"`` 格式(C 語言區" -"域設定)。" +"\"notAfter\" 日期,字串採用 ``\"%b %d %H:%M:%S %Y %Z\"`` 格式(C 語言區域設" +"定)。" #: ../../library/ssl.rst:343 msgid "Here's an example:" @@ -478,6 +478,8 @@ msgid "" "the input string. Local timezone was used previously. Return an integer (no " "fractions of a second in the input format)" msgstr "" +"將輸入的時間解讀為 UTC 時間,基於輸入字符串中指定的 'GMT' 時區。在之前是使用" +"本地的時區。回傳一個整數 (Integer) (在輸入格式中不包括秒的小數部分)。" #: ../../library/ssl.rst:366 msgid "" @@ -492,6 +494,13 @@ msgid "" "validation attempt fails. A timeout can be specified with the ``timeout`` " "parameter." msgstr "" +"輸入使用 SSL 保護的伺服器的地址 ``addr``,輸入形式為一個 pair (*hostname*, " +"*port-number*),獲取該伺服器的認證,並以 PEM 編碼字串的形式回傳。如果指定了" +"``ssl_version``,則使用指定的 SSL 協議來嘗試與伺服器連線。如果指定 " +"*ca_certs*,則它應該是一個包含根憑證列表的文件,並與 :meth:`SSLContext." +"load_verify_locations` 中的參數 *cafile* 所使用的格式相同。指定此參數將使函式" +"嘗試使用該組根憑證對服務器證書進行驗證,如果驗證失敗,調用將失敗。可以使用 " +"``timeout`` 參數指定超時。" #: ../../library/ssl.rst:377 msgid "This function is now IPv6-compatible." @@ -502,6 +511,8 @@ msgid "" "The default *ssl_version* is changed from :data:`PROTOCOL_SSLv3` to :data:" "`PROTOCOL_TLS` for maximum compatibility with modern servers." msgstr "" +"預設的 *ssl_version* 已經從 :data:`PROTOCOL_SSLv3` 改為 :data:" +"`PROTOCOL_TLS`,已確保與現今的伺服器有最大的相容性。" #: ../../library/ssl.rst:384 msgid "The *timeout* parameter was added." @@ -512,12 +523,14 @@ msgid "" "Given a certificate as a DER-encoded blob of bytes, returns a PEM-encoded " "string version of the same certificate." msgstr "" +"給定一個以 DER 編碼的 blob 作為認證,回傳以 PEM 編碼字符串版本的相同認證。" #: ../../library/ssl.rst:394 msgid "" "Given a certificate as an ASCII PEM string, returns a DER-encoded sequence " "of bytes for that same certificate." msgstr "" +"給定一個以 ASCII PEM 的字串作為認證,回傳以 DER 編碼的 bytes 序列的相同認證。" #: ../../library/ssl.rst:399 msgid "" @@ -525,24 +538,27 @@ msgid "" "paths are the same as used by :meth:`SSLContext.set_default_verify_paths`. " "The return value is a :term:`named tuple` ``DefaultVerifyPaths``:" msgstr "" +"回傳一個具有 OpenSSL 的預設 cafile 和 capath 路徑的命名 tuple。這些路徑與 :" +"meth:`SSLContext.set_default_verify_paths` 使用的相同。回傳值是一個 :term:" +"`named tuple` ,即 ``DefaultVerifyPaths``:" #: ../../library/ssl.rst:404 msgid "" ":attr:`cafile` - resolved path to cafile or ``None`` if the file doesn't " "exist," -msgstr "" +msgstr ":attr:`cafile` - 分析後的 cafile 路徑,如果文件不存在則為 ``None``。" #: ../../library/ssl.rst:405 msgid "" ":attr:`capath` - resolved path to capath or ``None`` if the directory " "doesn't exist," -msgstr "" +msgstr ":attr:`capath` - 分析後的 cafile 路徑,如果目錄不存在則為 ``None``。" #: ../../library/ssl.rst:406 msgid "" ":attr:`openssl_cafile_env` - OpenSSL's environment key that points to a " "cafile," -msgstr "" +msgstr ":attr:`openssl_cafile_env` - 指向 cafile 的 OpenSSL 環境密鑰," #: ../../library/ssl.rst:407 msgid ":attr:`openssl_cafile` - hard coded path to a cafile," @@ -552,7 +568,7 @@ msgstr ":attr:`openssl_cafile` - hard coded 的 cafile 路徑," msgid "" ":attr:`openssl_capath_env` - OpenSSL's environment key that points to a " "capath," -msgstr "" +msgstr ":attr:`openssl_capath_env` - 指向 capath 的 OpenSSL 環境密鑰," #: ../../library/ssl.rst:409 msgid ":attr:`openssl_capath` - hard coded path to a capath directory" From a8425d220a72673687d864ded326695d37ca5271 Mon Sep 17 00:00:00 2001 From: timmy Date: Thu, 4 Jan 2024 09:06:43 +0800 Subject: [PATCH 2/7] update commit --- library/ssl.po | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/library/ssl.po b/library/ssl.po index 1deb106613..79d9b09cf1 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: Python 3.12\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2023-12-21 18:18+0000\n" -"PO-Revision-Date: 2024-01-03 12:10+0800\n" +"PO-Revision-Date: 2024-01-04 09:05+0800\n" "Last-Translator: Adrian Liaw \n" "Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-" "tw)\n" @@ -460,7 +460,7 @@ msgid "" "representing the \"notBefore\" or \"notAfter\" date from a certificate in " "``\"%b %d %H:%M:%S %Y %Z\"`` strptime format (C locale)." msgstr "" -"回傳自紀元以來的秒數,給定的 ``cert_time`` 字串表示證書的 \"notBefore\" 或 " +"回傳自紀元以來的秒數,給定的 ``cert_time`` 字串表示憑證的 \"notBefore\" 或 " "\"notAfter\" 日期,字串採用 ``\"%b %d %H:%M:%S %Y %Z\"`` 格式(C 語言區域設" "定)。" @@ -478,8 +478,8 @@ msgid "" "the input string. Local timezone was used previously. Return an integer (no " "fractions of a second in the input format)" msgstr "" -"將輸入的時間解讀為 UTC 時間,基於輸入字符串中指定的 'GMT' 時區。在之前是使用" -"本地的時區。回傳一個整數 (Integer) (在輸入格式中不包括秒的小數部分)。" +"將輸入的時間直譯為 UTC 時間,基於輸入字符串中指定的 'GMT' 時區。在之前是使用" +"本地的時區。回傳一個整數(在輸入格式中不包括秒的小數部分)。" #: ../../library/ssl.rst:366 msgid "" @@ -495,12 +495,12 @@ msgid "" "parameter." msgstr "" "輸入使用 SSL 保護的伺服器的地址 ``addr``,輸入形式為一個 pair (*hostname*, " -"*port-number*),獲取該伺服器的認證,並以 PEM 編碼字串的形式回傳。如果指定了" +"*port-number*),獲取該伺服器的憑證,並以 PEM 編碼字串的形式回傳。如果指定了" "``ssl_version``,則使用指定的 SSL 協議來嘗試與伺服器連線。如果指定 " -"*ca_certs*,則它應該是一個包含根憑證列表的文件,並與 :meth:`SSLContext." -"load_verify_locations` 中的參數 *cafile* 所使用的格式相同。指定此參數將使函式" -"嘗試使用該組根憑證對服務器證書進行驗證,如果驗證失敗,調用將失敗。可以使用 " -"``timeout`` 參數指定超時。" +"*ca_certs*,則它應該是一個包含根憑證列表的檔案,並與 :meth:`SSLContext." +"load_verify_locations` 中的參數 *cafile* 所使用的格式相同。此呼叫將嘗試使用該" +"組根憑證對服務器證書進行驗證,如果驗證失敗,調用將失敗。可以使用 ``timeout`` " +"參數指定超時。" #: ../../library/ssl.rst:377 msgid "This function is now IPv6-compatible." @@ -523,14 +523,14 @@ msgid "" "Given a certificate as a DER-encoded blob of bytes, returns a PEM-encoded " "string version of the same certificate." msgstr "" -"給定一個以 DER 編碼的 blob 作為認證,回傳以 PEM 編碼字符串版本的相同認證。" +"給定一個以 DER 編碼的 blob 作為憑證,回傳以 PEM 編碼字串版本的相同憑證。" #: ../../library/ssl.rst:394 msgid "" "Given a certificate as an ASCII PEM string, returns a DER-encoded sequence " "of bytes for that same certificate." msgstr "" -"給定一個以 ASCII PEM 的字串作為認證,回傳以 DER 編碼的 bytes 序列的相同認證。" +"給定一個以 ASCII PEM 的字串作為憑證,回傳以 DER 編碼的 bytes 序列的相同憑證。" #: ../../library/ssl.rst:399 msgid "" @@ -538,7 +538,7 @@ msgid "" "paths are the same as used by :meth:`SSLContext.set_default_verify_paths`. " "The return value is a :term:`named tuple` ``DefaultVerifyPaths``:" msgstr "" -"回傳一個具有 OpenSSL 的預設 cafile 和 capath 路徑的命名 tuple。這些路徑與 :" +"回傳一個具有 OpenSSL 的預設 cafile 和 capath 路徑的附名元組。這些路徑與 :" "meth:`SSLContext.set_default_verify_paths` 使用的相同。回傳值是一個 :term:" "`named tuple` ,即 ``DefaultVerifyPaths``:" @@ -546,13 +546,13 @@ msgstr "" msgid "" ":attr:`cafile` - resolved path to cafile or ``None`` if the file doesn't " "exist," -msgstr ":attr:`cafile` - 分析後的 cafile 路徑,如果文件不存在則為 ``None``。" +msgstr ":attr:`cafile` - 解析後的 cafile 路徑,如果文件不存在則為 ``None``," #: ../../library/ssl.rst:405 msgid "" ":attr:`capath` - resolved path to capath or ``None`` if the directory " "doesn't exist," -msgstr ":attr:`capath` - 分析後的 cafile 路徑,如果目錄不存在則為 ``None``。" +msgstr ":attr:`capath` - 分析後的 cafile 路徑,如果目錄不存在則為 ``None``," #: ../../library/ssl.rst:406 msgid "" From bfe17c38a200e8c75ced9bac0c0900324cacfdd5 Mon Sep 17 00:00:00 2001 From: timmy Date: Thu, 4 Jan 2024 14:10:25 +0800 Subject: [PATCH 3/7] update commit --- library/ssl.po | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/library/ssl.po b/library/ssl.po index 79d9b09cf1..8f31afb2d9 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: Python 3.12\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2023-12-21 18:18+0000\n" -"PO-Revision-Date: 2024-01-04 09:05+0800\n" +"PO-Revision-Date: 2024-01-04 14:10+0800\n" "Last-Translator: Adrian Liaw \n" "Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-" "tw)\n" @@ -185,7 +185,7 @@ msgid "" "constructor directly." msgstr "" "回傳一個新的 :class:`SSLContext` 物件,使用給定 *purpose* 的預設值。這些設定" -"是由 :mod:`ssl` 選擇,通常比直接使用 :class:`SSLContext` 有更高的安全性。" +"是由 :mod:`ssl` 選擇,通常比直接呼叫 :class:`SSLContext` 有更高的安全性。" #: ../../library/ssl.rst:133 msgid "" @@ -264,15 +264,15 @@ msgstr "" #: ../../library/ssl.rst:177 msgid "RC4 was dropped from the default cipher string." -msgstr "把 RC4 從預設密碼中捨棄。" +msgstr "把 RC4 從預設密碼字串中捨棄。" #: ../../library/ssl.rst:181 msgid "ChaCha20/Poly1305 was added to the default cipher string." -msgstr "把 ChaCha20/Poly1305 加入預設密碼。" +msgstr "把 ChaCha20/Poly1305 加入預設密碼字串。" #: ../../library/ssl.rst:183 msgid "3DES was dropped from the default cipher string." -msgstr "把 3DES 從預設密碼中捨棄。" +msgstr "把 3DES 從預設密碼字串中捨棄。" #: ../../library/ssl.rst:187 msgid "Support for key logging to :envvar:`SSLKEYLOGFILE` was added." @@ -443,8 +443,8 @@ msgid "" "information on sources of entropy." msgstr "" "將給定的 *bytes* 混進 SSL 隨機偽隨機數產生器中。 *entropy* 參數(float 值)是" -"指字符串中包含熵值的下限(因此你可以將其設為 ``0.0``\\ )。請參閱 :rfc:" -"`1750` 了解有關熵源的更多資訊。" +"指字串中包含熵值的下限(因此你可以將其設為 ``0.0``\\ )。請參閱 :rfc:`1750` " +"了解有關熵源的更多資訊。" #: ../../library/ssl.rst:326 msgid "Writable :term:`bytes-like object` is now accepted." @@ -478,8 +478,8 @@ msgid "" "the input string. Local timezone was used previously. Return an integer (no " "fractions of a second in the input format)" msgstr "" -"將輸入的時間直譯為 UTC 時間,基於輸入字符串中指定的 'GMT' 時區。在之前是使用" -"本地的時區。回傳一個整數(在輸入格式中不包括秒的小數部分)。" +"將輸入的時間直譯為 UTC 時間,基於輸入字串中指定的 'GMT' 時區。在之前是使用本" +"地的時區。回傳一個整數(在輸入格式中不包括秒的小數部分)。" #: ../../library/ssl.rst:366 msgid "" @@ -530,7 +530,7 @@ msgid "" "Given a certificate as an ASCII PEM string, returns a DER-encoded sequence " "of bytes for that same certificate." msgstr "" -"給定一個以 ASCII PEM 的字串作為憑證,回傳以 DER 編碼的 bytes 序列的相同憑證。" +"給定一個以 ASCII PEM 的字串作為憑證,回傳以 DER 編碼的位元序組列的相同憑證。" #: ../../library/ssl.rst:399 msgid "" @@ -546,13 +546,13 @@ msgstr "" msgid "" ":attr:`cafile` - resolved path to cafile or ``None`` if the file doesn't " "exist," -msgstr ":attr:`cafile` - 解析後的 cafile 路徑,如果文件不存在則為 ``None``," +msgstr ":attr:`cafile` - 解析後的 cafile 路徑,如果檔案不存在則為 ``None``," #: ../../library/ssl.rst:405 msgid "" ":attr:`capath` - resolved path to capath or ``None`` if the directory " "doesn't exist," -msgstr ":attr:`capath` - 分析後的 cafile 路徑,如果目錄不存在則為 ``None``," +msgstr ":attr:`capath` - 解析後的 capath 路徑,如果目錄不存在則為 ``None``," #: ../../library/ssl.rst:406 msgid "" From a67c0599b270d8af5ab8b68413a7e72ce961fa28 Mon Sep 17 00:00:00 2001 From: timmy0123 <48618505+timmy0123@users.noreply.github.com> Date: Thu, 4 Jan 2024 14:12:19 +0800 Subject: [PATCH 4/7] Apply suggestions from code review Co-authored-by: Wei-Hsiang (Matt) Wang --- library/ssl.po | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/library/ssl.po b/library/ssl.po index 8f31afb2d9..995372e3ea 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -499,8 +499,8 @@ msgstr "" "``ssl_version``,則使用指定的 SSL 協議來嘗試與伺服器連線。如果指定 " "*ca_certs*,則它應該是一個包含根憑證列表的檔案,並與 :meth:`SSLContext." "load_verify_locations` 中的參數 *cafile* 所使用的格式相同。此呼叫將嘗試使用該" -"組根憑證對服務器證書進行驗證,如果驗證失敗,調用將失敗。可以使用 ``timeout`` " -"參數指定超時。" +"組根憑證對伺服器憑證進行驗證,如果驗證失敗,呼叫將失敗。可以使用 ``timeout`` " +"參數指定超時時間。" #: ../../library/ssl.rst:377 msgid "This function is now IPv6-compatible." @@ -538,9 +538,9 @@ msgid "" "paths are the same as used by :meth:`SSLContext.set_default_verify_paths`. " "The return value is a :term:`named tuple` ``DefaultVerifyPaths``:" msgstr "" -"回傳一個具有 OpenSSL 的預設 cafile 和 capath 路徑的附名元組。這些路徑與 :" +"回傳一個具有 OpenSSL 的預設 cafile 和 capath 路徑的附名元組。這些路徑與 :" "meth:`SSLContext.set_default_verify_paths` 使用的相同。回傳值是一個 :term:" -"`named tuple` ,即 ``DefaultVerifyPaths``:" +"`named tuple` ``DefaultVerifyPaths``:" #: ../../library/ssl.rst:404 msgid "" From cbec0008f78d03909c0ea94f11e8dbe1e571c4ce Mon Sep 17 00:00:00 2001 From: timmy Date: Thu, 4 Jan 2024 14:16:21 +0800 Subject: [PATCH 5/7] update commit --- library/ssl.po | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/library/ssl.po b/library/ssl.po index 995372e3ea..ab28840ffb 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: Python 3.12\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2023-12-21 18:18+0000\n" -"PO-Revision-Date: 2024-01-04 14:10+0800\n" +"PO-Revision-Date: 2024-01-04 14:16+0800\n" "Last-Translator: Adrian Liaw \n" "Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-" "tw)\n" @@ -523,7 +523,8 @@ msgid "" "Given a certificate as a DER-encoded blob of bytes, returns a PEM-encoded " "string version of the same certificate." msgstr "" -"給定一個以 DER 編碼的 blob 作為憑證,回傳以 PEM 編碼字串版本的相同憑證。" +"給定一個以 DER 編碼的位元組 blob 作為憑證,回傳以 PEM 編碼字串版本的相同憑" +"證。" #: ../../library/ssl.rst:394 msgid "" From 74a229b65942efca61909f75832444c05130a762 Mon Sep 17 00:00:00 2001 From: timmy Date: Thu, 4 Jan 2024 14:20:06 +0800 Subject: [PATCH 6/7] update commit --- library/ssl.po | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/library/ssl.po b/library/ssl.po index ab28840ffb..a4871ca449 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: Python 3.12\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2023-12-21 18:18+0000\n" -"PO-Revision-Date: 2024-01-04 14:16+0800\n" +"PO-Revision-Date: 2024-01-04 14:19+0800\n" "Last-Translator: Adrian Liaw \n" "Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-" "tw)\n" @@ -478,8 +478,8 @@ msgid "" "the input string. Local timezone was used previously. Return an integer (no " "fractions of a second in the input format)" msgstr "" -"將輸入的時間直譯為 UTC 時間,基於輸入字串中指定的 'GMT' 時區。在之前是使用本" -"地的時區。回傳一個整數(在輸入格式中不包括秒的小數部分)。" +"將輸入的時間直譯為 UTC 時間,如輸入字串中指定的 'GMT' 時區。在之前是使用本地" +"的時區。回傳一個整數(在輸入格式中不包括秒的小數部分)。" #: ../../library/ssl.rst:366 msgid "" From e0632be118aba3ecc5a57fa6c5f0cf84b21a257a Mon Sep 17 00:00:00 2001 From: timmy0123 <48618505+timmy0123@users.noreply.github.com> Date: Thu, 4 Jan 2024 15:03:39 +0800 Subject: [PATCH 7/7] Update library/ssl.po Co-authored-by: Wei-Hsiang (Matt) Wang --- library/ssl.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/ssl.po b/library/ssl.po index a4871ca449..5f5d13a377 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -531,7 +531,7 @@ msgid "" "Given a certificate as an ASCII PEM string, returns a DER-encoded sequence " "of bytes for that same certificate." msgstr "" -"給定一個以 ASCII PEM 的字串作為憑證,回傳以 DER 編碼的位元序組列的相同憑證。" +"給定一個以 ASCII PEM 的字串作為憑證,回傳以 DER 編碼的位元組序列的相同憑證。" #: ../../library/ssl.rst:399 msgid ""