Buggy code:
private final SignerInformation signerInformation ; private CAdESCertificateSource certSource ; private CertificateValidity signingCertificateValidity ; private Set < DigestAlgorithm > usedCertificatesDigestAlgorithms = new HashSet < DigestAlgorithm > ( ) ; private String signatureId ; private Date padesSigningTime = null ; private List < TimestampReference > signingCertificateTimestampReferences ; public CAdESSignature ( final byte [ ] data ) throws CMSException { } public CAdESSignature ( final byte [ ] data , final CertificatePool certPool ) throws CMSException { } public CAdESSignature ( final CMSSignedData cms , final CertificatePool certPool ) { } public CAdESSignature ( final CMSSignedData cmsSignedData , final SignerInformation signerInformation ) { } public CAdESSignature ( final CMSSignedData cmsSignedData , final SignerInformation signerInformation , final CertificatePool certPool ) { } public void setPadesSigningTime ( final Date padesSigningTime ) { } private static SignerInformation getFirstSignerInformation ( final CMSSignedData cms ) { } public CertificatePool getCertPool ( ) { } @ Override public SignatureForm getSignatureForm ( ) { } @ Override public CAdESCertificateSource getCertificateSource ( ) { } @ Override public OfflineCRLSource getCRLSource ( ) { } @ Override public OfflineOCSPSource getOCSPSource ( ) { } @ Override public CandidatesForSigningCertificate getCandidatesForSigningCertificate ( ) { } private boolean verifySignedReferencesToSigningCertificate ( ) { } private void verifySigningCertificateV1 ( final BigInteger signingTokenSerialNumber , final GeneralNames signingTokenIssuerName , final Attribute signingCertificateAttributeV1 ) { } private void verifySigningCertificateV2 ( final BigInteger signingTokenSerialNumber , final GeneralNames signingTokenIssuerName , final Attribute signingCertificateAttributeV2 ) { } private boolean verifySigningCertificateReferences ( final BigInteger signingTokenSerialNumber , final GeneralNames signingTokenIssuerName , final byte [ ] signingTokenCertHash , final byte [ ] certHash , final IssuerSerial issuerSerial ) { } static String getCanonicalizedName ( final GeneralNames generalNames ) { } @ Override public List < CertificateToken > getCertificates ( ) { } @ Override public SignaturePolicy getPolicyId ( ) { } @ Override public Date getSigningTime ( ) { } public CMSSignedData getCmsSignedData ( ) { } @ Override public SignatureProductionPlace getSignatureProductionPlace ( ) { } @ Override public CommitmentType getCommitmentTypeIndication ( ) { } @ Override public String [ ] getClaimedSignerRoles ( ) { } @ Override public List < CertifiedRole > getCertifiedSignerRoles ( ) { } @ Override public byte [ ] getContentTimestampData ( final TimestampToken timestampToken ) { } public List < TimestampToken > getContentTimestamps ( ) { } @ Override public List < TimestampToken > getSignatureTimestamps ( ) throws RuntimeException { } @ Override public List < TimestampToken > getTimestampsX1 ( ) { } @ Override public List < TimestampToken > getTimestampsX2 ( ) { } @ Override public List < TimestampToken > getArchiveTimestamps ( ) { } private void makeTimestampTokens ( ) { } private List < TimestampToken > getTimestampTokenList ( ) { } private List < TimestampToken > createTimestamps ( final ASN1ObjectIdentifier attrType , final TimestampType timestampType , final ArchiveTimestampType archiveTimestampType ) { } public List < TimestampReference > getSignatureTimestampedReferences ( ) { } private TimestampReference getSignatureTimestampReference ( ) { } private List < TimestampReference > getSigningCertificateTimestampReferences ( ) { } private TimestampReference createCertificateTimestampReference ( final DigestAlgorithm digestAlgorithm , final byte [ ] certHash ) { } @ Override public EncryptionAlgorithm getEncryptionAlgorithm ( ) { } @ Override public DigestAlgorithm getDigestAlgorithm ( ) { } @ Override public SignatureCryptographicVerification checkSignatureIntegrity ( ) { } private SignerInformation recreateSignerInformation ( ) throws IOException , CMSException { } private boolean isDetachedSignature ( ) { } private List < CertificateValidity > getCertificateValidityList ( ) { } @ Override public void checkSigningCertificate ( ) { } @ Override public String getContentType ( ) { } @ Override public String getContentIdentifier ( ) { } @ Override public String getContentHints ( ) { } public SignerInformation getSignerInformation ( ) { } @ Override public List < AdvancedSignature > getCounterSignatures ( ) { } @ Override public List < CertificateRef > getCertificateRefs ( ) { } @ Override public List < CRLRef > getCRLRefs ( ) { } @ Override public List < OCSPRef > getOCSPRefs ( ) { } @ Override public byte [ ] getSignatureTimestampData ( final TimestampToken timestampToken , String canonicalizationMethod ) { } @ Override public byte [ ] getTimestampX1Data ( final TimestampToken timestampToken , String canonicalizationMethod ) { } @ Override public byte [ ] getTimestampX2Data ( final TimestampToken timestampToken , String canonicalizationMethod ) { } @ Override public byte [ ] getArchiveTimestampData ( final TimestampToken timestampToken , String canonicalizationMethod ) throws DSSException { } private byte [ ] getArchiveTimestampDataV3 ( final TimestampToken timestampToken ) throws DSSException { } private byte [ ] getOriginalDocumentBytes ( ) throws DSSException { } public static byte [ ] getSignedContent ( final CMSTypedData cmsTypedData ) { } private byte [ ] getArchiveTimestampDataV2 ( TimestampToken timestampToken ) throws DSSException { } private ASN1Sequence getSignerInfoEncoded ( final SignerInfo signerInfo , final ASN1Encodable unauthenticatedAttributes ) { } private ASN1Sequence filterUnauthenticatedAttributes ( ASN1Set unauthenticatedAttributes , TimestampToken timestampToken ) { } @ Override public String getId ( ) { } @ Override public List < TimestampReference > getTimestampedReferences ( ) { } @ Override public Set < DigestAlgorithm > getUsedCertificatesDigestAlgorithms ( ) { } public static AttributeTable getUnsignedAttributes ( final SignerInformation signerInformation ) { } public static AttributeTable getSignedAttributes ( final SignerInformation signerInformation ) { } public boolean isDataForSignatureLevelPresent ( final SignatureLevel signatureLevel ) { } @ Override public Set < SignatureLevel > getSignatureLevels_ ( ) { } public boolean hasBProfile ( ) { } public boolean hasTProfile ( ) { } public boolean hasCProfile ( ) { } public boolean hasXProfile ( ) { } public boolean hasXLProfile ( ) { } public boolean hasLTProfile ( ) { } public boolean hasLTAProfile ( ) { } public boolean hasAProfile ( ) { } @ Override public SignatureLevel [ ] getSignatureLevels ( ) { <START_BUG> return new SignatureLevel [ ] { SignatureLevel . CAdES_101733_A , SignatureLevel . CAdES_101733_XL , SignatureLevel . CAdES_101733_X , SignatureLevel . CAdES_101733_C , SignatureLevel . CMS_NOT_ETSI , SignatureLevel . CAdES_BASELINE_LTA , SignatureLevel . CAdES_BASELINE_LT , SignatureLevel . CAdES_BASELINE_T , SignatureLevel . CAdES_BASELINE_B } ; <END_BUG> } No newline ; at end ; of file ; }

Fix:
return new SignatureLevel [ ] { SignatureLevel . CAdES_101733_A , SignatureLevel . CAdES_101733_XL , SignatureLevel . CAdES_101733_X , SignatureLevel . CAdES_101733_C , SignatureLevel . CAdES_BASELINE_LTA , SignatureLevel . CAdES_BASELINE_LT , SignatureLevel . CAdES_BASELINE_T , SignatureLevel . CAdES_BASELINE_B , SignatureLevel . CMS_NOT_ETSI } ;