@@ -1023,9 +1023,14 @@ build_cipher_string(VALUE v)
10231023 * ctx.ciphers = [name, ...]
10241024 * ctx.ciphers = [[name, version, bits, alg_bits], ...]
10251025 *
1026- * Sets the list of available cipher suites for this context. Note in a server
1027- * context some ciphers require the appropriate certificates. For example, an
1028- * RSA cipher suite can only be chosen when an RSA certificate is available.
1026+ * Sets the list of available cipher suites for TLS 1.2 and below for this
1027+ * context.
1028+ *
1029+ * Note in a server context some ciphers require the appropriate certificates.
1030+ * For example, an RSA cipher suite can only be chosen when an RSA certificate
1031+ * is available.
1032+ *
1033+ * This method does not affect TLS 1.3 connections. See also #ciphersuites=.
10291034 */
10301035static VALUE
10311036ossl_sslctx_set_ciphers (VALUE self , VALUE v )
@@ -1034,6 +1039,7 @@ ossl_sslctx_set_ciphers(VALUE self, VALUE v)
10341039 VALUE str ;
10351040
10361041 rb_check_frozen (self );
1042+ // Assigning nil is a no-op for compatibility
10371043 if (NIL_P (v ))
10381044 return v ;
10391045
@@ -1050,9 +1056,8 @@ ossl_sslctx_set_ciphers(VALUE self, VALUE v)
10501056 * call-seq:
10511057 * ctx.ciphersuites = "cipher1:cipher2:..."
10521058 * ctx.ciphersuites = [name, ...]
1053- * ctx.ciphersuites = [[name, version, bits, alg_bits], ...]
10541059 *
1055- * Sets the list of available TLSv1 .3 cipher suites for this context.
1060+ * Sets the list of available TLS 1 .3 cipher suites for this context.
10561061 */
10571062static VALUE
10581063ossl_sslctx_set_ciphersuites (VALUE self , VALUE v )
@@ -1061,6 +1066,7 @@ ossl_sslctx_set_ciphersuites(VALUE self, VALUE v)
10611066 VALUE str ;
10621067
10631068 rb_check_frozen (self );
1069+ // Assigning nil is a no-op for compatibility
10641070 if (NIL_P (v ))
10651071 return v ;
10661072
0 commit comments