zoujiajian 10 månader sedan
förälder
incheckning
79af9575b6

+ 1 - 1
netflix-service/src/main/java/com/cyksj/service/verify/impl/ApiVerifyServiceImpl.java

@@ -28,7 +28,7 @@ public class ApiVerifyServiceImpl implements ApiVerifyService {
 		}
 		Long timestamp = jsonObject.getLong("timestamp");
 		//1s内
-		if (System.currentTimeMillis() - timestamp > 1000) {
+		if (timestamp == null || System.currentTimeMillis() - timestamp > 1000) {
 			return Boolean.FALSE;
 		}
 		String bsign = SignatureUtils.generateSignature(Map.of("timestamp", timestamp.toString()), SIGN_SECRET);