Skip to content

Commit 0c18738

Browse files
Work on ssl (#953)
Co-authored-by: Wei-Hsiang (Matt) Wang <[email protected]>
1 parent 1c1c864 commit 0c18738

File tree

1 file changed

+31
-10
lines changed

1 file changed

+31
-10
lines changed

library/ssl.po

+31-10
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgstr ""
77
"Project-Id-Version: Python 3.12\n"
88
"Report-Msgid-Bugs-To: \n"
99
"POT-Creation-Date: 2024-08-04 00:03+0000\n"
10-
"PO-Revision-Date: 2024-08-27 01:29+0800\n"
10+
"PO-Revision-Date: 2024-08-28 00:43+0800\n"
1111
"Last-Translator: Adrian Liaw <[email protected]>\n"
1212
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
1313
"tw)\n"
@@ -1196,8 +1196,7 @@ msgid ""
11961196
"sockets)."
11971197
msgstr ""
11981198
":func:`create_default_context` 和 :meth:`SSLContext.load_default_certs` 的選"
1199-
"項。此值表示該語境可能會用於驗證網頁伺服器 (因此它將用於建立用戶端 "
1200-
"socket)。"
1199+
"項。此值表示該語境可能會用於驗證網頁伺服器 (因此它將用於建立用戶端 socket)。"
12011200

12021201
#: ../../library/ssl.rst:976
12031202
msgid ""
@@ -1219,8 +1218,8 @@ msgid ""
12191218
":class:`enum.IntEnum` collection of SSL and TLS versions for :attr:"
12201219
"`SSLContext.maximum_version` and :attr:`SSLContext.minimum_version`."
12211220
msgstr ""
1222-
"用於 :attr:`SSLContext.maximum_version` 和 :attr:"
1223-
"`SSLContext.minimum_version` 的 SSL 和 TLS 版本 :class:`enum.IntEnum` 集合。"
1221+
"用於 :attr:`SSLContext.maximum_version` 和 :attr:`SSLContext."
1222+
"minimum_version` 的 SSL 和 TLS 版本 :class:`enum.IntEnum` 集合。"
12241223

12251224
#: ../../library/ssl.rst:999
12261225
msgid ""
@@ -1308,8 +1307,8 @@ msgid ""
13081307
":meth:`~socket.socket.recv()`, :meth:`~socket.socket.recv_into()` (but "
13091308
"passing a non-zero ``flags`` argument is not allowed)"
13101309
msgstr ""
1311-
":meth:`~socket.socket.recv()`、:meth:`~socket.socket.recv_into()` (但不允許傳"
1312-
"遞非零的 ``flags`` 引數)"
1310+
":meth:`~socket.socket.recv()`、:meth:`~socket.socket.recv_into()` (但不允許"
1311+
"傳遞非零的 ``flags`` 引數)"
13131312

13141313
#: ../../library/ssl.rst:1038
13151314
msgid ""
@@ -1339,8 +1338,8 @@ msgid ""
13391338
"on non-blocking sockets <ssl-nonblocking>`."
13401339
msgstr ""
13411340
"然而,由於 SSL(和 TLS)協定在 TCP 之上有自己的框架,因此在某些方面,SSL "
1342-
"sockets 的抽象可能會與普通操作系統級別的 sockets 規範有所不同。特別是請參"
1343-
"\\ :ref:`關於 non-blocking sockets 的說明 <ssl-nonblocking>`。"
1341+
"sockets 的抽象可能會與普通操作系統級別的 sockets 規範有所不同。特別是請參閱"
1342+
"\\ :ref:`關於 non-blocking sockets 的說明 <ssl-nonblocking>`。"
13441343

13451344
#: ../../library/ssl.rst:1049
13461345
msgid ""
@@ -1359,56 +1358,71 @@ msgid ""
13591358
"received or sent. The socket timeout is now the maximum total duration of "
13601359
"the shutdown."
13611360
msgstr ""
1361+
":meth:`shutdown` 不會在每次接收或發送位元組時重置 socket 超時時間。現在,"
1362+
"socket 超時時間是關閉操作的最大總持續時間。"
13621363

13631364
#: ../../library/ssl.rst:1060
13641365
msgid ""
13651366
"It is deprecated to create a :class:`SSLSocket` instance directly, use :meth:"
13661367
"`SSLContext.wrap_socket` to wrap a socket."
13671368
msgstr ""
1369+
"直接建立 :class:`SSLSocket` 實例的方式已被棄用,請使用 :meth:`SSLContext."
1370+
"wrap_socket` 來包裝 socket。"
13681371

13691372
#: ../../library/ssl.rst:1064
13701373
msgid ""
13711374
":class:`SSLSocket` instances must to created with :meth:`~SSLContext."
13721375
"wrap_socket`. In earlier versions, it was possible to create instances "
13731376
"directly. This was never documented or officially supported."
13741377
msgstr ""
1378+
":class:`SSLSocket` 實例必須使用 :meth:`~SSLContext.wrap_socket` 建立。在較早"
1379+
"的版本中可以直接建立實例,但這從未被記錄或正式支援。"
13751380

13761381
#: ../../library/ssl.rst:1070
13771382
msgid ""
13781383
"Python now uses ``SSL_read_ex`` and ``SSL_write_ex`` internally. The "
13791384
"functions support reading and writing of data larger than 2 GB. Writing zero-"
13801385
"length data no longer fails with a protocol violation error."
13811386
msgstr ""
1387+
"Python 現在內部使用了 ``SSL_read_ex`` 和 ``SSL_write_ex`` 函式。這些函式支援"
1388+
"讀取和寫入大於 2 GB 的資料。寫入零長度的資料不再會導致協定違規錯誤。"
13821389

13831390
#: ../../library/ssl.rst:1075
13841391
msgid "SSL sockets also have the following additional methods and attributes:"
1385-
msgstr ""
1392+
msgstr "SSL sockets 還具有以下附加方法和屬性:"
13861393

13871394
#: ../../library/ssl.rst:1079
13881395
msgid ""
13891396
"Read up to *len* bytes of data from the SSL socket and return the result as "
13901397
"a ``bytes`` instance. If *buffer* is specified, then read into the buffer "
13911398
"instead, and return the number of bytes read."
13921399
msgstr ""
1400+
"從 SSL socket 讀取 *len* 位元組的資料,並將結果以 ``bytes`` 實例的形式回傳。"
1401+
"如果指定了 *buffer*,則將資料讀入緩衝區,並回傳讀取的位元組。"
13931402

13941403
#: ../../library/ssl.rst:1083
13951404
msgid ""
13961405
"Raise :exc:`SSLWantReadError` or :exc:`SSLWantWriteError` if the socket is :"
13971406
"ref:`non-blocking <ssl-nonblocking>` and the read would block."
13981407
msgstr ""
1408+
"如果 socket 是\\ :ref:`非阻塞的 <ssl-nonblocking>`\\ 則會引發 :exc:"
1409+
"`SSLWantReadError` 或 :exc:`SSLWantWriteError` 並且讀取操作將會被阻塞。"
13991410

14001411
#: ../../library/ssl.rst:1086
14011412
msgid ""
14021413
"As at any time a re-negotiation is possible, a call to :meth:`read` can also "
14031414
"cause write operations."
14041415
msgstr ""
1416+
"由於在任何時刻都可能發生重新協商,呼叫 :meth:`read` 也可能觸發寫入操作。"
14051417

14061418
#: ../../library/ssl.rst:1089
14071419
msgid ""
14081420
"The socket timeout is no longer reset each time bytes are received or sent. "
14091421
"The socket timeout is now the maximum total duration to read up to *len* "
14101422
"bytes."
14111423
msgstr ""
1424+
"當接收或發送位元組時,socket 的超時時間將不再重置。現在,socket 超時時間是讀"
1425+
"取最多 *len* 位元組的總最大持續時間。"
14121426

14131427
#: ../../library/ssl.rst:1094
14141428
msgid "Use :meth:`~SSLSocket.recv` instead of :meth:`~SSLSocket.read`."
@@ -1419,24 +1433,31 @@ msgid ""
14191433
"Write *buf* to the SSL socket and return the number of bytes written. The "
14201434
"*buf* argument must be an object supporting the buffer interface."
14211435
msgstr ""
1436+
"將 *buf* 寫入 SSL socket 並回傳寫入的位元組數量。*buf* 引數必須是支援緩衝區介"
1437+
"面的物件。"
14221438

14231439
#: ../../library/ssl.rst:1102
14241440
msgid ""
14251441
"Raise :exc:`SSLWantReadError` or :exc:`SSLWantWriteError` if the socket is :"
14261442
"ref:`non-blocking <ssl-nonblocking>` and the write would block."
14271443
msgstr ""
1444+
"如果 socket 是\\ :ref:`非阻塞的 <ssl-nonblocking>`\\ 則會引發 :exc:"
1445+
"`SSLWantReadError` 或 :exc:`SSLWantWriteError` 並且寫入操作將會被阻塞。"
14281446

14291447
#: ../../library/ssl.rst:1105
14301448
msgid ""
14311449
"As at any time a re-negotiation is possible, a call to :meth:`write` can "
14321450
"also cause read operations."
14331451
msgstr ""
1452+
"由於在任何時刻都可能發生重新協商,呼叫 :meth:`write` 也可能觸發讀取操作。"
14341453

14351454
#: ../../library/ssl.rst:1108
14361455
msgid ""
14371456
"The socket timeout is no longer reset each time bytes are received or sent. "
14381457
"The socket timeout is now the maximum total duration to write *buf*."
14391458
msgstr ""
1459+
"當接收或發送位元組時,socket 的超時時間將不再重置。現在,socket 超時時間是寫"
1460+
"入 *buf* 的總最大持續時間。"
14401461

14411462
#: ../../library/ssl.rst:1112
14421463
msgid "Use :meth:`~SSLSocket.send` instead of :meth:`~SSLSocket.write`."

0 commit comments

Comments
 (0)