public class X500Utils extends Object
Constructor and Description |
---|
X500Utils() |
Modifier and Type | Method and Description |
---|---|
String |
getName(X500Principal id,
String... fields)
Parse the DN from the Principal and extract the CN field.
|
String |
getSerial(X509Certificate cert)
Get the serial number from a certificate as a hex string.
|
public String getName(X500Principal id, String... fields)
id
- The identity to extract the distinguished name from.fields
- The names to look at when finding the field to return. Each
should be an upper-cased string.public String getSerial(X509Certificate cert)
cert
- The certificate to extract from.Copyright © 2015–2018 The Apache Software Foundation. All rights reserved.