Changeset 7bb76776 for core/java


Ignore:
Timestamp:
Mar 27, 2019 12:26:05 PM (16 months ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
de9d968
Parents:
64039ee
Message:

SelfSignedGenerator?: improve previous fix

File:
1 edited

Legend:

Unmodified
Added
Removed
  • core/java/src/net/i2p/crypto/SelfSignedGenerator.java

    r64039ee r7bb76776  
    250250        if (!cpub.equals(jpub)) {
    251251            boolean ok = false;
    252             if (cpub.getClass().getName().equals("sun.security.x509.X509Key")) {
     252            if ((jpub instanceof EdDSAPublicKey) &&
     253                cpub.getClass().getName().equals("sun.security.x509.X509Key")) {
    253254                // X509Certificate will sometimes contain an X509Key rather than the EdDSAPublicKey itself; the contained
    254255                // key is valid but needs to be instanced as an EdDSAPublicKey before it can be used.
Note: See TracChangeset for help on using the changeset viewer.