change the log level when decode an illegal mysql packet

This commit is contained in:
obdev
2023-02-21 12:12:21 +00:00
committed by ob-robot
parent 4c0a8986ec
commit 6940db9e22
3 changed files with 5 additions and 4 deletions

View File

@ -165,7 +165,8 @@ inline int ObMysqlProtocolProcessor::decode_sslr_body(ObICSMemPool& pool, const
buf += pktlen;
if (OB_FAIL(sslrpkt->decode())) {
LOG_ERROR("failed to decode OMPKSSLRequest", KPC(sslrpkt), K(ret));
LOG_WARN("failed to decode OMPKSSLRequest and the socket connection that this session belongs"
"to could be an illegal connection", KPC(sslrpkt), K(ret));
}
}
return ret;

View File

@ -48,7 +48,7 @@ int OMPKHandshakeResponse::decode()
capability_.capability_ = uint2korr(pos);
if (!capability_.cap_flags_.OB_CLIENT_PROTOCOL_41) {
ret = OB_NOT_SUPPORTED;
LOG_ERROR("ob only support mysql client protocol 4.1", K(ret));
LOG_WARN("ob only support mysql client protocol 4.1", K(ret));
} else {
ObMySQLUtil::get_uint4(pos, capability_.capability_);
// When the driver establishes a connection, it decides whether to open the CLIENT_MULTI_RESULTS

View File

@ -43,10 +43,10 @@ int OMPKSSLRequest::decode()
capability_.capability_ = uint2korr(pos);
if (OB_UNLIKELY(!capability_.cap_flags_.OB_CLIENT_SSL)) {
ret = OB_ERR_UNEXPECTED;
LOG_ERROR("error capability from ssl request packet", K(ret));
LOG_WARN("error capability from ssl request packet", K(ret));
} else if (OB_UNLIKELY(!capability_.cap_flags_.OB_CLIENT_PROTOCOL_41)) {
ret = OB_NOT_SUPPORTED;
LOG_ERROR("ob only support mysql client protocol 4.1", K(ret));
LOG_WARN("ob only support mysql client protocol 4.1", K(ret));
} else {
if (JDBC_SSL_MIN_SIZE == len) {
// JConnector only sends server capabilities before starting SSL negotiation. The below code is patch for this.