|
|
|
@ -18,6 +18,8 @@ import kr.xit.biz.ens.model.nice.NiceCiDTO.ResponseDataHeader;
|
|
|
|
|
import kr.xit.biz.ens.model.nice.NiceCiDTO.TokenRequest;
|
|
|
|
|
import kr.xit.biz.ens.model.nice.NiceCiDTO.TokenResDataBody;
|
|
|
|
|
import kr.xit.biz.ens.model.nice.NiceCiDTO.TokenResponse;
|
|
|
|
|
import kr.xit.biz.ens.model.nice.NiceCiDTO.TokenRevokeResDataBody;
|
|
|
|
|
import kr.xit.biz.ens.model.nice.NiceCiDTO.TokenRevokeResponse;
|
|
|
|
|
import kr.xit.core.exception.BizRuntimeException;
|
|
|
|
|
import kr.xit.core.spring.annotation.TraceLogging;
|
|
|
|
|
import kr.xit.core.spring.util.ApiWebClientUtil;
|
|
|
|
@ -110,18 +112,21 @@ public class NiceCiDummyTestService extends EgovAbstractServiceImpl {
|
|
|
|
|
* - current_timestamp
|
|
|
|
|
* Date currentDate = new Date();
|
|
|
|
|
* long current_timestamp = currentDate.getTime() /1000
|
|
|
|
|
* @param token
|
|
|
|
|
* @return
|
|
|
|
|
* </pre>
|
|
|
|
|
*/
|
|
|
|
|
@TraceLogging
|
|
|
|
|
public TokenResponse revokeToken(final String token){
|
|
|
|
|
return webClient.exchange(
|
|
|
|
|
HOST + API_GENERATE_TOKEN,
|
|
|
|
|
HttpMethod.POST,
|
|
|
|
|
null,
|
|
|
|
|
TokenResponse.class,
|
|
|
|
|
getHeaderMap(MediaType.APPLICATION_FORM_URLENCODED_VALUE, AUTH_TYPE_BASIC));
|
|
|
|
|
public TokenRevokeResponse revokeToken(){
|
|
|
|
|
|
|
|
|
|
return TokenRevokeResponse.builder()
|
|
|
|
|
.dataHeader(ResponseDataHeader.builder()
|
|
|
|
|
.gwRsltCd("1200")
|
|
|
|
|
.gwRsltMsg("오류없음")
|
|
|
|
|
.build())
|
|
|
|
|
.dataBody(TokenRevokeResDataBody.builder()
|
|
|
|
|
.result(true)
|
|
|
|
|
.build())
|
|
|
|
|
.build();
|
|
|
|
|
}
|
|
|
|
|
//--------------------------------------------------------------------------------
|
|
|
|
|
// 기관용 Token
|
|
|
|
|