ソースを参照

ip限制逻辑修改

qinchao 4 年 前
コミット
c60ec18d9d

+ 1 - 1
examcloud-core-examwork-service/src/main/java/cn/com/qmth/examcloud/core/examwork/service/impl/ExamServiceImpl.java

@@ -915,7 +915,7 @@ public class ExamServiceImpl implements ExamService {
                                     if (null != clientIp) {
                                         // IP取前三段
                                         clientIp = clientIp.substring(0, clientIp.lastIndexOf(".") + 1);
-                                        if (!realIp.startsWith(clientIp)) {
+                                        if (realIp.startsWith(clientIp)) {
                                             return false;
                                         }
                                     }