From 348120df1cb633a455e9f5180d5e2e8cba766482 Mon Sep 17 00:00:00 2001 From: leebj Date: Fri, 26 Jul 2024 09:33:54 +0900 Subject: [PATCH] =?UTF-8?q?=EC=95=94=ED=98=B8=ED=99=94=20=EC=A3=BC?= =?UTF-8?q?=EC=84=9D=20=ED=95=B4=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../cokr/xit/fims/base/web/MainController.java | 8 ++++++++ src/main/resources/xit-crypto.conf | 16 ++++++++-------- 2 files changed, 16 insertions(+), 8 deletions(-) diff --git a/src/main/java/cokr/xit/fims/base/web/MainController.java b/src/main/java/cokr/xit/fims/base/web/MainController.java index d01c1fb6..52627125 100644 --- a/src/main/java/cokr/xit/fims/base/web/MainController.java +++ b/src/main/java/cokr/xit/fims/base/web/MainController.java @@ -16,6 +16,7 @@ import org.springframework.web.servlet.mvc.method.annotation.SseEmitter; import cokr.xit.base.code.CommonCode; import cokr.xit.base.code.service.CodeService; +import cokr.xit.base.crypto.bean.XitAria; import cokr.xit.base.security.access.service.AuthorityService; import cokr.xit.base.user.SigunguQuery; import cokr.xit.base.user.service.SigunguDepartmentService; @@ -170,6 +171,11 @@ public class MainController extends cokr.xit.base.web.MainController { @RequestMapping(name="접속자 IP 확인", value="/ipInfo.do") public ModelAndView ipInfo(HttpServletRequest hreq) { + XitAria crypto = new XitAria("xit-aria"); + String a1 = crypto.encrypt("1234567890123"); + String a2 = crypto.decrypt(a1); + + String remoteAddr = CmmnUtil.getClientIpAddr(hreq); String net = ""; @@ -202,6 +208,8 @@ public class MainController extends cokr.xit.base.web.MainController { return new ModelAndView("jsonView") .addObject("remoteAddr", remoteAddr) .addObject("net", net) + .addObject("a1",a1) + .addObject("a2",a2) ; } diff --git a/src/main/resources/xit-crypto.conf b/src/main/resources/xit-crypto.conf index fe6a0f65..57cd98a0 100644 --- a/src/main/resources/xit-crypto.conf +++ b/src/main/resources/xit-crypto.conf @@ -8,14 +8,14 @@ "blockSize": 1024 } } - //, - //{ "name": "xit-aria", - // "class": "cokr.xit.base.crypto.bean.XitAria", - // "settings": { - // "charset": "EUC-KR", - // "key": "Copyright (c) 2015 - (주)엑스아이티" - // } - //} + , + { "name": "xit-aria", + "class": "cokr.xit.base.crypto.bean.XitAria", + "settings": { + "charset": "EUC-KR", + "key": "Copyright (c) 2015 - (주)엑스아이티" + } + } ], "targetValues": [ { "name": "주민등록번호",