SpotBugs Bug Detector Report
The following document contains the results of SpotBugs
SpotBugs Version is 4.7.3
Threshold is medium
Effort is default
Summary
| Classes |
Bugs |
Errors |
Missing Classes |
| 57 |
19 |
0 |
0 |
org.apache.shardingsphere.mcp.bootstrap.config.MCPLaunchConfiguration
| Bug |
Category |
Details |
Line |
Priority |
| org.apache.shardingsphere.mcp.bootstrap.config.MCPLaunchConfiguration.getDatabases() may expose internal representation by returning MCPLaunchConfiguration.databases |
MALICIOUS_CODE |
EI_EXPOSE_REP |
34 |
Medium |
| new org.apache.shardingsphere.mcp.bootstrap.config.MCPLaunchConfiguration(Map) may expose internal representation by storing an externally mutable object into MCPLaunchConfiguration.databases |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
56 |
Medium |
| new org.apache.shardingsphere.mcp.bootstrap.config.MCPLaunchConfiguration(HttpTransportConfiguration, Map) may expose internal representation by storing an externally mutable object into MCPLaunchConfiguration.databases |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
46 |
Medium |
org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlHttpTransportConfiguration
| Bug |
Category |
Details |
Line |
Priority |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlHttpTransportConfiguration.getSessionAttributionSource() may expose internal representation by returning YamlHttpTransportConfiguration.sessionAttributionSource |
MALICIOUS_CODE |
EI_EXPOSE_REP |
39 |
Medium |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlHttpTransportConfiguration.setSessionAttributionSource(YamlSessionAttributionSourceConfiguration) may expose internal representation by storing an externally mutable object into YamlHttpTransportConfiguration.sessionAttributionSource |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
29 |
Medium |
org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPLaunchConfiguration
| Bug |
Category |
Details |
Line |
Priority |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPLaunchConfiguration.getRuntimeDatabases() may expose internal representation by returning YamlMCPLaunchConfiguration.runtimeDatabases |
MALICIOUS_CODE |
EI_EXPOSE_REP |
45 |
Medium |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPLaunchConfiguration.getTransport() may expose internal representation by returning YamlMCPLaunchConfiguration.transport |
MALICIOUS_CODE |
EI_EXPOSE_REP |
40 |
Medium |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPLaunchConfiguration.setRuntimeDatabases(Map) may expose internal representation by storing an externally mutable object into YamlMCPLaunchConfiguration.runtimeDatabases |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
34 |
Medium |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPLaunchConfiguration.setTransport(YamlMCPTransportConfiguration) may expose internal representation by storing an externally mutable object into YamlMCPLaunchConfiguration.transport |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
34 |
Medium |
org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPTransportConfiguration
| Bug |
Category |
Details |
Line |
Priority |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPTransportConfiguration.getHttp() may expose internal representation by returning YamlMCPTransportConfiguration.http |
MALICIOUS_CODE |
EI_EXPOSE_REP |
39 |
Medium |
| org.apache.shardingsphere.mcp.bootstrap.config.yaml.config.YamlMCPTransportConfiguration.setHttp(YamlHttpTransportConfiguration) may expose internal representation by storing an externally mutable object into YamlMCPTransportConfiguration.http |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
32 |
Medium |
org.apache.shardingsphere.mcp.bootstrap.transport.server.MCPSyncServerFactory
| Bug |
Category |
Details |
Line |
Priority |
| new org.apache.shardingsphere.mcp.bootstrap.transport.server.MCPSyncServerFactory(MCPRuntimeContext, McpJsonMapper) may expose internal representation by storing an externally mutable object into MCPSyncServerFactory.jsonMapper |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
55 |
Medium |
org.apache.shardingsphere.mcp.bootstrap.transport.server.http.StreamableHttpMCPServlet
| Bug |
Category |
Details |
Line |
Priority |
| Class org.apache.shardingsphere.mcp.bootstrap.transport.server.http.StreamableHttpMCPServlet defines non-transient non-serializable instance field securityValidator |
BAD_PRACTICE |
SE_BAD_FIELD |
Not available |
Medium |
| Class org.apache.shardingsphere.mcp.bootstrap.transport.server.http.StreamableHttpMCPServlet defines non-transient non-serializable instance field sessionAttributionResolver |
BAD_PRACTICE |
SE_BAD_FIELD |
Not available |
Medium |
| Class org.apache.shardingsphere.mcp.bootstrap.transport.server.http.StreamableHttpMCPServlet defines non-transient non-serializable instance field sessionExecutionCoordinator |
BAD_PRACTICE |
SE_BAD_FIELD |
Not available |
Medium |
| Class org.apache.shardingsphere.mcp.bootstrap.transport.server.http.StreamableHttpMCPServlet defines non-transient non-serializable instance field sessionManager |
BAD_PRACTICE |
SE_BAD_FIELD |
Not available |
Medium |
| org.apache.shardingsphere.mcp.bootstrap.transport.server.http.validator.ShardingSphereServerTransportSecurityValidator stored into non-transient field StreamableHttpMCPServlet.securityValidator |
BAD_PRACTICE |
SE_BAD_FIELD_STORE |
91 |
Medium |
org.apache.shardingsphere.mcp.bootstrap.transport.server.http.validator.MCPTransportSecurityException
| Bug |
Category |
Details |
Line |
Priority |
| org.apache.shardingsphere.mcp.bootstrap.transport.server.http.validator.MCPTransportSecurityException doesn't override io.modelcontextprotocol.server.transport.ServerTransportSecurityException.equals(Object) |
STYLE |
EQ_DOESNT_OVERRIDE_EQUALS |
1 |
Medium |
org.apache.shardingsphere.mcp.bootstrap.transport.server.http.validator.ShardingSphereServerTransportSecurityValidator
| Bug |
Category |
Details |
Line |
Priority |
| new org.apache.shardingsphere.mcp.bootstrap.transport.server.http.validator.ShardingSphereServerTransportSecurityValidator(MCPSessionManager, OriginHeaderConstraint, ProtocolVersionHeaderConstraint, SessionAttributionResolver) may expose internal representation by storing an externally mutable object into ShardingSphereServerTransportSecurityValidator.sessionManager |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
38 |
Medium |