├── .circleci └── config.yml ├── .editorconfig ├── .eslintignore ├── .eslintrc.js ├── .github └── CODEOWNERS ├── .gitignore ├── .ncurc.js ├── .nvmrc ├── .vscode └── settings.json ├── LICENSE ├── README.md ├── docker-contract ├── README.md ├── callback-rules-screen.png ├── components_layout.drawio ├── components_layout.png ├── docker-compose.yml ├── docker │ ├── account-lookup-service │ │ └── default.json │ ├── als-consent-oracle │ │ ├── development.json │ │ └── development_db.json │ ├── central-ledger │ │ └── default.json │ ├── kafka │ │ ├── consumer.properties │ │ ├── producer.properties │ │ ├── server.properties │ │ └── tools-log4j.properties │ ├── sql-als-init │ │ └── 01_permissions.sql │ ├── sql-consent-oracle-init │ │ └── 01_permissions.sql │ ├── sql-init │ │ └── 01_permissions.sql │ └── wait4 │ │ ├── wait4.config.js │ │ └── wait4.js ├── ml-testing-toolkit │ ├── secrets │ │ ├── keygen.sh │ │ ├── privatekey.pem │ │ ├── publickey.cer │ │ └── tls │ │ │ ├── createSecrets.sh │ │ │ ├── hub_client.csr │ │ │ ├── hub_client_cacert.pem │ │ │ ├── hub_client_cakey.key │ │ │ ├── hub_client_key.key │ │ │ ├── hub_server.csr │ │ │ ├── hub_server_cacert.pem │ │ │ ├── hub_server_cacert.srl │ │ │ ├── hub_server_cakey.key │ │ │ ├── hub_server_cert.pem │ │ │ ├── hub_server_key.key │ │ │ └── openssl.conf │ └── spec_files │ │ ├── api_definitions │ │ ├── central_admin_9.3 │ │ │ ├── api_spec.yaml │ │ │ └── response_map.json │ │ ├── fspiop_1.0 │ │ │ ├── api_spec.yaml │ │ │ ├── callback_map.json │ │ │ ├── mockRef.json │ │ │ └── trigger_templates │ │ │ │ └── transaction_request_followup.json │ │ ├── fspiop_1.1 │ │ │ ├── api_spec.yaml │ │ │ ├── callback_map.json │ │ │ ├── mockRef.json │ │ │ └── trigger_templates │ │ │ │ └── transaction_request_followup.json │ │ ├── settlements_1.0 │ │ │ ├── api_spec.yaml │ │ │ ├── mockRef.json │ │ │ └── response_map.json │ │ ├── thirdparty_pisp │ │ │ ├── api_spec.yaml │ │ │ └── callback_map.json │ │ ├── thirdparty_scheme_adapter_sync │ │ │ ├── api_spec.yaml │ │ │ └── response_map.json │ │ └── thirdparty_simulator │ │ │ ├── api_spec.yaml │ │ │ └── response_map.json │ │ ├── reports │ │ └── templates │ │ │ └── newman │ │ │ ├── html_template.html │ │ │ ├── pdf_template.html │ │ │ └── script.js │ │ ├── rules_callback │ │ ├── config.json │ │ └── default.json │ │ ├── rules_response │ │ ├── config.json │ │ ├── default.json │ │ ├── default_pisp_rules.json │ │ └── default_thirdparty_scheme.json │ │ ├── rules_validation │ │ ├── config.json │ │ └── default.json │ │ ├── system_config.json │ │ └── user_config.json ├── pisp-sim │ ├── pisp_backend.env │ ├── pisp_scheme_adapter.env │ ├── rules.json │ └── secrets │ │ ├── jwsSigningKey.key │ │ ├── pisp_client.crt │ │ ├── pisp_client.key │ │ ├── pisp_server.crt │ │ └── pisp_server.key └── postman │ ├── .gitignore │ ├── Dockerfile │ ├── OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json │ ├── environments │ └── Mojaloop-Local-Docker-Compose.postman_environment.json │ ├── scripts │ ├── _00_seed_all.sh │ ├── _01_seed_hub_account.sh │ └── _02_seed_oracle.sh │ └── thirdparty-simulator.postman_collection.json ├── docker-live ├── .gitignore ├── Makefile ├── README.md ├── _test_oracle.sh ├── _test_transfer.sh ├── charts-base │ ├── deployment_setup.yaml │ └── kafka_values.yaml ├── charts-participant │ ├── Chart.yaml │ ├── configs │ │ └── thirdparty-scheme-adapter.json │ ├── templates │ │ ├── mojaloop-simulator.yaml │ │ ├── redis.yaml │ │ ├── sdk-scheme-adapter.yaml │ │ └── thirdparty-scheme-adapter.yaml │ ├── values_dfspa.yml │ ├── values_dfspb.yml │ └── values_pispa.yml ├── charts-switch │ ├── Chart.yaml │ ├── configs │ │ ├── consent-oracle-production_db.json │ │ └── thirdparty-api-adapter.json │ └── templates │ │ ├── account-lookup-service.yaml │ │ ├── als-consent-oracle.yaml │ │ ├── auth-service.yaml │ │ ├── central-ledger.yaml │ │ ├── ml-api-adapter.yaml │ │ ├── oracle-simulator.yaml │ │ ├── quoting-service.yaml │ │ ├── thirdparty-api-adapter.yaml │ │ └── transaction-request-service.yaml ├── deployment_setup.yaml ├── deployment_simulator.yaml └── kafka_values.yaml ├── docker-local ├── README.md ├── components_layout.drawio ├── components_layout.png ├── dfsp_a │ ├── dfsp_a_backend.env │ ├── dfsp_a_scheme_adapter.env │ ├── dfsp_a_thirdparty_sdk.json │ ├── rules.json │ └── secrets │ │ ├── dfsp_a_client.crt │ │ ├── dfsp_a_client.key │ │ ├── dfsp_a_server.crt │ │ ├── dfsp_a_server.key │ │ ├── dfsp_a_server_ca.crt │ │ ├── dfsp_a_server_intermediate.crt │ │ ├── dfsp_a_server_root.crt │ │ └── jwsSigningKey.key ├── dfsp_b │ ├── dfsp_b_backend.env │ ├── dfsp_b_scheme_adapter.env │ ├── dfsp_b_thirdparty_sdk.json │ ├── rules.json │ └── secrets │ │ ├── dfsp_b_client.crt │ │ ├── dfsp_b_client.key │ │ ├── dfsp_b_server.crt │ │ ├── dfsp_b_server.key │ │ └── jwsSigningKey.key ├── docker-clean-all.sh ├── docker-compose.ttk-cli.yml ├── docker-compose.yml ├── docker │ ├── account-lookup-service │ │ └── default.json │ ├── als-consent-oracle │ │ └── default.json │ ├── auth-service │ │ └── default.json │ ├── central-ledger │ │ └── default.json │ ├── central-settlement │ │ └── default.json │ ├── kafka │ │ ├── consumer.properties │ │ ├── producer.properties │ │ ├── server.properties │ │ └── tools-log4j.properties │ ├── ml-api-adapter │ │ └── default.json │ ├── quoting-service │ │ ├── default.json │ │ └── rules.json │ ├── sql-als-init │ │ └── 01_permissions.sql │ ├── sql-auth-service-init │ │ └── 01_permissions.sql │ ├── sql-consent-oracle-init │ │ └── 01_permissions.sql │ ├── sql-init │ │ └── 01_permissions.sql │ ├── thirdparty-api-svc │ │ └── default.json │ ├── transaction-requests-service │ │ └── default.json │ └── wait4 │ │ ├── wait4.config.js │ │ └── wait4.js ├── ml-bootstrap-config.json5 ├── ml-testing-toolkit │ ├── secrets │ │ ├── keygen.sh │ │ ├── privatekey.pem │ │ ├── publickey.cer │ │ └── tls │ │ │ ├── createSecrets.sh │ │ │ ├── hub_client.csr │ │ │ ├── hub_client_cacert.pem │ │ │ ├── hub_client_cakey.key │ │ │ ├── hub_client_key.key │ │ │ ├── hub_server.csr │ │ │ ├── hub_server_cacert.pem │ │ │ ├── hub_server_cacert.srl │ │ │ ├── hub_server_cakey.key │ │ │ ├── hub_server_cert.pem │ │ │ ├── hub_server_key.key │ │ │ └── openssl.conf │ └── spec_files │ │ ├── api_definitions │ │ ├── central_admin_9.3 │ │ │ ├── api_spec.yaml │ │ │ └── response_map.json │ │ ├── fspiop_1.0 │ │ │ ├── api_spec.yaml │ │ │ ├── callback_map.json │ │ │ ├── mockRef.json │ │ │ └── trigger_templates │ │ │ │ └── transaction_request_followup.json │ │ ├── fspiop_1.1 │ │ │ ├── api_spec.yaml │ │ │ ├── callback_map.json │ │ │ ├── mockRef.json │ │ │ └── trigger_templates │ │ │ │ └── transaction_request_followup.json │ │ ├── settlements_1.0 │ │ │ ├── api_spec.yaml │ │ │ ├── mockRef.json │ │ │ └── response_map.json │ │ ├── thirdparty_pisp │ │ │ ├── api_spec.yaml │ │ │ └── callback_map.json │ │ ├── thirdparty_sdk_outbound_0.1.1 │ │ │ └── api_spec.yaml │ │ └── thirdparty_simulator │ │ │ ├── api_spec.yaml │ │ │ └── response_map.json │ │ ├── reports │ │ └── templates │ │ │ └── newman │ │ │ ├── html_template.html │ │ │ ├── pdf_template.html │ │ │ └── script.js │ │ ├── rules_callback │ │ ├── config.json │ │ └── default.json │ │ ├── rules_response │ │ ├── config.json │ │ ├── default.json │ │ └── default_pisp_rules.json │ │ ├── rules_validation │ │ ├── config.json │ │ └── default.json │ │ ├── system_config.json │ │ └── user_config.json ├── pisp │ ├── pisp_backend.env │ ├── pisp_rules.json │ ├── pisp_scheme_adapter.env │ ├── pisp_thirdparty_sdk.json │ └── secrets │ │ ├── jwsSigningKey.key │ │ ├── pisp_client.crt │ │ ├── pisp_client.key │ │ ├── pisp_server.crt │ │ └── pisp_server.key ├── postman │ ├── .gitignore │ ├── Dockerfile │ ├── LICENSE.md │ ├── OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json │ ├── PISP Local Playground.postman_collection.json │ ├── PISP.postman_collection.json.postman_collection.json │ ├── README.md │ ├── environments │ │ ├── Mojaloop-Local-Docker-Compose.postman_environment.json │ │ ├── Mojaloop-Local-Docker-Compose.postman_environment_DFSP_PAYEE.json │ │ ├── Mojaloop-Local-Docker-Compose.postman_environment_DFSP_PAYER.json │ │ ├── Mojaloop-Local-Docker-Compose.postman_environment_DFSP_SIMULATOR.json │ │ ├── Mojaloop-Local-Docker-Compose.postman_environment_PISP.json │ │ └── Mojaloop-Local.postman_environment.json │ └── scripts │ │ ├── _00_seed_all.sh │ │ ├── _01_seed_hub_account.sh │ │ ├── _02_seed_oracle.sh │ │ ├── _03_seed_dfspa.sh │ │ ├── _04_seed_dfspb.sh │ │ ├── _05_seed_pisp.sh │ │ ├── _06_seed_dfsp_simulator.sh │ │ ├── _07_seed_dfsp_a_msisdn.sh │ │ ├── _08_seed_dfsp_b_msisdn.sh │ │ ├── _09_seed_dfsp_simulator_msisdn.sh │ │ ├── _10_seed_pisp_msisdn.sh │ │ ├── _11_seed_dfsp_backend_parties.sh │ │ ├── _12_seed_settlement_models.sh │ │ ├── _13_seed_centralAuth.sh │ │ ├── test-E2E-transaction-req-initiated-by-PISP.sh │ │ ├── testE2ETransfers.sh │ │ └── testEvents.js └── test-runner │ ├── secrets │ ├── keygen.sh │ ├── privatekey.pem │ ├── publickey.cer │ └── tls │ │ ├── createSecrets.sh │ │ ├── hub_client.csr │ │ ├── hub_client_cacert.pem │ │ ├── hub_client_cakey.key │ │ ├── hub_client_key.key │ │ ├── hub_server.csr │ │ ├── hub_server_cacert.pem │ │ ├── hub_server_cacert.srl │ │ ├── hub_server_cakey.key │ │ ├── hub_server_cert.pem │ │ ├── hub_server_key.key │ │ └── openssl.conf │ └── spec_files │ ├── api_definitions │ ├── als_admin_1.1 │ │ └── api_spec.yaml │ ├── central_admin_1.0 │ │ ├── api_spec.yaml │ │ └── response_map.json │ ├── central_admin_old_9.3 │ │ ├── api_spec.yaml │ │ └── response_map.json │ ├── fspiop_1.0 │ │ ├── api_spec.yaml │ │ ├── callback_map.json │ │ ├── mockRef.json │ │ └── trigger_templates │ │ │ ├── transaction_request_followup.json │ │ │ └── transaction_request_followup_quotes_only.json │ ├── fspiop_1.1 │ │ ├── api_spec.yaml │ │ ├── callback_map.json │ │ ├── mockRef.json │ │ └── trigger_templates │ │ │ └── transaction_request_followup.json │ ├── mojaloop_sdk_outbound_scheme_adapter_1.0 │ │ ├── api_spec.yaml │ │ ├── mockRef.json │ │ └── response_map.json │ ├── mojaloop_simulator_0.1 │ │ └── api_spec.yaml │ ├── mojaloop_simulator_sim_1.4 │ │ ├── api_spec.yaml │ │ ├── mockRef.json │ │ └── response_map.json │ ├── payment_manager_1.4 │ │ └── api_spec.yaml │ ├── settlements_1.0 │ │ ├── api_spec.yaml │ │ ├── mockRef.json │ │ └── response_map.json │ ├── settlements_2.0 │ │ ├── api_spec.yaml │ │ ├── mockRef.json │ │ └── response_map.json │ └── thirdparty_sdk_outbound_0.1 │ │ └── api_spec.yaml │ ├── reports │ └── templates │ │ ├── newman │ │ ├── html_template.html │ │ └── pdf_template.html │ │ └── testcase_definition │ │ └── table_view.html │ ├── rules_callback │ ├── config.json │ ├── default.json │ └── p2p-limit.json │ ├── rules_forward │ ├── config.json │ └── default.json │ ├── rules_response │ ├── config.json │ └── default.json │ ├── rules_validation │ ├── config.json │ ├── default.json │ └── p2p-limit.json │ ├── system_config.json │ └── user_config.json ├── docs ├── README.md ├── design-decisions │ ├── README.md │ ├── tandem_async_proxy.puml │ ├── tandem_clashing_endpoints.puml │ ├── tandem_generic_pattern.puml │ └── tandem_sync_client_server.puml ├── identifiers.md ├── out │ └── design-decisions │ │ ├── tandem_async_proxy.svg │ │ ├── tandem_clashing_endpoints.svg │ │ ├── tandem_generic_pattern.svg │ │ └── tandem_sync_client_server.svg ├── participant_endpoint_enums.md ├── roles_and_endpoints.md ├── scheme-adapters │ ├── README.md │ ├── adapters-layout.drawio │ └── adapters-layout.png └── scripts │ └── _update_seq.sh ├── index.html ├── jest.config.js ├── package-lock.json ├── package.json ├── scripts ├── _build_plantuml_all.sh ├── _build_plantuml_diff.sh ├── _configure_web_simulator.sh ├── _decodeKeyHandleId.js ├── _render_svg.js ├── _reset_test_state.sh ├── _restart_reseed_docker_local.sh ├── _setup_hosts_file.sh ├── _wait4_all.js └── _wait4_docker_contract.js ├── sonar-project.properties ├── src ├── Template.ts ├── index.ts ├── interface │ ├── thirdparty-dfsp-api.template.yaml │ ├── thirdparty-dfsp-api.yaml │ ├── thirdparty-pisp-api.template.yaml │ ├── thirdparty-pisp-api.yaml │ ├── ttk-thirdparty-api-template.yaml │ ├── ttk-thirdparty-api.yaml │ ├── ttk-thirdparty-sim-api-template.yaml │ └── ttk-thirdparty-sim-api.yaml └── seed │ ├── README.md │ ├── cli.ts │ ├── config.ts │ ├── index.ts │ ├── requests.ts │ ├── runResult.ts │ ├── steps │ ├── genericSteps.ts │ ├── hubSteps.ts │ ├── oracleSteps.ts │ ├── participantSteps.ts │ └── partySteps.ts │ ├── types.ts │ └── utils.ts ├── swagger_ui ├── favicon-16x16.png ├── oauth2-redirect.html ├── openapi.yaml ├── swagger-ui-bundle.js ├── swagger-ui-bundle.js.map ├── swagger-ui-standalone-preset.js ├── swagger-ui-standalone-preset.js.map ├── swagger-ui.css ├── swagger-ui.css.map ├── swagger-ui.js └── swagger-ui.js.map ├── test ├── contract │ ├── ConsentOracle.test.ts │ ├── DFSPAccountLinking.test.ts │ ├── P2PTransfer.test.ts │ ├── PISPAccountLinking.test.ts │ ├── PISPTransaction.test.ts │ ├── PISPTransfer.test.ts │ ├── PISPTransferFailure.test.ts │ ├── PostAuthorizations.test.ts │ ├── ThirdpartyRequestsTransaction.test.ts │ ├── ThirdpartySchemeAdapterInterface.test.ts │ └── data │ │ └── mockErrorData.json ├── e2e-ttk │ ├── .gitignore │ ├── collection.json │ └── environment.json ├── e2e │ ├── ConsentOracle.test.ts │ ├── P2PTransfer.test.ts │ ├── PISP_Discovery.test.ts │ ├── PISP_Linking.test.ts │ ├── PISP_Prelinking.test.ts │ ├── TestEnv.ts │ ├── depPISP_3PR_Transfer.test.ts │ ├── expected.ts │ └── pispLinkAndTransfer.test.ts ├── features │ └── template.scenario.feature ├── step-definitions │ └── template.step.ts └── unit │ └── index.test.ts └── tsconfig.json /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | end_of_line = lf 5 | insert_final_newline = true 6 | trim_trailing_whitespace = true 7 | charset = utf-8 8 | 9 | [{*.js,*.ts,package.json,*.yml,*.cjson}] 10 | indent_style = space 11 | indent_size = 2 12 | 13 | [*.md] 14 | trim_trailing_whitespace = false -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | node_modules/**/*.js 2 | coverage/* 3 | .circleci/* -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | parser: '@typescript-eslint/parser', // Specifies the ESLint parser 3 | plugins: [ 4 | 'cucumber', 5 | '@typescript-eslint' 6 | ], 7 | extends: [ 8 | 'eslint:recommended', 9 | 'standard', 10 | 'plugin:@typescript-eslint/eslint-recommended', 11 | 'plugin:@typescript-eslint/recommended', 12 | //'prettier/@typescript-eslint', // Uses eslint-config-prettier to disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier 13 | //'plugin:prettier/recommended', // Enables eslint-plugin-prettier and displays prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array. 14 | // Enforces ES6+ import/export syntax 15 | 'plugin:import/errors', 16 | 'plugin:import/warnings', 17 | 'plugin:import/typescript', 18 | ], 19 | parserOptions: { 20 | ecmaVersion: 2018, // Allows for the parsing of modern ECMAScript features 21 | sourceType: 'module', // Allows for the use of imports 22 | }, 23 | rules: { 24 | indent: 'off', 25 | '@typescript-eslint/indent': ['error', 2], 26 | '@typescript-eslint/no-explicit-any': 'error', 27 | '@typescript-eslint/no-var-requires': 'off', 28 | '@typescript-eslint/no-use-before-define': 'off', 29 | 'no-console': 'warn', 30 | quotes: ['error', 'single'], 31 | 'linebreak-style': ['error', 'unix'], 32 | semi: ['error', 'never'], 33 | 'cucumber/async-then': 2, 34 | 'cucumber/expression-type': 2, 35 | 'cucumber/no-restricted-tags': [2, 'wip', 'broken', 'foo'], 36 | 'cucumber/no-arrow-functions': 2 37 | } 38 | }; -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | 2 | * @kleyow @elnyry-sam-k 3 | -------------------------------------------------------------------------------- /.ncurc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | reject: [ 3 | // Upgrading past husky@4 to involves a full config migration with no current and apparent benefit. 4 | // So we are just sticking to husky@4.x.x for the time being. 5 | 'husky', 6 | // Upgrading past jest|ts-jest|@types/jest@26 introduces a lot of breaking changes to current tests. 7 | 'jest', 8 | 'ts-jest', 9 | '@types/jest' 10 | ] 11 | } 12 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | v16.15.0 2 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "plantuml.diagramsRoot": "docs", 3 | "plantuml.exportFormat": "png", 4 | "plantuml.exportOutDir": "docs/out", 5 | "cSpell.words": [ 6 | "Thirdparty" 7 | ] 8 | } -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | # LICENSE 2 | 3 | Copyright © 2020-2025 Mojaloop Foundation 4 | 5 | The Mojaloop files are made available by the Mojaloop Foundation under the Apache License, Version 2.0 6 | (the "License") and you may not use these files except in compliance with the [License](http://www.apache.org/licenses/LICENSE-2.0). 7 | 8 | You may obtain a copy of the License at [http://www.apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0) 9 | 10 | Unless required by applicable law or agreed to in writing, the Mojaloop files are distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the [License](http://www.apache.org/licenses/LICENSE-2.0). 11 | -------------------------------------------------------------------------------- /docker-contract/callback-rules-screen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mojaloop/pisp-project/01f8d384d54ef8e86821a2149143d741c5cc7b2b/docker-contract/callback-rules-screen.png -------------------------------------------------------------------------------- /docker-contract/components_layout.drawio: -------------------------------------------------------------------------------- 1 | 2 | 1VrbcqM4EP0aP5Lifnl0rrNV2dqd8tTM7r7JRgElgBgQcbxfvxIIMEg4eAKsk5fgpnU7p7vVarQybuK3hwyk4e/Yh9FKV/23lXG70nVNtzz6j0kOlcRw1EoQZMjnSq1gg/6FXFirFciHeUeRYBwRlHaFO5wkcEc6MpBleN9Ve8JRd9QUBHxEtRVsdiCCgtoP5JOQS23LbF98gSgI66E1m684BrU27zkPgY/3RyLjbmXcZBiT6il+u4ERQ68Gpmp3P/C2mVkGEzKmgWVVLV5BVPDV8YmRQ73cIMNFujKun3BCNlxsigPxsV9hRuCbjAewjWB/pdRGII4hyQ5Uj7dyHbdqx83D9ThY+xZsXeWy8Ahnm8sA5zdoum4RoA8chAEEVWMsIvMhoNXmUTuIKiJgyBAw3EkgMCUQ2BEd4zpkTwF7qiXMKjro2D8LXL9Q8tJ511RBM9O39mXdS4rylCrFdW90blWH3UGo+HjkHh2UjcSHbPYqfb0PEYGbFOzY2z2NQGzaJKarvdXoI2MHUV9eRyhIqIxgpuCDPCx70JoBOsw2VtHndpjDLoWaJ9qwJ2PQ1qZgcLRbn7HU8824h4HuWgIImi1zZPvKmgIFe9COp7FaJYM+ygdttwc4jfUpe9wdIkTtNXvfVreVYT9u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oH0slXVW7n9DV+9sB/dlef6vU21uExt1/ 3 | -------------------------------------------------------------------------------- /docker-contract/components_layout.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mojaloop/pisp-project/01f8d384d54ef8e86821a2149143d741c5cc7b2b/docker-contract/components_layout.png -------------------------------------------------------------------------------- /docker-contract/docker/account-lookup-service/default.json: -------------------------------------------------------------------------------- 1 | { 2 | "ADMIN_PORT": 4001, 3 | "API_PORT": 4002, 4 | "DATABASE": { 5 | "DIALECT": "mysql", 6 | "HOST": "mysql-als", 7 | "PORT": 3306, 8 | "USER": "account_lookup", 9 | "PASSWORD": "password", 10 | "DATABASE": "account_lookup", 11 | "POOL_MIN_SIZE": 10, 12 | "POOL_MAX_SIZE": 10, 13 | "ACQUIRE_TIMEOUT_MILLIS": 30000, 14 | "CREATE_TIMEOUT_MILLIS": 30000, 15 | "DESTROY_TIMEOUT_MILLIS": 5000, 16 | "IDLE_TIMEOUT_MILLIS": 30000, 17 | "REAP_INTERVAL_MILLIS": 1000, 18 | "CREATE_RETRY_INTERVAL_MILLIS": 200, 19 | "DEBUG": false 20 | }, 21 | "DISPLAY_ROUTES": true, 22 | "RUN_MIGRATIONS": true, 23 | "ENDPOINT_CACHE_CONFIG": { 24 | "expiresIn": 180000, 25 | "generateTimeout": 30000 26 | }, 27 | "ERROR_HANDLING": { 28 | "includeCauseExtension": false, 29 | "truncateExtensions": true 30 | }, 31 | "SWITCH_ENDPOINT": "http://central-ledger:3001", 32 | "INSTRUMENTATION": { 33 | "METRICS": { 34 | "DISABLED": false, 35 | "labels": { 36 | "fspId": "*" 37 | }, 38 | "config": { 39 | "timeout": 5000, 40 | "prefix": "moja_", 41 | "defaultLabels": { 42 | "serviceName": "account-lookup-service" 43 | } 44 | } 45 | } 46 | }, 47 | "ENDPOINT_SECURITY":{ 48 | "JWS": { 49 | "JWS_SIGN": false, 50 | "FSPIOP_SOURCE_TO_SIGN": "switch", 51 | "JWS_SIGNING_KEY_PATH": "secrets/jwsSigningKey.key" 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /docker-contract/docker/als-consent-oracle/development.json: -------------------------------------------------------------------------------- 1 | { 2 | "PORT": 3000, 3 | "HOST": "0.0.0.0", 4 | "INSPECT": { 5 | "DEPTH": 4, 6 | "SHOW_HIDDEN": false, 7 | "COLOR": true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /docker-contract/docker/als-consent-oracle/development_db.json: -------------------------------------------------------------------------------- 1 | { 2 | "client": "mysql", 3 | "version": "5.5", 4 | "connection": { 5 | "host": "als-consent-oracle-mysql", 6 | "port": 3306, 7 | "user": "als-consent-oracle", 8 | "password": "password", 9 | "database": "als-consent-oracle", 10 | "timezone": "UTC" 11 | }, 12 | "pool": { 13 | "min": 10, 14 | "max": 10, 15 | "acquireTimeoutMillis": 30000, 16 | "createTimeoutMillis": 30000, 17 | "destroyTimeoutMillis": 5000, 18 | "idleTimeoutMillis": 30000, 19 | "reapIntervalMillis": 1000, 20 | "createRetryIntervalMillis": 200 21 | }, 22 | "migrations": { 23 | "tableName": "als-consent-oracle", 24 | "loadExtensions": [".ts"] 25 | }, 26 | "seeds": { 27 | "loadExtensions": [".ts"] 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /docker-contract/docker/kafka/consumer.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | # see org.apache.kafka.clients.consumer.ConsumerConfig for more details 16 | 17 | # list of brokers used for bootstrapping knowledge about the rest of the cluster 18 | # format: host1:port1,host2:port2 ... 19 | bootstrap.servers=localhost:9092 20 | 21 | # consumer group id 22 | group.id=test-consumer-group 23 | 24 | # What to do when there is no initial offset in Kafka or if the current 25 | # offset does not exist any more on the server: latest, earliest, none 26 | #auto.offset.reset= 27 | -------------------------------------------------------------------------------- /docker-contract/docker/kafka/producer.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | # see org.apache.kafka.clients.producer.ProducerConfig for more details 16 | 17 | ############################# Producer Basics ############################# 18 | 19 | # list of brokers used for bootstrapping knowledge about the rest of the cluster 20 | # format: host1:port1,host2:port2 ... 21 | bootstrap.servers=localhost:9092 22 | 23 | # specify the compression codec for all data generated: none, gzip, snappy, lz4, zstd 24 | compression.type=none 25 | 26 | # name of the partitioner class for partitioning events; default partition spreads data randomly 27 | #partitioner.class= 28 | 29 | # the maximum amount of time the client will wait for the response of a request 30 | #request.timeout.ms= 31 | 32 | # how long `KafkaProducer.send` and `KafkaProducer.partitionsFor` will block for 33 | #max.block.ms= 34 | 35 | # the producer will wait for up to the given delay to allow other records to be sent so that the sends can be batched together 36 | #linger.ms= 37 | 38 | # the maximum size of a request in bytes 39 | #max.request.size= 40 | 41 | # the default batch size in bytes when batching multiple records sent to a partition 42 | #batch.size= 43 | 44 | # the total bytes of memory the producer can use to buffer records waiting to be sent to the server 45 | #buffer.memory= 46 | -------------------------------------------------------------------------------- /docker-contract/docker/kafka/tools-log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | log4j.rootLogger=WARN, stderr 17 | 18 | log4j.appender.stderr=org.apache.log4j.ConsoleAppender 19 | log4j.appender.stderr.layout=org.apache.log4j.PatternLayout 20 | log4j.appender.stderr.layout.ConversionPattern=[%d] %p %m (%c)%n 21 | log4j.appender.stderr.Target=System.err 22 | -------------------------------------------------------------------------------- /docker-contract/docker/sql-als-init/01_permissions.sql: -------------------------------------------------------------------------------- 1 | ALTER USER 'account_lookup'@'%' identified WITH mysql_native_password by 'password'; 2 | FLUSH PRIVILEGES; -------------------------------------------------------------------------------- /docker-contract/docker/sql-consent-oracle-init/01_permissions.sql: -------------------------------------------------------------------------------- 1 | ALTER USER 'als-consent-oracle'@'%' identified WITH mysql_native_password by 'password'; 2 | FLUSH PRIVILEGES; 3 | -------------------------------------------------------------------------------- /docker-contract/docker/sql-init/01_permissions.sql: -------------------------------------------------------------------------------- 1 | ALTER USER 'central_ledger'@'%' identified WITH mysql_native_password by 'password'; 2 | FLUSH PRIVILEGES; -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/keygen.sh: -------------------------------------------------------------------------------- 1 | #openssl genrsa -des3 -out privatekey.pem 2048 2 | openssl genrsa -out privatekey.pem 2048 3 | openssl req -new -x509 -key privatekey.pem -out publickey.cer -days 1825 -subj "/CN=testingtoolkitdfsp/C=US/ST=Ohio/L=Columbus/O=Testing Toolkit/OU=Payments" 4 | #openssl rsa -in privatekey.pem -pubout -out publickey.cer 5 | #openssl rsa -in privatekey.pem -out privatekey.pem 6 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/privatekey.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN RSA PRIVATE KEY----- 2 | MIIEpQIBAAKCAQEAwczEjlUeOPutgPRlpZSbcbJJwsmmxsBfoPDw1sjBiR7L6Doh 3 | VqKd810+TmiDRYgCzOLabje/mtLiDC95MtuPF5yUiVE04ar6Ny5pZLxJEnbDEOAE 4 | TxOn1gzCKeRHYOcgybDi6TLhnvyFyIaXKzyBhEYvxI8VvRV11UawLqvpgVrdsbZy 5 | 1FQOMLq7OB+J6qC7fhR61F6Wu45RZlZMB482c658P7dCQCdQtEMEF5kuBNB/JuUR 6 | e0qKjl2udKVL3wgBC7J7o7Tx8kY5T63q/ZC3TfoTclFeXtIePt8Eu74u3d6WpSWb 7 | Z12mewRBVPtmbGHgEXpih3uayaqIeC8Dc4zO5QIDAQABAoIBAQCPMGJR36YS6DGL 8 | xAeOTbyERvykxSVKWDzPxvXLXE1SqMRz8u9K+Z/GfjBY8nN7XkDjbQGCygHxvLpz 9 | 0me0IfEZuwEsbCmsSw3Q06PfYBaFY+ZAg6PrYVRynL6hAR+UA3GAVAdz0bpOI7od 10 | LQRoV65CMzF8A1RGfqKvUClAcph2j4lbjjRZ1OExDdcbRCI4h9qgGOMo9o9OEB1X 11 | HHiPhtS1ZwjczqCyJHkkHbOgYNPN7SDy8vHFOVjMDIADF+S/NLrxGUUIUDvNMnGV 12 | D4G8thQD2zSatMjlbJJ+oNt++T/SJMSIiuQTB5zy/KpiMPUN+AXhq5h/dHDcFXhA 13 | ng2deEcJAoGBAOQr1g/s/3V32tQpYloTMOPqIJoVnZnlcXbKy3nWLuOrkVlM0x3V 14 | AEwC7ntb2eOSQ331AvBd/EESgtZr1jvxfsHG+MjwEylcOE33g4MqCKthGcnFA8zG 15 | Z5h6OqTtHdY1bmuiisPvBA4/x2o7mWJz35vT0Sny3cci3f2D6pmPpuq3AoGBANlv 16 | wjWgeDQSR8nTdM1P7zepVdN51f8Fl3r49kMhceVHdwL5iL7q4GkxUgpCyBkFoElW 17 | vmsLgR1fnb+qBtF2kvljQtlRrlgwz1GgYNhp+aAgcAjvQ9fQcvCLr1leXzf6VBHx 18 | jXEIUAlAJVlJ5gWKlDNK9ytjurOvOXipRC4GQKdDAoGBALNOt6RATOjVTYSZGQ9M 19 | MYmKPiCYiAeexbHi4FBYvvRvqYOR2f6BmwAg9aS/o9Uw5hUf7DVUxp2knGlAyVTG 20 | DSTe5jeSYpyIOj8bGaCD8dgsMIXda4ULDfJHa7qcFGx4BNRVIdOkC33fJSkYuQsj 21 | oD/nD2J1109c2TMW7c/LkhK1AoGAUD8xws7tbfJNMkxrMBbPJ5DETx8I/myW4lid 22 | slrWiRLd9mgXsrZGiiwcphLNfIaaCFcOQb1mMmwGcSUUDRwg1A9xLXk6yeuBqBNz 23 | iotaCGHQV0vOkwioUuSKm4X7yFIH0vN+CvhRaYiWACUI0oS5e1CwdgABeK0znbeC 24 | pSXDmLcCgYEA1ls595Ue5cUCmFDvpCIifsATNOMPguKeFuPbYSItQod3P3Bj6txV 25 | phe0jUtWPhIF3I0XOtea2Usvbrj64GMNWLaeK2pdsbIWBlsu2tuqaAfKYiGpGCAh 26 | QWGAPwZ4w7Z3nmA6IhaD6zUnzBGserHv59XttKK0AiQwYMn6UvUIq0M= 27 | -----END RSA PRIVATE KEY----- 28 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/publickey.cer: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIDbjCCAlYCCQDudXfDH36/JjANBgkqhkiG9w0BAQsFADB5MRswGQYDVQQDDBJ0 3 | ZXN0aW5ndG9vbGtpdGRmc3AxCzAJBgNVBAYTAlVTMQ0wCwYDVQQ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bSqy0BhQdKYDcxulaQuqibwD 20 | i0dWSdTWoseAbUqp2ACc6aF/ 21 | -----END CERTIFICATE----- 22 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/tls/createSecrets.sh: -------------------------------------------------------------------------------- 1 | OUTPUT_DIR="." 2 | 3 | rm *.key *.pem *.csr *.crt *.srl 4 | 5 | ## Generating Server CA certificate 6 | openssl genrsa -out "$OUTPUT_DIR/hub_server_cakey.key" 4096 7 | openssl req -new -sha256 -config openssl.conf -nodes -x509 -days 10000 -extensions v3_ca -key "$OUTPUT_DIR/hub_server_cakey.key" -out "$OUTPUT_DIR/hub_server_cacert.pem" -subj '/CN=hubserverca/C=US/ST=Ohio/L=Columbus/O=Hub Server CA/OU=Payments' 8 | 9 | ## Generate server key 10 | openssl genrsa -out "$OUTPUT_DIR/hub_server_key.key" 4096 11 | 12 | ## Generate server csr 13 | openssl req -new -sha256 -config openssl.conf -key hub_server_cakey.key -subj "/C=US/ST=CA/O=Hub Server/CN=mojaloop-testing-toolkit" -out hub_server.csr 14 | 15 | ## Sign server cert 16 | openssl x509 -req -days 3650 -sha256 -extfile openssl.conf -extensions v3_req -in hub_server.csr -signkey hub_server_key.key -CA hub_server_cacert.pem -CAkey hub_server_cakey.key -CAcreateserial -out hub_server_cert.pem 17 | 18 | ## Generating Client CA certificate 19 | openssl genrsa -out "$OUTPUT_DIR/hub_client_cakey.key" 4096 20 | openssl req -new -sha256 -config openssl.conf -nodes -x509 -days 10000 -extensions v3_ca -key "$OUTPUT_DIR/hub_client_cakey.key" -out "$OUTPUT_DIR/hub_client_cacert.pem" -subj '/CN=hubclientca/C=US/ST=Ohio/L=Columbus/O=Hub Client CA/OU=Payments' 21 | 22 | ## Generate client key 23 | openssl genrsa -out "$OUTPUT_DIR/hub_client_key.key" 4096 24 | 25 | ## Generate client csr 26 | openssl req -new -sha256 -key hub_client_key.key -out "$OUTPUT_DIR/hub_client.csr" -subj '/CN=hubclient/C=US/ST=Ohio/L=Columbus/O=Hub Client/OU=Payments/emailAddress=admin@hubclient.com' 27 | 28 | 29 | #openssl x509 -in hub_server_cert.pem -text -noout -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/tls/hub_client.csr: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE REQUEST----- 2 | MIIE1TCCAr0CAQAwgY8xEjAQBgNVBAMMCWh1YmNsaWVudDELMAkGA1UEBhMCVVMx 3 | DTALBgNVBAgMBE9oaW8xETAPBgNVBAcMCENvbHVtYnVzMRMwEQYDVQQKDApIdWIg 4 | Q2xpZW50MREwDwYDVQQLDAhQYXltZW50czEiMCAGCSqGSIb3DQEJARYTYWRtaW5A 5 | aHViY2xpZW50LmNvbTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMXw 6 | zRGgrVa7eiuO6ZgNc16gLTW+akYh86CDIiIYtDIKUcLsmViLVXqMdPbaheMPTNr3 7 | PGhAYyMjRUSf/PtxokTexyfr2ATF1JL8MC9ea6y4nnKfuf5mHdEyWCEGMywNPsVO 8 | 2Dvf8w7RmV+Do/HzE0479lK/JqFAOxeSrNiQXhmJ1gv6Km7E4tuvqVLDhry55LWN 9 | MSpT8dcHoYylzvtutXTlYTZfPAN9J7cqHS/BdXPOw5GM0104RKctR6ma6bCt3OvV 10 | BqrKsvJ+cKOmfj86jYottMWKLlDYkszikqsKOQebqjNj8wDTNX4JhETkjF2WlemN 11 | h4FBTmzmE88ugUY3b+PsySZxsbL1UURZINofsZTGyjV6GETKeGXVbIvJAY4+xpES 12 | vv0QhBjz7aX4rNngbERuMkXa3WF4EYkU1Yl61XnWvYSm5MAF2j+oGoOD4SgxXJxm 13 | Xs5jS4wAYBPA1VkafaXQQ/cCrD+F3kxSy+CHnuTaPt/Dqq89zvN9yMcqwkdIChfY 14 | og8NP01aMe84rkcfQpBVUe9wkgo/lsFqBE9lRuuxhFpGyhNL1g9VJ/DSVIkZm8Ba 15 | 1jcGbl25SdtU0FswGLkl45JpQtjvErdldNerhcxHoAVA1AlqRS71lV8Uq5TqdLHh 16 | fMz8JSV9YEyAc4gP2YBOfonHFtXGyelYHukblHi3AgMBAAGgADANBgkqhkiG9w0B 17 | AQsFAAOCAgEAqHiCShmAw+D0MBPTll4bJMeIk6PhlhV/OaLakDoAu4HjQgaMODP2 18 | uJjX07jRQFiMPFNJNgTJHfdl/azSIsfI56/6XVmUwYENDzwUVHkBo0d9XSCPX+cn 19 | gFRc6J2ccGJO0O+ac8lsvIrAWd72chbhAxm09xQ/iz4aT+zwc7TrpYtn6mdfTkWD 20 | xrNTcuUrT2CBNQKpO3m2oA/lJbnlfoz+m16hJQmmLX5i+qympS9EmH9un5yH4Lx+ 21 | EuiMcuKad4kxQF27hnnp9z/WQr/DR6Y826NpqWDA5gvJcCXo+ACfl+JIQSN54Z68 22 | J0C+1idE5lY12jgXUGBMn3gwAA39hucPDVu4br0Q6oOnYLD8ZnVpsy1Pvf1ekIvb 23 | PJEYOUu8lsuwJQcpdLwrEV2WDFsxRalYTnvYazv+dtBmidSHziZythQZNPcDQNvN 24 | 8OmwEE0t+o9TpEgHRVLonwRm3AfHiEmD/fsj0yylZzg7hSDa9QaQ1TW/nCC/3KfZ 25 | ASztRCe+teibaLbRiLNUwhI+kkYTy1jibeDtb7A/FE8rlnC21e+5/Ds+90FEtcaG 26 | kesHJkC7rtzGlsdZGB0HnDJTWE9vxFsIcHf0+oJ73yKI/17+0DW7jBFp874hdhMj 27 | ip8xnZFDmplztB3aPzIpmNClAcNn5AP+m9cKbg8wY/wmTcRlF7hNAMU= 28 | -----END CERTIFICATE REQUEST----- 29 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/tls/hub_client_cacert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFdjCCA16gAwIBAgIJAL5G4HWE3SsRMA0GCSqGSIb3DQEBCwUAMHAxFDASBgNV 3 | BAMMC2h1YmNsaWVudGNhMQswCQYDVQQGEwJVUzENM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WF7GTp+r5XSbNyQQIDAQABoxMwETAPBgNVHRMBAf8E 20 | BTADAQH/MA0GCSqGSIb3DQEBCwUAA4ICAQCH/r0Wjh7FKDnXi707BZwgZL4Agu+Z 21 | sntNZx7lbkJKLovpAouN7oHqwSJ5b1r7KOoW8RFZk/5wHBsis1GTU1HHaErAG/KU 22 | jSz7amU1aUCKaXk/qMyEF6oVQ09a06OMYfqhNwzLL+zuzZT274z/WEA9V/EOkLrF 23 | sm34vSZk8RMVwcnja0Tq21K6gk7hJ64cq1/sOtZhS6t6YRnzu7mA0PjnaeHPuGBv 24 | qxYt1WmMvxEzBP6D6NgFRKuwDmZxDH9mV+o3BTktzUh83F40I5rjzXI7Wfw/D3Od 25 | 1Sgypq/rJJowCBWY7NkWfB1Oykl1Ql3ThUNSwDaN8WZLZINQcwjbv5CWoJ8uJ3yX 26 | YNy/29k1jmsjx0/LdH3oHshdhfnekUSqRjHsSHqKuobwr7mivERKIPywQQzqId0+ 27 | SW/Y4wMXroVCSDhApDy5CKXpW1j4fRWQy+vgLZTof3t8mv4znfc+P8M0ET/HoH2Q 28 | q1B8Cwis0JIxfMQJ/HiypVo0g2cPCpqQkhwJk8kFuJccPiCnm9yR5wsmVm0wF1/d 29 | glB2lou8lGNBjnMuRxSjQ6S/k4XNGupV8D9qnoHCrIcfNRwfsNIFFRbbDFn9pfog 30 | IV4kF6529qmxTMcmQXCPhkTHRkTypvPc9Hgxd60GtJVmHIxBFHRWNcSRVFuZtyHm 31 | cTQg3x0mFGAD9Q== 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/tls/hub_server.csr: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE REQUEST----- 2 | MIIEuTCCAqECAQAwUjELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAkNBMRMwEQYDVQQK 3 | DApIdWIgU2VydmVyMSEwHwYDVQQDDBhtb2phbG9vcC10ZXN0aW5nLXRvb2xraXQw 4 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ZgN2jOZe 20 | j7Zb2B3A6LucaGqwRBTNLnDAGORkiQpRAMbcSb3KXv/JmUYzJX5/23P6w0hXi7wj 21 | Xuq4Ew7ZAeAZDG8q/iIqCjput3S656jx8GNi+AaFSsa4TkigKzUuC9CyAAC89SYw 22 | 0NcTlGPmYVYKKA6Y8+ryWjSt1CEvn2FmpigRBZqtFvPFkaTQMY48cUgj2ZohV6e+ 23 | irTBqHk6Eo1H8IdkJtjVgcb/4LTTijCzl4k0EnSAJkuo+2yOMUaEzCjIpsmEDwkp 24 | pRBFqrXYEljRL8CKuMNNBukreepadb3HGtzEahjn4bbL6b5fkUuj6dpS+4JI7Xqn 25 | aI1LEfU4YsmlBlvA3KKbBmBcRFtINtOl4a430LJzfKypdgbis6NP0ihd3ssoEycP 26 | ggHh4vpJ40PqBeOeYM9XkJ7yfe8zt6A0/cB23MUV9uWSNKetgZ/1gGt5SiYA800P 27 | PYPQ28YgKQflOEabmw== 28 | -----END CERTIFICATE REQUEST----- 29 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/tls/hub_server_cacert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFdjCCA16gAwIBAgIJAIl8NQS3mbtGMA0GCSqGSIb3DQEBCwUAMHAxFDASBgNV 3 | BAMMC2h1YnNlcnZlcmNhMQswCQYDVQQGEwJVUzENMAsGA1UECAwET2hpbzERMA8G 4 | A1UEBwwIQ29sdW1idXMxFjAUBgNVBAoMDUh1YiBTZXJ2ZXIgQ0ExETAPBgNVBAsM 5 | CFBheW1lbnRzMB4XDTIwMDQwNzIwMjA0MloXDTQ3MDgyNDIwMjA0MlowcDEUMBIG 6 | A1UEAwwLaHVic2VydmVyY2ExCzAJBgNVBAYTAlVTMQ0wCwYDVQQIDARPaGlvMREw 7 | DwYDVQQHDAhDb2x1bWJ1czEWMBQGA1UECgwNSHViIFNlcnZlciBDQTERMA8GA1UE 8 | CwwIUGF5bWVudHMwggIiMA0GCSq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mnAw+9LjjH4fZHlFDo2eES4O81Zv5s7U24FNswj/r9Wg 25 | YZtwPVMB+3ZCXK9ZPnezP3ZO6x4DRZUHahSwYiFkeb4+1NqIsTx5nLKZPm/fEkjg 26 | 4bXVH1X4YuRRHMm33PHJR0ujH51zYAC2U10mOAPJq7u/S/h4JpZDr24A3ne7tQ3G 27 | rIMrPZsy5pY2794DXfOnO2fqIcyRSulm6s/tYw+3FPm4/7oi9eQKfoyAz9J+2DEE 28 | PTlrkYT0AlhZki90I+jETBNXVwmWnMykAMuExW5xw6EiteM4uYmQn9l/Wsd3NEVZ 29 | Ds7RFZrYWcPPHw0uaPIL5KQE6w2JgS+fraduc6kvBFgVfZIxJ97anVp6WzwLISbv 30 | aQyfltKvLrsSsrAmNDlWscKfJbgVt64ZbF1kVTeHNTgR1I0X8vf4v5CQm18X+D2C 31 | /q24z8GZ2Wwxxw== 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/tls/hub_server_cacert.srl: -------------------------------------------------------------------------------- 1 | ECF605B40A1A7D39 2 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/secrets/tls/openssl.conf: -------------------------------------------------------------------------------- 1 | [ req ] 2 | distinguished_name = req_distinguished_name 3 | extensions = v3_ca 4 | req_extensions = v3_ca 5 | [ v3_ca ] 6 | basicConstraints = critical,CA:TRUE 7 | [ v3_req ] 8 | basicConstraints = CA:FALSE 9 | extendedKeyUsage = serverAuth, clientAuth, codeSigning, emailProtection 10 | 11 | [ req_distinguished_name ] 12 | countryName = US 13 | countryName_default = KR 14 | countryName_min = 2 15 | countryName_max = 2 16 | organizationName = User DFSP CA 17 | organizationName_default = User DFSP CA -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/api_definitions/central_admin_9.3/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/health": { 3 | "get": { 4 | "response": {} 5 | } 6 | }, 7 | "/metrics": { 8 | "get": { 9 | "response": {} 10 | } 11 | }, 12 | "/participants": { 13 | "get": { 14 | "response": {} 15 | }, 16 | "post": { 17 | "response": {} 18 | } 19 | }, 20 | "/participants/limits": { 21 | "get": { 22 | "response": {} 23 | } 24 | }, 25 | "/participants/{name}": { 26 | "get": { 27 | "response": {} 28 | }, 29 | "put": { 30 | "response": {} 31 | } 32 | }, 33 | "/participants/{name}/endpoints": { 34 | "get": { 35 | "response": {} 36 | }, 37 | "post": { 38 | "response": {} 39 | } 40 | }, 41 | "/participants/{name}/limits": { 42 | "get": { 43 | "response": {} 44 | }, 45 | "put": { 46 | "response": {} 47 | } 48 | }, 49 | "/participants/{name}/positions": { 50 | "get": { 51 | "response": {} 52 | } 53 | }, 54 | "/participants/{name}/accounts": { 55 | "get": { 56 | "response": {} 57 | }, 58 | "post": { 59 | "response": {} 60 | } 61 | }, 62 | "/participants/{name}/initialPositionAndLimits": { 63 | "post": { 64 | "response": {} 65 | } 66 | }, 67 | "/participants/{name}/accounts/{id}": { 68 | "put": { 69 | "response": {} 70 | }, 71 | "post": { 72 | "response": {} 73 | } 74 | }, 75 | "/participants/{name}/accounts/{id}/transfers/{transferId}": { 76 | "put": { 77 | "response": {} 78 | } 79 | }, 80 | "/settlementModels": { 81 | "get": { 82 | "response": {} 83 | }, 84 | "post": { 85 | "response": {} 86 | } 87 | }, 88 | "/settlementModels/{name}": { 89 | "get": { 90 | "response": {} 91 | }, 92 | "put": { 93 | "response": {} 94 | } 95 | } 96 | } -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/api_definitions/fspiop_1.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "party.personalInfo.complexName.firstName", 4 | "pattern": "John|David|Michael|Chris|Mike|Mark|Paul|Daniel|James|Maria" 5 | }, 6 | { 7 | "id": "party.personalInfo.complexName.middleName", 8 | "pattern": "G|P|N|S" 9 | }, 10 | { 11 | "id": "party.personalInfo.complexName.lastName", 12 | "pattern": "Smith|Jones|Johnson|Lee|Brown|Williams|Rodriguez|Garcia|Gonzalez|Lopez" 13 | }, 14 | { 15 | "id": "party.personalInfo.dateOfBirth", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "transferId", 20 | "faker": "internet.email" 21 | }, 22 | { 23 | "id": "transferState", 24 | "pattern": "COMMITTED|RESERVED|ABORTED|RECEIVED" 25 | }, 26 | { 27 | "id": "fulfilment", 28 | "pattern": "[A-Fa-f0-9]{64}" 29 | }, 30 | { 31 | "id": "condition", 32 | "pattern": "[A-Fa-f0-9]{64}" 33 | }, 34 | { 35 | "id": "ilpPacket", 36 | "pattern": "[A-Fa-f0-9]{256}" 37 | }, 38 | { 39 | "id": "transferAmount.currency", 40 | "pattern": "USD" 41 | }, 42 | { 43 | "id": "transferAmount.amount", 44 | "pattern": "123" 45 | }, 46 | { 47 | "id": "payeeReceiveAmount.currency", 48 | "pattern": "USD" 49 | }, 50 | { 51 | "id": "payeeReceiveAmount.amount", 52 | "pattern": "123" 53 | }, 54 | { 55 | "id": "payeeFspFee.currency", 56 | "pattern": "USD" 57 | }, 58 | { 59 | "id": "payeeFspFee.amount", 60 | "pattern": "2" 61 | }, 62 | { 63 | "id": "payeeFspCommission.currency", 64 | "pattern": "USD" 65 | }, 66 | { 67 | "id": "payeeFspCommission.amount", 68 | "pattern": "3" 69 | }, 70 | 71 | { 72 | "id": "errorInformation.errorCode", 73 | "pattern": "600[1-9]" 74 | }, 75 | { 76 | "id": "errorInformation.errorDescription", 77 | "pattern": "This is a mock error description" 78 | }, 79 | { 80 | "id": "Content-Length", 81 | "pattern": "123" 82 | } 83 | ] -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/api_definitions/fspiop_1.1/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "party.personalInfo.complexName.firstName", 4 | "pattern": "John|David|Michael|Chris|Mike|Mark|Paul|Daniel|James|Maria" 5 | }, 6 | { 7 | "id": "party.personalInfo.complexName.middleName", 8 | "pattern": "G|P|N|S" 9 | }, 10 | { 11 | "id": "party.personalInfo.complexName.lastName", 12 | "pattern": "Smith|Jones|Johnson|Lee|Brown|Williams|Rodriguez|Garcia|Gonzalez|Lopez" 13 | }, 14 | { 15 | "id": "party.personalInfo.dateOfBirth", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "transferId", 20 | "faker": "internet.email" 21 | }, 22 | { 23 | "id": "transferState", 24 | "pattern": "COMMITTED|RESERVED|ABORTED|RECEIVED" 25 | }, 26 | { 27 | "id": "fulfilment", 28 | "pattern": "[A-Fa-f0-9]{64}" 29 | }, 30 | { 31 | "id": "condition", 32 | "pattern": "[A-Fa-f0-9]{64}" 33 | }, 34 | { 35 | "id": "ilpPacket", 36 | "pattern": "[A-Fa-f0-9]{256}" 37 | }, 38 | { 39 | "id": "transferAmount.currency", 40 | "pattern": "USD" 41 | }, 42 | { 43 | "id": "transferAmount.amount", 44 | "pattern": "123" 45 | }, 46 | { 47 | "id": "payeeReceiveAmount.currency", 48 | "pattern": "USD" 49 | }, 50 | { 51 | "id": "payeeReceiveAmount.amount", 52 | "pattern": "123" 53 | }, 54 | { 55 | "id": "payeeFspFee.currency", 56 | "pattern": "USD" 57 | }, 58 | { 59 | "id": "payeeFspFee.amount", 60 | "pattern": "2" 61 | }, 62 | { 63 | "id": "payeeFspCommission.currency", 64 | "pattern": "USD" 65 | }, 66 | { 67 | "id": "payeeFspCommission.amount", 68 | "pattern": "3" 69 | }, 70 | 71 | { 72 | "id": "errorInformation.errorCode", 73 | "pattern": "600[1-9]" 74 | }, 75 | { 76 | "id": "errorInformation.errorDescription", 77 | "pattern": "This is a mock error description" 78 | }, 79 | { 80 | "id": "Content-Length", 81 | "pattern": "123" 82 | } 83 | ] -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/api_definitions/settlements_1.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "changedDate", 4 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 5 | }, 6 | { 7 | "id": "createdDate", 8 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 9 | }, 10 | { 11 | "id": "state", 12 | "pattern": "OPEN|CLOSED" 13 | }, 14 | { 15 | "id": "settlementWindows.items.items.createdDate", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "settlementWindows.items.items.changedDate", 20 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 21 | }, 22 | { 23 | "id": "settlementWindows.items.items.state", 24 | "pattern": "OPEN|CLOSED" 25 | }, 26 | { 27 | "id": "participants.items.accounts.items.state", 28 | "pattern": "OPEN|CLOSED" 29 | }, 30 | { 31 | "id": "participants.items.accounts.items.netSettlementAmount.amount", 32 | "pattern": "123" 33 | }, 34 | { 35 | "id": "participants.items.accounts.items.netSettlementAmount.currency", 36 | "pattern": "USD" 37 | } 38 | ] -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/api_definitions/settlements_1.0/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/settlementWindows/{id}": { 3 | "post": { 4 | "response": { 5 | "bodyOverride": { 6 | "id": "{$request.params.id}", 7 | "reason": "{$request.body.reason}" 8 | } 9 | } 10 | } 11 | }, 12 | "/settlementWindows": { 13 | "get": { 14 | "response": {} 15 | } 16 | }, 17 | "/settlements": { 18 | "post": { 19 | "response": { 20 | "bodyOverride": { 21 | } 22 | } 23 | } 24 | }, 25 | "/settlements/{id}": { 26 | "get": { 27 | "response": { 28 | "bodyOverride": { 29 | "id": "{$request.params.id}" 30 | } 31 | } 32 | } 33 | } 34 | } -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/api_definitions/thirdparty_scheme_adapter_sync/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/health": { 3 | "get": { 4 | "response": {} 5 | } 6 | }, 7 | "/linking/providers": { 8 | "get": { 9 | "response": {} 10 | } 11 | }, 12 | "/linking/accounts/{fspId}/{userId}": { 13 | "get": { 14 | "response": {} 15 | } 16 | }, 17 | "/thirdpartyTransaction/partyLookup": { 18 | "post": { 19 | "response": {} 20 | } 21 | }, 22 | "/thirdpartyTransaction/{ID}/initiate": { 23 | "post": { 24 | "response": {} 25 | } 26 | }, 27 | "/thirdpartyTransaction/{ID}/approve": { 28 | "post": { 29 | "response": {} 30 | } 31 | }, 32 | "/linking/request-consent": { 33 | "post": { 34 | "response": {} 35 | } 36 | }, 37 | "/linking/request-consent/{ID}/authenticate": { 38 | "patch": { 39 | "response": {} 40 | } 41 | }, 42 | "/linking/request-consent/{ID}/pass-credential": { 43 | "post": { 44 | "response": {} 45 | } 46 | } 47 | } -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/api_definitions/thirdparty_simulator/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/login": { 3 | "post": { 4 | "response": { 5 | "bodyOverride": {} 6 | } 7 | } 8 | }, 9 | "/authorize": { 10 | "post": { 11 | "response": { 12 | "bodyOverride": {} 13 | } 14 | } 15 | }, 16 | "/sendOTP": { 17 | "post": { 18 | "response": { 19 | "bodyOverride": {} 20 | } 21 | } 22 | }, 23 | "/verifyOTPorSecret": { 24 | "post": { 25 | "response": { 26 | "bodyOverride": {} 27 | } 28 | } 29 | }, 30 | "/OTPorSecret/{ID}": { 31 | "get": { 32 | "response": { 33 | "bodyOverride": {} 34 | } 35 | } 36 | }, 37 | "/store/consentRequests/{ID}": { 38 | "get": { 39 | "response": { 40 | "bodyOverride": {} 41 | } 42 | }, 43 | "post": { 44 | "response": { 45 | "bodyOverride": {} 46 | } 47 | } 48 | } 49 | } -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/rules_callback/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } 4 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/rules_response/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default_thirdparty_scheme.json" 3 | } -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/rules_validation/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } 4 | -------------------------------------------------------------------------------- /docker-contract/ml-testing-toolkit/spec_files/user_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "VERSION": 1, 3 | "CALLBACK_ENDPOINT": "http://pisp-sim-scheme-adapter:8000", 4 | "ALS_ENDPOINT": "http://account-lookup-service:4002", 5 | "CALLBACK_RESOURCE_ENDPOINTS": { 6 | "enabled": false, 7 | "endpoints": [ 8 | { 9 | "method": "put", 10 | "path": "/parties/{Type}/{ID}", 11 | "endpoint": "http://localhost:4002" 12 | }, 13 | { 14 | "method": "put", 15 | "path": "/quotes/{ID}", 16 | "endpoint": "http://localhost:3002" 17 | }, 18 | { 19 | "method": "put", 20 | "path": "/transfers/{ID}", 21 | "endpoint": "http://localhost:3000" 22 | } 23 | ] 24 | }, 25 | "HUB_ONLY_MODE": false, 26 | "ENDPOINTS_DFSP_WISE": { 27 | "dfsps": {} 28 | }, 29 | "SEND_CALLBACK_ENABLE": true, 30 | "FSPID": "pisp-sim", 31 | "DEFAULT_USER_FSPID": "userdfsp", 32 | "TRANSFERS_VALIDATION_WITH_PREVIOUS_QUOTES": true, 33 | "TRANSFERS_VALIDATION_ILP_PACKET": true, 34 | "TRANSFERS_VALIDATION_CONDITION": true, 35 | "ILP_SECRET": "secret", 36 | "VERSIONING_SUPPORT_ENABLE": true, 37 | "VALIDATE_INBOUND_JWS": false, 38 | "VALIDATE_INBOUND_PUT_PARTIES_JWS": false, 39 | "JWS_SIGN": false, 40 | "JWS_SIGN_PUT_PARTIES": false, 41 | "INBOUND_MUTUAL_TLS_ENABLED": false, 42 | "OUTBOUND_MUTUAL_TLS_ENABLED": false, 43 | "ADVANCED_FEATURES_ENABLED": true, 44 | "CALLBACK_TIMEOUT": 20000 45 | } 46 | -------------------------------------------------------------------------------- /docker-contract/pisp-sim/rules.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "ruleId": 1, 4 | "description": "Returns an Payee rejected transaction error (ML error 5105) from the simulator when transfer value is 5105 in any currency", 5 | "conditions": { 6 | "all": [ 7 | { 8 | "fact": "path", 9 | "operator": "equal", 10 | "value": "/transfers" 11 | }, 12 | { 13 | "fact": "method", 14 | "operator": "equal", 15 | "value": "POST" 16 | }, 17 | { 18 | "fact": "body", 19 | "operator": "equal", 20 | "value": "5105", 21 | "path": ".amount" 22 | } 23 | ] 24 | }, 25 | "event": { 26 | "type": "simulateError", 27 | "params": { 28 | "statusCode": 500, 29 | "body": { 30 | "statusCode": "5105", 31 | "message": "Payee rejected transaction" 32 | } 33 | } 34 | } 35 | } 36 | ] 37 | -------------------------------------------------------------------------------- /docker-contract/pisp-sim/secrets/pisp_client.crt: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFmTCCA4ECCQCFCo6/dWH3szANBgkqhkiG9w0BAQsFADCBkzEcMBoGCSqGSIb3 3 | DQEJARYNZGVtb0B0ZXN0LmNvbTELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAldBMRAw 4 | DgYDVQQHDAdTZWF0dGxlMQ8wDQYDVQQKDAZraWZpeWExETAPBgNVBAsMCHBheW1l 5 | bnRzMSMwIQYDVQQDDBpzd2l0Y2gtc2VydmVyLWludGVybWVkaWF0ZTAeFw0yMDAz 6 | MTAwMTIxNTZaFw0yMTA3MjMwMTIxNTZaMIGIMRwwGgYJKoZIhvcNAQkBFg1kZW1v 7 | QHRlc3QuY29tMQswCQYDVQQGEwJVUzELMAkGA1UECAwCV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fn+FB1bLbea5dFoAdTPHuKhrVroAQa/Itaf 24 | +srfeDXVfjUYhjv6bg9KcwIUy5ePGhIzt6z00tx2srXOmXVspjh23hWd2MOTytvA 25 | nx1qNYl+VCajUsZZEMPM6M7KVsTiZzAe4QUkeCn31JjcStbcBqyEelqezruvWhDH 26 | EfQmd+9GgBNUV9aqrVZu2ms9tlLswMHR1UuKjMFrYoz+uDj7LTY4VsCMl1V3lhhT 27 | d8y7Q33g1nRhCHcov5W8CAm1yNmhJ5FFD2OdCyUtX821TzXQAb8qax6XkOaNSdk0 28 | BiYjIa4/Ugpbe3EVt5Y4bg3b2X8GBf+XMWaci+q6CUSouoSIJ4utp0NpMTWT47Sp 29 | CaEnim85jZKUXFKpR7tQzAhVHy5fh4lG8iYwQVIzPcLhNE9neo3xGK8kVncaupjK 30 | C9feyVRwu+5t0PObTcad4XMr2XebhyplRvWTyAKJVbO0uAgYTpl4p+bfO2rBGelQ 31 | EEjHHDwxWwk/kp+jChXpRG9iL4ESdsTaGcdTZv77UG00WmlbHa2czxv02sVD 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-contract/pisp-sim/secrets/pisp_server.crt: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFvjCCA6agAwIBAgIEXmbqazANBgkqhkiG9w0BAQsFADCBlTEcMBoGCSqGSIb3 3 | DQEJARYNZGVtb0B0ZXN0LmNvbTELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAldBMRAw 4 | DgYDVQQHDAdTZWF0dGxlMQ8wDQYDVQQKDAZraWZpeWExETAPBgNVBAsMCHBheW1l 5 | bnRzMSUwIwYDVQQDDBxwYXllZWZzcC1zZXJ2ZXItaW50ZXJtZWRpYXRlMB4XDTIw 6 | MDMxMDAxMTYyN1oXDTIxMDMxMDAxMTYyN1owgYgxHDAaBgkqhkiG9w0BCQEWDWRl 7 | bW9AdGVzdC5jb20xCzAJBgNVBAYTAlVTMQswCQYDVQQIDAJXQTE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5nuQW9Bk3yT7SUDGFBQ7f5xd+iUaqtGmKpHQ 24 | kEtqmu89oeDT5aSievyEJGaZTWrb86lxFoAOK4dNrUshzaIsjr9/0wk3sL85gDsO 25 | bwhKUc1qGg883poAx19xG9+tlvYOJ73lhytIz30zqk3R5ZAuq+VZukzyFsZrk1Gc 26 | UWe74zb2x7O2EnRU1SDDU7KEyHpjVQX2j+qDXiXExX24KAYubhzM/Oq7wqf4o7R6 27 | lwW8wBg/jOR9uX6d8VOiVBsTZtO/feEeH8TY3pUg+B2F+F5mAsARki4PiBzWgKKY 28 | 8b7Uc6s3xFcewwVhDCAh2Lw8mDcyZMEIpVWe68YIYxCG3+OtNFrIFPAfJoni1vRQ 29 | uI2+xU5JS860cJLpIyy6NAfTO8bvjz1/+OHPrUH05EouEodqhwixEDm8PPN648jD 30 | WLa4PHCo+5Px0LZe05GnqgY7NN/SQdjfso/Gj7ZB+qYKbTx5BMwpWl9bBzHfM/T5 31 | hQOkuehT8rjrO+CLg9IpoWzGZoaGu2CFuUUAj+/hD1I0wX9As+Sv66YBWJOKuOGd 32 | ei6F1OP6VTgkTc5mXphN6f9bkKcVrrosjSKG11oVXD8qJw== 33 | -----END CERTIFICATE----- 34 | -------------------------------------------------------------------------------- /docker-contract/postman/.gitignore: -------------------------------------------------------------------------------- 1 | **/.DS_Store 2 | .idea/** 3 | -------------------------------------------------------------------------------- /docker-contract/postman/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM node:10.15.3-alpine 2 | 3 | WORKDIR /opt/postman 4 | 5 | COPY . /opt/postman/ 6 | 7 | RUN npm install -g newman -------------------------------------------------------------------------------- /docker-contract/postman/scripts/_00_seed_all.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | 5 | cd ${DIR} 6 | # tolerate errors here, since postman collections are not idempotent 7 | ./_01_seed_hub_account.sh 8 | set -e 9 | set -u 10 | 11 | ./_02_seed_oracle.sh 12 | -------------------------------------------------------------------------------- /docker-contract/postman/scripts/_01_seed_hub_account.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Hub Account' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-contract/postman/scripts/_02_seed_oracle.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Oracle Onboarding' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-live/.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # Ignore state files made by make 3 | .* 4 | 5 | # allow gitignore 6 | !.gitignore -------------------------------------------------------------------------------- /docker-live/README.md: -------------------------------------------------------------------------------- 1 | # Docker-Live 2 | 3 | A live lab environment for PISP Demos. Deployed using K8s + Helm 4 | 5 | 6 | ## Prerequisites 7 | - `helm` v3 or later 8 | - `kubectl` and access to a running cluster 9 | - `kubens` 10 | - a kubeconfig file (e.g. `~/.kube/config`) 11 | - a kubectl namespace, for this example, we will use `pisp-lab` 12 | 13 | ## Installing 14 | 15 | ```bash 16 | cd ./docker-live 17 | 18 | # create and switch to namespace 19 | kubectl create namespace pisp-lab 20 | kubens pisp-lab 21 | 22 | # install the switch 23 | make install-switch 24 | 25 | # install the participants 26 | # Currently dfspa, dfspb, pispa 27 | make install-participants 28 | 29 | # wait for pods to be up and running 30 | kubectl get po 31 | 32 | # find the IP address of the load balancer and set ELB_URL variable 33 | make get-elb 34 | 35 | # Will print something like the following 36 | # ****.elb.amazonaws.com 37 | 38 | # Export 39 | export ELB_URL=****.elb.amazonaws.com 40 | 41 | # check the health of the services 42 | make health-check 43 | 44 | # seed the database 45 | npm run reseed:docker-live 46 | 47 | # run a test transaction 48 | make transfer-p2p 49 | 50 | ``` 51 | 52 | ## Kubecl .yaml files + Helm Charts 53 | 54 | For this lab, we use a simplified version of the Mojaloop Helm charts. This includes: 55 | - single instance MySQL 56 | - simplified Kafka with readymade `public/kafka` chart 57 | 58 | 59 | Additionally, the install is broken into separate pieces: 60 | 61 | 1. **Prerequisites:** mysql, kafka, with a combination of helm and kafka (see `.install-base` in the [`./Makefile`](./Makefile)) 62 | 2. **Switch:** The application expressed as helm charts in [`./charts-switch`](./charts-switch) 63 | 3. **Participants:** The DFSP and PISP participants. Defined in helm charts at [`./charts-participant`](./charts-participant), and customized using `values.yml` files for either a PISP or DFSP 64 | -------------------------------------------------------------------------------- /docker-live/_test_oracle.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | 5 | ORACLE_ID_TYPE=ORACLE 6 | 7 | curl -s -X GET ${ELB_URL}/account-lookup-service/health 8 | curl -s -X GET ${ELB_URL}/account-lookup-service-admin/health 9 | echo '' 10 | 11 | # register the oracle 12 | curl -s -X POST ${ELB_URL}/account-lookup-service-admin/oracles \ 13 | -H 'Content-Type: application/json' \ 14 | -H 'Date: 2021-02-09T03:07:11.718Z' \ 15 | -d '{ 16 | "oracleIdType": "'$ORACLE_ID_TYPE'", 17 | "endpoint": { 18 | "value": "als-consent-oracle/oracle", 19 | "endpointType": "URL" 20 | }, 21 | "currency": "USD", 22 | "isDefault": true 23 | }' 24 | 25 | echo '' 26 | 27 | # A super simple rough test of the Consents oracle 28 | # change ORACLE_ID_TYPE to MSISDN for a proper test, since 29 | # since the ALS doesn't like the `CONSENTS` type 30 | # TODO - fix in mojaloop/project#2015 31 | curl -s -X POST $ELB_URL/account-lookup-service/participants/$ORACLE_ID_TYPE/123 \ 32 | -H 'Accept: application/vnd.interoperability.participants+json;version=1' \ 33 | -H 'Content-Type: application/vnd.interoperability.participants+json;version=1.0' \ 34 | -H 'Date: 2021-02-09T03:07:11.718Z' \ 35 | -H 'FSPIOP-Source: dfspa' \ 36 | -d '{ 37 | "fspId": "dfspa" 38 | }' 39 | 40 | curl -s -X GET $ELB_URL/account-lookup-service/participants/$ORACLE_ID_TYPE/123 \ 41 | -H 'Accept: application/vnd.interoperability.participants+json;version=1' \ 42 | -H 'Content-Type: application/vnd.interoperability.participants+json;version=1.0' \ 43 | -H 'Date: 2021-02-09T03:07:11.718Z' \ 44 | -H 'FSPIOP-Source: dfspa' 45 | 46 | echo 'Not monitoring endpoints here... go and check the logs yourself to check the callbacks' -------------------------------------------------------------------------------- /docker-live/_test_transfer.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | 5 | # A super simple transfer from DFSPA -> DFSPB 6 | # Currently stops at `WAITING_FOR_PARTY_ACCEPTANCE` 7 | # but we just want to verify the endpoints are hooked up correctly 8 | curl -s --request POST ${ELB_URL}/dfspa/mojaloop-simulator/test/scenarios \ 9 | --header 'Content-Type: application/json' \ 10 | --data-raw '[ 11 | { 12 | "name": "scenario1", 13 | "operation": "postTransfers", 14 | "body": { 15 | "from": { 16 | "idType": "MSISDN", 17 | "idValue": "123456789" 18 | }, 19 | "to": { 20 | "idType": "MSISDN", 21 | "idValue": "987654321" 22 | }, 23 | "amountType": "SEND", 24 | "currency": "USD", 25 | "amount": "100", 26 | "transactionType": "TRANSFER", 27 | "note": "Test note", 28 | "homeTransactionId": "123ABC" 29 | } 30 | } 31 | ]' | jq 32 | 33 | -------------------------------------------------------------------------------- /docker-live/charts-base/kafka_values.yaml: -------------------------------------------------------------------------------- 1 | persistence: 2 | enabled: false -------------------------------------------------------------------------------- /docker-live/charts-participant/Chart.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v2 2 | name: pisp-poc-participant 3 | description: A helm chart for a PISP or DFSP participant 4 | type: application 5 | version: 1.0.0 6 | appVersion: 1.0.0 7 | -------------------------------------------------------------------------------- /docker-live/charts-participant/configs/thirdparty-scheme-adapter.json: -------------------------------------------------------------------------------- 1 | {{- $participantId := .Values.participantId }} 2 | { 3 | "INBOUND": { 4 | "PORT": 4005, 5 | "HOST": "0.0.0.0" 6 | }, 7 | "OUTBOUND": { 8 | "PORT": 4006, 9 | "HOST": "0.0.0.0" 10 | }, 11 | "WSO2_AUTH": { 12 | "staticToken": "0706c62f-c022-3c42-8d14-8b5df128876d", 13 | "tokenEndpoint": "", 14 | "clientKey": "test-client-key", 15 | "clientSecret": "test-client-secret", 16 | "refreshSeconds": 3600 17 | }, 18 | "REDIS": { 19 | "PORT": 6379, 20 | "HOST": "dfspa-redis", 21 | "TIMEOUT": 100 22 | }, 23 | "INSPECT": { 24 | "DEPTH": 4, 25 | "SHOW_HIDDEN": false, 26 | "COLOR": true 27 | }, 28 | "SHARED": { 29 | "PEER_ENDPOINT": "transaction-requests-service:4003", 30 | "ALS_ENDPOINT": "account-lookup-service:4001", 31 | "QUOTES_ENDPOINT": "quoting-service:3002", 32 | "TRANSFERS_ENDPOINT": "ml-api-adapter:3000", 33 | "BULK_TRANSFERS_ENDPOINT": "", 34 | "DFSP_ID": "{{ $participantId }}", 35 | "DFSP_BACKEND_URI": "{{ $participantId }}-mojaloop-simulator:3000", 36 | "DFSP_BACKEND_HTTP_SCHEME": "http", 37 | "JWS_SIGN": false, 38 | "JWS_SIGNING_KEY": "./secrets/jwsSigningKey.key", 39 | "TLS": { 40 | "inbound": { 41 | "mutualTLS": { 42 | "enabled": false 43 | }, 44 | "creds": { 45 | "ca": "./secrets/dfsp_a_client.crt", 46 | "cert": "./secrets/dfsp_a_client.crt", 47 | "key": "./secrets/dfsp_a_client.crt" 48 | } 49 | }, 50 | "outbound": { 51 | "mutualTLS": { 52 | "enabled": false 53 | }, 54 | "creds": { 55 | "ca": "./secrets/dfsp_a_client.crt", 56 | "cert": "./secrets/dfsp_a_client.crt", 57 | "key": "./secrets/dfsp_a_client.crt" 58 | } 59 | }, 60 | "test": { 61 | "mutualTLS": { 62 | "enabled": false 63 | }, 64 | "creds": { 65 | "ca": "./secrets/dfsp_a_client.crt", 66 | "cert": "./secrets/dfsp_a_client.crt", 67 | "key": "./secrets/dfsp_a_client.crt" 68 | } 69 | } 70 | } 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /docker-live/charts-participant/templates/redis.yaml: -------------------------------------------------------------------------------- 1 | {{- $participantId := .Values.participantId }} 2 | apiVersion: apps/v1 3 | kind: Deployment 4 | metadata: 5 | name: {{ $participantId }}-redis 6 | labels: 7 | app: {{ $participantId }}-redis 8 | spec: 9 | replicas: 1 10 | strategy: 11 | type: RollingUpdate 12 | rollingUpdate: 13 | maxSurge: 1 # exeed the replicas by 1 pod 14 | selector: 15 | matchLabels: 16 | app: {{ $participantId }}-redis 17 | template: 18 | metadata: 19 | labels: 20 | app: {{ $participantId }}-redis 21 | spec: 22 | containers: 23 | - name: redis 24 | image: redis:5.0.4-alpine 25 | --- 26 | apiVersion: v1 27 | kind: Service 28 | metadata: 29 | name: {{ $participantId }}-redis 30 | spec: 31 | ports: 32 | - port: 6379 33 | selector: 34 | app: {{ $participantId }}-redis 35 | clusterIP: None 36 | -------------------------------------------------------------------------------- /docker-live/charts-participant/values_pispa.yml: -------------------------------------------------------------------------------- 1 | 2 | participantName: 'A PISP' 3 | participantId: 'pispa' 4 | 5 | # Set both to true if DFSP, set only `thirdpartyApiSupport` to true if PISP 6 | thirdpartyApiSupport: true 7 | mojaloopApiSupport: false 8 | 9 | mojaloop_simulator: 10 | jwsSigningKey: '' 11 | -------------------------------------------------------------------------------- /docker-live/charts-switch/Chart.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: v2 2 | name: pisp-poc-switch 3 | description: A Helm chart for Kubernetes 4 | type: application 5 | version: 1.0.0 6 | appVersion: 1.0.0 7 | -------------------------------------------------------------------------------- /docker-live/charts-switch/configs/consent-oracle-production_db.json: -------------------------------------------------------------------------------- 1 | { 2 | "client": "mysql", 3 | "version": "5.5", 4 | "connection": { 5 | "host": "localhost", 6 | "port": 3306, 7 | "user": "oracle_consent", 8 | "password": "password", 9 | "database": "oracle_consent", 10 | "timezone": "UTC" 11 | }, 12 | "pool": { 13 | "min": 10, 14 | "max": 10, 15 | "acquireTimeoutMillis": 30000, 16 | "createTimeoutMillis": 30000, 17 | "destroyTimeoutMillis": 5000, 18 | "idleTimeoutMillis": 30000, 19 | "reapIntervalMillis": 1000, 20 | "createRetryIntervalMillis": 200 21 | }, 22 | "migrations": { 23 | "tableName": "oracle_consent", 24 | "loadExtensions": [ 25 | ".ts" 26 | ] 27 | }, 28 | "seeds": { 29 | "loadExtensions": [ 30 | ".ts" 31 | ] 32 | } 33 | } -------------------------------------------------------------------------------- /docker-live/charts-switch/configs/thirdparty-api-adapter.json: -------------------------------------------------------------------------------- 1 | { 2 | "PORT": 3008, 3 | "HOST": "0.0.0.0", 4 | "INSPECT": { 5 | "DEPTH": 4, 6 | "SHOW_HIDDEN": false, 7 | "COLOR": true 8 | }, 9 | "ENDPOINT_CACHE_CONFIG": { 10 | "expiresIn": 180000, 11 | "generateTimeout": 30000 12 | }, 13 | "ENDPOINT_SERVICE_URL": "http://centralledger:3001", 14 | "ERROR_HANDLING": { 15 | "includeCauseExtension": true, 16 | "truncateExtensions": true 17 | }, 18 | "INSTRUMENTATION": { 19 | "METRICS": { 20 | "DISABLED": false, 21 | "labels": { 22 | "eventId": "*" 23 | }, 24 | "config": { 25 | "timeout": 5000, 26 | "prefix": "moja_3p_api", 27 | "defaultLabels": { 28 | "serviceName": "thirdparty-api-svc" 29 | } 30 | } 31 | } 32 | }, 33 | "KAFKA": { 34 | "TOPIC_TEMPLATES": { 35 | "GENERAL_TOPIC_TEMPLATE": { 36 | "TEMPLATE": "topic-{{functionality}}-{{action}}", 37 | "REGEX": "topic-(.*)-(.*)" 38 | } 39 | }, 40 | "CONSUMER": [ 41 | { 42 | "eventType": "notification", 43 | "eventAction": "commit", 44 | "options": { 45 | "mode": 2, 46 | "batchSize": 1, 47 | "pollFrequency": 10, 48 | "recursiveTimeout": 100, 49 | "messageCharset": "utf8", 50 | "messageAsJSON": true, 51 | "sync": true, 52 | "consumeTimeout": 1000 53 | }, 54 | "rdkafkaConf": { 55 | "client.id": "3p-con-notification-event", 56 | "group.id": "3p-group-notification-event", 57 | "metadata.broker.list": "kafka:9092", 58 | "socket.keepalive.enable": true 59 | }, 60 | "topicConf": { 61 | "auto.offset.reset": "earliest" 62 | } 63 | } 64 | ] 65 | }, 66 | "MOCK_CALLBACK": { 67 | "transactionRequestId": "abc-12345", 68 | "pispId": "pisp" 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /docker-live/charts-switch/templates/auth-service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: auth-service 5 | labels: 6 | app: auth-service 7 | spec: 8 | replicas: 1 9 | strategy: 10 | type: RollingUpdate 11 | rollingUpdate: 12 | maxSurge: 1 # exeed the replicas by 1 pod 13 | selector: 14 | matchLabels: 15 | app: auth-service 16 | template: 17 | metadata: 18 | labels: 19 | app: auth-service 20 | spec: 21 | containers: 22 | - name: auth-service 23 | image: mojaloop/auth-service:v11.2.4 24 | livenessProbe: 25 | initialDelaySeconds: 30 26 | httpGet: 27 | path: /health 28 | port: 4004 29 | readinessProbe: 30 | initialDelaySeconds: 30 31 | httpGet: 32 | path: /health 33 | port: 4004 34 | env: 35 | - name: PARTICIPANT_ID 36 | value: central-auth 37 | # TODO: add endpoint config - see https://github.com/mojaloop/auth-service/issues/51 38 | --- 39 | apiVersion: v1 40 | kind: Service 41 | metadata: 42 | name: auth-service 43 | spec: 44 | ports: 45 | - port: 4004 46 | selector: 47 | app: auth-service 48 | clusterIP: None 49 | --- 50 | apiVersion: extensions/v1beta1 51 | kind: Ingress 52 | metadata: 53 | name: auth-service 54 | annotations: 55 | nginx.ingress.kubernetes.io/rewrite-target: /$2 56 | nginx.ingress.kubernetes.io/use-regex: "true" 57 | spec: 58 | rules: 59 | - http: 60 | paths: 61 | - path: /auth-service(/|$)(.*) 62 | backend: 63 | serviceName: auth-service 64 | servicePort: 4004 65 | -------------------------------------------------------------------------------- /docker-live/charts-switch/templates/oracle-simulator.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: oracle-simulator 5 | labels: 6 | app: oracle-simulator 7 | spec: 8 | replicas: 1 9 | strategy: 10 | type: RollingUpdate 11 | rollingUpdate: 12 | maxSurge: 1 # exeed the replicas by 1 pod 13 | selector: 14 | matchLabels: 15 | app: oracle-simulator 16 | template: 17 | metadata: 18 | labels: 19 | app: oracle-simulator 20 | spec: 21 | containers: 22 | - name: oracle-simulator 23 | image: mojaloop/simulator:v9.5.0 24 | livenessProbe: 25 | initialDelaySeconds: 30 26 | httpGet: 27 | path: /health 28 | port: 8444 29 | readinessProbe: 30 | initialDelaySeconds: 30 31 | httpGet: 32 | path: /health 33 | port: 8444 34 | env: 35 | - name: LOG_LEVEL 36 | value: info 37 | - name: TRANSFERS_ENDPOINT 38 | value: http://ml-api-adapter:3000 39 | - name: QUOTES_ENDPOINT 40 | value: http://quoting-service:3002 41 | - name: PARTIES_ENDPOINT 42 | value: http://account-lookup-service:4002 43 | - name: TRANSACTION_REQUESTS_ENDPOINT 44 | value: http://transaction-request-service:4003 45 | - name: TRANSFERS_FULFIL_RESPONSE_DISABLED 46 | value: 'false' 47 | 48 | --- 49 | apiVersion: v1 50 | kind: Service 51 | metadata: 52 | name: oracle-simulator 53 | spec: 54 | ports: 55 | - port: 8444 56 | selector: 57 | app: oracle-simulator 58 | clusterIP: None 59 | --- 60 | apiVersion: extensions/v1beta1 61 | kind: Ingress 62 | metadata: 63 | name: oracle-simulator 64 | annotations: 65 | nginx.ingress.kubernetes.io/rewrite-target: /$2 66 | nginx.ingress.kubernetes.io/use-regex: "true" 67 | spec: 68 | rules: 69 | - http: 70 | paths: 71 | - path: /oracle-simulator(/|$)(.*) 72 | backend: 73 | serviceName: oracle-simulator 74 | servicePort: 8444 75 | -------------------------------------------------------------------------------- /docker-live/charts-switch/templates/quoting-service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: quoting-service 5 | labels: 6 | app: quoting-service 7 | spec: 8 | replicas: 1 9 | strategy: 10 | type: RollingUpdate 11 | rollingUpdate: 12 | maxSurge: 1 # exeed the replicas by 1 pod 13 | selector: 14 | matchLabels: 15 | app: quoting-service 16 | template: 17 | metadata: 18 | labels: 19 | app: quoting-service 20 | spec: 21 | containers: 22 | - name: quoting-service 23 | image: mojaloop/quoting-service:v10.1.0 24 | livenessProbe: 25 | initialDelaySeconds: 30 26 | httpGet: 27 | path: /health 28 | port: 3002 29 | readinessProbe: 30 | initialDelaySeconds: 30 31 | httpGet: 32 | path: /health 33 | port: 3002 34 | env: 35 | - name: QUOTE_DATABASE__HOST 36 | value: mysql 37 | - name: QUOTE_SWITCH_ENDPOINT 38 | value: http://centralledger:3001 39 | # command: [ "sh", "-c", "tail -f /dev/null" ] 40 | securityContext: 41 | runAsUser: 0 42 | --- 43 | apiVersion: v1 44 | kind: Service 45 | metadata: 46 | name: quoting-service 47 | spec: 48 | ports: 49 | - port: 3002 50 | selector: 51 | app: quoting-service 52 | clusterIP: None 53 | --- 54 | apiVersion: extensions/v1beta1 55 | kind: Ingress 56 | metadata: 57 | name: quoting-service 58 | annotations: 59 | nginx.ingress.kubernetes.io/rewrite-target: /$2 60 | nginx.ingress.kubernetes.io/use-regex: "true" 61 | spec: 62 | rules: 63 | - http: 64 | paths: 65 | - path: /quoting-service(/|$)(.*) 66 | backend: 67 | serviceName: quoting-service 68 | servicePort: 3002 69 | -------------------------------------------------------------------------------- /docker-live/charts-switch/templates/transaction-request-service.yaml: -------------------------------------------------------------------------------- 1 | apiVersion: apps/v1 2 | kind: Deployment 3 | metadata: 4 | name: transaction-requests-service 5 | labels: 6 | app: transaction-requests-service 7 | spec: 8 | replicas: 1 9 | strategy: 10 | type: RollingUpdate 11 | rollingUpdate: 12 | maxSurge: 1 # exeed the replicas by 1 pod 13 | selector: 14 | matchLabels: 15 | app: transaction-requests-service 16 | template: 17 | metadata: 18 | labels: 19 | app: transaction-requests-service 20 | spec: 21 | containers: 22 | - name: transaction-requests-service 23 | image: mojaloop/transaction-requests-service:v10.6.1.1-pisp 24 | livenessProbe: 25 | initialDelaySeconds: 30 26 | httpGet: 27 | path: /health 28 | port: 4003 29 | readinessProbe: 30 | initialDelaySeconds: 30 31 | httpGet: 32 | path: /health 33 | port: 4003 34 | env: 35 | - name: ES_SWITCH_ENDPOINT 36 | value: http://central-ledger:3001 37 | 38 | --- 39 | apiVersion: v1 40 | kind: Service 41 | metadata: 42 | name: transaction-requests-service 43 | spec: 44 | ports: 45 | - port: 4003 46 | selector: 47 | app: transaction-requests-service 48 | clusterIP: None 49 | --- 50 | apiVersion: extensions/v1beta1 51 | kind: Ingress 52 | metadata: 53 | name: transaction-requests-service 54 | annotations: 55 | nginx.ingress.kubernetes.io/rewrite-target: /$2 56 | nginx.ingress.kubernetes.io/use-regex: "true" 57 | spec: 58 | rules: 59 | - http: 60 | paths: 61 | - path: /transaction-requests-service(/|$)(.*) 62 | backend: 63 | serviceName: transaction-requests-service 64 | servicePort: 4003 65 | -------------------------------------------------------------------------------- /docker-live/kafka_values.yaml: -------------------------------------------------------------------------------- 1 | persistence: 2 | enabled: false -------------------------------------------------------------------------------- /docker-local/components_layout.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mojaloop/pisp-project/01f8d384d54ef8e86821a2149143d741c5cc7b2b/docker-local/components_layout.png -------------------------------------------------------------------------------- /docker-local/dfsp_a/secrets/dfsp_a_client.crt: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFmTCCA4ECCQDXyM5jK2EwsTANBgkqhkiG9w0BAQsFADCBkzEcMBoGCSqGSIb3 3 | DQEJARYNZGVtb0B0ZXN0LmNvbTELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAldBMRAw 4 | DgYDVQQHDAdTZWF0dGxlMQ8wDQYDVQQKDAZraWZpeWExETAPBgNVBAsMCHBheW1l 5 | bnRzMSMwIQYDVQQDDBpzd2l0Y2gtc2VydmVyLWludGVybWVkaWF0ZTAeFw0yMDAz 6 | MTAwMjA0MTJaFw0yMTA3MjMwMjA0MTJaMIGIMRwwGgYJKoZIhvcNAQkBFg1kZW1v 7 | QHRlc3QuY29tMQswCQYDVQQGEwJVUzELMAkGA1UECAwCV0ExEDAOBgNVBAcMB1Nl 8 | YXR0bGUxDzANBgNVBAoMBmtpZml5YTERMA8GA1UECwwIcGF5bWVudHMxGDAWBgNV 9 | BAMMD3BheWVyZnNwLWNsaWVudDCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoC 10 | ggIBAOnWgK3ZaAicFaLQWG8GWrUU0GzXe5T3+5z9zXTwFNkVh3qZVvvgv9ulT0Or 11 | eSKcljD8So36ztRr//4xHp6G0iu8caLp1vDp12lseobvXNR38F7HPLrdDfqh7b3e 12 | yPHZquDPKwmVHgoemO/eFy73u16cCqXpm1WG5+K+0iXJ9N2OoDVV0NdvVpohdhUU 13 | MuBaCvQqx+iLCDYgkjE/3q2UNPp8jPPNGSz/Bbg2GiVfIiskJ1UZJ4xJ38zijFuC 14 | M0dnkLffup1sY591HdEmtztAvl9jumwhh3zPoc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ndp1SFKWTHtIKUJQ8EXSMmsfKpU4A48SETUwu6gmAL03I 31 | tiQhhf1C5SX9QhrkRrbB2wgw7dO8qmt64qKEJ0ZtucG114ZMR6oRzE1T4PE1 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-local/dfsp_a/secrets/dfsp_a_server_root.crt: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFrTCCA5WgAwIBAgIEXmbuoDANBgkqhkiG9w0BAQsFADCBjTEcMBoGCSqGSIb3 3 | DQEJARYNZGVtb0B0ZXN0LmNvbTELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAldBMRAw 4 | DgYDVQQHDAdTZWF0dGxlMQ8wDQYDVQQKDAZraWZpeWExETAPBgNVBAsMCHBheW1l 5 | bnRzMR0wGwYDVQQDDBRwYXllcmZzcC1zZXJ2ZXItcm9vdDAeFw0yMDAzMTAwMTM0 6 | MjRaFw0yMTAzMTAwMTM0MjRaMIGNMRwwGgYJKoZIhvcNAQkBFg1kZW1vQHRlc3Qu 7 | Y29tMQswCQYDVQQGEwJVUzELMAkGA1UECAwCV0ExEDAOBgNVBAcMB1NlYXR0bGUx 8 | DzANBgNVBAoMBmtpZml5YTERMA8GA1UECwwIcGF5bWVudHMxHTAbBgNVBAMMFHBh 9 | eWVyZnNwLXNlcnZlci1yb290MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKC 10 | AgEAoXc7Gav9qEcjlXXDDVjQtZ+ZQtf9K1b3tucaGsBCnHExxawo8KcAlMZAv+k1 11 | 51pJRk34gGLVhi8/I6+LzjQyoDHopg7ERlOTJUZUNq1sKdWsTNl8PpAQHGxLJ6uV 12 | 6JCa9KXNXb3qqR4AgqiDejZS4D5wH09rcDwIA4tAuiiHebgEnk5aujHOZZJe3+xV 13 | zO+bkaqwxoTOsK3AFCR9/3ntGPyfgPonxXV3fE3et/id/GFDeSGrARiZp7OPfNs4 14 | Y2qjqUIQ2JhvxsrIHXak2+aQ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pZpm/psAxs6/HpaAM2+Wxhqim63wM3juGW0Je9Y5o0s/Uln6cef9LfVKFD79S 31 | M+WhaOXDC4cEFCjvH5C2pb5NMK01R/r5qx392vnbPP5R5l6Rp6izi2jsdgi17suY 32 | RNbE3PxZ41gv/qx1i9G0oyU= 33 | -----END CERTIFICATE----- 34 | -------------------------------------------------------------------------------- /docker-local/dfsp_b/secrets/dfsp_b_client.crt: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFmTCCA4ECCQCFCo6/dWH3szANBgkqhkiG9w0BAQsFADCBkzEcMBoGCSqGSIb3 3 | DQEJARYNZGVtb0B0ZXN0LmNvbTELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAldBMRAw 4 | DgYDVQQHDAdTZWF0dGxlMQ8wDQYDVQQKDAZraWZpeWExETAPBgNVBAsMCHBheW1l 5 | bnRzMSMwIQYDVQQDDBpzd2l0Y2gtc2VydmVyLWludGVybWVkaWF0ZTAeFw0yMDAz 6 | MTAwMTIxNTZaFw0yMTA3MjMwMTIxNTZaMIGIMRwwGgYJKoZIhvcNAQkBFg1kZW1v 7 | QHRlc3QuY29tMQswCQYDVQQGEwJVUzELMAkGA1UECAwCV0ExEDAOBgNVBAcMB1Nl 8 | YXR0bGUxDzANBgNVBAoMBmtpZml5YTERMA8GA1UECwwIcGF5bWVudHMxGDAWBgNV 9 | BAMMD3BheWVlZnNwLWNsaWVudDCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoC 10 | ggIBAKw1Gg/hyzTaaTrVZIBNaSnmoL8XrpDDW4LFGccp4fEAhTZCJP0/WBFyrX2s 11 | 17iciaUgx3wYjYsiMZEvcWZ09nSaKSdF7QKcN6zfrwHaY5lAEzEL1+as9JWrh2aU 12 | 46jQINZ/UxjuQXx3k4bd8Fd7qylt1BKIEQlJhw540TupCWwcUfbPdkmQrpe5kGjn 13 | TZQA4Pr+IdfpbzaFTkAfPXE2NIPQCNux8pmwnSupUL2m9vj9YEVv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cLhNE9neo3xGK8kVncaupjK 30 | C9feyVRwu+5t0PObTcad4XMr2XebhyplRvWTyAKJVbO0uAgYTpl4p+bfO2rBGelQ 31 | EEjHHDwxWwk/kp+jChXpRG9iL4ESdsTaGcdTZv77UG00WmlbHa2czxv02sVD 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-local/docker-clean-all.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | docker rm -f $(docker ps -a -q) 3 | docker volume rm $(docker volume ls -q) 4 | -------------------------------------------------------------------------------- /docker-local/docker-compose.ttk-cli.yml: -------------------------------------------------------------------------------- 1 | version: "3.7" 2 | 3 | networks: 4 | mojaloop-net: 5 | name: mojaloop-net 6 | 7 | # Runs a ttk in CLI mode that runs the tests on startup 8 | # run alongside the environment docker-compose.yml 9 | services: 10 | ttk-cli: 11 | container_name: ttk-cli 12 | image: mojaloop/ml-testing-toolkit:v13.5.2 13 | volumes: 14 | - "../test/e2e-ttk:/opt/mojaloop-testing-toolkit/tests" 15 | ports: 16 | - "45000:5000" 17 | - "45050:5050" 18 | command: 19 | - sh 20 | - -c 21 | # - "sleep infinity" 22 | - "npm run cli -- -m outbound -i tests/collection.json -e tests/environment.json -u http://test-runner:5050 --report-target file:///opt/mojaloop-testing-toolkit/tests/results.html --report-format html --report-auto-filename-enable false" 23 | networks: 24 | - mojaloop-net -------------------------------------------------------------------------------- /docker-local/docker/account-lookup-service/default.json: -------------------------------------------------------------------------------- 1 | { 2 | "ADMIN_PORT": 4001, 3 | "API_PORT": 4002, 4 | "DATABASE": { 5 | "DIALECT": "mysql", 6 | "HOST": "mysql-als", 7 | "PORT": 3306, 8 | "USER": "account_lookup", 9 | "PASSWORD": "password", 10 | "DATABASE": "account_lookup", 11 | "POOL_MIN_SIZE": 10, 12 | "POOL_MAX_SIZE": 10, 13 | "ACQUIRE_TIMEOUT_MILLIS": 30000, 14 | "CREATE_TIMEOUT_MILLIS": 30000, 15 | "DESTROY_TIMEOUT_MILLIS": 5000, 16 | "IDLE_TIMEOUT_MILLIS": 30000, 17 | "REAP_INTERVAL_MILLIS": 1000, 18 | "CREATE_RETRY_INTERVAL_MILLIS": 200, 19 | "DEBUG": false 20 | }, 21 | "DISPLAY_ROUTES": true, 22 | "RUN_MIGRATIONS": true, 23 | "ENDPOINT_CACHE_CONFIG": { 24 | "expiresIn": 180000, 25 | "generateTimeout": 30000 26 | }, 27 | "ERROR_HANDLING": { 28 | "includeCauseExtension": false, 29 | "truncateExtensions": true 30 | }, 31 | "SWITCH_ENDPOINT": "http://central-ledger:3001", 32 | "INSTRUMENTATION": { 33 | "METRICS": { 34 | "DISABLED": false, 35 | "labels": { 36 | "fspId": "*" 37 | }, 38 | "config": { 39 | "timeout": 5000, 40 | "prefix": "moja_", 41 | "defaultLabels": { 42 | "serviceName": "account-lookup-service" 43 | } 44 | } 45 | } 46 | }, 47 | "ENDPOINT_SECURITY":{ 48 | "JWS": { 49 | "JWS_SIGN": false, 50 | "FSPIOP_SOURCE_TO_SIGN": "switch", 51 | "JWS_SIGNING_KEY_PATH": "secrets/jwsSigningKey.key" 52 | } 53 | }, 54 | "FEATURE_ENABLE_EXTENDED_PARTY_ID_TYPE": true 55 | } 56 | -------------------------------------------------------------------------------- /docker-local/docker/als-consent-oracle/default.json: -------------------------------------------------------------------------------- 1 | { 2 | "PORT": 3000, 3 | "HOST": "0.0.0.0", 4 | "INSPECT": { 5 | "DEPTH": 4, 6 | "SHOW_HIDDEN": false, 7 | "COLOR": true 8 | }, 9 | "DATABASE": { 10 | "DIALECT": "mysql", 11 | "HOST": "als-consent-oracle-mysql", 12 | "PORT": 3306, 13 | "USER": "als-consent-oracle", 14 | "PASSWORD": "password", 15 | "DATABASE": "als-consent-oracle", 16 | "POOL_MIN_SIZE": 10, 17 | "POOL_MAX_SIZE": 10, 18 | "ACQUIRE_TIMEOUT_MILLIS": 30000, 19 | "CREATE_TIMEOUT_MILLIS": 30000, 20 | "DESTROY_TIMEOUT_MILLIS": 5000, 21 | "IDLE_TIMEOUT_MILLIS": 30000, 22 | "REAP_INTERVAL_MILLIS": 1000, 23 | "CREATE_RETRY_INTERVAL_MILLIS": 200 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /docker-local/docker/kafka/consumer.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | # see org.apache.kafka.clients.consumer.ConsumerConfig for more details 16 | 17 | # list of brokers used for bootstrapping knowledge about the rest of the cluster 18 | # format: host1:port1,host2:port2 ... 19 | bootstrap.servers=localhost:9092 20 | 21 | # consumer group id 22 | group.id=test-consumer-group 23 | 24 | # What to do when there is no initial offset in Kafka or if the current 25 | # offset does not exist any more on the server: latest, earliest, none 26 | #auto.offset.reset= 27 | -------------------------------------------------------------------------------- /docker-local/docker/kafka/producer.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | # see org.apache.kafka.clients.producer.ProducerConfig for more details 16 | 17 | ############################# Producer Basics ############################# 18 | 19 | # list of brokers used for bootstrapping knowledge about the rest of the cluster 20 | # format: host1:port1,host2:port2 ... 21 | bootstrap.servers=localhost:9092 22 | 23 | # specify the compression codec for all data generated: none, gzip, snappy, lz4, zstd 24 | compression.type=none 25 | 26 | # name of the partitioner class for partitioning events; default partition spreads data randomly 27 | #partitioner.class= 28 | 29 | # the maximum amount of time the client will wait for the response of a request 30 | #request.timeout.ms= 31 | 32 | # how long `KafkaProducer.send` and `KafkaProducer.partitionsFor` will block for 33 | #max.block.ms= 34 | 35 | # the producer will wait for up to the given delay to allow other records to be sent so that the sends can be batched together 36 | #linger.ms= 37 | 38 | # the maximum size of a request in bytes 39 | #max.request.size= 40 | 41 | # the default batch size in bytes when batching multiple records sent to a partition 42 | #batch.size= 43 | 44 | # the total bytes of memory the producer can use to buffer records waiting to be sent to the server 45 | #buffer.memory= 46 | -------------------------------------------------------------------------------- /docker-local/docker/kafka/tools-log4j.properties: -------------------------------------------------------------------------------- 1 | # Licensed to the Apache Software Foundation (ASF) under one or more 2 | # contributor license agreements. See the NOTICE file distributed with 3 | # this work for additional information regarding copyright ownership. 4 | # The ASF licenses this file to You under the Apache License, Version 2.0 5 | # (the "License"); you may not use this file except in compliance with 6 | # the License. You may obtain a copy of the License at 7 | # 8 | # http://www.apache.org/licenses/LICENSE-2.0 9 | # 10 | # Unless required by applicable law or agreed to in writing, software 11 | # distributed under the License is distributed on an "AS IS" BASIS, 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | # See the License for the specific language governing permissions and 14 | # limitations under the License. 15 | 16 | log4j.rootLogger=WARN, stderr 17 | 18 | log4j.appender.stderr=org.apache.log4j.ConsoleAppender 19 | log4j.appender.stderr.layout=org.apache.log4j.PatternLayout 20 | log4j.appender.stderr.layout.ConversionPattern=[%d] %p %m (%c)%n 21 | log4j.appender.stderr.Target=System.err 22 | -------------------------------------------------------------------------------- /docker-local/docker/quoting-service/default.json: -------------------------------------------------------------------------------- 1 | { 2 | "HOSTNAME": "http://quoting-service", 3 | "LISTEN_ADDRESS": "0.0.0.0", 4 | "PORT": 3002, 5 | "AMOUNT": { 6 | "PRECISION": 18, 7 | "SCALE": 4 8 | }, 9 | "PROTOCOL_VERSIONS": { 10 | "CONTENT": { 11 | "DEFAULT": "1.1", 12 | "VALIDATELIST": [ 13 | "1.1", 14 | "1.0" 15 | ] 16 | }, 17 | "ACCEPT": { 18 | "DEFAULT": "1", 19 | "VALIDATELIST": [ 20 | "1", 21 | "1.0", 22 | "1.1" 23 | ] 24 | } 25 | }, 26 | "DATABASE": { 27 | "DIALECT": "mysql", 28 | "HOST": "mysql", 29 | "PORT": 3306, 30 | "USER": "central_ledger", 31 | "PASSWORD": "password", 32 | "SCHEMA": "central_ledger", 33 | "POOL_MIN_SIZE": 10, 34 | "POOL_MAX_SIZE": 10, 35 | "ACQUIRE_TIMEOUT_MILLIS": 30000, 36 | "CREATE_TIMEOUT_MILLIS": 30000, 37 | "DESTROY_TIMEOUT_MILLIS": 5000, 38 | "IDLE_TIMEOUT_MILLIS": 30000, 39 | "REAP_INTERVAL_MILLIS": 1000, 40 | "CREATE_RETRY_INTERVAL_MILLIS": 200, 41 | "DEBUG": false 42 | }, 43 | "SWITCH_ENDPOINT": "http://central-ledger:3001", 44 | "ERROR_HANDLING": { 45 | "includeCauseExtension": false, 46 | "truncateExtensions": true 47 | }, 48 | "SIMPLE_ROUTING_MODE": true, 49 | "ENDPOINT_SECURITY":{ 50 | "JWS": { 51 | "JWS_SIGN": false, 52 | "FSPIOP_SOURCE_TO_SIGN": "switch", 53 | "JWS_SIGNING_KEY_PATH": "secrets/jwsSigningKey.key" 54 | } 55 | }, 56 | "API_DOCUMENTATION_ENDPOINTS": true 57 | } 58 | -------------------------------------------------------------------------------- /docker-local/docker/quoting-service/rules.json: -------------------------------------------------------------------------------- 1 | [] 2 | -------------------------------------------------------------------------------- /docker-local/docker/sql-als-init/01_permissions.sql: -------------------------------------------------------------------------------- 1 | ALTER USER 'account_lookup'@'%' identified WITH mysql_native_password by 'password'; 2 | FLUSH PRIVILEGES; -------------------------------------------------------------------------------- /docker-local/docker/sql-auth-service-init/01_permissions.sql: -------------------------------------------------------------------------------- 1 | ALTER USER 'auth-service'@'%' identified WITH mysql_native_password by 'password'; 2 | FLUSH PRIVILEGES; 3 | -------------------------------------------------------------------------------- /docker-local/docker/sql-consent-oracle-init/01_permissions.sql: -------------------------------------------------------------------------------- 1 | ALTER USER 'als-consent-oracle'@'%' identified WITH mysql_native_password by 'password'; 2 | FLUSH PRIVILEGES; 3 | -------------------------------------------------------------------------------- /docker-local/docker/sql-init/01_permissions.sql: -------------------------------------------------------------------------------- 1 | ALTER USER 'central_ledger'@'%' identified WITH mysql_native_password by 'password'; 2 | FLUSH PRIVILEGES; -------------------------------------------------------------------------------- /docker-local/docker/thirdparty-api-svc/default.json: -------------------------------------------------------------------------------- 1 | { 2 | "PORT": 3008, 3 | "HOST": "0.0.0.0", 4 | "INSPECT": { 5 | "DEPTH": 4, 6 | "SHOW_HIDDEN": false, 7 | "COLOR": true 8 | }, 9 | "ENDPOINT_CACHE_CONFIG": { 10 | "expiresIn": 180000, 11 | "generateTimeout": 30000 12 | }, 13 | "ENDPOINT_SERVICE_URL": "http://central-ledger:3001", 14 | "PARTICIPANT_LIST_LOCAL": [ 15 | "dfspa", 16 | "dfspb" 17 | ], 18 | "ERROR_HANDLING": { 19 | "includeCauseExtension": true, 20 | "truncateExtensions": true 21 | }, 22 | "INSTRUMENTATION": { 23 | "METRICS": { 24 | "DISABLED": false, 25 | "labels": { 26 | "eventId": "*" 27 | }, 28 | "config": { 29 | "timeout": 5000, 30 | "prefix": "moja_3p_api", 31 | "defaultLabels": { 32 | "serviceName": "thirdparty-api-svc" 33 | } 34 | } 35 | } 36 | }, 37 | "KAFKA": { 38 | "TOPIC_TEMPLATES": { 39 | "GENERAL_TOPIC_TEMPLATE": { 40 | "TEMPLATE": "topic-{{functionality}}-{{action}}", 41 | "REGEX": "topic-(.*)-(.*)" 42 | } 43 | }, 44 | "CONSUMER": [ 45 | { 46 | "eventType": "notification", 47 | "eventAction": "commit", 48 | "options": { 49 | "mode": 2, 50 | "batchSize": 1, 51 | "pollFrequency": 10, 52 | "recursiveTimeout": 100, 53 | "messageCharset": "utf8", 54 | "messageAsJSON": true, 55 | "sync": true, 56 | "consumeTimeout": 1000 57 | }, 58 | "rdkafkaConf": { 59 | "client.id": "3p-con-notification-event", 60 | "group.id": "3p-group-notification-event", 61 | "metadata.broker.list": "kafka:9092", 62 | "socket.keepalive.enable": true 63 | }, 64 | "topicConf": { 65 | "auto.offset.reset": "earliest" 66 | } 67 | } 68 | ] 69 | }, 70 | "MOCK_CALLBACK": { 71 | "transactionRequestId": "abc-12345", 72 | "pispId": "pisp" 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /docker-local/docker/transaction-requests-service/default.json: -------------------------------------------------------------------------------- 1 | { 2 | "PORT": 4003, 3 | "ENDPOINT_CACHE_CONFIG": { 4 | "expiresIn": 180000, 5 | "generateTimeout": 30000 6 | }, 7 | "SWITCH_ENDPOINT": "http://central-ledger:3001", 8 | "ERROR_HANDLING": { 9 | "includeCauseExtension": true, 10 | "truncateExtensions": true 11 | }, 12 | "INSTRUMENTATION": { 13 | "METRICS": { 14 | "DISABLED": false, 15 | "labels": { 16 | "eventId": "*" 17 | }, 18 | "config": { 19 | "timeout": 5000, 20 | "prefix": "moja_trs_", 21 | "defaultLabels": { 22 | "serviceName": "transaction-requests" 23 | } 24 | } 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/keygen.sh: -------------------------------------------------------------------------------- 1 | #openssl genrsa -des3 -out privatekey.pem 2048 2 | openssl genrsa -out privatekey.pem 2048 3 | openssl req -new -x509 -key privatekey.pem -out publickey.cer -days 1825 -subj "/CN=testingtoolkitdfsp/C=US/ST=Ohio/L=Columbus/O=Testing Toolkit/OU=Payments" 4 | #openssl rsa -in privatekey.pem -pubout -out publickey.cer 5 | #openssl rsa -in privatekey.pem -out privatekey.pem 6 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/privatekey.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN RSA PRIVATE KEY----- 2 | MIIEpQIBAAKCAQEAwczEjlUeOPutgPRlpZSbcbJJwsmmxsBfoPDw1sjBiR7L6Doh 3 | VqKd810+TmiDRYgCzOLabje/mtLiDC95MtuPF5yUiVE04ar6Ny5pZLxJEnbDEOAE 4 | TxOn1gzCKeRHYOcgybDi6TLhnvyFyIaXKzyBhEYvxI8VvRV11UawLqvpgVrdsbZy 5 | 1FQOMLq7OB+J6qC7fhR61F6Wu45RZlZMB482c658P7dCQCdQtEMEF5kuBNB/JuUR 6 | e0qKjl2udKVL3wgBC7J7o7Tx8kY5T63q/ZC3TfoTclFeXtIePt8Eu74u3d6WpSWb 7 | Z12mewRBVPtmbGHgEXpih3uayaqIeC8Dc4zO5QIDAQABAoIBAQCPMGJR36YS6DGL 8 | xAeOTbyERvykxSVKWDzPxvXLXE1SqMRz8u9K+Z/GfjBY8nN7XkDjbQGCygHxvLpz 9 | 0me0IfEZuwEsbCmsSw3Q06PfYBaFY+ZAg6PrYVRynL6hAR+UA3GAVAdz0bpOI7od 10 | LQRoV65CMzF8A1RGfqKvUClAcph2j4lbjjRZ1OExDdcbRCI4h9qgGOMo9o9OEB1X 11 | HHiPhtS1ZwjczqCyJHkkHbOgYNPN7SDy8vHFOVjMDIADF+S/NLrxGUUIUDvNMnGV 12 | D4G8thQD2zSatMjlbJJ+oNt++T/SJMSIiuQTB5zy/KpiMPUN+AXhq5h/dHDcFXhA 13 | ng2deEcJAoGBAOQr1g/s/3V32tQpYloTMOPqIJoVnZnlcXbKy3nWLuOrkVlM0x3V 14 | AEwC7ntb2eOSQ331AvBd/EESgtZr1jvxfsHG+MjwEylcOE33g4MqCKthGcnFA8zG 15 | Z5h6OqTtHdY1bmuiisPvBA4/x2o7mWJz35vT0Sny3cci3f2D6pmPpuq3AoGBANlv 16 | wjWgeDQSR8nTdM1P7zepVdN51f8Fl3r49kMhceVHdwL5iL7q4GkxUgpCyBkFoElW 17 | vmsLgR1fnb+qBtF2kvljQtlRrlgwz1GgYNhp+aAgcAjvQ9fQcvCLr1leXzf6VBHx 18 | jXEIUAlAJVlJ5gWKlDNK9ytjurOvOXipRC4GQKdDAoGBALNOt6RATOjVTYSZGQ9M 19 | MYmKPiCYiAeexbHi4FBYvvRvqYOR2f6BmwAg9aS/o9Uw5hUf7DVUxp2knGlAyVTG 20 | DSTe5jeSYpyIOj8bGaCD8dgsMIXda4ULDfJHa7qcFGx4BNRVIdOkC33fJSkYuQsj 21 | oD/nD2J1109c2TMW7c/LkhK1AoGAUD8xws7tbfJNMkxrMBbPJ5DETx8I/myW4lid 22 | slrWiRLd9mgXsrZGiiwcphLNfIaaCFcOQb1mMmwGcSUUDRwg1A9xLXk6yeuBqBNz 23 | iotaCGHQV0vOkwioUuSKm4X7yFIH0vN+CvhRaYiWACUI0oS5e1CwdgABeK0znbeC 24 | pSXDmLcCgYEA1ls595Ue5cUCmFDvpCIifsATNOMPguKeFuPbYSItQod3P3Bj6txV 25 | phe0jUtWPhIF3I0XOtea2Usvbrj64GMNWLaeK2pdsbIWBlsu2tuqaAfKYiGpGCAh 26 | QWGAPwZ4w7Z3nmA6IhaD6zUnzBGserHv59XttKK0AiQwYMn6UvUIq0M= 27 | -----END RSA PRIVATE KEY----- 28 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/publickey.cer: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIDbjCCAlYCCQDudXfDH36/JjANBgkqhkiG9w0BAQsFADB5MRswGQYDVQQDDBJ0 3 | ZXN0aW5ndG9vbGtpdGRmc3AxCzAJBgNVBAYTAlVTMQ0wCwYDVQQIDARPaGlvMREw 4 | DwYDVQQHDAhDb2x1bWJ1czEYMBYG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ACc6aF/ 21 | -----END CERTIFICATE----- 22 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/tls/createSecrets.sh: -------------------------------------------------------------------------------- 1 | OUTPUT_DIR="." 2 | 3 | rm *.key *.pem *.csr *.crt *.srl 4 | 5 | ## Generating Server CA certificate 6 | openssl genrsa -out "$OUTPUT_DIR/hub_server_cakey.key" 4096 7 | openssl req -new -sha256 -config openssl.conf -nodes -x509 -days 10000 -extensions v3_ca -key "$OUTPUT_DIR/hub_server_cakey.key" -out "$OUTPUT_DIR/hub_server_cacert.pem" -subj '/CN=hubserverca/C=US/ST=Ohio/L=Columbus/O=Hub Server CA/OU=Payments' 8 | 9 | ## Generate server key 10 | openssl genrsa -out "$OUTPUT_DIR/hub_server_key.key" 4096 11 | 12 | ## Generate server csr 13 | openssl req -new -sha256 -config openssl.conf -key hub_server_cakey.key -subj "/C=US/ST=CA/O=Hub Server/CN=mojaloop-testing-toolkit" -out hub_server.csr 14 | 15 | ## Sign server cert 16 | openssl x509 -req -days 3650 -sha256 -extfile openssl.conf -extensions v3_req -in hub_server.csr -signkey hub_server_key.key -CA hub_server_cacert.pem -CAkey hub_server_cakey.key -CAcreateserial -out hub_server_cert.pem 17 | 18 | ## Generating Client CA certificate 19 | openssl genrsa -out "$OUTPUT_DIR/hub_client_cakey.key" 4096 20 | openssl req -new -sha256 -config openssl.conf -nodes -x509 -days 10000 -extensions v3_ca -key "$OUTPUT_DIR/hub_client_cakey.key" -out "$OUTPUT_DIR/hub_client_cacert.pem" -subj '/CN=hubclientca/C=US/ST=Ohio/L=Columbus/O=Hub Client CA/OU=Payments' 21 | 22 | ## Generate client key 23 | openssl genrsa -out "$OUTPUT_DIR/hub_client_key.key" 4096 24 | 25 | ## Generate client csr 26 | openssl req -new -sha256 -key hub_client_key.key -out "$OUTPUT_DIR/hub_client.csr" -subj '/CN=hubclient/C=US/ST=Ohio/L=Columbus/O=Hub Client/OU=Payments/emailAddress=admin@hubclient.com' 27 | 28 | 29 | #openssl x509 -in hub_server_cert.pem -text -noout -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/tls/hub_client.csr: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE REQUEST----- 2 | MIIE1TCCAr0CAQAwgY8xEjAQBgNVBAMMCWh1YmNsaWVudDELMAkGA1UEBhMCVVMx 3 | DTALBgNVBAgMBE9oaW8xETAPBgNVBAcMCENvbHVtYnVzMRMwEQYDVQQKDApIdWIg 4 | Q2xpZW50MREwDwYDVQQLDAhQYXltZW50czEiMCAGCSqGSIb3DQEJARYTYWRtaW5A 5 | aHViY2xpZW50LmNvbTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMXw 6 | zRGgrVa7eiuO6ZgNc16gLTW+akYh86CDIiIYtDIKUcLsmViLVXqMdPbaheMPTNr3 7 | PGhAYyMjRUSf/PtxokTexyfr2ATF1JL8MC9ea6y4nnKfuf5mHdEyWCEGMywNPsVO 8 | 2Dvf8w7RmV+Do/HzE0479lK/JqFAOxeSrNiQXhmJ1gv6Km7E4tuvqVLDhry55LWN 9 | MSpT8dcHoYylzvtutXTlYTZfPAN9J7cqHS/BdXPOw5GM0104RKctR6ma6bCt3OvV 10 | BqrKsvJ+cKOmfj86jYottMWKLlDYkszikqsKOQebqjNj8wDTNX4JhETkjF2WlemN 11 | h4FBTmzmE88ugUY3b+PsySZxsbL1UURZINofsZTGyjV6GETKeGXVbIvJAY4+xpES 12 | vv0QhBjz7aX4rNngbERuMkXa3WF4EYkU1Yl61XnWvYSm5MAF2j+oGoOD4SgxXJxm 13 | Xs5jS4wAYBPA1VkafaXQQ/cCrD+F3kxSy+CHnuTaPt/Dqq89zvN9yMcqwkdIChfY 14 | og8NP01aMe84rkcfQpBVUe9wkgo/lsFqBE9lRuuxhFpGyhNL1g9VJ/DSVIkZm8Ba 15 | 1jcGbl25SdtU0FswGLkl45JpQtjvErdldNerhcxHoAVA1AlqRS71lV8Uq5TqdLHh 16 | fMz8JSV9YEyAc4gP2YBOfonHFtXGyelYHukblHi3AgMBAAGgADANBgkqhkiG9w0B 17 | AQsFAAOCAgEAqHiCShmAw+D0MBPTll4bJMeIk6PhlhV/OaLakDoAu4HjQgaMODP2 18 | uJjX07jRQFiMPFNJNgTJHfdl/azSIsfI56/6XVmUwYENDzwUVHkBo0d9XSCPX+cn 19 | gFRc6J2ccGJO0O+ac8lsvIrAWd72chbhAxm09xQ/iz4aT+zwc7TrpYtn6mdfTkWD 20 | xrNTcuUrT2CBNQKpO3m2oA/lJbnlfoz+m16hJQmmLX5i+qympS9EmH9un5yH4Lx+ 21 | EuiMcuKad4kxQF27hnnp9z/WQr/DR6Y826NpqWDA5gvJcCXo+ACfl+JIQSN54Z68 22 | J0C+1idE5lY12jgXUGBMn3gwAA39hucPDVu4br0Q6oOnYLD8ZnVpsy1Pvf1ekIvb 23 | PJEYOUu8lsuwJQcpdLwrEV2WDFsxRalYTnvYazv+dtBmidSHziZythQZNPcDQNvN 24 | 8OmwEE0t+o9TpEgHRVLonwRm3AfHiEmD/fsj0yylZzg7hSDa9QaQ1TW/nCC/3KfZ 25 | ASztRCe+teibaLbRiLNUwhI+kkYTy1jibeDtb7A/FE8rlnC21e+5/Ds+90FEtcaG 26 | kesHJkC7rtzGlsdZGB0HnDJTWE9vxFsIcHf0+oJ73yKI/17+0DW7jBFp874hdhMj 27 | ip8xnZFDmplztB3aPzIpmNClAcNn5AP+m9cKbg8wY/wmTcRlF7hNAMU= 28 | -----END CERTIFICATE REQUEST----- 29 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/tls/hub_client_cacert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFdjCCA16gAwIBAgIJAL5G4HWE3SsRMA0GCSqGSIb3DQEBCwUAMHAxFDASBgNV 3 | BAMMC2h1YmNsaWVudGNhMQswCQYDVQQGEwJVUzENMAsGA1UECAwET2hpbzERMA8G 4 | A1UEBwwIQ29sdW1idXMxFjA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ADAQH/MA0GCSqGSIb3DQEBCwUAA4ICAQCH/r0Wjh7FKDnXi707BZwgZL4Agu+Z 21 | sntNZx7lbkJKLovpAouN7oHqwSJ5b1r7KOoW8RFZk/5wHBsis1GTU1HHaErAG/KU 22 | jSz7amU1aUCKaXk/qMyEF6oVQ09a06OMYfqhNwzLL+zuzZT274z/WEA9V/EOkLrF 23 | sm34vSZk8RMVwcnja0Tq21K6gk7hJ64cq1/sOtZhS6t6YRnzu7mA0PjnaeHPuGBv 24 | qxYt1WmMvxEzBP6D6NgFRKuwDmZxDH9mV+o3BTktzUh83F40I5rjzXI7Wfw/D3Od 25 | 1Sgypq/rJJowCBWY7NkWfB1Oykl1Ql3ThUNSwDaN8WZLZINQcwjbv5CWoJ8uJ3yX 26 | YNy/29k1jmsjx0/LdH3oHshdhfnekUSqRjHsSHqKuobwr7mivERKIPywQQzqId0+ 27 | SW/Y4wMXroVCSDhApDy5CKXpW1j4fRWQy+vgLZTof3t8mv4znfc+P8M0ET/HoH2Q 28 | q1B8Cwis0JIxfMQJ/HiypVo0g2cPCpqQkhwJk8kFuJccPiCnm9yR5wsmVm0wF1/d 29 | glB2lou8lGNBjnMuRxSjQ6S/k4XNGupV8D9qnoHCrIcfNRwfsNIFFRbbDFn9pfog 30 | IV4kF6529qmxTMcmQXCPhkTHRkTypvPc9Hgxd60GtJVmHIxBFHRWNcSRVFuZtyHm 31 | cTQg3x0mFGAD9Q== 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/tls/hub_server.csr: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE REQUEST----- 2 | MIIEuTCCAqECAQAwUjELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAkNBMRMwEQYDVQQK 3 | DApIdWIgU2VydmVyMSEwHwYDVQQDDBhtb2phbG9vcC10ZXN0aW5nLXRvb2xraXQw 4 | ggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCk2scZn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cSb3KXv/JmUYzJX5/23P6w0hXi7wj 21 | Xuq4Ew7ZAeAZDG8q/iIqCjput3S656jx8GNi+AaFSsa4TkigKzUuC9CyAAC89SYw 22 | 0NcTlGPmYVYKKA6Y8+ryWjSt1CEvn2FmpigRBZqtFvPFkaTQMY48cUgj2ZohV6e+ 23 | irTBqHk6Eo1H8IdkJtjVgcb/4LTTijCzl4k0EnSAJkuo+2yOMUaEzCjIpsmEDwkp 24 | pRBFqrXYEljRL8CKuMNNBukreepadb3HGtzEahjn4bbL6b5fkUuj6dpS+4JI7Xqn 25 | aI1LEfU4YsmlBlvA3KKbBmBcRFtINtOl4a430LJzfKypdgbis6NP0ihd3ssoEycP 26 | ggHh4vpJ40PqBeOeYM9XkJ7yfe8zt6A0/cB23MUV9uWSNKetgZ/1gGt5SiYA800P 27 | PYPQ28YgKQflOEabmw== 28 | -----END CERTIFICATE REQUEST----- 29 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/tls/hub_server_cacert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFdjCCA16gAwIBAgIJAIl8NQS3mbtGMA0GCSqGSIb3DQEBCwUAMHAxFDASBgNV 3 | BAMMC2h1YnNlcnZlcmNhMQswCQYDVQQGEwJVUzENMAsGA1UECAwET2hpbzERMA8G 4 | A1UEBwwIQ29sdW1idXMxFjAUBgNVBAoMDUh1YiBTZXJ2ZXIgQ0ExETAPBgNVBAsM 5 | CFBheW1lbnRzMB4XDTIwMDQwNzIwMjA0MloXDTQ3MDgyNDIwMjA0MlowcDEUMBIG 6 | A1UEAwwLaHVic2VydmVyY2ExCzAJBgNVBAYTAlVTMQ0wCwYDVQQIDARPaGlvMREw 7 | DwYDVQQHDAhDb2x1bWJ1czEWMBQGA1UECgwNSHViIFNlcnZlciBDQTERMA8GA1UE 8 | CwwIUGF5bWVudHMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCk2scZ 9 | n0PznJdCjD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twPVMB+3ZCXK9ZPnezP3ZO6x4DRZUHahSwYiFkeb4+1NqIsTx5nLKZPm/fEkjg 26 | 4bXVH1X4YuRRHMm33PHJR0ujH51zYAC2U10mOAPJq7u/S/h4JpZDr24A3ne7tQ3G 27 | rIMrPZsy5pY2794DXfOnO2fqIcyRSulm6s/tYw+3FPm4/7oi9eQKfoyAz9J+2DEE 28 | PTlrkYT0AlhZki90I+jETBNXVwmWnMykAMuExW5xw6EiteM4uYmQn9l/Wsd3NEVZ 29 | Ds7RFZrYWcPPHw0uaPIL5KQE6w2JgS+fraduc6kvBFgVfZIxJ97anVp6WzwLISbv 30 | aQyfltKvLrsSsrAmNDlWscKfJbgVt64ZbF1kVTeHNTgR1I0X8vf4v5CQm18X+D2C 31 | /q24z8GZ2Wwxxw== 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/tls/hub_server_cacert.srl: -------------------------------------------------------------------------------- 1 | ECF605B40A1A7D39 2 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/secrets/tls/openssl.conf: -------------------------------------------------------------------------------- 1 | [ req ] 2 | distinguished_name = req_distinguished_name 3 | extensions = v3_ca 4 | req_extensions = v3_ca 5 | [ v3_ca ] 6 | basicConstraints = critical,CA:TRUE 7 | [ v3_req ] 8 | basicConstraints = CA:FALSE 9 | extendedKeyUsage = serverAuth, clientAuth, codeSigning, emailProtection 10 | 11 | [ req_distinguished_name ] 12 | countryName = US 13 | countryName_default = KR 14 | countryName_min = 2 15 | countryName_max = 2 16 | organizationName = User DFSP CA 17 | organizationName_default = User DFSP CA -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/api_definitions/central_admin_9.3/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/health": { 3 | "get": { 4 | "response": {} 5 | } 6 | }, 7 | "/metrics": { 8 | "get": { 9 | "response": {} 10 | } 11 | }, 12 | "/participants": { 13 | "get": { 14 | "response": {} 15 | }, 16 | "post": { 17 | "response": {} 18 | } 19 | }, 20 | "/participants/limits": { 21 | "get": { 22 | "response": {} 23 | } 24 | }, 25 | "/participants/{name}": { 26 | "get": { 27 | "response": {} 28 | }, 29 | "put": { 30 | "response": {} 31 | } 32 | }, 33 | "/participants/{name}/endpoints": { 34 | "get": { 35 | "response": {} 36 | }, 37 | "post": { 38 | "response": {} 39 | } 40 | }, 41 | "/participants/{name}/limits": { 42 | "get": { 43 | "response": {} 44 | }, 45 | "put": { 46 | "response": {} 47 | } 48 | }, 49 | "/participants/{name}/positions": { 50 | "get": { 51 | "response": {} 52 | } 53 | }, 54 | "/participants/{name}/accounts": { 55 | "get": { 56 | "response": {} 57 | }, 58 | "post": { 59 | "response": {} 60 | } 61 | }, 62 | "/participants/{name}/initialPositionAndLimits": { 63 | "post": { 64 | "response": {} 65 | } 66 | }, 67 | "/participants/{name}/accounts/{id}": { 68 | "put": { 69 | "response": {} 70 | }, 71 | "post": { 72 | "response": {} 73 | } 74 | }, 75 | "/participants/{name}/accounts/{id}/transfers/{transferId}": { 76 | "put": { 77 | "response": {} 78 | } 79 | }, 80 | "/settlementModels": { 81 | "get": { 82 | "response": {} 83 | }, 84 | "post": { 85 | "response": {} 86 | } 87 | }, 88 | "/settlementModels/{name}": { 89 | "get": { 90 | "response": {} 91 | }, 92 | "put": { 93 | "response": {} 94 | } 95 | } 96 | } -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/api_definitions/fspiop_1.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "party.personalInfo.complexName.firstName", 4 | "pattern": "John|David|Michael|Chris|Mike|Mark|Paul|Daniel|James|Maria" 5 | }, 6 | { 7 | "id": "party.personalInfo.complexName.middleName", 8 | "pattern": "G|P|N|S" 9 | }, 10 | { 11 | "id": "party.personalInfo.complexName.lastName", 12 | "pattern": "Smith|Jones|Johnson|Lee|Brown|Williams|Rodriguez|Garcia|Gonzalez|Lopez" 13 | }, 14 | { 15 | "id": "party.personalInfo.dateOfBirth", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "transferId", 20 | "faker": "internet.email" 21 | }, 22 | { 23 | "id": "transferState", 24 | "pattern": "COMMITTED|RESERVED|ABORTED|RECEIVED" 25 | }, 26 | { 27 | "id": "fulfilment", 28 | "pattern": "[A-Fa-f0-9]{64}" 29 | }, 30 | { 31 | "id": "condition", 32 | "pattern": "[A-Fa-f0-9]{64}" 33 | }, 34 | { 35 | "id": "ilpPacket", 36 | "pattern": "[A-Fa-f0-9]{256}" 37 | }, 38 | { 39 | "id": "transferAmount.currency", 40 | "pattern": "USD" 41 | }, 42 | { 43 | "id": "transferAmount.amount", 44 | "pattern": "123" 45 | }, 46 | { 47 | "id": "payeeReceiveAmount.currency", 48 | "pattern": "USD" 49 | }, 50 | { 51 | "id": "payeeReceiveAmount.amount", 52 | "pattern": "123" 53 | }, 54 | { 55 | "id": "payeeFspFee.currency", 56 | "pattern": "USD" 57 | }, 58 | { 59 | "id": "payeeFspFee.amount", 60 | "pattern": "2" 61 | }, 62 | { 63 | "id": "payeeFspCommission.currency", 64 | "pattern": "USD" 65 | }, 66 | { 67 | "id": "payeeFspCommission.amount", 68 | "pattern": "3" 69 | }, 70 | 71 | { 72 | "id": "errorInformation.errorCode", 73 | "pattern": "600[1-9]" 74 | }, 75 | { 76 | "id": "errorInformation.errorDescription", 77 | "pattern": "This is a mock error description" 78 | }, 79 | { 80 | "id": "Content-Length", 81 | "pattern": "123" 82 | } 83 | ] -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/api_definitions/fspiop_1.1/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "party.personalInfo.complexName.firstName", 4 | "pattern": "John|David|Michael|Chris|Mike|Mark|Paul|Daniel|James|Maria" 5 | }, 6 | { 7 | "id": "party.personalInfo.complexName.middleName", 8 | "pattern": "G|P|N|S" 9 | }, 10 | { 11 | "id": "party.personalInfo.complexName.lastName", 12 | "pattern": "Smith|Jones|Johnson|Lee|Brown|Williams|Rodriguez|Garcia|Gonzalez|Lopez" 13 | }, 14 | { 15 | "id": "party.personalInfo.dateOfBirth", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "transferId", 20 | "faker": "internet.email" 21 | }, 22 | { 23 | "id": "transferState", 24 | "pattern": "COMMITTED|RESERVED|ABORTED|RECEIVED" 25 | }, 26 | { 27 | "id": "fulfilment", 28 | "pattern": "[A-Fa-f0-9]{64}" 29 | }, 30 | { 31 | "id": "condition", 32 | "pattern": "[A-Fa-f0-9]{64}" 33 | }, 34 | { 35 | "id": "ilpPacket", 36 | "pattern": "[A-Fa-f0-9]{256}" 37 | }, 38 | { 39 | "id": "transferAmount.currency", 40 | "pattern": "USD" 41 | }, 42 | { 43 | "id": "transferAmount.amount", 44 | "pattern": "123" 45 | }, 46 | { 47 | "id": "payeeReceiveAmount.currency", 48 | "pattern": "USD" 49 | }, 50 | { 51 | "id": "payeeReceiveAmount.amount", 52 | "pattern": "123" 53 | }, 54 | { 55 | "id": "payeeFspFee.currency", 56 | "pattern": "USD" 57 | }, 58 | { 59 | "id": "payeeFspFee.amount", 60 | "pattern": "2" 61 | }, 62 | { 63 | "id": "payeeFspCommission.currency", 64 | "pattern": "USD" 65 | }, 66 | { 67 | "id": "payeeFspCommission.amount", 68 | "pattern": "3" 69 | }, 70 | 71 | { 72 | "id": "errorInformation.errorCode", 73 | "pattern": "600[1-9]" 74 | }, 75 | { 76 | "id": "errorInformation.errorDescription", 77 | "pattern": "This is a mock error description" 78 | }, 79 | { 80 | "id": "Content-Length", 81 | "pattern": "123" 82 | } 83 | ] -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/api_definitions/settlements_1.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "changedDate", 4 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 5 | }, 6 | { 7 | "id": "createdDate", 8 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 9 | }, 10 | { 11 | "id": "state", 12 | "pattern": "OPEN|CLOSED" 13 | }, 14 | { 15 | "id": "settlementWindows.items.items.createdDate", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "settlementWindows.items.items.changedDate", 20 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 21 | }, 22 | { 23 | "id": "settlementWindows.items.items.state", 24 | "pattern": "OPEN|CLOSED" 25 | }, 26 | { 27 | "id": "participants.items.accounts.items.state", 28 | "pattern": "OPEN|CLOSED" 29 | }, 30 | { 31 | "id": "participants.items.accounts.items.netSettlementAmount.amount", 32 | "pattern": "123" 33 | }, 34 | { 35 | "id": "participants.items.accounts.items.netSettlementAmount.currency", 36 | "pattern": "USD" 37 | } 38 | ] -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/api_definitions/settlements_1.0/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/settlementWindows/{id}": { 3 | "post": { 4 | "response": { 5 | "bodyOverride": { 6 | "id": "{$request.params.id}", 7 | "reason": "{$request.body.reason}" 8 | } 9 | } 10 | } 11 | }, 12 | "/settlementWindows": { 13 | "get": { 14 | "response": {} 15 | } 16 | }, 17 | "/settlements": { 18 | "post": { 19 | "response": { 20 | "bodyOverride": { 21 | } 22 | } 23 | } 24 | }, 25 | "/settlements/{id}": { 26 | "get": { 27 | "response": { 28 | "bodyOverride": { 29 | "id": "{$request.params.id}" 30 | } 31 | } 32 | } 33 | } 34 | } -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/api_definitions/thirdparty_simulator/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/login": { 3 | "post": { 4 | "response": { 5 | "bodyOverride": {} 6 | } 7 | } 8 | }, 9 | "/authorize": { 10 | "post": { 11 | "response": { 12 | "bodyOverride": {} 13 | } 14 | } 15 | }, 16 | "/sendOTP": { 17 | "post": { 18 | "response": { 19 | "bodyOverride": {} 20 | } 21 | } 22 | }, 23 | "/verifyOTPorSecret": { 24 | "post": { 25 | "response": { 26 | "bodyOverride": {} 27 | } 28 | } 29 | }, 30 | "/OTPorSecret/{ID}": { 31 | "get": { 32 | "response": { 33 | "bodyOverride": {} 34 | } 35 | } 36 | }, 37 | "/store/consentRequests/{ID}": { 38 | "get": { 39 | "response": { 40 | "bodyOverride": {} 41 | } 42 | }, 43 | "post": { 44 | "response": { 45 | "bodyOverride": {} 46 | } 47 | } 48 | } 49 | } -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/rules_callback/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } 4 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/rules_response/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/rules_validation/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } 4 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/system_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "API_PORT": 5000, 3 | "HOSTING_ENABLED": false, 4 | "CONFIG_VERSIONS": { 5 | "response": 1, 6 | "callback": 1, 7 | "validation": 1, 8 | "forward": 1, 9 | "userSettings": 1 10 | }, 11 | "DB": { 12 | "URI": "mongodb://login-flow-simulator-mongo:27017/dfsps" 13 | }, 14 | "OAUTH": { 15 | "AUTH_ENABLED": false, 16 | "APP_OAUTH_CLIENT_KEY": "asdf", 17 | "APP_OAUTH_CLIENT_SECRET": "asdf", 18 | "MTA_ROLE": "Application/MTA", 19 | "PTA_ROLE": "Application/PTA", 20 | "EVERYONE_ROLE": "Internal/everyone", 21 | "OAUTH2_ISSUER": "http://ml-testing-toolkit:5050/api/oauth2/token", 22 | "JWT_COOKIE_NAME": "TTK-API_ACCESS_TOKEN", 23 | "EMBEDDED_CERTIFICATE": "password" 24 | }, 25 | "CONNECTION_MANAGER": { 26 | "API_URL": "http://connection-manager-api:5061", 27 | "AUTH_ENABLED": false, 28 | "HUB_USERNAME": "hub", 29 | "HUB_PASSWORD": "hub" 30 | }, 31 | "KEYCLOAK": { 32 | "ENABLED": false, 33 | "API_URL": "http://172.17.0.1:9080", 34 | "REALM": "testingtoolkit", 35 | "USERNAME": "hub", 36 | "PASSWORD": "hub" 37 | }, 38 | "API_DEFINITIONS": [ 39 | { 40 | "type": "fspiop", 41 | "version": "1.0", 42 | "folderPath": "fspiop_1.0", 43 | "asynchronous": true 44 | }, 45 | { 46 | "type": "fspiop", 47 | "version": "1.1", 48 | "folderPath": "fspiop_1.1", 49 | "asynchronous": true 50 | }, 51 | { 52 | "type": "thirdparty_simulator", 53 | "version": "0.1", 54 | "folderPath": "thirdparty_simulator" 55 | }, 56 | { 57 | "type": "settlements", 58 | "version": "1.0", 59 | "folderPath": "settlements_1.0" 60 | }, 61 | { 62 | "type": "central_admin", 63 | "version": "9.3", 64 | "folderPath": "central_admin_9.3" 65 | }, 66 | { 67 | "type": "thirdparty_pisp", 68 | "version": "0.1", 69 | "folderPath": "thirdparty_pisp", 70 | "asynchronous": true 71 | } 72 | ] 73 | } 74 | -------------------------------------------------------------------------------- /docker-local/ml-testing-toolkit/spec_files/user_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "VERSION": 1, 3 | "CALLBACK_ENDPOINT": "http://pisp-sim-scheme-adapter:8000", 4 | "ALS_ENDPOINT": "http://account-lookup-service:4002", 5 | "CALLBACK_RESOURCE_ENDPOINTS": { 6 | "enabled": false, 7 | "endpoints": [ 8 | { 9 | "method": "put", 10 | "path": "/parties/{Type}/{ID}", 11 | "endpoint": "http://localhost:4002" 12 | }, 13 | { 14 | "method": "put", 15 | "path": "/quotes/{ID}", 16 | "endpoint": "http://localhost:3002" 17 | }, 18 | { 19 | "method": "put", 20 | "path": "/transfers/{ID}", 21 | "endpoint": "http://localhost:3000" 22 | } 23 | ] 24 | }, 25 | "HUB_ONLY_MODE": false, 26 | "ENDPOINTS_DFSP_WISE": { 27 | "dfsps": {} 28 | }, 29 | "SEND_CALLBACK_ENABLE": true, 30 | "FSPID": "pisp-sim", 31 | "DEFAULT_USER_FSPID": "userdfsp", 32 | "TRANSFERS_VALIDATION_WITH_PREVIOUS_QUOTES": true, 33 | "TRANSFERS_VALIDATION_ILP_PACKET": true, 34 | "TRANSFERS_VALIDATION_CONDITION": true, 35 | "ILP_SECRET": "secret", 36 | "VERSIONING_SUPPORT_ENABLE": true, 37 | "VALIDATE_INBOUND_JWS": false, 38 | "VALIDATE_INBOUND_PUT_PARTIES_JWS": false, 39 | "JWS_SIGN": false, 40 | "JWS_SIGN_PUT_PARTIES": false, 41 | "INBOUND_MUTUAL_TLS_ENABLED": false, 42 | "OUTBOUND_MUTUAL_TLS_ENABLED": false, 43 | "ADVANCED_FEATURES_ENABLED": true, 44 | "CALLBACK_TIMEOUT": 20000 45 | } 46 | -------------------------------------------------------------------------------- /docker-local/pisp/pisp_rules.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "ruleId": 1, 4 | "description": "Successfully accepting request", 5 | "conditions": { 6 | "all": [ 7 | { 8 | "fact": "path", 9 | "operator": "equal", 10 | "value": "/authorizations" 11 | }, 12 | { 13 | "fact": "method", 14 | "operator": "equal", 15 | "value": "POST" 16 | } 17 | ] 18 | }, 19 | "event": { 20 | "type": "FIXED_CALLBACK", 21 | "params": { 22 | "statusCode": 202, 23 | "body": "" 24 | } 25 | } 26 | } 27 | ] -------------------------------------------------------------------------------- /docker-local/pisp/secrets/pisp_client.crt: --------------------------------------------------------------------------------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jatuuvCSilIOUrVdrofYEg2S3Ln636rbEB60IZ8VD/q 18 | YTfcoijtRMRWwoWzvLEcA/G22KH/CN8bcCsVWxol0ZOxFs2jrbJcjp2H7wxRsZdE 19 | CSJWd7/ZIZbHJWc+umIaIBXyE9nX1tmd7V3LsyXTdXSXoI0ngS5dFkXsfWWrNYOb 20 | KYVqltlTfmUMqxiYd5WzhF27Jt/8XiXsgYySwB8rw25eq3S1AgMBAAEwDQYJKoZI 21 | hvcNAQELBQADggIBABN8SxBSBvjDtYmJ05u0k3ZCrIT8yF+zmr61bI9Myys4HAg/ 22 | tRvGltk0nnEnSf6kptBLaLk42zu60gABkEfg4OtJwdS8Ujbm4Munvw/fFyktz5QD 23 | xs3vhmwdjiFIbsBcWV3lgtSYODrTkfn+FB1bLbea5dFoAdTPHuKhrVroAQa/Itaf 24 | +srfeDXVfjUYhjv6bg9KcwIUy5ePGhIzt6z00tx2srXOmXVspjh23hWd2MOTytvA 25 | nx1qNYl+VCajUsZZEMPM6M7KVsTiZzAe4QUkeCn31JjcStbcBqyEelqezruvWhDH 26 | EfQmd+9GgBNUV9aqrVZu2ms9tlLswMHR1UuKjMFrYoz+uDj7LTY4VsCMl1V3lhhT 27 | d8y7Q33g1nRhCHcov5W8CAm1yNmhJ5FFD2OdCyUtX821TzXQAb8qax6XkOaNSdk0 28 | BiYjIa4/Ugpbe3EVt5Y4bg3b2X8GBf+XMWaci+q6CUSouoSIJ4utp0NpMTWT47Sp 29 | CaEnim85jZKUXFKpR7tQzAhVHy5fh4lG8iYwQVIzPcLhNE9neo3xGK8kVncaupjK 30 | C9feyVRwu+5t0PObTcad4XMr2XebhyplRvWTyAKJVbO0uAgYTpl4p+bfO2rBGelQ 31 | EEjHHDwxWwk/kp+jChXpRG9iL4ESdsTaGcdTZv77UG00WmlbHa2czxv02sVD 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-local/pisp/secrets/pisp_server.crt: -------------------------------------------------------------------------------- 1 | -----BEGIN C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8rEgMICR7rhM0uLaz0qX6FvxVGle3XynQ 18 | VS9CLD0Zgzj/tmkVI/QLyemKAzC50qjDqkufnQoDCVLUNRWHh7MzhwboBaIUABqx 19 | Sjnt2okNnevUhRmtegEeJNnz594hKe6n3ogJbpZaS+9dvbA1NPJX+iF9kFyPzDQY 20 | V8L3pAHHqiRpgK7Mp8epUKL7hLHLj9RkvPCHNzq4Cvr7xDEnZK0CAwEAAaMhMB8w 21 | HQYDVR0lBBYwFAYIKwYBBQUHAwEGCCsGAQUFBwMCMA0GCSqGSIb3DQEBCwUAA4IC 22 | AQBoCPHnIZxLKduXp0F+dAEH5ALI/yvjP9mBAAErTInZ3Qva4O7m8jM61PTwyy6v 23 | 2I7I7++zT2wPujk/qtSvtfO5fCCB5nuQW9Bk3yT7SUDGFBQ7f5xd+iUaqtGmKpHQ 24 | kEtqmu89oeDT5aSievyEJGaZTWrb86lxFoAOK4dNrUshzaIsjr9/0wk3sL85gDsO 25 | bwhKUc1qGg883poAx19xG9+tlvYOJ73lhytIz30zqk3R5ZAuq+VZukzyFsZrk1Gc 26 | UWe74zb2x7O2EnRU1SDDU7KEyHpjVQX2j+qDXiXExX24KAYubhzM/Oq7wqf4o7R6 27 | lwW8wBg/jOR9uX6d8VOiVBsTZtO/feEeH8TY3pUg+B2F+F5mAsARki4PiBzWgKKY 28 | 8b7Uc6s3xFcewwVhDCAh2Lw8mDcyZMEIpVWe68YIYxCG3+OtNFrIFPAfJoni1vRQ 29 | uI2+xU5JS860cJLpIyy6NAfTO8bvjz1/+OHPrUH05EouEodqhwixEDm8PPN648jD 30 | WLa4PHCo+5Px0LZe05GnqgY7NN/SQdjfso/Gj7ZB+qYKbTx5BMwpWl9bBzHfM/T5 31 | hQOkuehT8rjrO+CLg9IpoWzGZoaGu2CFuUUAj+/hD1I0wX9As+Sv66YBWJOKuOGd 32 | ei6F1OP6VTgkTc5mXphN6f9bkKcVrrosjSKG11oVXD8qJw== 33 | -----END CERTIFICATE----- 34 | -------------------------------------------------------------------------------- /docker-local/postman/.gitignore: -------------------------------------------------------------------------------- 1 | **/.DS_Store 2 | .idea/** 3 | -------------------------------------------------------------------------------- /docker-local/postman/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM node:10.15.3-alpine 2 | 3 | WORKDIR /opt/postman 4 | 5 | COPY . /opt/postman/ 6 | 7 | RUN npm install -g newman -------------------------------------------------------------------------------- /docker-local/postman/LICENSE.md: -------------------------------------------------------------------------------- 1 | # LICENSE 2 | 3 | Copyright © 2020-2025 Mojaloop Foundation 4 | 5 | The Mojaloop files are made available by the Mojaloop Foundation under the Apache License, Version 2.0 6 | (the "License") and you may not use these files except in compliance with the [License](http://www.apache.org/licenses/LICENSE-2.0). 7 | 8 | You may obtain a copy of the License at [http://www.apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0) 9 | 10 | Unless required by applicable law or agreed to in writing, the Mojaloop files are distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the [License](http://www.apache.org/licenses/LICENSE-2.0). 11 | -------------------------------------------------------------------------------- /docker-local/postman/PISP Local Playground.postman_collection.json: -------------------------------------------------------------------------------- 1 | { 2 | "info": { 3 | "_postman_id": "75e90dcb-9438-4f70-acaf-5f4e56933baa", 4 | "name": "PISP Local Playground", 5 | "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" 6 | }, 7 | "item": [ 8 | { 9 | "name": "POST /authorization", 10 | "item": [ 11 | { 12 | "name": "fire POST /authorization on dfsp B scheme adapter", 13 | "request": { 14 | "method": "POST", 15 | "header": [], 16 | "body": { 17 | "mode": "raw", 18 | "raw": "{\n\t\"toParticipantId\": \"pisp\",\n\t\"authenticationType\": \"U2F\",\n\t\"retriesLeft\": \"1\",\n\t\"amount\": {\n\t\t\"currency\": \"USD\",\n\t\t\"amount\": \"100\"\n\t},\n\t\"transactionId\": \"c87e9f61-e0d1-4a1c-a992-002718daf402\",\n\t\"transactionRequestId\": \"aca279be-60c6-42ff-aab5-901d61b5e35c\",\n\t\"quote\": {\n\t\t\"transferAmount\": {\n\t\t\t\"currency\": \"USD\",\n\t\t\t\"amount\": \"105\"\n\t\t},\n\t\t\"expiration\": \"2020-07-15T09:48:54.961Z\",\n\t\t\"ilpPacket\": \"ilp-packet-value\",\n\t\t\"condition\": \"condition-000000000-111111111-222222222-abc\"\n\t}\n}", 19 | "options": { 20 | "raw": { 21 | "language": "json" 22 | } 23 | } 24 | }, 25 | "url": { 26 | "raw": "http://localhost:6002/authorizations", 27 | "protocol": "http", 28 | "host": [ 29 | "localhost" 30 | ], 31 | "port": "6002", 32 | "path": [ 33 | "authorizations" 34 | ] 35 | } 36 | }, 37 | "response": [] 38 | } 39 | ], 40 | "protocolProfileBehavior": {} 41 | } 42 | ], 43 | "protocolProfileBehavior": {} 44 | } -------------------------------------------------------------------------------- /docker-local/postman/scripts/_00_seed_all.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | 5 | cd ${DIR} 6 | # tolerate errors here, since postman collections are not idempotent 7 | ./_01_seed_hub_account.sh 8 | set -e 9 | set -u 10 | 11 | # need to run settlement models towards beginning 12 | ./_12_seed_settlement_models.sh 13 | ./_02_seed_oracle.sh 14 | ./_03_seed_dfspa.sh 15 | ./_04_seed_dfspb.sh 16 | ./_05_seed_pisp.sh 17 | ./_13_seed_centralAuth.sh 18 | ./_06_seed_dfsp_simulator.sh 19 | ./_07_seed_dfsp_a_msisdn.sh 20 | ./_08_seed_dfsp_b_msisdn.sh 21 | ./_09_seed_dfsp_simulator_msisdn.sh 22 | ./_10_seed_pisp_msisdn.sh 23 | ./_11_seed_dfsp_backend_parties.sh 24 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_01_seed_hub_account.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Hub Account' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_02_seed_oracle.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Oracle Onboarding' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_03_seed_dfspa.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='payerfsp (p2p transfers)' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment_DFSP_PAYER.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_04_seed_dfspb.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='payeefsp (p2p transfers)' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment_DFSP_PAYEE.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_05_seed_pisp.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='pisp (data setup)' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment_PISP.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_06_seed_dfsp_simulator.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='payeefsp (p2p transfers)' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment_DFSP_SIMULATOR.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_07_seed_dfsp_a_msisdn.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Oracle Onboarding-MSISDN-DFSP-A' \ 11 | --environment="${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment.json" \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_08_seed_dfsp_b_msisdn.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Oracle Onboarding-MSISDN-DFSP-B' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment_DFSP_PAYEE.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_09_seed_dfsp_simulator_msisdn.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Oracle Onboarding-MSISDN-SIMULATOR' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment_DFSP_SIMULATOR.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | 14 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_10_seed_pisp_msisdn.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Oracle Onboarding-MSISDN-PISP' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_11_seed_dfsp_backend_parties.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Add parties to DFSP backends' \ 11 | ${POSTMAN_DIR}/PISP.postman_collection.json.postman_collection.json 12 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_12_seed_settlement_models.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='Settlement Models' \ 11 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment.json \ 12 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 13 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/_13_seed_centralAuth.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | # todo: create environment for centralAuth auth-service. right now collection that 9 | # populate participant endpoints uses hard coded values 10 | newman run \ 11 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 12 | --folder='centralAuth auth-service (data setup)' \ 13 | --environment=${POSTMAN_DIR}/environments/Mojaloop-Local-Docker-Compose.postman_environment_DFSP_PAYER.json \ 14 | ${POSTMAN_DIR}/OSS-New-Deployment-FSP-Setup-DFSPS.postman_collection.json 15 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/test-E2E-transaction-req-initiated-by-PISP.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='PISP-Initiate-TRX-Reqs-Tests' \ 11 | ${POSTMAN_DIR}/PISP.postman_collection.json.postman_collection.json 12 | -------------------------------------------------------------------------------- /docker-local/postman/scripts/testE2ETransfers.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PATH=$(cd ${DIR} && npm bin):$PATH 5 | POSTMAN_DIR="${DIR}/.." 6 | NEWMAN_REQUEST_DELAY=${NEWMAN_REQUEST_DELAY:=100} 7 | 8 | newman run \ 9 | --delay-request=${NEWMAN_REQUEST_DELAY} \ 10 | --folder='E2E Tests' \ 11 | ${POSTMAN_DIR}/PISP.postman_collection.json.postman_collection.json 12 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/keygen.sh: -------------------------------------------------------------------------------- 1 | #openssl genrsa -des3 -out privatekey.pem 2048 2 | openssl genrsa -out privatekey.pem 2048 3 | openssl req -new -x509 -key privatekey.pem -out publickey.cer -days 1825 -subj "/CN=testingtoolkitdfsp/C=US/ST=Ohio/L=Columbus/O=Testing Toolkit/OU=Payments" 4 | #openssl rsa -in privatekey.pem -pubout -out publickey.cer 5 | #openssl rsa -in privatekey.pem -out privatekey.pem 6 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/privatekey.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN RSA PRIVATE KEY----- 2 | MIIEpQIBAAKCAQEAwczEjlUeOPutgPRlpZSbcbJJwsmmxsBfoPDw1sjBiR7L6Doh 3 | VqKd810+TmiDRYgCzOLabje/mtLiDC95MtuPF5yUiVE04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RvqYOR2f6BmwAg9aS/o9Uw5hUf7DVUxp2knGlAyVTG 20 | DSTe5jeSYpyIOj8bGaCD8dgsMIXda4ULDfJHa7qcFGx4BNRVIdOkC33fJSkYuQsj 21 | oD/nD2J1109c2TMW7c/LkhK1AoGAUD8xws7tbfJNMkxrMBbPJ5DETx8I/myW4lid 22 | slrWiRLd9mgXsrZGiiwcphLNfIaaCFcOQb1mMmwGcSUUDRwg1A9xLXk6yeuBqBNz 23 | iotaCGHQV0vOkwioUuSKm4X7yFIH0vN+CvhRaYiWACUI0oS5e1CwdgABeK0znbeC 24 | pSXDmLcCgYEA1ls595Ue5cUCmFDvpCIifsATNOMPguKeFuPbYSItQod3P3Bj6txV 25 | phe0jUtWPhIF3I0XOtea2Usvbrj64GMNWLaeK2pdsbIWBlsu2tuqaAfKYiGpGCAh 26 | QWGAPwZ4w7Z3nmA6IhaD6zUnzBGserHv59XttKK0AiQwYMn6UvUIq0M= 27 | -----END RSA PRIVATE KEY----- 28 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/publickey.cer: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIDbjCCAlYCCQDudXfDH36/JjANBgkqhkiG9w0BAQsFADB5MRswGQYDVQQDDBJ0 3 | ZXN0aW5ndG9vbGtpdGRmc3AxCzAJBgNVBAYTAlVTMQ0wCwYDVQQIDARPaGlvMREw 4 | DwYDVQQHDAhDb2x1bWJ1czEYMBYGA1UECgwPVGVzdGluZyBUb29sa2l0MREwDwYD 5 | VQQLDAhQYXltZW50czAeFw0yMDAzMjQxNzU1MjZaFw0yNTAzMjMxNzU1MjZaMHkx 6 | GzAZBgNVBAMMEnRlc3Rpbmd0b29sa2l0ZGZzcDELMAkGA1UEBhMCVVMxDTALBgNV 7 | BAgMBE9oaW8xETAPBgNVBAcMCENvbHVtYnVzMRgwFgYDVQQKDA9UZXN0aW5nIFRv 8 | b2xraXQxETAPBgNVBAsMCFBheW1lbnRzMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A 9 | MIIBCgKCAQEAwczEjlUeOPutgPRlpZSbcbJJwsmmxsBfoPDw1sjBiR7L6DohVqKd 10 | 810+TmiDRYgCzOLabje/mtLiDC95MtuPF5yUiVE04ar6Ny5pZLxJEnbDEOAETxOn 11 | 1gzCKeRHYOcgybDi6TLhnvyFyIaXKzyBhEYvxI8VvRV11UawLqvpgVrdsbZy1FQO 12 | MLq7OB+J6qC7fhR61F6Wu45RZlZMB482c658P7dCQCdQtEMEF5kuBNB/JuURe0qK 13 | jl2udKVL3wgBC7J7o7Tx8kY5T63q/ZC3TfoTclFeXtIePt8Eu74u3d6WpSWbZ12m 14 | ewRBVPtmbGHgEXpih3uayaqIeC8Dc4zO5QIDAQABMA0GCSqGSIb3DQEBCwUAA4IB 15 | AQAZ1lQ/KcSGwy/jQUIGF87JugLU17nnIEG2TrkC5n+fZDQqs8QqU6itbkdGQyNj 16 | F5aLoPEdrKzevnBztlAEq0bofR0uDnQPN74A/NwOUfWds0hq5elZnO9Uq0G15Go4 17 | pfqLbSjHxSu6LZaHP6f9+WvMqNbGr3kipz8GSIQWixzdKBnNxCwWjZmk4gD5cahU 18 | XIpMAZumsnKk6pWilmuMIxC579CyLkGdVze3Kj6GunUJ1pieZzv4+RUJz8NgXxjW 19 | ZRwqCkEqPe/8S1X9srtcrdbHryDdC18Ldu/rADEKbSqy0BhQdKYDcxulaQuqibwD 20 | i0dWSdTWoseAbUqp2ACc6aF/ 21 | -----END CERTIFICATE----- 22 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/tls/createSecrets.sh: -------------------------------------------------------------------------------- 1 | OUTPUT_DIR="." 2 | 3 | rm *.key *.pem *.csr *.crt *.srl 4 | 5 | ## Generating Server CA certificate 6 | openssl genrsa -out "$OUTPUT_DIR/hub_server_cakey.key" 4096 7 | openssl req -new -sha256 -config openssl.conf -nodes -x509 -days 10000 -extensions v3_ca -key "$OUTPUT_DIR/hub_server_cakey.key" -out "$OUTPUT_DIR/hub_server_cacert.pem" -subj '/CN=hubserverca/C=US/ST=Ohio/L=Columbus/O=Hub Server CA/OU=Payments' 8 | 9 | ## Generate server key 10 | openssl genrsa -out "$OUTPUT_DIR/hub_server_key.key" 4096 11 | 12 | ## Generate server csr 13 | openssl req -new -sha256 -config openssl.conf -key hub_server_cakey.key -subj "/C=US/ST=CA/O=Hub Server/CN=mojaloop-testing-toolkit" -out hub_server.csr 14 | 15 | ## Sign server cert 16 | openssl x509 -req -days 3650 -sha256 -extfile openssl.conf -extensions v3_req -in hub_server.csr -signkey hub_server_key.key -CA hub_server_cacert.pem -CAkey hub_server_cakey.key -CAcreateserial -out hub_server_cert.pem 17 | 18 | ## Generating Client CA certificate 19 | openssl genrsa -out "$OUTPUT_DIR/hub_client_cakey.key" 4096 20 | openssl req -new -sha256 -config openssl.conf -nodes -x509 -days 10000 -extensions v3_ca -key "$OUTPUT_DIR/hub_client_cakey.key" -out "$OUTPUT_DIR/hub_client_cacert.pem" -subj '/CN=hubclientca/C=US/ST=Ohio/L=Columbus/O=Hub Client CA/OU=Payments' 21 | 22 | ## Generate client key 23 | openssl genrsa -out "$OUTPUT_DIR/hub_client_key.key" 4096 24 | 25 | ## Generate client csr 26 | openssl req -new -sha256 -key hub_client_key.key -out "$OUTPUT_DIR/hub_client.csr" -subj '/CN=hubclient/C=US/ST=Ohio/L=Columbus/O=Hub Client/OU=Payments/emailAddress=admin@hubclient.com' 27 | 28 | 29 | #openssl x509 -in hub_server_cert.pem -text -noout -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/tls/hub_client.csr: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE REQUEST----- 2 | MIIE1TCCAr0CAQAwgY8xEjAQBgNVBAMMCWh1YmNsaWVudDELMAkGA1UEBhMCVVMx 3 | DTALBgNVBAgMBE9oaW8xETAPBgNVBAcMCENvbHVtYnVzMRMwEQYDVQQKDApIdWIg 4 | Q2xpZW50MREwDwYDVQQLDAhQYXltZW50czEiMCAGCSqGS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LX5i+qympS9EmH9un5yH4Lx+ 21 | EuiMcuKad4kxQF27hnnp9z/WQr/DR6Y826NpqWDA5gvJcCXo+ACfl+JIQSN54Z68 22 | J0C+1idE5lY12jgXUGBMn3gwAA39hucPDVu4br0Q6oOnYLD8ZnVpsy1Pvf1ekIvb 23 | PJEYOUu8lsuwJQcpdLwrEV2WDFsxRalYTnvYazv+dtBmidSHziZythQZNPcDQNvN 24 | 8OmwEE0t+o9TpEgHRVLonwRm3AfHiEmD/fsj0yylZzg7hSDa9QaQ1TW/nCC/3KfZ 25 | ASztRCe+teibaLbRiLNUwhI+kkYTy1jibeDtb7A/FE8rlnC21e+5/Ds+90FEtcaG 26 | kesHJkC7rtzGlsdZGB0HnDJTWE9vxFsIcHf0+oJ73yKI/17+0DW7jBFp874hdhMj 27 | ip8xnZFDmplztB3aPzIpmNClAcNn5AP+m9cKbg8wY/wmTcRlF7hNAMU= 28 | -----END CERTIFICATE REQUEST----- 29 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/tls/hub_client_cacert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFdjCCA16gAwIBAgIJAL5G4HWE3SsRMA0GCSqGSIb3DQEBCwUAMHAxFDASBgNV 3 | BAMMC2h1YmNsaWVudGNhMQswCQYDVQQGEwJVUzENMAsGA1UECAwET2hpbzERMA8G 4 | A1UEBwwIQ29sdW1idXMxFjAUBgNVBAoMDUh1YiBDbGllbnQgQ0ExETAPBgNVBAsM 5 | CFBheW1lbnRzMB4XDTIwMDQwNzIwMjA0NVoXDTQ3MDgyNDIwMjA0NVowcDEUMBIG 6 | A1UEAwwLaHViY2xpZW50Y2ExCzAJBgNVBAYTAlVTMQ0wCwYDVQQIDARPaGlvMREw 7 | DwYDVQQHDAhDb2x1bWJ1czEWMBQGA1UECgwNSHViIENsaWVudCBDQTERMA8GA1UE 8 | CwwIUGF5bWVudHMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQD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BTktzUh83F40I5rjzXI7Wfw/D3Od 25 | 1Sgypq/rJJowCBWY7NkWfB1Oykl1Ql3ThUNSwDaN8WZLZINQcwjbv5CWoJ8uJ3yX 26 | YNy/29k1jmsjx0/LdH3oHshdhfnekUSqRjHsSHqKuobwr7mivERKIPywQQzqId0+ 27 | SW/Y4wMXroVCSDhApDy5CKXpW1j4fRWQy+vgLZTof3t8mv4znfc+P8M0ET/HoH2Q 28 | q1B8Cwis0JIxfMQJ/HiypVo0g2cPCpqQkhwJk8kFuJccPiCnm9yR5wsmVm0wF1/d 29 | glB2lou8lGNBjnMuRxSjQ6S/k4XNGupV8D9qnoHCrIcfNRwfsNIFFRbbDFn9pfog 30 | IV4kF6529qmxTMcmQXCPhkTHRkTypvPc9Hgxd60GtJVmHIxBFHRWNcSRVFuZtyHm 31 | cTQg3x0mFGAD9Q== 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/tls/hub_server.csr: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE REQUEST----- 2 | MIIEuTCCAqECAQAwUjELMAkGA1UEBhMCVVMxCzAJBgNVBAgMAkNBMRMwEQYDVQQK 3 | DApIdWIgU2VydmVyMSEwHwYDVQQDDBhtb2phbG9vcC10ZXN0aW5nLXRvb2xraXQw 4 | ggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCk2scZn0PznJdCjD7qu/je 5 | Gv8LsKVFufwouxVxw90W/xYPxwsPKp2yr0uBLLV2PgOlefO0InCd68fxLfIRF6jS 6 | 1ai2YGg0mquufZ9Lr6jjC+nLuFFu107EBNizo+3WLgefvY/xp3mMNzi2jgWTKGeb 7 | A0InqGYPuR+O+ca49hc0nsaCtDFfLGL5fA0Y111RM0aPDMkYSWnxE4NBAw78xQUe 8 | hT5TteNEClM0RLao/qz2B5QrCrIhB1IMHgDbhbRRKrppGVcAyJLEomleTC5hJ/oq 9 | sR/V6UVPZxIUk+N8nSTR9qSPttAWx67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fU4YsmlBlvA3KKbBmBcRFtINtOl4a430LJzfKypdgbis6NP0ihd3ssoEycP 26 | ggHh4vpJ40PqBeOeYM9XkJ7yfe8zt6A0/cB23MUV9uWSNKetgZ/1gGt5SiYA800P 27 | PYPQ28YgKQflOEabmw== 28 | -----END CERTIFICATE REQUEST----- 29 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/tls/hub_server_cacert.pem: -------------------------------------------------------------------------------- 1 | -----BEGIN CERTIFICATE----- 2 | MIIFdjCCA16gAwIBAgIJAIl8NQS3mbtGMA0GCSqGSIb3DQEBCwUAMHAxFDASBgNV 3 | BAMMC2h1YnNlcnZlcmNhMQswCQYDVQQGEwJVUzENMAsGA1UECAwET2hpbzERMA8G 4 | A1UEBwwIQ29sdW1idXMxFjAUBgNVBAoMDUh1YiBTZXJ2ZXIgQ0ExETAPBgNVBAsM 5 | CFBheW1lbnRzMB4XDTIwMDQwNzIwMjA0MloXDTQ3MDgyNDIwMjA0MlowcDEUMBIG 6 | A1UEAwwLaHVic2VydmVyY2ExCzAJBgNVBAYTAlVTMQ0wCwYDVQQIDARPaGlvMREw 7 | DwYDVQQHDAhDb2x1bWJ1czEWMBQGA1UECgwNSHViIFNlcnZlciBDQTERMA8GA1UE 8 | CwwIUGF5bWVudHMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCk2scZ 9 | n0PznJdCjD7qu/jeGv8LsKVFufwouxVxw90W/xYPxwsPKp2yr0uBLLV2PgOlefO0 10 | InCd68fxLfIRF6jS1ai2YGg0mquufZ9Lr6jjC+nLuFFu107EBNizo+3WLgefvY/x 11 | p3mMNzi2jgWTKGebA0InqGYPuR+O+ca49hc0nsaCtDFfLGL5fA0Y111RM0aPDMkY 12 | SWnxE4NBAw78xQUehT5TteNEClM0RLao/qz2B5QrCrIhB1IMHgDbhbRRKrppGVcA 13 | yJLEomleTC5hJ/oqsR/V6UVPZxIUk+N8nSTR9qSPttAWx67CRNPm1Ox2d/M//btj 14 | +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IxJ97anVp6WzwLISbv 30 | aQyfltKvLrsSsrAmNDlWscKfJbgVt64ZbF1kVTeHNTgR1I0X8vf4v5CQm18X+D2C 31 | /q24z8GZ2Wwxxw== 32 | -----END CERTIFICATE----- 33 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/tls/hub_server_cacert.srl: -------------------------------------------------------------------------------- 1 | ECF605B40A1A7D39 2 | -------------------------------------------------------------------------------- /docker-local/test-runner/secrets/tls/openssl.conf: -------------------------------------------------------------------------------- 1 | [ req ] 2 | distinguished_name = req_distinguished_name 3 | extensions = v3_ca 4 | req_extensions = v3_ca 5 | [ v3_ca ] 6 | basicConstraints = critical,CA:TRUE 7 | [ v3_req ] 8 | basicConstraints = CA:FALSE 9 | extendedKeyUsage = serverAuth, clientAuth, codeSigning, emailProtection 10 | 11 | [ req_distinguished_name ] 12 | countryName = US 13 | countryName_default = KR 14 | countryName_min = 2 15 | countryName_max = 2 16 | organizationName = User DFSP CA 17 | organizationName_default = User DFSP CA -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/central_admin_1.0/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/health": { 3 | "get": { 4 | "response": {} 5 | } 6 | }, 7 | "/metrics": { 8 | "get": { 9 | "response": {} 10 | } 11 | }, 12 | "/participants": { 13 | "get": { 14 | "response": {} 15 | }, 16 | "post": { 17 | "response": {} 18 | } 19 | }, 20 | "/participants/limits": { 21 | "get": { 22 | "response": {} 23 | } 24 | }, 25 | "/participants/{name}": { 26 | "get": { 27 | "response": {} 28 | }, 29 | "put": { 30 | "response": {} 31 | } 32 | }, 33 | "/participants/{name}/endpoints": { 34 | "get": { 35 | "response": {} 36 | }, 37 | "post": { 38 | "response": {} 39 | } 40 | }, 41 | "/participants/{name}/limits": { 42 | "get": { 43 | "response": {} 44 | }, 45 | "put": { 46 | "response": {} 47 | } 48 | }, 49 | "/participants/{name}/positions": { 50 | "get": { 51 | "response": {} 52 | } 53 | }, 54 | "/participants/{name}/accounts": { 55 | "get": { 56 | "response": {} 57 | }, 58 | "post": { 59 | "response": {} 60 | } 61 | }, 62 | "/participants/{name}/initialPositionAndLimits": { 63 | "post": { 64 | "response": {} 65 | } 66 | }, 67 | "/participants/{name}/accounts/{id}": { 68 | "put": { 69 | "response": {} 70 | }, 71 | "post": { 72 | "response": {} 73 | } 74 | }, 75 | "/participants/{name}/accounts/{id}/transfers/{transferId}": { 76 | "put": { 77 | "response": {} 78 | } 79 | }, 80 | "/settlementModels": { 81 | "get": { 82 | "response": {} 83 | }, 84 | "post": { 85 | "response": {} 86 | } 87 | }, 88 | "/settlementModels/{name}": { 89 | "get": { 90 | "response": {} 91 | }, 92 | "put": { 93 | "response": {} 94 | } 95 | } 96 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/central_admin_old_9.3/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/health": { 3 | "get": { 4 | "response": {} 5 | } 6 | }, 7 | "/metrics": { 8 | "get": { 9 | "response": {} 10 | } 11 | }, 12 | "/participants": { 13 | "get": { 14 | "response": {} 15 | }, 16 | "post": { 17 | "response": {} 18 | } 19 | }, 20 | "/participants/limits": { 21 | "get": { 22 | "response": {} 23 | } 24 | }, 25 | "/participants/{name}": { 26 | "get": { 27 | "response": {} 28 | }, 29 | "put": { 30 | "response": {} 31 | } 32 | }, 33 | "/participants/{name}/endpoints": { 34 | "get": { 35 | "response": {} 36 | }, 37 | "post": { 38 | "response": {} 39 | } 40 | }, 41 | "/participants/{name}/limits": { 42 | "get": { 43 | "response": {} 44 | }, 45 | "put": { 46 | "response": {} 47 | } 48 | }, 49 | "/participants/{name}/positions": { 50 | "get": { 51 | "response": {} 52 | } 53 | }, 54 | "/participants/{name}/accounts": { 55 | "get": { 56 | "response": {} 57 | }, 58 | "post": { 59 | "response": {} 60 | } 61 | }, 62 | "/participants/{name}/initialPositionAndLimits": { 63 | "post": { 64 | "response": {} 65 | } 66 | }, 67 | "/participants/{name}/accounts/{id}": { 68 | "put": { 69 | "response": {} 70 | }, 71 | "post": { 72 | "response": {} 73 | } 74 | }, 75 | "/participants/{name}/accounts/{id}/transfers/{transferId}": { 76 | "put": { 77 | "response": {} 78 | } 79 | }, 80 | "/settlementModels": { 81 | "get": { 82 | "response": {} 83 | }, 84 | "post": { 85 | "response": {} 86 | } 87 | }, 88 | "/settlementModels/{name}": { 89 | "get": { 90 | "response": {} 91 | }, 92 | "put": { 93 | "response": {} 94 | } 95 | } 96 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/fspiop_1.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "party.personalInfo.complexName.firstName", 4 | "pattern": "John|David|Michael|Chris|Mike|Mark|Paul|Daniel|James|Maria" 5 | }, 6 | { 7 | "id": "party.personalInfo.complexName.middleName", 8 | "pattern": "G|P|N|S" 9 | }, 10 | { 11 | "id": "party.personalInfo.complexName.lastName", 12 | "pattern": "Smith|Jones|Johnson|Lee|Brown|Williams|Rodriguez|Garcia|Gonzalez|Lopez" 13 | }, 14 | { 15 | "id": "party.personalInfo.dateOfBirth", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "transferId", 20 | "faker": "internet.email" 21 | }, 22 | { 23 | "id": "transferState", 24 | "pattern": "COMMITTED|RESERVED|ABORTED|RECEIVED" 25 | }, 26 | { 27 | "id": "fulfilment", 28 | "pattern": "[A-Fa-f0-9]{64}" 29 | }, 30 | { 31 | "id": "condition", 32 | "pattern": "[A-Fa-f0-9]{64}" 33 | }, 34 | { 35 | "id": "ilpPacket", 36 | "pattern": "[A-Fa-f0-9]{256}" 37 | }, 38 | { 39 | "id": "transferAmount.currency", 40 | "pattern": "USD" 41 | }, 42 | { 43 | "id": "transferAmount.amount", 44 | "pattern": "123" 45 | }, 46 | { 47 | "id": "payeeReceiveAmount.currency", 48 | "pattern": "USD" 49 | }, 50 | { 51 | "id": "payeeReceiveAmount.amount", 52 | "pattern": "123" 53 | }, 54 | { 55 | "id": "payeeFspFee.currency", 56 | "pattern": "USD" 57 | }, 58 | { 59 | "id": "payeeFspFee.amount", 60 | "pattern": "2" 61 | }, 62 | { 63 | "id": "payeeFspCommission.currency", 64 | "pattern": "USD" 65 | }, 66 | { 67 | "id": "payeeFspCommission.amount", 68 | "pattern": "3" 69 | }, 70 | 71 | { 72 | "id": "errorInformation.errorCode", 73 | "pattern": "600[1-9]" 74 | }, 75 | { 76 | "id": "errorInformation.errorDescription", 77 | "pattern": "This is a mock error description" 78 | }, 79 | { 80 | "id": "Content-Length", 81 | "pattern": "123" 82 | } 83 | ] -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/fspiop_1.1/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "party.personalInfo.complexName.firstName", 4 | "pattern": "John|David|Michael|Chris|Mike|Mark|Paul|Daniel|James|Maria" 5 | }, 6 | { 7 | "id": "party.personalInfo.complexName.middleName", 8 | "pattern": "G|P|N|S" 9 | }, 10 | { 11 | "id": "party.personalInfo.complexName.lastName", 12 | "pattern": "Smith|Jones|Johnson|Lee|Brown|Williams|Rodriguez|Garcia|Gonzalez|Lopez" 13 | }, 14 | { 15 | "id": "party.personalInfo.dateOfBirth", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "transferId", 20 | "faker": "internet.email" 21 | }, 22 | { 23 | "id": "transferState", 24 | "pattern": "COMMITTED|RESERVED|ABORTED|RECEIVED" 25 | }, 26 | { 27 | "id": "fulfilment", 28 | "pattern": "[A-Fa-f0-9]{64}" 29 | }, 30 | { 31 | "id": "condition", 32 | "pattern": "[A-Fa-f0-9]{64}" 33 | }, 34 | { 35 | "id": "ilpPacket", 36 | "pattern": "[A-Fa-f0-9]{256}" 37 | }, 38 | { 39 | "id": "transferAmount.currency", 40 | "pattern": "USD" 41 | }, 42 | { 43 | "id": "transferAmount.amount", 44 | "pattern": "123" 45 | }, 46 | { 47 | "id": "payeeReceiveAmount.currency", 48 | "pattern": "USD" 49 | }, 50 | { 51 | "id": "payeeReceiveAmount.amount", 52 | "pattern": "123" 53 | }, 54 | { 55 | "id": "payeeFspFee.currency", 56 | "pattern": "USD" 57 | }, 58 | { 59 | "id": "payeeFspFee.amount", 60 | "pattern": "2" 61 | }, 62 | { 63 | "id": "payeeFspCommission.currency", 64 | "pattern": "USD" 65 | }, 66 | { 67 | "id": "payeeFspCommission.amount", 68 | "pattern": "3" 69 | }, 70 | 71 | { 72 | "id": "errorInformation.errorCode", 73 | "pattern": "600[1-9]" 74 | }, 75 | { 76 | "id": "errorInformation.errorDescription", 77 | "pattern": "This is a mock error description" 78 | }, 79 | { 80 | "id": "Content-Length", 81 | "pattern": "123" 82 | } 83 | ] -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/mojaloop_sdk_outbound_scheme_adapter_1.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "party.personalInfo.dateOfBirth", 4 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 5 | }, 6 | { 7 | "id": "party.name", 8 | "pattern": "Vijay Kumar Guthi" 9 | }, 10 | { 11 | "id": "party.personalInfo.complexName.firstName", 12 | "pattern": "Vijay" 13 | }, 14 | { 15 | "id": "party.personalInfo.complexName.lastName", 16 | "pattern": "Kumar" 17 | }, 18 | { 19 | "id": "party.personalInfo.complexName.middleName", 20 | "pattern": "Guthi" 21 | } 22 | ] 23 | -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/mojaloop_sdk_outbound_scheme_adapter_1.0/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/parties/{Type}/{ID}": { 3 | "get": { 4 | "response": { 5 | "bodyOverride": { 6 | "party": { 7 | "partyIdInfo": { 8 | "partyIdType": "{$request.params.Type}", 9 | "partyIdentifier": "{$request.params.ID}", 10 | "fspId": "ttk", 11 | "partySubIdOrType": null, 12 | "extensionList": null 13 | }, 14 | "accounts": null, 15 | "merchantClassificationCode": null 16 | } 17 | } 18 | } 19 | } 20 | } 21 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/mojaloop_simulator_sim_1.4/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "firstName", 4 | "pattern": "John|David|Michael|Chris|Mike|Mark|Paul|Daniel|James|Maria" 5 | }, 6 | { 7 | "id": "middleName", 8 | "pattern": "G|P|N|S" 9 | }, 10 | { 11 | "id": "lastName", 12 | "pattern": "Smith|Jones|Johnson|Lee|Brown|Williams|Rodriguez|Garcia|Gonzalez|Lopez" 13 | }, 14 | { 15 | "id": "dateOfBirth", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "transferState", 20 | "pattern": "COMMITTED|RESERVED|ABORTED|RECEIVED" 21 | }, 22 | { 23 | "id": "fulfilment", 24 | "pattern": "[A-Fa-f0-9]{64}" 25 | }, 26 | { 27 | "id": "condition", 28 | "pattern": "[A-Fa-f0-9]{64}" 29 | }, 30 | { 31 | "id": "ilpPacket", 32 | "pattern": "[A-Fa-f0-9]{256}" 33 | }, 34 | { 35 | "id": "transferAmount.currency", 36 | "pattern": "USD" 37 | }, 38 | { 39 | "id": "transferAmount.amount", 40 | "pattern": "123" 41 | }, 42 | { 43 | "id": "payeeReceiveAmountCurrency", 44 | "pattern": "USD" 45 | }, 46 | { 47 | "id": "payeeReceiveAmount", 48 | "pattern": "123" 49 | }, 50 | { 51 | "id": "payeeFspFeeAmountCurrency", 52 | "pattern": "USD" 53 | }, 54 | { 55 | "id": "payeeFspFeeAmount", 56 | "pattern": "2" 57 | }, 58 | { 59 | "id": "payeeFspCommissionAmountCurrency", 60 | "pattern": "USD" 61 | }, 62 | { 63 | "id": "payeeFspCommissionAmount", 64 | "pattern": "3" 65 | }, 66 | 67 | { 68 | "id": "errorInformation.errorCode", 69 | "pattern": "600[1-9]" 70 | }, 71 | { 72 | "id": "errorInformation.errorDescription", 73 | "pattern": "This is a mock error description" 74 | }, 75 | { 76 | "id": "Content-Length", 77 | "pattern": "123" 78 | } 79 | ] -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/mojaloop_simulator_sim_1.4/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/parties/{idType}/{idValue}": { 3 | "get": { 4 | "response": { 5 | "bodyOverride": { 6 | "idType": "{$request.params.idType}", 7 | "idValue": "{$request.params.idValue}", 8 | "merchantClassificationCode": null 9 | } 10 | } 11 | } 12 | }, 13 | "/quoterequests": { 14 | "post": { 15 | "response": { 16 | "bodyOverride": { 17 | "quoteId": "{$request.body.quoteId}", 18 | "transactionId": "{$request.body.transactionId}", 19 | "transferAmount": "{$request.body.amount}", 20 | "transferAmountCurrency": "{$request.body.currency}", 21 | "expiration": "{$request.body.expiration}", 22 | "geoCode": null, 23 | "extensionList": null 24 | } 25 | } 26 | } 27 | }, 28 | "/transfers": { 29 | "post": { 30 | "response": { 31 | "bodyOverride": { 32 | "homeTransactionId": "{$request.body.transferId}" 33 | } 34 | } 35 | } 36 | } 37 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/settlements_1.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "changedDate", 4 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 5 | }, 6 | { 7 | "id": "createdDate", 8 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 9 | }, 10 | { 11 | "id": "state", 12 | "pattern": "OPEN|CLOSED" 13 | }, 14 | { 15 | "id": "settlementWindows.items.items.createdDate", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "settlementWindows.items.items.changedDate", 20 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 21 | }, 22 | { 23 | "id": "settlementWindows.items.items.state", 24 | "pattern": "OPEN|CLOSED" 25 | }, 26 | { 27 | "id": "participants.items.accounts.items.state", 28 | "pattern": "OPEN|CLOSED" 29 | }, 30 | { 31 | "id": "participants.items.accounts.items.netSettlementAmount.amount", 32 | "pattern": "123" 33 | }, 34 | { 35 | "id": "participants.items.accounts.items.netSettlementAmount.currency", 36 | "pattern": "USD" 37 | } 38 | ] -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/settlements_1.0/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/settlementWindows/{id}": { 3 | "post": { 4 | "response": { 5 | "bodyOverride": { 6 | "id": "{$request.params.id}", 7 | "reason": "{$request.body.reason}" 8 | } 9 | } 10 | } 11 | }, 12 | "/settlementWindows": { 13 | "get": { 14 | "response": {} 15 | } 16 | }, 17 | "/settlements": { 18 | "post": { 19 | "response": { 20 | "bodyOverride": { 21 | } 22 | } 23 | } 24 | }, 25 | "/settlements/{id}": { 26 | "get": { 27 | "response": { 28 | "bodyOverride": { 29 | "id": "{$request.params.id}" 30 | } 31 | } 32 | } 33 | } 34 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/settlements_2.0/mockRef.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": "changedDate", 4 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 5 | }, 6 | { 7 | "id": "createdDate", 8 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 9 | }, 10 | { 11 | "id": "state", 12 | "pattern": "OPEN|CLOSED" 13 | }, 14 | { 15 | "id": "settlementWindows.items.items.createdDate", 16 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 17 | }, 18 | { 19 | "id": "settlementWindows.items.items.changedDate", 20 | "pattern": "^(19)\\d\\d[-](0[1-9]|1[012])[-](0[1-9]|[12][0-9]|2[0-8])$" 21 | }, 22 | { 23 | "id": "settlementWindows.items.items.state", 24 | "pattern": "OPEN|CLOSED" 25 | }, 26 | { 27 | "id": "participants.items.accounts.items.state", 28 | "pattern": "OPEN|CLOSED" 29 | }, 30 | { 31 | "id": "participants.items.accounts.items.netSettlementAmount.amount", 32 | "pattern": "123" 33 | }, 34 | { 35 | "id": "participants.items.accounts.items.netSettlementAmount.currency", 36 | "pattern": "USD" 37 | } 38 | ] -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/api_definitions/settlements_2.0/response_map.json: -------------------------------------------------------------------------------- 1 | { 2 | "/settlementWindows/{id}": { 3 | "post": { 4 | "response": { 5 | "bodyOverride": { 6 | "id": "{$request.params.id}", 7 | "reason": "{$request.body.reason}" 8 | } 9 | } 10 | } 11 | }, 12 | "/settlementWindows": { 13 | "get": { 14 | "response": {} 15 | } 16 | }, 17 | "/settlements": { 18 | "post": { 19 | "response": { 20 | "bodyOverride": { 21 | } 22 | } 23 | } 24 | }, 25 | "/settlements/{id}": { 26 | "get": { 27 | "response": { 28 | "bodyOverride": { 29 | "id": "{$request.params.id}" 30 | } 31 | } 32 | } 33 | } 34 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/reports/templates/testcase_definition/table_view.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | {{#each test_cases}} 57 | 58 | 59 | 60 | {{#each requests}} 61 | 62 | 63 | 64 | 65 | 74 | 75 | {{/each}} 76 | {{/each}} 77 | 78 |
TestcaseRequest DescriptionTest ScenarioExpected Result
Folder Name > File Name
{{name}}
{{#if @first}}{{../meta.info}}{{/if}} {{meta.info}}{{description}}
({{method}} {{operationPath}})
66 | {{#if tests.assertions}} 67 |
    68 | {{#each tests.assertions}} 69 |
  • {{description}}
  • 70 | {{/each}} 71 |
72 | {{/if}} 73 |
79 | 80 | 81 | 82 | -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/rules_callback/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/rules_forward/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/rules_response/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/rules_validation/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "activeRulesFile": "default.json" 3 | } -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/rules_validation/default.json: -------------------------------------------------------------------------------- 1 | [] -------------------------------------------------------------------------------- /docker-local/test-runner/spec_files/rules_validation/p2p-limit.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "ruleId": 1, 4 | "priority": 1, 5 | "description": "post /quotes", 6 | "apiVersion": { 7 | "minorVersion": 0, 8 | "majorVersion": 1, 9 | "type": "fspiop", 10 | "asynchronous": true 11 | }, 12 | "conditions": { 13 | "all": [ 14 | { 15 | "fact": "body", 16 | "operator": "numericGreaterThan", 17 | "value": "{$environment.ttkAllowedAmount}", 18 | "path": "amount.amount" 19 | }, 20 | { 21 | "fact": "body", 22 | "operator": "equal", 23 | "value": "testingtoolkitdfsp", 24 | "path": "payee.partyIdInfo.fspId" 25 | }, 26 | { 27 | "fact": "operationPath", 28 | "operator": "equal", 29 | "value": "/quotes" 30 | }, 31 | { 32 | "fact": "method", 33 | "operator": "equal", 34 | "value": "post" 35 | } 36 | ] 37 | }, 38 | "event": { 39 | "method": "put", 40 | "path": "/quotes/{ID}/error", 41 | "params": { 42 | "body": { 43 | "errorInformation": { 44 | "errorCode": "5100", 45 | "errorDescription": "The total allowed amount for the dfsp has been reached" 46 | } 47 | }, 48 | "scripts": {} 49 | }, 50 | "type": "MOCK_ERROR_CALLBACK" 51 | }, 52 | "type": "validation", 53 | "version": 1 54 | } 55 | ] -------------------------------------------------------------------------------- /docs/README.md: -------------------------------------------------------------------------------- 1 | # PISP/Docs 2 | 3 | Supporting documentation for the PISP implementation. 4 | 5 | ## Overview 6 | - Design Elements 7 | - [Mojaloop Roles + Endpoints](./roles_and_endpoints.md) 8 | - [Design Decisions](./design-decisions/README.md) 9 | 10 | ### Error codes 11 | 12 | Error codes can be found here https://github.com/mojaloop/documentation/blob/master/website/versioned_docs/v1.0.1/api/thirdparty/data-models.md#errorcodes 13 | 14 | ### Sequence Diagrams 15 | 16 | Diagrams can be found here https://github.com/mojaloop/documentation/tree/master/website/versioned_docs/v1.0.1/api/thirdparty/assets/diagrams 17 | -------------------------------------------------------------------------------- /docs/design-decisions/tandem_async_proxy.puml: -------------------------------------------------------------------------------- 1 | @startuml 2 | 3 | box "Mojaloop" 4 | participant Switch as S 5 | end box 6 | 7 | box "SDK-scheme-adapter" 8 | participant "SDK-Incoming" as Sin 9 | participant "SDK-Outgoing" as Sout 10 | end box 11 | box "thirdparty-sdk" 12 | participant "Thirdparty-Incoming" as Tin 13 | participant "Thirdparty-Outgoing" as Tout 14 | end box 15 | 16 | participant PISP as P 17 | 18 | P -> Tout: start the Transfer flow which involes using of\nGET /parties/MSISDN/12345678 19 | activate P 20 | activate Tout 21 | 22 | Tout -> Sout: GET /parties/MSISDN/12345678 23 | activate Sout 24 | Sout --> Tout: 200 OK 25 | Sout -> Sout: discover that this call is comming\nfrom thirdparty-sdk 26 | Tout -> Tout: register to PUB/SUB channel\nand wait for response 27 | 28 | Sout -> S: GET /parties/MSISDN/12345678 29 | activate S 30 | deactivate Tout 31 | S --> Sout: 200 OK 32 | deactivate Sout 33 | 34 | S -> S: finding party information 35 | 36 | S -> Sin: PUT /parties/MSISDN/12345678 37 | deactivate S 38 | activate Sin 39 | Sin -> Sin: discover that this call should be propagated\nto the proper thirdparty-sdk' callback 40 | Sin -> Tin: PUT /parties/MSISDN/12345678 41 | activate Tin 42 | deactivate Sin 43 | Tin -> Tout: send PUT payload via PUB/SUB channel 44 | deactivate Tin 45 | activate Tout 46 | Tout -> Tout: consume PUT payload received via PUB/SUB channel to PISP and continue the Transfer flow 47 | Tout -> P: send result of Transfer flow 48 | @enduml 49 | -------------------------------------------------------------------------------- /docs/design-decisions/tandem_clashing_endpoints.puml: -------------------------------------------------------------------------------- 1 | @startuml 2 | title Adapters Tandem: clashing endpoints 3 | 4 | box "Mojaloop" 5 | participant Switch as S 6 | end box 7 | 8 | box "SDK-scheme-adapter" 9 | participant "SDK-Incoming" as Sin 10 | participant "SDK-Outgoing" as Sout 11 | end box 12 | 13 | box "thirdparty-sdk" 14 | participant "Thirdparty-Incoming" as Tin 15 | participant "Thirdparty-Outgoing" as Tout 16 | end box 17 | 18 | participant PISP as P 19 | 20 | note over Sin 21 | PUT /parties/MSISDN/... 22 | callback registered 23 | in the Mojaloop switch 24 | end note 25 | 26 | note over Tin 27 | PUT /parties/MSISDN/... 28 | two callbacks for the same endpoint 29 | can't be registered in Mojaloop Switch 30 | end note 31 | 32 | activate P 33 | P -> Tout: start the Transfer flow which involes using of\nGET /parties/MSISDN/12345678 34 | activate Tout 35 | Tout -> S: GET /parties/MSISDN/12345678 36 | activate S 37 | S --> Tout: 200 OK 38 | Tout --> Tin: register to PUB/SUB channel\nto receive data from PUT /parties 39 | activate Tin 40 | Tin -> Tin: waiting on PUT /parties/MSISDN/... callback 41 | Tout -> Tout: keeping open connection with PISP\nand waiting on data to be send down as response 42 | S -> S: resolving party information 43 | S -> Sin: PUT /parties/MSISDN/12345678 44 | deactivate S 45 | activate Sin 46 | Sin -> Sin: unexpected PUT /parties/MSISDN/12345678 - what to do with it? 47 | Tin -> Tin: still waiting on PUT /parties - it will never be delivered to Thirdparty-Incoming\n so it can't be PUB to Thirdparty-Outgoing 48 | deactivate Sin 49 | P -> P: still open connection and listening 50 | @enduml 51 | -------------------------------------------------------------------------------- /docs/design-decisions/tandem_generic_pattern.puml: -------------------------------------------------------------------------------- 1 | @startuml 2 | 3 | box "Mojaloop" 4 | participant Switch as S 5 | end box 6 | 7 | box "SDK-scheme-adapter" 8 | participant "SDK-Incoming" as Sin 9 | participant "SDK-Outgoing" as Sout 10 | end box 11 | box "thirdparty-sdk" 12 | participant "Thirdparty-Incoming" as Tin 13 | participant "Thirdparty-Outgoing" as Tout 14 | end box 15 | 16 | participant PISP as P 17 | 18 | activate Tout 19 | activate P 20 | P -> Tout: start workflow 21 | Tout -> Sout: sync GET 22 | activate Sout 23 | Sout -> Sout: register to PUB/SUB channel\nand wait for response 24 | Tout -> Tout: wait on response from sync call 25 | 26 | Sout -> S: GET 27 | activate S 28 | S --> Sout: 200 OK 29 | deactivate Sout 30 | S -> S: finding party information 31 | 32 | S -> Sin: PUT 33 | deactivate S 34 | activate Sin 35 | Sin -> Sout: publish PUT payload to PUB/SUB channel 36 | deactivate Sin 37 | activate Sout 38 | Sout -> Tout: send PUT payload as http response 39 | deactivate Sout 40 | 41 | Tout -> Tout: consume PUT payload received from call\nand continue the workflow 42 | Tout -> P: return workflow result to PISP 43 | @enduml 44 | -------------------------------------------------------------------------------- /docs/design-decisions/tandem_sync_client_server.puml: -------------------------------------------------------------------------------- 1 | @startuml 2 | 3 | box "Mojaloop" 4 | participant Switch as S 5 | end box 6 | 7 | box "SDK-scheme-adapter" 8 | participant "SDK-Incoming" as Sin 9 | participant "SDK-Outgoing" as Sout 10 | end box 11 | box "thirdparty-sdk" 12 | participant "Thirdparty-Incoming" as Tin 13 | participant "Thirdparty-Outgoing" as Tout 14 | end box 15 | 16 | participant PISP as P 17 | 18 | P -> Tout: start the Transfer flow which involes using of\nGET /parties/MSISDN/12345678 19 | activate P 20 | activate Tout 21 | 22 | Tout -> Sout: sync GET /parties/MSISDN/12345678 23 | activate Sout 24 | Sout -> Sout: register to PUB/SUB channel\nand wait for response 25 | Tout -> Tout: wait on response from sync call 26 | 27 | Sout -> S: GET /parties/MSISDN/12345678 28 | activate S 29 | S --> Sout: 200 OK 30 | deactivate Sout 31 | S -> S: finding party information 32 | 33 | S -> Sin: PUT /parties/MSISDN/12345678 34 | deactivate S 35 | activate Sin 36 | Sin -> Sout: publish PUT payload to PUB/SUB channel 37 | deactivate Sin 38 | activate Sout 39 | Sout -> Tout: send PUT payload as http response 40 | deactivate Sout 41 | 42 | Tout -> Tout: consume PUT payload received from call\nand continue the Transfer flow 43 | Tout -> P: send result of Transfer flow 44 | @enduml 45 | -------------------------------------------------------------------------------- /docs/participant_endpoint_enums.md: -------------------------------------------------------------------------------- 1 | # Participant Endpoint Enums 2 | 3 | This is the list of endpoints that a PISP or DFSP must register with the switch to get callbacks from the `thirdparty-api-svc`. 4 | 5 | These endpoints should be added to the enums of `central-services-shared` and the seeds of `central-ledger`. 6 | 7 | ## PISP: 8 | 9 | `TP_CB_URL_TRANSACTION_REQUEST_POST` 10 | `TP_CB_URL_TRANSACTION_REQUEST_PUT` 11 | `TP_CB_URL_TRANSACTION_REQUEST_PUT_ERROR` 12 | `TP_CB_URL_CONSENT_REQUEST_POST` 13 | `TP_CB_URL_CONSENT_REQUEST_PUT` 14 | `TP_CB_URL_CONSENT_REQUEST_PUT_ERROR` 15 | `TP_CB_URL_CONSENT_POST` 16 | `TP_CB_URL_CONSENT_GET` 17 | `TP_CB_URL_CONSENT_PUT` 18 | `TP_CB_URL_CONSENT_PUT_ERROR` 19 | `TP_CB_URL_TRANSACTION_REQUEST_PATCH` 20 | `TP_CB_URL_TRANSACTION_REQUEST_AUTH_POST` 21 | ## DFSP: 22 | 23 | `TP_CB_URL_TRANSACTION_REQUEST_POST` 24 | `TP_CB_URL_TRANSACTION_REQUEST_PUT` 25 | `TP_CB_URL_TRANSACTION_REQUEST_PUT_ERROR` 26 | `TP_CB_URL_CONSENT_REQUEST_POST` 27 | `TP_CB_URL_CONSENT_REQUEST_PUT` 28 | `TP_CB_URL_CONSENT_REQUEST_PUT_ERROR` 29 | `TP_CB_URL_CONSENT_POST` 30 | `TP_CB_URL_CONSENT_GET` 31 | `TP_CB_URL_CONSENT_PUT` 32 | `TP_CB_URL_CONSENT_PUT_ERROR` 33 | `TP_CB_URL_TRANSACTION_REQUEST_AUTH_PUT_ERROR` 34 | `TP_CB_URL_TRANSACTION_REQUEST_AUTH_PUT` 35 | -------------------------------------------------------------------------------- /docs/roles_and_endpoints.md: -------------------------------------------------------------------------------- 1 | # Mojaloop/PISP Roles 2 | 3 | A summary of Mojaloop FSPIOP API Endpoints and Roles as they stand today. 4 | 5 | ## Roles 6 | 7 | - DFSP 8 | - fund-holding participant 9 | - has clearing and settlement functions 10 | - allows PISPs to initiate transfers on behalf of their users 11 | 12 | - PISP 13 | - non-fund holding participant (and therefore no clearing or settlements as well) 14 | - initiates transfers on user's behalf 15 | - assumes delegated permissions _from_ user 16 | 17 | ## API Calls: 18 | 19 | Information about API calls can be found here https://github.com/mojaloop/documentation/blob/master/website/versioned_docs/v1.0.1/api/thirdparty/data-models.md#ThirdPartyAPISpecification 20 | -------------------------------------------------------------------------------- /docs/scheme-adapters/README.md: -------------------------------------------------------------------------------- 1 | # Scheme Adapters: SDK & Thirdparty 2 | 3 | ## layout of sdk-scheme-adapter and thirdparty-sdk 4 | 5 | ![adapters-layout](./adapters-layout.png) 6 | 7 | ## exposing synchronous API endpoints at SDK-Outgoing interface 8 | 9 | > pattern of exposing the asynchronous GET/POST -> PUT sequence of calls/callbacks into one synchronous call interface on Outgoing sdk-scheme-adapter 10 | 11 | ![generic-pattern](../out/design-decisions/tandem_generic_pattern.svg) 12 | 13 | - sync API - synchronous api endpoints to be used by thirdparty scheme-adapter 14 | 15 | ### list of endpoints to be exposed 16 | 17 | > **=>** Outgoing 18 | > **<=** Incoming 19 | 20 | #### Linking flow 21 | 22 | **Discovery** 23 | - => GET /parties/{Type}/{ID} <= PUT /parties/{Type}/{ID} 24 | 25 | **Request consent** 26 | - => POST /consentRequests <= PUT /consentRequests/{ID} 27 | 28 | **Authentication** 29 | - => PUT /consentRequests/{ID} 30 | 31 | **Grant consent** 32 | - => POST /consents <= POST /consents 33 | 34 | **Credential registration** 35 | - => POST /consents/{ID}/generateChallenge <= PUT /consents/{ID}` 36 | 37 | #### Unlinking flow 38 | - => POST /consents/{ID}/revoke <= PATCH /consents/{ID} 39 | 40 | ### Thirdparty credential registration 41 | - TODO 42 | 43 | #### Transfer flow 44 | 45 | **Discovery lookup phase** 46 | - => GET /parties/{Type}/{ID} <= PUT /parties/{Type}/{ID} 47 | 48 | **Agreement phase** 49 | - => POST /quotes <= PUT /quotes/{ID} 50 | - => POST /authorizations <= PUT /authorizations/{ID} 51 | - => POST /thirdpartyRequests/transactions/{ID}/authorizations <= PUT /thirdpartyRequests/transactions/{ID}/authorizations 52 | 53 | **Transfer phase** 54 | - => POST /transfers <= PUT /transfers/{ID} 55 | - <= PATCH /thirdpartyRequests/transactions/{ID} 56 | -------------------------------------------------------------------------------- /docs/scheme-adapters/adapters-layout.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mojaloop/pisp-project/01f8d384d54ef8e86821a2149143d741c5cc7b2b/docs/scheme-adapters/adapters-layout.png -------------------------------------------------------------------------------- /docs/scripts/_update_seq.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | 5 | # rm -rf ./out 6 | # TODO: regenerate... 7 | -------------------------------------------------------------------------------- /jest.config.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | 3 | module.exports = { 4 | verbose: true, 5 | preset: 'ts-jest', 6 | testEnvironment: 'node', 7 | collectCoverage: false, 8 | collectCoverageFrom: ['./src/**/*.ts'], 9 | coverageReporters: ['json', 'lcov', 'text'], 10 | clearMocks: true, 11 | coverageThreshold: { 12 | global: { 13 | statements: 90, 14 | functions: 90, 15 | branches: 90, 16 | lines: 90 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /scripts/_build_plantuml_all.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PUML_PORT=9999 5 | export PUML_BASE_URL=http://localhost:${PUML_PORT} 6 | 7 | ## 8 | # searches through repo for plantuml sources 9 | # and exports them using `node-plantuml` 10 | ## 11 | 12 | trap ctrl_c INT 13 | function ctrl_c() { 14 | echo "exit early - stopping docker" 15 | docker stop puml-local 16 | exit 1 17 | } 18 | 19 | # run the docker puml server 20 | docker run -d --rm \ 21 | --name puml-local \ 22 | -p ${PUML_PORT}:8080 \ 23 | plantuml/plantuml-server:jetty-v1.2020.21 24 | 25 | # Wait for docker to be up 26 | sleep 2 27 | 28 | for i in $(find ${DIR}/../docs -name '*.puml'); do 29 | echo "rendering .puml -> .svg for diagram diagram: $i" 30 | # make the destination directory if not exists 31 | mkdir -p $(dirname $i | sed 's#docs#docs/out#g') 32 | ${DIR}/_render_svg.js $i $(echo $i | sed 's/puml/svg/g' | sed 's#docs#docs/out#g') 33 | done 34 | 35 | docker stop puml-local 36 | -------------------------------------------------------------------------------- /scripts/_build_plantuml_diff.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | PUML_PORT=9999 5 | export PUML_BASE_URL=http://localhost:${PUML_PORT} 6 | 7 | ## 8 | # searches through repo for plantuml sources 9 | # and exports them using `node-plantuml` 10 | ## 11 | 12 | trap ctrl_c INT 13 | function ctrl_c() { 14 | echo "exit early - stopping docker" 15 | docker stop puml-local 16 | exit 1 17 | } 18 | 19 | # run the docker puml server 20 | docker run -d --rm \ 21 | --name puml-local \ 22 | -p ${PUML_PORT}:8080 \ 23 | plantuml/plantuml-server:jetty-v1.2020.21 24 | 25 | # Wait for docker to be up 26 | sleep 2 27 | 28 | for i in $(git diff --staged --name-only `find ${DIR}/../docs -name '*.puml'`); do 29 | echo "found diagram: $i" 30 | # make the destination directory if not exists 31 | mkdir -p $(dirname $i | sed 's#docs#docs/out#g') 32 | # puml generate -s $i -o $(echo $i | sed 's/puml/svg/g' | sed 's#docs#docs/out#g') -i $(echo $i | sed -e 's;[^/]*$;;'); 33 | ${DIR}/_render_svg.js $i $(echo $i | sed 's/puml/svg/g' | sed 's#docs#docs/out#g') 34 | done 35 | 36 | git add ./docs/out 37 | 38 | docker stop puml-local 39 | -------------------------------------------------------------------------------- /scripts/_configure_web_simulator.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | TTK_HOST=${TTK_HOST:-localhost:15000} 4 | CONSENT_REQUEST_ID=${CONSENT_REQUEST_ID:-3b346cec-47b3-4def-b870-edb255aaf6c3} 5 | 6 | echo "CONSENT_REQUEST_ID is: ${CONSENT_REQUEST_ID}" 7 | 8 | 9 | # Populate a list of demo accounts 10 | curl -X POST "http://${TTK_HOST}/store/consentRequests/${CONSENT_REQUEST_ID}" \ 11 | -H 'Accept: application/json' \ 12 | -H 'Content-Type: application/json' \ 13 | -d ' 14 | { 15 | "scopes": [ 16 | { 17 | "accountId": "dfspa.username.1234", 18 | "actions": [ 19 | "accounts.transfer", 20 | "accounts.getBalance" 21 | ] 22 | }, 23 | { 24 | "accountId": "dfspa.username.5678", 25 | "actions": [ 26 | "accounts.transfer", 27 | "accounts.getBalance" 28 | ] 29 | } 30 | ] 31 | }' 32 | -------------------------------------------------------------------------------- /scripts/_render_svg.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | 3 | 4 | /** 5 | * Uses plantuml server to render a puml to svg 6 | */ 7 | 8 | const fs = require('fs') 9 | const path = require('path') 10 | const util = require('util') 11 | const got = require('got') 12 | const SVGO = require('svgo') 13 | const plantumlEncoder = require('plantuml-encoder') 14 | 15 | const rendererBaseUrl = process.env.PUML_BASE_URL || 'http://www.plantuml.com/plantuml' 16 | 17 | svgo = new SVGO({ 18 | js2svg: { pretty: true, indent: 2 }, 19 | plugins: [ 20 | { removeComments: true }, 21 | ] 22 | }); 23 | 24 | async function main() { 25 | let [_, _script, inputPath, outputPath] = process.argv 26 | 27 | if (!inputPath) { 28 | console.log("usage: ./_render_svg.js []") 29 | process.exit(1) 30 | } 31 | 32 | // If not specified, replace .puml or .plantuml with `.svg` 33 | if (!outputPath) { 34 | outputPath = inputPath.replace('.puml', '.svg') 35 | .replace('.plantuml', '.svg') 36 | } 37 | 38 | const rawPumlContents = fs.readFileSync(inputPath) 39 | const encoded = plantumlEncoder.encode(rawPumlContents.toString()) 40 | const url = path.join(rendererBaseUrl, 'svg', encoded) 41 | let result 42 | try { 43 | result = await got.get(url) 44 | } catch (err) { 45 | console.log('http request failed to render puml with error', err.message) 46 | if (err.message.indexOf('Response code 403') > -1) { 47 | console.log('Note: sometimes the public puml renderer fails when the input diagrams are too large. Try running your own renderer server with docker.') 48 | } 49 | 50 | if (err.message.indexOf('Response code 400') > -1) { 51 | console.log('This could be due to bad syntax in the puml diagram. Url is:') 52 | console.log(url) 53 | } 54 | 55 | process.exit(1) 56 | } 57 | 58 | // Strip comments and prettify svg 59 | // This makes sure that our .svg files are deterministic and diffable 60 | const formatted = await svgo.optimize(result.body) 61 | fs.writeFileSync(outputPath, formatted.data) 62 | } 63 | 64 | main() 65 | -------------------------------------------------------------------------------- /scripts/_reset_test_state.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | 4 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 5 | 6 | # A little utility that resets the test state to make 7 | # writing e2e tests easier 8 | 9 | cd ${DIR}/../docker-local 10 | # Reset the redis cache so we can reuse the same transactionRequestIds etc. 11 | docker-compose stop pisp-redis dfspa-redis 12 | docker-compose rm -f pisp-redis dfspa-redis 13 | 14 | # reset the databases 15 | docker exec -it auth-service-mysql mysql -D auth-service -e 'SET FOREIGN_KEY_CHECKS=0;truncate Consent; truncate Scope; SET FOREIGN_KEY_CHECKS=1; select * from Consent;' 16 | docker exec -it als-consent-oracle-mysql mysql -D als-consent-oracle -e 'truncate Consent;' 17 | 18 | docker-compose up -d -------------------------------------------------------------------------------- /scripts/_restart_reseed_docker_local.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | cd $DIR/../docker-local 5 | 6 | # Restart docker-local and reseed 7 | docker-compose stop 8 | docker-compose rm -f 9 | docker-compose up -d 10 | npm run wait-4-docker 11 | npx ml-bootstrap@0.3.16 -c $DIR/../docker-local/ml-bootstrap-config.json5 12 | 13 | # configure the web simulator 14 | export CONSENT_REQUEST_ID=b51ec534-ee48-4575-b6a9-ead2955b8069 15 | $DIR/_configure_web_simulator.sh -------------------------------------------------------------------------------- /scripts/_setup_hosts_file.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" 4 | 5 | set -u 6 | set -e 7 | 8 | HOSTS_FILE=/etc/hosts 9 | touch ${HOSTS_FILE} 10 | 11 | if [ `cat ${HOSTS_FILE} | grep 'central-ledger.local' | wc -l` -gt 0 ]; then 12 | echo "[WARN] Already found Mojaloop hosts in ${HOSTS_FILE}" 13 | echo "[WARN] exiting with status: 0" 14 | exit 0 15 | fi 16 | 17 | echo " 18 | # Added by mojaloop 19 | # to allow local access to mojaloop docker-compose environment 20 | 127.0.0.1 central-ledger.local central-settlement.local ml-api-adapter.local account-lookup-service.local account-lookup-service-admin.local quoting-service.local moja-simulator.local central-ledger central-settlement ml-api-adapter account-lookup-service account-lookup-service-admin quoting-service simulator host.docker.internal 21 | 127.0.0.1 dfspa-backend dfspb-backend pisp-backend dfspa-sdk-scheme-adapter dfspb-sdk-scheme-adapter pisp-sdk-scheme-adapter transaction-request-service 22 | 127.0.0.1 pisp-thirdparty-sdk dfspa-thirdparty-sdk dfspb-thirdparty-sdk 23 | # end of section 24 | " >> ${HOSTS_FILE} 25 | 26 | cat ${HOSTS_FILE} 27 | -------------------------------------------------------------------------------- /sonar-project.properties: -------------------------------------------------------------------------------- 1 | # Required metadata 2 | sonar.projectKey=auth-service 3 | sonar.projectName=auth-service 4 | sonar.projectVersion=0.1.0 5 | 6 | # Comma-separated paths to directories with sources (required) 7 | sonar.sources=src,test 8 | 9 | # Language 10 | sonar.language=ts 11 | 12 | # Encoding of the source files 13 | sonar.sourceEncoding=UTF-8 14 | sonar.exclusions=migrations 15 | 16 | # To import the LCOV report 17 | sonar.typescript.lcov.reportPaths=lcov.info -------------------------------------------------------------------------------- /src/Template.ts: -------------------------------------------------------------------------------- 1 | /***** 2 | License 3 | -------------- 4 | Copyright © 2020-2025 Mojaloop Foundation 5 | The Mojaloop files are made available by the Mojaloop Foundation under the Apache License, Version 2.0 (the "License") and you may not use these files except in compliance with the License. You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, the Mojaloop files are distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. 10 | 11 | Contributors 12 | -------------- 13 | This is the official list of the Mojaloop project contributors for this file. 14 | Names of the original copyright holders (individuals or organizations) 15 | should be listed with a '*' in the first column. People who have 16 | contributed from an organization can be listed under the organization 17 | that actually holds the copyright for their contributions (see the 18 | Mojaloop Foundation for an example). Those individuals should have 19 | their names indented and be marked with a '-'. Email address can be added 20 | optionally within square brackets . 21 | 22 | * Mojaloop Foundation 23 | - Name Surname 24 | 25 | 26 | *****/ 27 | 28 | 'use strict' 29 | 30 | export default class Template { 31 | public static add (num1: number, num2: number): number { 32 | return num1 + num2 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | /***** 2 | License 3 | -------------- 4 | Copyright © 2020-2025 Mojaloop Foundation 5 | The Mojaloop files are made available by the Mojaloop Foundation under the Apache License, Version 2.0 (the "License") and you may not use these files except in compliance with the License. You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, the Mojaloop files are distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. 10 | 11 | Contributors 12 | -------------- 13 | This is the official list of the Mojaloop project contributors for this file. 14 | Names of the original copyright holders (individuals or organizations) 15 | should be listed with a '*' in the first column. People who have 16 | contributed from an organization can be listed under the organization 17 | that actually holds the copyright for their contributions (see the 18 | Mojaloop Foundation for an example). Those individuals should have 19 | their names indented and be marked with a '-'. Email address can be added 20 | optionally within square brackets . 21 | 22 | * Mojaloop Foundation 23 | - Name Surname 24 | 25 | 26 | *****/ 27 | 28 | 'use strict' 29 | 30 | import Template from './Template' 31 | 32 | export default new Template() 33 | -------------------------------------------------------------------------------- /src/seed/README.md: -------------------------------------------------------------------------------- 1 | # ./seed 2 | 3 | Seed contains TS scripts related to seeding pisp environments. 4 | 5 | For now, it is a simple port from the postman approach of seeding the database, for use in the `docker-live` k8s environment. 6 | 7 | In the future, we may want to: 8 | 1. Use this tool to seed the `docker-local` environment 9 | 2. Spin off into a standalone tool for others in the Mojaloop Community 10 | 11 | 12 | ## TODO: 13 | - unit testing + test coverage 14 | - improve config tooling 15 | - improve cli running - make it possible to just run one of the collections 16 | - fix hack where the `settlementAccountId` is hardcoded 17 | -------------------------------------------------------------------------------- /src/seed/cli.ts: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ts-node 2 | 3 | 4 | import collections from './index' 5 | import { RunResultType } from './runResult' 6 | import { SeedCollection } from './types' 7 | import chalk from 'chalk'; 8 | 9 | const runCollection = async (collection: SeedCollection) => { 10 | const collectionNameFormatted = chalk.blue(collection.name) 11 | 12 | console.log(`\n\n ${chalk.bold('Running')}: ${collectionNameFormatted}\n ${chalk.bold('Description')}: ${collection.description}`) 13 | console.log(` |`) 14 | const result = await collection.run() 15 | console.log(` |`) 16 | switch (result.type) { 17 | case RunResultType.SUCCESS: { 18 | console.log(` ${collectionNameFormatted} ${chalk.green(`Passed`)}`) 19 | if (result.warnings.length > 0) { 20 | console.log(` ${chalk.yellow('Passed with warnings:')} \n - ${result.warnings.join('\n - ')}`) 21 | } 22 | 23 | break; 24 | } 25 | case RunResultType.FAILURE: 26 | console.log(`${collectionNameFormatted} ${chalk.red(`Failed`)}`) 27 | if (result.warnings.length > 0) { 28 | console.log(` ${chalk.yellow('Failed with warnings:')} \n - ${result.warnings.join('\n - ')}`) 29 | } 30 | console.log(` ${chalk.red('Failed with errors:')} \n - ${result.errors.join('\n - ')}`) 31 | break; 32 | } 33 | } 34 | 35 | async function main() { 36 | for (const collection of collections) { 37 | await runCollection(collection) 38 | } 39 | } 40 | 41 | main() 42 | .catch(err => { 43 | console.log('cli.ts, fatal error', err) 44 | process.exit(1) 45 | }) 46 | -------------------------------------------------------------------------------- /src/seed/index.ts: -------------------------------------------------------------------------------- 1 | import config, { DFSPParticipant, ParticipantType } from './config' 2 | 3 | import hubSteps from './steps/hubSteps' 4 | import oracleSteps from './steps/oracleSteps' 5 | import makeParticipantSteps from './steps/participantSteps' 6 | import makePartySteps from './steps/partySteps' 7 | import { SeedCollection } from './types' 8 | 9 | 10 | const collections: Array = [ 11 | hubSteps(config), 12 | oracleSteps(config), 13 | 14 | // Generate a set of participant steps for each participant 15 | ...config.participants.map(p => makeParticipantSteps(p)(config)), 16 | 17 | // Generate a set of party steps for DFSP participants 18 | ...config.participants 19 | .filter(p => p.type === ParticipantType.DFSP) 20 | // we cast here because TS isn't smart enough to figure out the types after a filter 21 | .map(p => makePartySteps(p as unknown as DFSPParticipant)(config)), 22 | ] 23 | 24 | export default collections 25 | -------------------------------------------------------------------------------- /src/seed/runResult.ts: -------------------------------------------------------------------------------- 1 | 2 | // Strict typing of run results 3 | export enum RunResultType { 4 | SUCCESS = 'SUCCESS', 5 | FAILURE = 'FAILURE', 6 | } 7 | 8 | export type RunResult = SuccessResult | FailureResult 9 | export interface SuccessResult { 10 | type: RunResultType.SUCCESS 11 | warnings: Array 12 | } 13 | 14 | export interface FailureResult { 15 | type: RunResultType.FAILURE 16 | warnings: Array 17 | errors: Array 18 | } 19 | 20 | export class Result { 21 | public static Success(warnings?: Array): SuccessResult { 22 | return { 23 | type: RunResultType.SUCCESS, 24 | warnings: warnings || [] 25 | } 26 | } 27 | 28 | public static Failure(errors: Array, warnings?: Array): FailureResult { 29 | return { 30 | type: RunResultType.FAILURE, 31 | warnings: warnings || [], 32 | errors, 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /src/seed/steps/genericSteps.ts: -------------------------------------------------------------------------------- 1 | import chalk from 'chalk'; 2 | import { GlobalConfig } from '../config'; 3 | import { Result, RunResult, RunResultType } from '../runResult'; 4 | import { SeedCollection, SeedStep } from '../types'; 5 | export interface ConstConfig { 6 | id: string, 7 | name: string, 8 | description?: string, 9 | ignoreFailure: boolean, 10 | } 11 | 12 | export class GenericSteps implements SeedCollection { 13 | id: string; 14 | name: string; 15 | description?: string; 16 | steps: SeedStep[]; 17 | ignoreFailure: boolean; 18 | 19 | constructor(constConfig: ConstConfig, globalConfig: GlobalConfig, stepGenerator: (config: GlobalConfig) => Array) { 20 | this.id = constConfig.id 21 | this.name = constConfig.name 22 | this.description = constConfig.description 23 | this.ignoreFailure = constConfig.ignoreFailure 24 | 25 | this.steps = stepGenerator(globalConfig) 26 | } 27 | 28 | public async run(): Promise { 29 | let warnings: Array = [] 30 | let errors: Array = [] 31 | 32 | for (const step of this.steps) { 33 | console.log(" - step:", chalk.magenta(step.name)) 34 | const result = await step.command() 35 | 36 | warnings = warnings.concat(result.warnings) 37 | if (result.type === RunResultType.FAILURE) { 38 | if (step.ignoreFailure) { 39 | // add to warnings - we are ignoring the failure 40 | warnings = warnings.concat(result.errors.map(e => `${step.name}: ${e.name}, ${e.message}`)) 41 | } else { 42 | // only add errors if we aren't ignoring failures 43 | errors = errors.concat(result.errors) 44 | } 45 | } 46 | } 47 | 48 | if (errors.length > 0) { 49 | return Result.Failure(errors, warnings) 50 | } 51 | 52 | return Result.Success(warnings) 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /src/seed/steps/oracleSteps.ts: -------------------------------------------------------------------------------- 1 | 2 | import { GlobalConfig } from '../config'; 3 | import Requests from '../requests'; 4 | import { SeedStep } from '../types'; 5 | import { wrapWithRunResult } from '../utils'; 6 | import { ConstConfig, GenericSteps } from './genericSteps'; 7 | 8 | 9 | // Step Constant config 10 | // This won't change dynamically 11 | const constConfig: ConstConfig = { 12 | id: 'oraclesteps', 13 | name: 'Oracle Steps', 14 | description: 'Seeds the initial oracle config', 15 | ignoreFailure: true, 16 | } 17 | 18 | // Define steps here 19 | const stepGenerator = (config: GlobalConfig): Array => { 20 | return [ 21 | { 22 | name: 'create a default oracle', 23 | // This command is not idempotent 24 | ignoreFailure: true, 25 | command: wrapWithRunResult(() => Requests.postOracles(config.urls.alsAdmin, { 26 | body: { 27 | "oracleIdType": "MSISDN", 28 | "endpoint": { 29 | "value": `${config.applicationUrls.oracle}/oracle`, 30 | "endpointType": "URL" 31 | }, 32 | "currency": "USD", 33 | "isDefault": true 34 | } 35 | })) 36 | }, 37 | 38 | ] 39 | } 40 | 41 | const steps = (config: any) => new GenericSteps(constConfig, config, stepGenerator) 42 | export default steps 43 | -------------------------------------------------------------------------------- /src/seed/steps/partySteps.ts: -------------------------------------------------------------------------------- 1 | import { DFSPParticipant, GlobalConfig } from "../config"; 2 | import Requests from '../requests'; 3 | import { SeedStep } from '../types'; 4 | import { wrapWithRunResult } from '../utils'; 5 | import { ConstConfig, GenericSteps } from './genericSteps'; 6 | 7 | 8 | function makeStepsForParticipantAndParties(config: GlobalConfig, participant: DFSPParticipant): Array { 9 | const steps: Array = [] 10 | 11 | participant.parties.forEach(party => { 12 | // For each party 13 | // 1. Register at the ALS 14 | // 2. Create an entry in the Simulator 15 | // TODO: Anything else? 16 | 17 | steps.push({ 18 | name: `register with ALS: ${party.idType}/${party.idValue}`, 19 | ignoreFailure: false, 20 | command: wrapWithRunResult(() => Requests.postALSParticipant(config.urls.als, { 21 | headers: { 22 | 'FSPIOP-Source': participant.id 23 | }, 24 | idType: party.idType, 25 | idValueOrSubType: party.idValue, 26 | body: { 27 | fspId: participant.id, 28 | currency: config.currency 29 | } 30 | })) 31 | }) 32 | 33 | steps.push({ 34 | name: `register with simulator ${party.idType}/${party.idValue}`, 35 | // Will fail if already exists 36 | ignoreFailure: true, 37 | command: wrapWithRunResult(() => Requests.postSimulatorParty(participant.simulatorAdminUrl, { 38 | body: { 39 | ...party 40 | } 41 | })) 42 | }) 43 | }) 44 | 45 | return steps 46 | } 47 | 48 | function makePartySteps(participant: DFSPParticipant) { 49 | const constConfig: ConstConfig = { 50 | id: `parties_for_participant_${participant.id}`, 51 | name: `Parties Steps - ${participant.id}`, 52 | description: `Sets up parties for ${participant.id}`, 53 | ignoreFailure: false, 54 | } 55 | const stepGenerator = (config: GlobalConfig) => makeStepsForParticipantAndParties(config, participant) 56 | 57 | return (config: GlobalConfig) => new GenericSteps(constConfig, config, stepGenerator) 58 | } 59 | 60 | 61 | export default makePartySteps 62 | -------------------------------------------------------------------------------- /src/seed/types.ts: -------------------------------------------------------------------------------- 1 | import { RunResult } from './runResult'; 2 | 3 | export interface SeedStep { 4 | name: string, 5 | ignoreFailure: boolean, 6 | command: () => Promise 7 | } 8 | 9 | export interface SeedCollection { 10 | id: string, 11 | name: string, 12 | description?: string, 13 | steps: Array 14 | ignoreFailure: boolean 15 | run: () => Promise 16 | } 17 | -------------------------------------------------------------------------------- /src/seed/utils.ts: -------------------------------------------------------------------------------- 1 | import { Result, RunResult } from './runResult' 2 | 3 | /** 4 | * @function wrapWithRunResult 5 | * @description A simple wrapper around an anonymous function 6 | * if the function throws an error, the wrapper will return a FailureResult 7 | * @param func 8 | */ 9 | export function wrapWithRunResult (func: () => any): () => Promise { 10 | return async () => { 11 | try { 12 | await func() 13 | return Result.Success() 14 | } catch (err) { 15 | return Result.Failure([err]) 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /swagger_ui/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mojaloop/pisp-project/01f8d384d54ef8e86821a2149143d741c5cc7b2b/swagger_ui/favicon-16x16.png -------------------------------------------------------------------------------- /test/contract/P2PTransfer.test.ts: -------------------------------------------------------------------------------- 1 | import TestEnv from '../e2e/TestEnv' 2 | import axios from 'axios' 3 | 4 | /** 5 | * @name P2PTransfer 6 | * @description This is more of a sanity check so we know our environment is up and running 7 | */ 8 | describe('Peer to Peer transfer', () => { 9 | it('Performs a P2P transfer from Alice -> Bob', async () => { 10 | // Arrange 11 | const scenariosURI = `${TestEnv.baseUrls.pispContract}/scenarios` 12 | const options = [ 13 | { 14 | name: 'scenario1', 15 | operation: 'postTransfers', 16 | body: { 17 | from: { 18 | ...TestEnv.users.alice 19 | }, 20 | to: { 21 | ...TestEnv.users.bob 22 | }, 23 | amountType: TestEnv.amountType, 24 | currency: TestEnv.currency, 25 | amount: TestEnv.amount, 26 | transactionType: 'TRANSFER', 27 | note: 'Test p2p transfer', 28 | homeTransactionId: 'homeTxId123' 29 | } 30 | } 31 | ] 32 | const expected = { 33 | amount: TestEnv.amount, 34 | currentState: 'COMPLETED', 35 | fulfil: expect.objectContaining({ 36 | transferState: 'COMMITTED' 37 | }), 38 | from: expect.objectContaining({ 39 | idType: 'MSISDN', 40 | idValue: TestEnv.users.alice.idValue 41 | }), 42 | to: expect.objectContaining({ 43 | idType: 'MSISDN', 44 | idValue: TestEnv.users.bob.idValue 45 | }), 46 | quoteResponse: expect.objectContaining({ 47 | transferAmount: { 48 | amount: TestEnv.amount, 49 | currency: TestEnv.currency 50 | } 51 | }) 52 | } 53 | 54 | // Act 55 | // TODO: use client library 56 | const result = await axios.post(scenariosURI, options) 57 | 58 | // Assert 59 | expect(result.status).toBe(200) 60 | expect(result.data.scenario1.result).toEqual(expect.objectContaining(expected)) 61 | }) 62 | }) 63 | -------------------------------------------------------------------------------- /test/contract/ThirdpartyRequestsTransaction.test.ts: -------------------------------------------------------------------------------- 1 | import TestEnv from '../e2e/TestEnv' 2 | import axios from 'axios' 3 | 4 | /** 5 | * @name ThirdpartyRequestsTransactions 6 | * @description Thirdparty Requests Transactions Tests 7 | */ 8 | describe('Thirdparty Requests Transaction Tests', () => { 9 | it('Test GET /thirdpartyRequests/transactions request', async () => { 10 | const tprURI = `${TestEnv.baseUrls.pispContractSchemeAdapter}/thirdpartyRequests/transactions/02e28448-3c05-4059-b5f7-d518d0a2d8ea` 11 | 12 | const result = await axios.get(tprURI) 13 | 14 | // Assert 15 | expect(result.status).toBe(200) 16 | expect(result.data.currentState).toBe('COMPLETED') 17 | }) 18 | 19 | it('Test POST /thirdpartyRequests/transactions request', async () => { 20 | const tprURI = `${TestEnv.baseUrls.pispContractSchemeAdapter}/thirdpartyRequests/transactions` 21 | const options = { 22 | transactionRequestId: '02e28448-3c05-4059-b5f7-d518d0a2d8ea', 23 | sourceAccountId: 'dfspa.alice.1234', 24 | consentId: 'ddab7438-a8a8-2dc0-b6bf-25c8e28a7561', 25 | payee: { 26 | partyIdInfo: { 27 | partyIdType: 'MSISDN', 28 | partyIdentifier: '+4412345678', 29 | fspId: 'dfspb' 30 | } 31 | }, 32 | payer: { 33 | personalInfo: { 34 | complexName: { 35 | firstName: 'Ayesha', 36 | lastName: 'Takia' 37 | } 38 | }, 39 | partyIdInfo: { 40 | partyIdType: 'MSISDN', 41 | partyIdentifier: '+44 8765 4321', 42 | fspId: 'dfspa' 43 | } 44 | }, 45 | amountType: 'SEND', 46 | amount: { 47 | amount: '100', 48 | currency: 'USD' 49 | }, 50 | transactionType: { 51 | scenario: 'TRANSFER', 52 | initiator: 'PAYER', 53 | initiatorType: 'CONSUMER' 54 | }, 55 | expiration: '2016-05-24T08:38:08.699-04:00' 56 | } 57 | 58 | const result = await axios.post(tprURI, options) 59 | 60 | // Assert 61 | expect(result.status).toBe(200) 62 | expect(result.data.currentState).toBe('COMPLETED') 63 | }) 64 | }) 65 | -------------------------------------------------------------------------------- /test/e2e-ttk/.gitignore: -------------------------------------------------------------------------------- 1 | tmp.json 2 | tmp.js 3 | *.html -------------------------------------------------------------------------------- /test/e2e-ttk/environment.json: -------------------------------------------------------------------------------- 1 | {} -------------------------------------------------------------------------------- /test/e2e/PISP_Discovery.test.ts: -------------------------------------------------------------------------------- 1 | import TestEnv from './TestEnv' 2 | import axios from 'axios' 3 | 4 | describe('GET /linking/accounts/{fspId}/{userId}', (): void => { 5 | const expectedResp = { 6 | accounts: [ 7 | { 8 | accountNickname: 'dfspa.user.nickname1', 9 | address: 'dfspa.username.1234', 10 | currency: 'ZAR' 11 | }, 12 | { 13 | accountNickname: 'dfspa.user.nickname2', 14 | address: 'dfspa.username.5678', 15 | currency: 'USD' 16 | } 17 | ], 18 | currentState: 'COMPLETED' 19 | } 20 | 21 | it('PISP requests DFSP to return user accounts for linking', async (): Promise => { 22 | const scenariosURI = `${TestEnv.baseUrls.pispThirdpartySchemeAdapterOutbound}/linking/accounts/dfspa/username1234` 23 | const response = await axios.get(scenariosURI) 24 | 25 | // Assert 26 | expect(response.status).toBe(200) 27 | expect(response.data).toEqual(expectedResp) 28 | }) 29 | 30 | it('PISP requests DFSP: Expect ID not found', async (): Promise => { 31 | const scenariosURI = `${TestEnv.baseUrls.pispThirdpartySchemeAdapterOutbound}/linking/accounts/dfspa/test` 32 | const idNotFoundResp = { 33 | accounts: [], 34 | errorInformation: { 35 | errorCode: '3200', 36 | errorDescription: 'Generic ID not found' 37 | }, 38 | currentState: 'COMPLETED' 39 | } 40 | 41 | await axios.get(scenariosURI) 42 | .catch(error => { 43 | // Assert 44 | expect(error.response.status).toBe(500) 45 | expect(error.response.data).toEqual(expect.objectContaining(idNotFoundResp)) 46 | }) 47 | }) 48 | }) 49 | -------------------------------------------------------------------------------- /test/e2e/PISP_Prelinking.test.ts: -------------------------------------------------------------------------------- 1 | import TestEnv from './TestEnv' 2 | import axios from 'axios' 3 | 4 | describe('GET /linking/providers', (): void => { 5 | const expectedResp = { 6 | currentState: 'providersLookupSuccess', 7 | providers: ['dfspa', 'dfspb'] 8 | } 9 | 10 | it('PISP requests Thirdparty service enabled DFSPs', async (): Promise => { 11 | const scenariosURI = `${TestEnv.baseUrls.pispThirdpartySchemeAdapterOutbound}/linking/providers` 12 | const response = await axios.get(scenariosURI) 13 | 14 | // Assert 15 | expect(response.status).toBe(200) 16 | expect(response.data).toEqual(expectedResp) 17 | }) 18 | 19 | // There's no arguments that can be used for conditions for rules to make the 20 | // ml-testing-toolkit return an error with the GET /services/{ServiceType} request 21 | it.todo('PISP requests Thirdparty service enabled DFSPs - error returned') 22 | }) 23 | -------------------------------------------------------------------------------- /test/e2e/expected.ts: -------------------------------------------------------------------------------- 1 | 2 | export const Alice = { 3 | partyIdInfo: { 4 | partyIdType: 'MSISDN', 5 | partyIdentifier: '123456789', 6 | fspId: 'dfspa' 7 | }, 8 | personalInfo: { 9 | complexName: { firstName: 'Alice', middleName: 'K', lastName: 'Alpaca' }, 10 | dateOfBirth: '1970-01-01' 11 | }, 12 | name: 'Alice Alpaca', 13 | accounts: { 14 | account: [ 15 | { 16 | address: 'moja.amber.53451233-b82a5456a-4fa9-838b-123456789', 17 | currency: 'USD', 18 | description: 'savings' 19 | }, 20 | { 21 | address: 'moja.amber.8f027046-b8236345a-4fa9-838b-123456789', 22 | currency: 'USD', 23 | description: 'checkings' 24 | } 25 | ] 26 | } 27 | } 28 | 29 | export const Bob = { 30 | partyIdInfo: { 31 | partyIdType: 'MSISDN', 32 | partyIdentifier: '987654321', 33 | fspId: 'dfspb' 34 | }, 35 | personalInfo: { 36 | complexName: { firstName: 'Bob', middleName: 'O', lastName: 'Babirusa' }, 37 | dateOfBirth: '1970-01-01' 38 | }, 39 | name: 'Bob Babirusa', 40 | accounts: { 41 | account: [ 42 | { 43 | address: 'moja.burgundy.76542756-f49gk439f-6a5f-543d-987654321', 44 | currency: 'USD', 45 | description: 'savings' 46 | }, 47 | { 48 | address: 'moja.burgundy.43638980-f49gk439f-6a5f-543d-987654321', 49 | currency: 'USD', 50 | description: 'checkings' 51 | } 52 | ] 53 | } 54 | } 55 | 56 | export default { 57 | Alice, 58 | Bob 59 | } 60 | -------------------------------------------------------------------------------- /test/features/template.scenario.feature: -------------------------------------------------------------------------------- 1 | Feature: Template addiction 2 | 3 | Scenario: Adding two arguments 4 | Given Template and two arguments: A=1 and B=2 5 | When I add A and B 6 | Then The result should be C=3 7 | 8 | Scenario: Checking index module layout 9 | Given Index module 10 | When I have default imported Index type 11 | Then The imported Index is type object -------------------------------------------------------------------------------- /test/step-definitions/template.step.ts: -------------------------------------------------------------------------------- 1 | import { loadFeature, defineFeature } from 'jest-cucumber' 2 | 3 | import Template from '../../src/Template' 4 | import path from 'path' 5 | 6 | const featurePath = path.join(__dirname, '../features/template.scenario.feature') 7 | const feature = loadFeature(featurePath) 8 | 9 | defineFeature(feature, (test): void => { 10 | let A: number, B: number, C: number 11 | test('Adding two arguments', ({ given, when, then }): void => { 12 | given('Template and two arguments: A=1 and B=2', (): void => { 13 | A = 1 14 | B = 2 15 | }) 16 | 17 | when('I add A and B', (): void => { 18 | C = Template.add(A, B) 19 | }) 20 | 21 | then('The result should be C=3', (): void => { 22 | expect(C).toBe(3) 23 | }) 24 | }) 25 | 26 | test('Checking index module layout', ({ given, when, then }): void => { 27 | let index = {} 28 | let indexType = '' 29 | given('Index module', (): void => { 30 | index = require('../../src/index') 31 | }) 32 | 33 | when('I have default imported Index type', (): void => { 34 | indexType = typeof index 35 | }) 36 | 37 | then('The imported Index is type object', (): void => { 38 | expect(indexType).toEqual('object') 39 | }) 40 | }) 41 | }) 42 | -------------------------------------------------------------------------------- /test/unit/index.test.ts: -------------------------------------------------------------------------------- 1 | /***** 2 | License 3 | -------------- 4 | Copyright © 2020-2025 Mojaloop Foundation 5 | The Mojaloop files are made available by the Mojaloop Foundation under the Apache License, Version 2.0 (the "License") and you may not use these files except in compliance with the License. You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, the Mojaloop files are distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. 10 | 11 | Contributors 12 | -------------- 13 | This is the official list of the Mojaloop project contributors for this file. 14 | Names of the original copyright holders (individuals or organizations) 15 | should be listed with a '*' in the first column. People who have 16 | contributed from an organization can be listed under the organization 17 | that actually holds the copyright for their contributions (see the 18 | Mojaloop Foundation for an example). Those individuals should have 19 | their names indented and be marked with a '-'. Email address can be added 20 | optionally within square brackets . 21 | 22 | * Mojaloop Foundation 23 | - Name Surname 24 | 25 | * Lewis Daly 26 | 27 | * Paweł Marzec 28 | *****/ 29 | 30 | 'use strict' 31 | 32 | import Template from '../../src/Template' 33 | import * as index from '../../src' 34 | 35 | describe('minimal unit test', (): void => { 36 | it('should pass', (): void => { 37 | // invoke static method 38 | expect(Template.add(1, 2)).toBe(3) 39 | // module layout test 40 | expect(typeof index).toBe('object') 41 | }) 42 | }) 43 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "include": [ 3 | "src", 4 | "**/*.test.ts", 5 | "test" 6 | ], 7 | "exclude": [ 8 | "node_modules", 9 | "**/*.spec.ts", 10 | "lib", 11 | "coverage" 12 | ], 13 | "compilerOptions": { 14 | "target": "es2018", 15 | "module": "commonjs", 16 | "resolveJsonModule": true, 17 | "lib": [ 18 | "esnext" 19 | ], 20 | "importHelpers": true, 21 | "declaration": true, 22 | "sourceMap": true, 23 | "rootDir": "src", 24 | "outDir": "dist", 25 | "strict": true, 26 | "noImplicitAny": true, 27 | "strictNullChecks": true, 28 | "strictFunctionTypes": true, 29 | "strictPropertyInitialization": true, 30 | "noImplicitThis": true, 31 | "alwaysStrict": true, 32 | "noUnusedLocals": true, 33 | "noUnusedParameters": true, 34 | "noImplicitReturns": true, 35 | "noFallthroughCasesInSwitch": true, 36 | "moduleResolution": "node", 37 | "baseUrl": "./", 38 | "paths": { 39 | "*": [ 40 | "src/*", 41 | "node_modules/*" 42 | ] 43 | }, 44 | "esModuleInterop": true 45 | } 46 | } 47 | --------------------------------------------------------------------------------