Apache Commons logo Apache Commons Net™ logo

SpotBugs Bug Detector Report

The following document contains the results of SpotBugs

SpotBugs Version is 4.9.3

Threshold is medium

Effort is default

Summary

Classes Bugs Errors Missing Classes
239 25 0 0

Files

Class Bugs
org.apache.commons.net.examples.ftp.TFTPExample 2
org.apache.commons.net.examples.ntp.SimpleNTPServer 5
org.apache.commons.net.finger.FingerClient 1
org.apache.commons.net.ftp.parser.RegexFTPFileEntryParserImpl 2
org.apache.commons.net.imap.IMAP 1
org.apache.commons.net.nntp.NNTPClient 1
org.apache.commons.net.ntp.TimeInfo 4
org.apache.commons.net.ntp.TimeStamp 1
org.apache.commons.net.smtp.SimpleSMTPHeader 1
org.apache.commons.net.telnet.TelnetClient 1
org.apache.commons.net.tftp.TFTPRequestPacket 1
org.apache.commons.net.util.Base64 2
org.apache.commons.net.util.SubnetUtils 2
org.apache.commons.net.util.SubnetUtils$SubnetAddressStringIterator 1

org.apache.commons.net.examples.ftp.TFTPExample

Bug Category Details Line Priority
org.apache.commons.net.examples.ftp.TFTPExample.receive(int, String, String, String, TFTPClient) may fail to clean up java.io.OutputStream on checked exception EXPERIMENTAL OBL_UNSATISFIED_OBLIGATION_EXCEPTION_EDGE 193 Medium
org.apache.commons.net.examples.ftp.TFTPExample.send(int, String, String, String, TFTPClient) may fail to clean up java.io.InputStream on checked exception EXPERIMENTAL OBL_UNSATISFIED_OBLIGATION_EXCEPTION_EDGE 228 Medium

org.apache.commons.net.examples.ntp.SimpleNTPServer

Bug Category Details Line Priority
Shared primitive variable "port" in one thread may not yield the value of the most recent write from another thread MT_CORRECTNESS AT_STALE_THREAD_WRITE_OF_PRIMITIVE 91 Medium
Shared primitive variable "started" in one thread may not yield the value of the most recent write from another thread MT_CORRECTNESS AT_STALE_THREAD_WRITE_OF_PRIMITIVE 191 Medium
Shared primitive variable "started" in one thread may not yield the value of the most recent write from another thread MT_CORRECTNESS AT_STALE_THREAD_WRITE_OF_PRIMITIVE 204 Medium
Exception thrown in class org.apache.commons.net.examples.ntp.SimpleNTPServer at new org.apache.commons.net.examples.ntp.SimpleNTPServer() will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 65 Medium
Exception thrown in class org.apache.commons.net.examples.ntp.SimpleNTPServer at new org.apache.commons.net.examples.ntp.SimpleNTPServer(int) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 76 Medium

org.apache.commons.net.finger.FingerClient

Bug Category Details Line Priority
org.apache.commons.net.finger.FingerClient.getInputStream(boolean, String, String) may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 110 Medium

org.apache.commons.net.ftp.parser.RegexFTPFileEntryParserImpl

Bug Category Details Line Priority
Exception thrown in class org.apache.commons.net.ftp.parser.RegexFTPFileEntryParserImpl at new org.apache.commons.net.ftp.parser.RegexFTPFileEntryParserImpl(String) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 60 Medium
Exception thrown in class org.apache.commons.net.ftp.parser.RegexFTPFileEntryParserImpl at new org.apache.commons.net.ftp.parser.RegexFTPFileEntryParserImpl(String, int) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 74 Medium

org.apache.commons.net.imap.IMAP

Bug Category Details Line Priority
Shared primitive variable "replyCode" in one thread may not yield the value of the most recent write from another thread MT_CORRECTNESS AT_STALE_THREAD_WRITE_OF_PRIMITIVE 294 Medium

org.apache.commons.net.nntp.NNTPClient

Bug Category Details Line Priority
Dead store to list in org.apache.commons.net.nntp.NNTPClient.listNewNews(NewGroupsOrNewsQuery) STYLE DLS_DEAD_LOCAL_STORE 438 Medium

org.apache.commons.net.ntp.TimeInfo

Bug Category Details Line Priority
Exception thrown in class org.apache.commons.net.ntp.TimeInfo at new org.apache.commons.net.ntp.TimeInfo(NtpV3Packet, long) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 53 Medium
Exception thrown in class org.apache.commons.net.ntp.TimeInfo at new org.apache.commons.net.ntp.TimeInfo(NtpV3Packet, long, List) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 78 Medium
Exception thrown in class org.apache.commons.net.ntp.TimeInfo at new org.apache.commons.net.ntp.TimeInfo(NtpV3Packet, long, List, boolean) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 93 Medium
Exception thrown in class org.apache.commons.net.ntp.TimeInfo at new org.apache.commons.net.ntp.TimeInfo(NtpV3Packet, long, boolean) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 66 Medium

org.apache.commons.net.ntp.TimeStamp

Bug Category Details Line Priority
Exception thrown in class org.apache.commons.net.ntp.TimeStamp at new org.apache.commons.net.ntp.TimeStamp(String) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 253 Medium

org.apache.commons.net.smtp.SimpleSMTPHeader

Bug Category Details Line Priority
Exception thrown in class org.apache.commons.net.smtp.SimpleSMTPHeader at new org.apache.commons.net.smtp.SimpleSMTPHeader(String, String, String) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 67 Medium

org.apache.commons.net.telnet.TelnetClient

Bug Category Details Line Priority
Shared primitive variable "readerThread" in one thread may not yield the value of the most recent write from another thread MT_CORRECTNESS AT_STALE_THREAD_WRITE_OF_PRIMITIVE 372 Medium

org.apache.commons.net.tftp.TFTPRequestPacket

Bug Category Details Line Priority
Exception thrown in class org.apache.commons.net.tftp.TFTPRequestPacket at new org.apache.commons.net.tftp.TFTPRequestPacket(int, DatagramPacket) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 96 Medium

org.apache.commons.net.util.Base64

Bug Category Details Line Priority
org.apache.commons.net.util.Base64.finalize() is public; should be protected MALICIOUS_CODE FI_PUBLIC_SHOULD_BE_PROTECTED 605-606 Medium
org.apache.commons.net.util.Base64.finalize() does nothing except call super.finalize(); delete it BAD_PRACTICE FI_USELESS 605-606 Medium

org.apache.commons.net.util.SubnetUtils

Bug Category Details Line Priority
Exception thrown in class org.apache.commons.net.util.SubnetUtils at new org.apache.commons.net.util.SubnetUtils(String) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 420 Medium
Exception thrown in class org.apache.commons.net.util.SubnetUtils at new org.apache.commons.net.util.SubnetUtils(String, String) will leave the constructor. The object under construction remains partially initialized and may be vulnerable to Finalizer attacks. BAD_PRACTICE CT_CONSTRUCTOR_THROW 453 Medium

org.apache.commons.net.util.SubnetUtils$SubnetAddressStringIterator

Bug Category Details Line Priority
org.apache.commons.net.util.SubnetUtils$SubnetAddressStringIterator.next() cannot throw NoSuchElementException BAD_PRACTICE IT_NO_SUCH_ELEMENT 81 Medium