親們,運(yùn)行結(jié)果正確,但是出現(xiàn)警告,如下,有人出現(xiàn)這種情況么?該怎么辦呢?
Fri Dec 11 18:28:21 CST 2015 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.
小美,22
2018-01-25
看到這里就實(shí)驗(yàn)了一下,就是要在連接數(shù)據(jù)庫中添加設(shè)置useSSL=false
2017-10-13
即在原來的數(shù)據(jù)庫名稱后面添加
?useUnicode=true&characterEncoding=utf-8&useSSL=false
2017-08-10
我就直接后面加個(gè)這個(gè)就好了?useSSL=false;
2017-07-24
jdbc:mysql://localhost:3306/spring?useSSL=true
關(guān)鍵是在jdbc建立連接的時(shí)候,出于安全考慮,連接通道采用SSL,只需要加上useSSL=true的參數(shù)就好了。
當(dāng)然,前面程序里面報(bào)的是warning,不加這個(gè)參數(shù),也不會(huì)有問題。
2017-02-19
Sun Feb 19 18:09:11 CST 2017 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.這個(gè)是怎么回事呢
2016-05-30
新版本的MySQL要求是否進(jìn)行ssl連接,conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/jsp_db?useUnicode=true&characterEncoding=utf-8&useSSL=false","root","123456");正解!
2016-03-27
如果你非要不讓他報(bào)warning,你改成這樣就行了
String url="jdbc:mysql://localhost:3306/bbs?user=root&password=usbw&useSSL=false";
2016-03-27
這個(gè)不是報(bào)錯(cuò),我以前百度過,這個(gè)不影響你使用,你肯定用的5.1.38版本的jar所以出現(xiàn)這個(gè)問題,我以前用老版本的jar包沒問題
2016-03-19
我的錯(cuò)誤是unknown database ‘jsp_db’怎么回事
2015-12-23
conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/jsp_db","root","123456");
這個(gè)地方改成conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/jsp_db?useUnicode=true&characterEncoding=utf-8&useSSL=false","root","123456");
試試,我的可以了