Computer/JAVA

[JAVA] jar 파일 keystore 서명하여 배포하기

jamezc 2020. 4. 22. 01:17

 

1. 키 저장소 생성

keytool –genkey -keystore work.keystore -alias codingfun

 

2. 키 저장소 자가 인증

keytool -selfcert -alias codingfun -keystore codingfun.keystore

 

3. 인증된 키 저장소 확인

keytool -list -keystore codingfun.keystore

 

4. 키 저장소를 이용하여 JAR 서명

jarsigner -keystore codingfun.keystore AAAA.jar codingfun

Keytool 폴더 내의 keystore 파일명, jar 파일명, keystore 생성시 입력했던 alias 값을 차례로 입력해준다.