maskit commented on a change in pull request #7598:
URL: https://github.com/apache/trafficserver/pull/7598#discussion_r593570744



##########
File path: plugins/experimental/client_allow_list/main.cc
##########
@@ -0,0 +1,180 @@
+/** @file
+
+  SSL client certificate verification plugin, main source file.
+
+  Checks for specificate names in the client provided certificate and
+  fails the handshake if none of the good names are present
+
+  @section license License
+
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+ */
+
+#include <openssl/ssl.h>
+#include <openssl/x509.h>
+#include <openssl/x509v3.h>
+#include <openssl/asn1.h>
+
+#include "client_allow_list.h"
+
+using namespace client_allow_list_plugin;
+
+#if TS_VERSION_MAJOR < 9
+#define TSVConnSslConnectionGet TSVConnSSLConnectionGet
+#endif
+
+namespace
+{
+inline const char *
+ASN1_get_data(ASN1_STRING *cn)
+{
+#if OPENSSL_VERSION_NUMBER < 0x10100000L

Review comment:
       I don't recommend to use `OPENSSL_VERSION_NUMBER` for new code because 
it's going to be deprecated.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to