Skip to content
This repository has been archived by the owner on Mar 12, 2024. It is now read-only.

Commit

Permalink
Merge pull request #18 from catenax-ng/main
Browse files Browse the repository at this point in the history
rename-refactor
  • Loading branch information
carslen authored Feb 2, 2023
2 parents 6f56685 + 43b64bb commit f7847ce
Show file tree
Hide file tree
Showing 122 changed files with 1,549 additions and 950 deletions.
42 changes: 25 additions & 17 deletions .env.docker
Original file line number Diff line number Diff line change
@@ -1,21 +1,29 @@
APP_VERSION=
CX_NAME=Catena-X-Wallet
CX_BPN=BPNL000000000000
CX_SHORT_DID=ArqouCjqi4RwBXQqjAbQrG
CX_VERKEY=6Ng3Cu39yTViaEUg1BETpze78nXZqHpb6Q783X2rRhe6
#CX_DB_JDBC_URL=jdbc:h2:mem:miw;DB_CLOSE_DELAY=-1;
#CX_DB_JDBC_DRIVER=org.h2.Driver
CX_DB_JDBC_URL=jdbc:postgresql://db-host-placeholder:5432/miwdev?user=db-user-placeholder&password=db-password-placeholder
CX_DB_JDBC_DRIVER=org.postgresql.Driver
APP_VERSION=3.1.0
MIW_NAME=Base-Wallet
MIW_BPN=BPNL000000000000
MIW_SHORT_DID=ArqouCjqi4RwBXQqjAbQrG
MIW_VERKEY=6Ng3Cu39yTViaEUg1BETpze78nXZqHpb6Q783X2rRhe6
MIW_MEMBERSHIP_ORG=Organisation-A
MIW_DB_JDBC_URL=jdbc:postgresql://db-host-placeholder:5432/db-name-placeholder?user=db-user-placeholder&password=db-password-placeholder
MIW_DB_JDBC_DRIVER=org.postgresql.Driver

CX_AUTH_JWKS_URL=http://auth-host-placeholder:8081/auth/realms/catenax/protocol/openid-connect/certs
CX_AUTH_ISSUER_URL=http://auth-host-placeholder:8081/auth/realms/catenax
CX_AUTH_REALM=catenax
CX_AUTH_CLIENT_ID=ManagedIdentityWallets
CX_AUTH_CLIENT_SECRET=ManagedIdentityWallets-Secret
CX_AUTH_REDIRECT_URL=http://localhost:8080/callback
CX_AUTH_ROLE_MAPPINGS=create_wallets:add_wallets,view_wallets:view_wallets,update_wallets:update_wallets,delete_wallets:delete_wallets,view_wallet:view_wallet,update_wallet:update_wallet
CX_AUTH_RESOURCE_ID=ManagedIdentityWallets
MIW_AUTH_JWKS_URL=http://auth-host-placeholder:8081/auth/realms/localkeycloak/protocol/openid-connect/certs
MIW_AUTH_ISSUER_URL=http://auth-host-placeholder:8081/auth/realms/localkeycloak
MIW_AUTH_REALM=localkeycloak
MIW_AUTH_CLIENT_ID=ManagedIdentityWallets
MIW_AUTH_CLIENT_SECRET=ManagedIdentityWallets-Secret
MIW_AUTH_REDIRECT_URL=http://localhost:8080/callback
MIW_AUTH_ROLE_MAPPINGS=create_wallets:add_wallets,view_wallets:view_wallets,update_wallets:update_wallets,delete_wallets:delete_wallets,view_wallet:view_wallet,update_wallet:update_wallet
MIW_AUTH_RESOURCE_ID=ManagedIdentityWallets

MIW_OPENAPI_TITLE="placeholder - Managed Identity Wallets API"
MIW_OPENAPI_DESCRIPTION="placeholder - Managed Identity Wallets API"
MIW_OPENAPI_TERM_OF_SERVICES_URL="placeholder-url-to-term-of-services"
MIW_OPENAPI_CONTACT_NAME="placeholder-contact-name"
MIW_OPENAPI_CONTACT_EMAIL="placeholder-contact-email"
MIW_OPENAPI_CONTACT_URL="placeholder-url"
MIW_OPENAPI_LICENSE_NAME="Apache 2.0"
MIW_OPENAPI_LICENSE_URL="placeholder-url-to-license"

ACAPY_NETWORK_IDENTIFIER=local:test
ACAPY_BASE_WALLET_API_ADMIN_URL=http://localhost:11000
Expand Down
121 changes: 104 additions & 17 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,25 +1,44 @@
APP_VERSION=
CX_NAME="Catena-X-Wallet"
CX_BPN="BPNL000000000000"
CX_SHORT_DID="ArqouCjqi4RwBXQqjAbQrG"
CX_VERKEY="6Ng3Cu39yTViaEUg1BETpze78nXZqHpb6Q783X2rRhe6"
CX_DB_JDBC_URL="jdbc:postgresql://localhost:5432/miwdev?user=db-user-placeholder&password=db-password-placeholder"
CX_DB_JDBC_DRIVER="org.postgresql.Driver"
CX_AUTH_JWKS_URL="http://localhost:8081/auth/realms/catenax/protocol/openid-connect/certs"
CX_AUTH_ISSUER_URL="http://localhost:8081/auth/realms/catenax"
CX_AUTH_REALM="catenax"
CX_AUTH_CLIENT_ID="ManagedIdentityWallets"
CX_AUTH_CLIENT_SECRET="ManagedIdentityWallets-Secret"
CX_AUTH_REDIRECT_URL="http://localhost:8080/callback"
CX_AUTH_ROLE_MAPPINGS="create_wallets:add_wallets,view_wallets:view_wallets,update_wallets:update_wallets,delete_wallets:delete_wallets,view_wallet:view_wallet,update_wallet:update_wallet"
CX_AUTH_RESOURCE_ID="ManagedIdentityWallets"
MIW_NAME="Base-Wallet"
MIW_BPN="BPNL000000000000"
# The identifier part of the DID of the base wallet DID
MIW_SHORT_DID="replace-short-did-of-endorser"
# The verkey of the base wallet DID
MIW_VERKEY="replace-verjkey-of-endorser"
MIW_MEMBERSHIP_ORG="replace-name-of-organisation"

# Database connection
MIW_DB_JDBC_URL="jdbc:postgresql://localhost:5432/postgres?user=postgres&password=local_password"
MIW_DB_JDBC_DRIVER="org.postgresql.Driver"

# IAM - Keycloak
MIW_AUTH_JWKS_URL="http://localhost:8081/auth/realms/localkeycloak/protocol/openid-connect/certs"
MIW_AUTH_ISSUER_URL="http://localhost:8081/auth/realms/localkeycloak"
MIW_AUTH_REALM="localkeycloak"
MIW_AUTH_CLIENT_ID="ManagedIdentityWallets"
MIW_AUTH_CLIENT_SECRET="ManagedIdentityWallets-Secret"
MIW_AUTH_REDIRECT_URL="http://localhost:8080/callback"
MIW_AUTH_ROLE_MAPPINGS="create_wallets:add_wallets,view_wallets:view_wallets,update_wallets:update_wallets,delete_wallets:delete_wallets,view_wallet:view_wallet,update_wallet:update_wallet"
MIW_AUTH_RESOURCE_ID="ManagedIdentityWallets"

# OpenAPI configuration
MIW_OPENAPI_TITLE="placeholder - Managed Identity Wallets API"
MIW_OPENAPI_DESCRIPTION="placeholder - Managed Identity Wallets API"
MIW_OPENAPI_TERM_OF_SERVICES_URL="placeholder-url-to-term-of-services"
MIW_OPENAPI_CONTACT_NAME="placeholder-contact-name"
MIW_OPENAPI_CONTACT_EMAIL="placeholder-contact-email"
MIW_OPENAPI_CONTACT_URL="placeholder-url"
MIW_OPENAPI_LICENSE_NAME="Apache 2.0"
MIW_OPENAPI_LICENSE_URL="placeholder-url-to-license"

# AcaPy connection and configuration
ACAPY_NETWORK_IDENTIFIER="local:test"
ACAPY_BASE_WALLET_API_ADMIN_URL="http://localhost:11000"
ACAPY_BASE_WALLET_ADMIN_API_KEY="ApiKeySecretPlaceholderAcapyBase"
ACAPY_BASE_WALLET_ADMIN_API_KEY="replace-admin-api-key"
ACAPY_API_ADMIN_URL="http://localhost:11003"
ACAPY_ADMIN_API_KEY="ApiKeySecretPlaceholderAcapyMT"
ACAPY_ADMIN_API_KEY="replace-admin-api-key"

# Business partner data pool connection and configuration
BPDM_DATAPOOL_URL="https://catenax-bpdm-int.demo.catena-x.net"
BPDM_AUTH_CLIENT_ID="ClientIdPlaceHolder"
BPDM_AUTH_CLIENT_SECRET="ClientSecretPlaceHolder"
Expand All @@ -28,8 +47,76 @@ BPDM_AUTH_SCOPE="openid"
BPDM_AUTH_URL="https://centralidp.demo.catena-x.net/auth/realms/CX-Central/protocol/openid-connect/token"
BPDM_PULL_DATA_AT_HOUR="23"

# Revocation service connection and configuration
REVOCATION_URL="http://localhost:8086"
REVOCATION_CREATE_STATUS_LIST_CREDENTIAL_AT_HOUR="3"

# Set to OFF in production to avoid extensive logging
LOG_LEVEL_EXPOSED=INFO
LOG_LEVEL_EXPOSED=INFO

# The following variables are required by docker-compose `dev-assets/dev-containers/docker-compose.yml` for the local developement setup.

# Postgres - These must match the values inside MIW_DB_JDBC_URL and QUARKUS_DATASOURCE_JDBC_URL
POSTGRES_USER="postgres"
POSTGRES_PASSWORD="local_password"
PGDATA="/data/postgres-data"

WAIT_HOSTS="local_postgres:5432"
WAIT_HOSTS_TIMEOUT="300"
WAIT_SLEEP_INTERVAL="5"
WAIT_HOST_CONNECT_TIMEOUT="3"

# Keycloak
KEYCLOAK_USER="admin"
KEYCLOAK_PASSWORD="changeme"
KEYCLOAK_IMPORT="/tmp/local-realm.json"

# AcaPy endorser instance
ACAPY_ENDORSER_CONNECTION_PORT="8000"
# It must have the same port as ACAPY_BASE_WALLET_API_ADMIN_URL
ACAPY_ENDORSER_ADMIN_PORT="11000"
# The endpoint url in the DID document
ACAPY_ENDORSER_ENDPOINT="http://local_base_acapy:8000/"
# Random and secure value
ACAPY_ENDORSER_WALLET_KEY="replace-wallet-key"
# The random and secure seed of the base wallet. MIW_VERKEY and MIW_SHORT_DID are generated from this seed
ACAPY_ENDORSER_SEED="replace-seed"
# Indy ledger
ACAPY_ENDORSER_LEDGER_URL="http://dev.greenlight.bcovrin.vonx.io/genesis"
# Random and secure value
ACAPY_ENDORSER_JWT_SECRET="replace-secret"

# AcaPy MT instance
ACAPY_MT_CONNECTION_PORT="8003"
# It must have the same port as ACAPY_API_ADMIN_URL
ACAPY_MT_ADMIN_PORT="11003"
# The endpoint url in the DID document
ACAPY_MT_ENDPOINT="http://local_mt_acapy:8003/"
# Random and secure value
ACAPY_MT_WALLET_KEY="replace-wallet-key"
# The random and secure seed of the management wallet
ACAPY_MT_SEED="replace-seed"
# Indy ledger
ACAPY_MT_LEDGER_URL="http://dev.greenlight.bcovrin.vonx.io/genesis"
# Random and secure value
ACAPY_MT_JWT_SECRET="replace-jwt-secret"

# AcaPy external test instance
ACAPY_TEST_CONNECTION_PORT="8001"
ACAPY_TEST_ADMIN_PORT="11001"
# The endpoint url in the DID document
ACAPY_TEST_ENDPOINT="http://test_acapy:8001/"
# Random and secure value
ACAPY_TEST_WALLET_KEY="replace-wallet-key"
# The random and secure seed of the external/self-managed wallet
ACAPY_TEST_SEED="replace-seed"
# Indy ledger
ACAPY_TEST_LEDGER_URL="http://dev.greenlight.bcovrin.vonx.io/genesis"
# Random and secure value
ACAPY_TEST_ADMIN_KEY="replace-admin-api-key"
# Random and secure value
ACAPY_TEST_JWT_SECRET="replace-jwt-secret"

# Revocation service
# Related to the Postgres configuration
QUARKUS_DATASOURCE_JDBC_URL="jdbc:postgresql://local_postgres:5432/postgres?user=postgres&password=local_password"
2 changes: 1 addition & 1 deletion .github/workflows/kics.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2021-2022 Contributors to the Eclipse Foundation
# Copyright (c) 2021-2023 Contributors to the Eclipse Foundation

# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/trivy.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2021-2022 Contributors to the Eclipse Foundation
# Copyright (c) 2021-2023 Contributors to the Eclipse Foundation

# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down Expand Up @@ -65,7 +65,7 @@ jobs:
with:
sarif_file: "trivy-results1.sarif"

analyze-product-core-managed-identity-wallets-service:
analyze-managed-identity-wallets-service:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
permissions:
Expand All @@ -87,7 +87,7 @@ jobs:
uses: aquasecurity/trivy-action@master
with:
# Path to Docker image
image-ref: "ghcr.io/catenax-ng/product-core-managed-identity-wallets_service:latest"
image-ref: "ghcr.io/catenax-ng/tx-managed-identity-wallets_service:latest"
format: "sarif"
output: "trivy-results3.sarif"
exit-code: "1"
Expand All @@ -99,7 +99,7 @@ jobs:
with:
sarif_file: "trivy-results3.sarif"

analyze-product-core-managed-identity-wallets-service-develop:
analyze-managed-identity-wallets-service-develop:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/develop'
permissions:
Expand All @@ -121,7 +121,7 @@ jobs:
uses: aquasecurity/trivy-action@master
with:
# Path to Docker image
image-ref: "ghcr.io/catenax-ng/product-core-managed-identity-wallets_service:latest-develop"
image-ref: "ghcr.io/catenax-ng/tx-managed-identity-wallets_service:latest-develop"
format: "sarif"
output: "trivy-results3.sarif"
exit-code: "1"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/veracode.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2021-2022 Contributors to the Eclipse Foundation
# Copyright (c) 2021-2023 Contributors to the Eclipse Foundation

# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
16 changes: 16 additions & 0 deletions .idea/codeStyles/Project.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions .idea/codeStyles/codeStyleConfig.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 9 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [3.1.0] - 2023-01-26
- Fix regex bug in utility method
- Rename enviroment variables and secrets
- Set verkey as optional in the verify credentials and presentation method
- Re-enable BPDM scheduler
- Make the values in OpenAPI configurable

## [3.0.0] - 2023-01-09
- Use separate AcaPy instances for Catena-X Endorser wallet and multi-tenant company wallets
- Support endorsement by Catena-X wallet for setting did-communication service endpoints for company wallet
- Use separate AcaPy instances for Base Endorser wallet and multi-tenant company wallets
- Support endorsement by Base wallet for setting did-communication service endpoints for company wallet
- Support acceptance and reception of connection requests and credential issuance from external issuers by company wallets

## [2.2.0] - 2022-12-20
Expand Down
Loading

0 comments on commit f7847ce

Please sign in to comment.