The following document contains the results of FindBugs Report
FindBugs Version is 2.0.0
Threshold is medium
Effort is min
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to dirExcludes in gov.nasa.pds.harvest.HarvestLauncher.logHeader(Policy) | STYLE | DLS_DEAD_LOCAL_STORE | 345 | Medium |
Dead store to fileIncludes in gov.nasa.pds.harvest.HarvestLauncher.logHeader(Policy) | STYLE | DLS_DEAD_LOCAL_STORE | 344 | Medium |
gov.nasa.pds.harvest.HarvestLauncher.processMain(String[]) invokes System.exit(...), which shuts down the entire virtual machine | BAD_PRACTICE | DM_EXIT | 637 | Medium |
gov.nasa.pds.harvest.HarvestLauncher.query(CommandLine) invokes System.exit(...), which shuts down the entire virtual machine | BAD_PRACTICE | DM_EXIT | 221 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numAssociationsNotRegistered from instance method gov.nasa.pds.harvest.association.AssociationPublisher.publish(File, Metadata) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 114 | Medium |
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numAssociationsRegistered from instance method gov.nasa.pds.harvest.association.AssociationPublisher.publish(File, Metadata) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 109 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
gov.nasa.pds.harvest.constants.Constants.collections isn't final but should be | MALICIOUS_CODE | MS_SHOULD_BE_FINAL | 163 | High |
gov.nasa.pds.harvest.constants.Constants.nonPrimaryMembers isn't final but should be | MALICIOUS_CODE | MS_SHOULD_BE_FINAL | 161 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to label in gov.nasa.pds.harvest.crawler.PDS3ProductCrawler.passesPreconditions(File) | STYLE | DLS_DEAD_LOCAL_STORE | 114 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to fileObjectEntries in gov.nasa.pds.harvest.crawler.actions.FileObjectRegistrationAction.performAction(File, Metadata) | STYLE | DLS_DEAD_LOCAL_STORE | 137 | Medium |
Possible null pointer dereference of file in gov.nasa.pds.harvest.crawler.actions.FileObjectRegistrationAction.getPds3FileObjects(File, List) on exception path | CORRECTNESS | NP_NULL_ON_SOME_PATH_EXCEPTION | 428 | Medium |
Exception is caught when Exception is not thrown in gov.nasa.pds.harvest.crawler.actions.FileObjectRegistrationAction.performAction(File, Metadata) | STYLE | REC_CATCH_EXCEPTION | 197 | Medium |
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numAncillaryProductsNotRegistered from instance method gov.nasa.pds.harvest.crawler.actions.FileObjectRegistrationAction.performAction(File, Metadata) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 201 | Medium |
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numAncillaryProductsRegistered from instance method gov.nasa.pds.harvest.crawler.actions.FileObjectRegistrationAction.performAction(File, Metadata) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 177 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numProductsNotRegistered from instance method gov.nasa.pds.harvest.crawler.actions.RegistryUniquenessCheckerAction.performAction(File, Metadata) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 88 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unread field: gov.nasa.pds.harvest.crawler.actions.SaveMetadataAction.DESCRIPTION; should this field be static? | PERFORMANCE | SS_SHOULD_BE_STATIC | 37 | Medium |
Unread field: gov.nasa.pds.harvest.crawler.actions.SaveMetadataAction.ID; should this field be static? | PERFORMANCE | SS_SHOULD_BE_STATIC | 34 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unread field: gov.nasa.pds.harvest.crawler.actions.ValidObjectTypeCheckerAction.DESCRIPTION; should this field be static? | PERFORMANCE | SS_SHOULD_BE_STATIC | 21 | Medium |
Unread field: gov.nasa.pds.harvest.crawler.actions.ValidObjectTypeCheckerAction.ID; should this field be static? | PERFORMANCE | SS_SHOULD_BE_STATIC | 20 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to references in gov.nasa.pds.harvest.crawler.metadata.extractor.BundleMetExtractor.extractMetadata(File) | STYLE | DLS_DEAD_LOCAL_STORE | 68 | Medium |
Exception is caught when Exception is not thrown in gov.nasa.pds.harvest.crawler.metadata.extractor.BundleMetExtractor.extractMetadata(File) | STYLE | REC_CATCH_EXCEPTION | 144 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to references in gov.nasa.pds.harvest.crawler.metadata.extractor.CollectionMetExtractor.extractMetadata(File) | STYLE | DLS_DEAD_LOCAL_STORE | 77 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
gov.nasa.pds.harvest.crawler.metadata.extractor.Pds3MetExtractor.createLid(File, Label, LidContents) concatenates strings using + in a loop | PERFORMANCE | SBSC_USE_STRINGBUFFER_CONCATENATION | 200 | Medium |
gov.nasa.pds.harvest.crawler.metadata.extractor.Pds3MetExtractor.createTitle(File, Label, TitleContents) concatenates strings using + in a loop | PERFORMANCE | SBSC_USE_STRINGBUFFER_CONCATENATION | 255 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to dataClasses in gov.nasa.pds.harvest.crawler.metadata.extractor.Pds4MetExtractor.extractMetadata(File) | STYLE | DLS_DEAD_LOCAL_STORE | 88 | Medium |
Dead store to references in gov.nasa.pds.harvest.crawler.metadata.extractor.Pds4MetExtractor.extractMetadata(File) | STYLE | DLS_DEAD_LOCAL_STORE | 87 | Medium |
Exception is caught when Exception is not thrown in gov.nasa.pds.harvest.crawler.metadata.extractor.Pds4MetExtractor.extractMetadata(File) | STYLE | REC_CATCH_EXCEPTION | 172 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Found reliance on default encoding in gov.nasa.pds.harvest.file.ChecksumManifest.read(File): new java.io.FileReader(File) | I18N | DM_DEFAULT_ENCODING | 53 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Possible null pointer dereference of input in gov.nasa.pds.harvest.file.MD5Checksum.createChecksum(String) on exception path | CORRECTNESS | NP_NULL_ON_SOME_PATH_EXCEPTION | 70 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to extrinsic in gov.nasa.pds.harvest.ingest.RegistryIngester.hasProduct(URL, String) | STYLE | DLS_DEAD_LOCAL_STORE | 133 | Medium |
gov.nasa.pds.harvest.ingest.RegistryIngester.createFileObjectMetadata(FileObject, Metadata) invokes inefficient new Long(long) constructor; use Long.valueOf(long) instead | PERFORMANCE | DM_NUMBER_CTOR | 395 | Medium |
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numProductsNotRegistered from instance method gov.nasa.pds.harvest.ingest.RegistryIngester.ingest(URL, File, Metadata) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 221 | Medium |
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numProductsRegistered from instance method gov.nasa.pds.harvest.ingest.RegistryIngester.ingest(URL, File, Metadata) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 217 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Found reliance on default encoding in new gov.nasa.pds.harvest.inventory.InventoryTableReader(File): new java.io.FileReader(File) | I18N | DM_DEFAULT_ENCODING | 79 | High |
Unread field: gov.nasa.pds.harvest.inventory.InventoryTableReader.parentDirectory | PERFORMANCE | URF_UNREAD_FIELD | 65 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unread field: gov.nasa.pds.harvest.inventory.InventoryXMLReader.parentDirectory | PERFORMANCE | URF_UNREAD_FIELD | 57 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numErrors from instance method gov.nasa.pds.harvest.logging.formatter.HarvestFormatter.format(LogRecord) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 63 | Medium |
Write to static field gov.nasa.pds.harvest.stats.HarvestStats.numWarnings from instance method gov.nasa.pds.harvest.logging.formatter.HarvestFormatter.format(LogRecord) | STYLE | ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD | 60 | Medium |
Unread field: gov.nasa.pds.harvest.logging.formatter.HarvestFormatter.config | PERFORMANCE | URF_UNREAD_FIELD | 45 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unread field: gov.nasa.pds.harvest.registry.RegistryClient.password | PERFORMANCE | URF_UNREAD_FIELD | 82 | Medium |
Unread field: gov.nasa.pds.harvest.registry.RegistryClient.user | PERFORMANCE | URF_UNREAD_FIELD | 81 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unwritten field: gov.nasa.pds.harvest.security.SecurityClient.mediaType | CORRECTNESS | UWF_UNWRITTEN_FIELD | 60 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
gov.nasa.pds.harvest.stats.HarvestStats.numAncillaryProductsNotRegistered isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 21 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numAncillaryProductsRegistered isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 19 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numAssociationsNotRegistered isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 25 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numAssociationsRegistered isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 23 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numBadFiles isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 11 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numErrors isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 27 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numFilesSkipped isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 13 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numGeneratedChecksumsDiffInLabel isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 39 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numGeneratedChecksumsDiffInManifest isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 33 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numGeneratedChecksumsNotCheckedInLabel isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 41 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numGeneratedChecksumsNotCheckedInManifest isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 35 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numGeneratedChecksumsSameInLabel isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 37 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numGeneratedChecksumsSameInManifest isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 31 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numGoodFiles isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 9 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numManifestChecksumsDiffInLabel isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 45 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numManifestChecksumsNotCheckedInLabel isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 47 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numManifestChecksumsSameInLabel isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 43 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numProductsNotRegistered isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 17 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numProductsRegistered isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 15 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.numWarnings isn't final and can't be protected from malicious code | MALICIOUS_CODE | MS_CANNOT_BE_FINAL | 29 | Medium |
gov.nasa.pds.harvest.stats.HarvestStats.registeredProductTypes isn't final but should be | MALICIOUS_CODE | MS_SHOULD_BE_FINAL | 50 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Equals method for gov.nasa.pds.harvest.util.LidVid assumes the argument is of type LidVid | BAD_PRACTICE | BC_EQUALS_METHOD_SHOULD_WORK_FOR_ALL_OBJECTS | 73 | Medium |
gov.nasa.pds.harvest.util.LidVid defines equals and uses Object.hashCode() | BAD_PRACTICE | HE_EQUALS_USE_HASHCODE | 72 | High |
gov.nasa.pds.harvest.util.LidVid.equals(Object) does not check for null argument | BAD_PRACTICE | NP_EQUALS_SHOULD_HANDLE_NULL_ARGUMENT | 72 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Found reliance on default encoding in gov.nasa.pds.harvest.util.Utility.toXML(Association): java.io.ByteArrayOutputStream.toString() | I18N | DM_DEFAULT_ENCODING | 122 | High |
Found reliance on default encoding in gov.nasa.pds.harvest.util.Utility.toXML(ExtrinsicObject): java.io.ByteArrayOutputStream.toString() | I18N | DM_DEFAULT_ENCODING | 101 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
level could be null and is guaranteed to be dereferenced in gov.nasa.pds.harvest.util.XMLValidationEventHandler.handleEvent(ValidationEvent) | CORRECTNESS | NP_GUARANTEED_DEREF | 47 | Medium |