Commit 7bbab3c5 by xieshixiang

返回参数校对

parent e8c03071
...@@ -18,7 +18,7 @@ import org.springframework.web.bind.annotation.RestController; ...@@ -18,7 +18,7 @@ import org.springframework.web.bind.annotation.RestController;
**/ **/
@Slf4j @Slf4j
@RestController @RestController
@RequestMapping( "/tool" ) @RequestMapping("/tool")
public class ToolController { public class ToolController {
@Autowired @Autowired
SignKeyConfigBean signKeyConfigBean; SignKeyConfigBean signKeyConfigBean;
...@@ -29,8 +29,8 @@ public class ToolController { ...@@ -29,8 +29,8 @@ public class ToolController {
* @param plain 明文 * @param plain 明文
* @return * @return
*/ */
@GetMapping( value = "encrypt" ) @GetMapping(value = "encrypt")
public String encrypt( String plain ) { public String encrypt(String plain) {
return EncryptStringAes.encryptAes(plain, signKeyConfigBean.getKey()); return EncryptStringAes.encryptAes(plain, signKeyConfigBean.getKey());
} }
...@@ -40,8 +40,8 @@ public class ToolController { ...@@ -40,8 +40,8 @@ public class ToolController {
* @param cipher 密文 * @param cipher 密文
* @return * @return
*/ */
@PostMapping( value = "decrypt" ) @GetMapping(value = "decrypt")
public String decrypt( String cipher ) { public String decrypt(String cipher) {
return EncryptStringAes.decryptAes(cipher, signKeyConfigBean.getKey()); return EncryptStringAes.decryptAes(cipher, signKeyConfigBean.getKey());
} }
...@@ -50,7 +50,7 @@ public class ToolController { ...@@ -50,7 +50,7 @@ public class ToolController {
* *
* @return * @return
*/ */
@GetMapping( value = "timestamp" ) @GetMapping(value = "timestamp")
public String timestamp() { public String timestamp() {
return String.valueOf(System.currentTimeMillis()); return String.valueOf(System.currentTimeMillis());
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment