CRL TBSCertList lacks generics type parameter

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

CRL TBSCertList lacks generics type parameter

cryptearth
Hey there, Matt here.

org.bouncycastle.asn1.x509.TBSCertList.getRevokedCertificateEnumeration()
only returns raw-type Enumeration. To comply common practice and to
match return type of getRevokedCertificates() enum should have generic
type TBSCertList.CRLEntry. Using Enumeration<TBSCertList.CRLEntry>
entryList=tbsCertList.getRevokedCertificateEnumeration(); causes
compiler warning:

D:\data\java>javac -Xlint:unchecked de\cryptearth\crypto\pki\Helper.java
de\cryptearth\crypto\pki\Helper.java:173: warning: [unchecked] unchecked
conversion
                 Enumeration<TBSCertList.CRLEntry>
entryList=tbsCertList.getRevokedCertificateEnumeration();
^
   required: Enumeration<CRLEntry>
   found:    Enumeration
1 warning

TBSCertList.java lines 106 and 127 should corrected to "implements
Enumeration<TBSCertList.CRLEntry>".

Matt