The following document contains the results of FindBugs Report
FindBugs Version is 1.3.9
Threshold is medium
Effort is min
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Null pointer dereference of System.err in org.asteriskjava.Cli.showHelp() | CORRECTNESS | NP_ALWAYS_NULL | 72 | High |
| Null pointer dereference of System.out in org.asteriskjava.Cli.showVersion() | CORRECTNESS | NP_ALWAYS_NULL | 80 | High |
| Null pointer dereference of System.err in org.asteriskjava.Cli.parseOptions(String[]) | CORRECTNESS | NP_ALWAYS_NULL | 57 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.config.dialplan.ConfigExtension.getApplication() may expose internal representation by returning ConfigExtension.application | MALICIOUS_CODE | EI_EXPOSE_REP | 55 | Medium |
| new org.asteriskjava.config.dialplan.ConfigExtension(String, int, String, String, String[]) may expose internal representation by storing an externally mutable object into ConfigExtension.application | MALICIOUS_CODE | EI_EXPOSE_REP2 | 28 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Method org.asteriskjava.config.dialplan.ExtensionsConfigFileReader.harvestApplicationWithArguments(String) concatenates strings using + in a loop | PERFORMANCE | SBSC_USE_STRINGBUFFER_CONCATENATION | 109 | Medium |
| Method org.asteriskjava.config.dialplan.ExtensionsConfigFileReader.processQuotesAndSlashes(String, char, char) concatenates strings using + in a loop | PERFORMANCE | SBSC_USE_STRINGBUFFER_CONCATENATION | 181 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.fastagi.AbstractAgiServer.getMaximumPoolSize() is unsynchronized, org.asteriskjava.fastagi.AbstractAgiServer.setMaximumPoolSize(int) is synchronized | MT_CORRECTNESS | UG_SYNC_SET_UNSYNC_GET | 137 | Medium |
| org.asteriskjava.fastagi.AbstractAgiServer.getPoolSize() is unsynchronized, org.asteriskjava.fastagi.AbstractAgiServer.setPoolSize(int) is synchronized | MT_CORRECTNESS | UG_SYNC_SET_UNSYNC_GET | 101 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.fastagi.AbstractMappingStrategy.getClassLoader() creates a java.net.URLClassLoader classloader, which should be performed within a doPrivileged block | BAD_PRACTICE | DP_CREATE_CLASSLOADER_INSIDE_DO_PRIVILEGED | 98 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Inconsistent synchronization of org.asteriskjava.fastagi.AgiServerThread.agiServer; locked 75% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 81 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Inconsistent synchronization of org.asteriskjava.fastagi.ResourceBundleMappingStrategy.resourceBundleName; locked 66% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 108 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.fastagi.ScriptEngineMappingStrategy.getClassLoader() creates a java.net.URLClassLoader classloader, which should be performed within a doPrivileged block | BAD_PRACTICE | DP_CREATE_CLASSLOADER_INSIDE_DO_PRIVILEGED | 209 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.fastagi.command.ExecCommand.getOptions() may expose internal representation by returning ExecCommand.options | MALICIOUS_CODE | EI_EXPOSE_REP | 95 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.fastagi.command.GosubCommand.getArguments() may expose internal representation by returning GosubCommand.arguments | MALICIOUS_CODE | EI_EXPOSE_REP | 137 | Medium |
| org.asteriskjava.fastagi.command.GosubCommand.setArguments(String[]) may expose internal representation by storing an externally mutable object into GosubCommand.arguments | MALICIOUS_CODE | EI_EXPOSE_REP2 | 147 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.fastagi.internal.AgiRequestImpl.getEnhanced() has Boolean return type and returns explicit null | BAD_PRACTICE | NP_BOOLEAN_RETURN_NULL | 365 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.fastagi.internal.AsyncAgiConnectionHandler.onAsyncAgiEndEvent(AsyncAgiEvent) ignores exceptional return value of java.util.concurrent.BlockingQueue.offer(Object) | BAD_PRACTICE | RV_RETURN_VALUE_IGNORED_BAD_PRACTICE | 104 | Medium |
| org.asteriskjava.fastagi.internal.AsyncAgiConnectionHandler.onAsyncAgiExecEvent(AsyncAgiEvent) ignores exceptional return value of java.util.concurrent.BlockingQueue.offer(Object) | BAD_PRACTICE | RV_RETURN_VALUE_IGNORED_BAD_PRACTICE | 99 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.live.ChannelStateHistoryEntry.getDate() may expose internal representation by returning ChannelStateHistoryEntry.date | MALICIOUS_CODE | EI_EXPOSE_REP | 57 | Medium |
| new org.asteriskjava.live.ChannelStateHistoryEntry(Date, ChannelState) may expose internal representation by storing an externally mutable object into ChannelStateHistoryEntry.date | MALICIOUS_CODE | EI_EXPOSE_REP2 | 46 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.live.DialedChannelHistoryEntry.getDate() may expose internal representation by returning DialedChannelHistoryEntry.date | MALICIOUS_CODE | EI_EXPOSE_REP | 52 | Medium |
| new org.asteriskjava.live.DialedChannelHistoryEntry(Date, AsteriskChannel) may expose internal representation by storing an externally mutable object into DialedChannelHistoryEntry.date | MALICIOUS_CODE | EI_EXPOSE_REP2 | 41 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.live.ExtensionHistoryEntry.getDate() may expose internal representation by returning ExtensionHistoryEntry.date | MALICIOUS_CODE | EI_EXPOSE_REP | 57 | Medium |
| new org.asteriskjava.live.ExtensionHistoryEntry(Date, Extension) may expose internal representation by storing an externally mutable object into ExtensionHistoryEntry.date | MALICIOUS_CODE | EI_EXPOSE_REP2 | 46 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.live.LinkedChannelHistoryEntry.getDateLinked() may expose internal representation by returning LinkedChannelHistoryEntry.dateLinked | MALICIOUS_CODE | EI_EXPOSE_REP | 53 | Medium |
| org.asteriskjava.live.LinkedChannelHistoryEntry.getDateUnlinked() may expose internal representation by returning LinkedChannelHistoryEntry.dateUnlinked | MALICIOUS_CODE | EI_EXPOSE_REP | 63 | Medium |
| new org.asteriskjava.live.LinkedChannelHistoryEntry(Date, AsteriskChannel) may expose internal representation by storing an externally mutable object into LinkedChannelHistoryEntry.dateLinked | MALICIOUS_CODE | EI_EXPOSE_REP2 | 42 | Medium |
| org.asteriskjava.live.LinkedChannelHistoryEntry.setDateUnlinked(Date) may expose internal representation by storing an externally mutable object into LinkedChannelHistoryEntry.dateUnlinked | MALICIOUS_CODE | EI_EXPOSE_REP2 | 73 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Null pointer dereference of System.out in org.asteriskjava.live.internal.AgentManager.initialize() | CORRECTNESS | NP_ALWAYS_NULL | 93 | High |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Inconsistent synchronization of org.asteriskjava.live.internal.AsteriskChannelImpl.linkedChannel; locked 50% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 517 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Inconsistent synchronization of org.asteriskjava.live.internal.AsteriskQueueEntryImpl.state; locked 50% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 80 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Inconsistent synchronization of org.asteriskjava.live.internal.AsteriskServerImpl.eventListener; locked 75% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 1193 | Medium |
| Inconsistent synchronization of org.asteriskjava.live.internal.AsteriskServerImpl.initialized; locked 66% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 1066 | Medium |
| Inconsistent synchronization of org.asteriskjava.live.internal.AsteriskServerImpl.managerEventListenerProxy; locked 42% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 1188 | Medium |
| Inconsistent synchronization of org.asteriskjava.live.internal.AsteriskServerImpl.skipQueues; locked 50% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 156 | Medium |
| Inconsistent synchronization of org.asteriskjava.live.internal.AsteriskServerImpl.version; locked 75% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 1058 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.live.internal.CallDetailRecordImpl.getAnswerDate() may expose internal representation by returning CallDetailRecordImpl.answerDate | MALICIOUS_CODE | EI_EXPOSE_REP | 128 | Medium |
| org.asteriskjava.live.internal.CallDetailRecordImpl.getEndDate() may expose internal representation by returning CallDetailRecordImpl.endDate | MALICIOUS_CODE | EI_EXPOSE_REP | 158 | Medium |
| org.asteriskjava.live.internal.CallDetailRecordImpl.getStartDate() may expose internal representation by returning CallDetailRecordImpl.startDate | MALICIOUS_CODE | EI_EXPOSE_REP | 173 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Method org.asteriskjava.live.internal.ChannelManager.handleStatusEvent(StatusEvent) makes inefficient use of keySet iterator instead of entrySet iterator | PERFORMANCE | WMI_WRONG_MAP_ITERATOR | 227 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Inconsistent synchronization of org.asteriskjava.live.internal.MeetMeUserImpl.state; locked 50% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 93 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.manager.action.AbstractManagerAction.toString() might ignore java.lang.Exception | BAD_PRACTICE | DE_MIGHT_IGNORE | 76 | Medium |
| Exception is caught when Exception is not thrown in org.asteriskjava.manager.action.AbstractManagerAction.toString() | STYLE | REC_CATCH_EXCEPTION | 76 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.manager.event.ManagerEvent.getDateReceived() may expose internal representation by returning ManagerEvent.dateReceived | MALICIOUS_CODE | EI_EXPOSE_REP | 83 | Medium |
| org.asteriskjava.manager.event.ManagerEvent.setDateReceived(Date) may expose internal representation by storing an externally mutable object into ManagerEvent.dateReceived | MALICIOUS_CODE | EI_EXPOSE_REP2 | 91 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.defaultResponseTimeout; locked 57% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 1361 | Medium |
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.eventMask; locked 50% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 1361 | Medium |
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.hostname; locked 60% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 247 | Medium |
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.password; locked 50% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 361 | Medium |
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.reader; locked 61% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 901 | Medium |
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.readerThread; locked 85% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 1399 | Medium |
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.socket; locked 57% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 881 | Medium |
| Inconsistent synchronization of org.asteriskjava.manager.internal.ManagerConnectionImpl.writer; locked 66% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 904 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Method org.asteriskjava.manager.response.GetConfigResponse.getCategories() makes inefficient use of keySet iterator instead of entrySet iterator | PERFORMANCE | WMI_WRONG_MAP_ITERATOR | 80 | Medium |
| Method org.asteriskjava.manager.response.GetConfigResponse.getLines(int) makes inefficient use of keySet iterator instead of entrySet iterator | PERFORMANCE | WMI_WRONG_MAP_ITERATOR | 145 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.manager.response.ManagerResponse.getDateReceived() may expose internal representation by returning ManagerResponse.dateReceived | MALICIOUS_CODE | EI_EXPOSE_REP | 112 | Medium |
| org.asteriskjava.manager.response.ManagerResponse.setDateReceived(Date) may expose internal representation by storing an externally mutable object into ManagerResponse.dateReceived | MALICIOUS_CODE | EI_EXPOSE_REP2 | 121 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Null pointer dereference of System.err in org.asteriskjava.tools.HtmlEventTracer.getProperty(Object, String) | CORRECTNESS | NP_ALWAYS_NULL | 195 | High |
| Null pointer dereference of System.err in org.asteriskjava.tools.HtmlEventTracer.main(String[]) | CORRECTNESS | NP_ALWAYS_NULL | 69 | High |
| Null pointer dereference of System.out in org.asteriskjava.tools.HtmlEventTracer.onManagerEvent(ManagerEvent) | CORRECTNESS | NP_ALWAYS_NULL | 103 | High |
| Null pointer dereference of System.err in org.asteriskjava.tools.HtmlEventTracer.write() | CORRECTNESS | NP_ALWAYS_NULL | 163 | High |
| Null pointer dereference of System.err in org.asteriskjava.tools.HtmlEventTracer.main(String[]) | CORRECTNESS | NP_ALWAYS_NULL | 81 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| org.asteriskjava.util.DateUtil.overrideCurrentDate(Date) may expose internal static state by storing a mutable object into a static field org.asteriskjava.util.DateUtil.currentDate | MALICIOUS_CODE | EI_EXPOSE_STATIC_REP2 | 55 | Medium |
| public static org.asteriskjava.util.DateUtil.getDate() may expose internal representation by returning DateUtil.currentDate | MALICIOUS_CODE | MS_EXPOSE_REP | 71 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Method org.asteriskjava.util.internal.Log4JLogger.debug(Object) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 113 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.debug(Object, Throwable) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 128 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.error(Object) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 203 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.error(Object, Throwable) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 218 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.fatal(Object) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 233 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.fatal(Object, Throwable) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 248 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.info(Object) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 143 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.info(Object, Throwable) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 158 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.trace(Object) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 82 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.trace(Object, Throwable) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 98 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.warn(Object) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 173 | Medium |
| Method org.asteriskjava.util.internal.Log4JLogger.warn(Object, Throwable) uses the same code for two branches | STYLE | DB_DUPLICATE_BRANCHES | 188 | Medium |