Comparator for prioritizing certificates in path building.
The sort order is as follows:
| Modifier and Type | Field and Description |
|---|---|
| private static final Map | ALGORITHM_OID_PRIORITY_MAP
Map of signature algorithm OIDs to priorities. |
| private static final Integer | |
| private static final Integer | |
| private static final Integer | |
| private static final Integer | |
| private static final Integer | |
| private static final Integer | |
| private static final Integer |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public int | compare(X509Certificate
the first object to be compared. lhs, X509Certificate the second object to be compared. rhs)Implements java. |
| private int | |
| private int | |
| private int | |
| private int | |
| private int |
| ALGORITHM_OID_PRIORITY_MAP | back to summary |
|---|---|
| private static final Map<String, Integer> ALGORITHM_OID_PRIORITY_MAP Map of signature algorithm OIDs to priorities. OIDs with a lower priority will be sorted before those with higher. | |
| PRIORITY_MD5 | back to summary |
|---|---|
| private static final Integer PRIORITY_MD5 | |
| PRIORITY_SHA1 | back to summary |
|---|---|
| private static final Integer PRIORITY_SHA1 | |
| PRIORITY_SHA224 | back to summary |
|---|---|
| private static final Integer PRIORITY_SHA224 | |
| PRIORITY_SHA256 | back to summary |
|---|---|
| private static final Integer PRIORITY_SHA256 | |
| PRIORITY_SHA384 | back to summary |
|---|---|
| private static final Integer PRIORITY_SHA384 | |
| PRIORITY_SHA512 | back to summary |
|---|---|
| private static final Integer PRIORITY_SHA512 | |
| PRIORITY_UNKNOWN | back to summary |
|---|---|
| private static final Integer PRIORITY_UNKNOWN | |
| CertificatePriorityComparator | back to summary |
|---|---|
| public CertificatePriorityComparator() | |
| compare | back to summary |
|---|---|
| public int compare(X509Certificate lhs, X509Certificate rhs) Implements java. Doc from java. Compares its two arguments for order. Returns a negative integer, zero, or a positive integer as the first argument is less than, equal to, or greater than the second.
The implementor must ensure that
The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that
| |
| compareKeyAlgorithm | back to summary |
|---|---|
| private int compareKeyAlgorithm(PublicKey lhs, PublicKey rhs) | |
| compareKeySize | back to summary |
|---|---|
| private int compareKeySize(PublicKey lhs, PublicKey rhs) | |
| compareSignatureAlgorithm | back to summary |
|---|---|
| private int compareSignatureAlgorithm(X509Certificate lhs, X509Certificate rhs) | |
| compareStrength | back to summary |
|---|---|
| private int compareStrength(X509Certificate lhs, X509Certificate rhs) | |
| getKeySize | back to summary |
|---|---|
| private int getKeySize(PublicKey pkey) | |