You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by GitBox <gi...@apache.org> on 2021/12/09 09:33:39 UTC

[GitHub] [httpcomponents-core] ok2c commented on a change in pull request #337: Check if a given protocol is secure and enabled.

ok2c commented on a change in pull request #337:
URL: https://github.com/apache/httpcomponents-core/pull/337#discussion_r765593321



##########
File path: httpcore5/src/main/java/org/apache/hc/core5/http/ssl/TLS.java
##########
@@ -94,4 +94,15 @@ public static ProtocolVersion parse(final String s) throws ParseException {
         return enabledProtocols.toArray(new String[0]);
     }
 
+    /**
+     * Check if a given protocol is considered secure and is enabled by default.
+     *
+     * @return {@code true} if the given protocol is secure and enabled, otherwise return {@code
+     * false}.
+     * @since 5.2
+     */
+    public static boolean isSecureAndEnabled(final String protocol) {

Review comment:
       @arturobernalg I think the name is still bad and misleading. Protocols are enabled by default because they are consdiered secure. You should change the name to `isSecureAndEnabledByDefault` or to `isSecure`.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org