• BlackBerry Dynamics
  • Runtime library for Android applications
  • 12.0.1.79
AbstractVerifier Class Referenceabstract

Abstract base class for all standard com.good.gd.apache.http.conn.ssl.X509HostnameVerifier implementations. More...

Inheritance diagram for AbstractVerifier:
X509HostnameVerifier AllowAllHostnameVerifier BrowserCompatHostnameVerifier StrictHostnameVerifier

Description

Author
Julius Davies

Notice

The following notice applies to the original API on which this API is based, and to its documentation. The documentation of this API has been revised from the original.

/*
 * Copyright (C) 2006 The Android Open Source Project
 *
 * Licensed 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.
 */

Static Public Member Functions

static String[] getDNSSubjectAlts (X509Certificate cert)
 Extracts the array of SubjectAlt DNS names from an X509Certificate. More...
 
static int countDots (final String s)
 Counts the number of dots "." in a string. More...
 

Additional Inherited Members

- Public Member Functions inherited from X509HostnameVerifier
void verify (String host, String[] cns, String[] subjectAlts) throws SSLException
 Checks to see if the supplied hostname matches any of the supplied CNs or "DNS" Subject-Alts. More...
 

Member Function Documentation

◆ getDNSSubjectAlts()

static String [] getDNSSubjectAlts ( X509Certificate  cert)
static

Returns null if there aren't any.

Note: Java doesn't appear able to extract international characters from the SubjectAlts. It can only extract international characters from the CN field.

(Or maybe the version of OpenSSL I'm using to test isn't storing the international characters correctly in the SubjectAlts?).

Parameters
certX509Certificate
Returns
Array of SubjectALT DNS names stored in the certificate.

◆ countDots()

static int countDots ( final String  s)
static
Parameters
sstring to count dots from
Returns
number of dots