-
Notifications
You must be signed in to change notification settings - Fork 4
Setting up the library
Mtabe edited this page Jul 16, 2024
·
4 revisions
To use this library first you need to create a .env file at the root of your project then install the dotenv-java library
For Maven
<dependency>
<groupId>io.github.cdimascio</groupId>
<artifactId>dotenv-java</artifactId>
<version>2.2.0</version>
</dependency>
For Gradle
implementation 'io.github.cdimascio:dotenv-java:2.2.0'
Then add the following to your .env
PRIVATE_KEYSTORE_PATH=../test-keys/private-key.pfx
PUBLIC_KEYSTORE_PATH=../test-keys/public-key.pfx
PRIVATE_KEYSTORE_PASSWORD=passpass
PUBLIC_KEYSTORE_PASSWORD=passpass
PRIVATE_KEY_ALIAS=gepgclient
PUBLIC_KEY_ALIAS=gepgclient
KEYSTORE_TYPE=PKCS12
SIGNATURE_ALGORITHM=SHA1withRSA
GEPG_CODE=GepgCode
SP_CODE=SPCode
API_URL=https://uat1.gepg.go.tz
eGA will provide you with almost all of these configurations except maybe
KEYSTORE_TYPE which should be PKCS12 and SIGNATURE_ALGORITHM which must be set to SHA1withRSA