work on cleaning up benchmark logic
This commit is contained in:
parent
82fd1a1164
commit
8cc1edfe0a
@ -68,7 +68,12 @@ taler_exchange_benchmark_LDADD = \
|
||||
$(XLIB)
|
||||
|
||||
EXTRA_DIST = \
|
||||
benchmark-common.conf \
|
||||
benchmark-cs.conf \
|
||||
benchmark-rsa.conf \
|
||||
bank-benchmark-cs.conf \
|
||||
bank-benchmark-rsa.conf \
|
||||
coins-cs.conf \
|
||||
coins-rsa.conf \
|
||||
$(bin_SCRIPTS) \
|
||||
exchange_benchmark_home/.local/share/taler/exchange/offline-keys/master.priv
|
||||
|
@ -1,128 +1,17 @@
|
||||
# This file is in the public domain.
|
||||
#
|
||||
[paths]
|
||||
# Persistent data storage for the testcase
|
||||
# This value is a default for `taler_config_home'
|
||||
taler_test_home = exchange_benchmark_home/
|
||||
|
||||
[taler]
|
||||
# Currency supported by the exchange (can only be one)
|
||||
currency = EUR
|
||||
CURRENCY_ROUND_UNIT = EUR:0.01
|
||||
|
||||
[exchange]
|
||||
# how long is one signkey valid?
|
||||
signkey_duration = 4 weeks
|
||||
signkey_legal_duration = 2 years
|
||||
# how long do we provide to clients denomination and signing keys
|
||||
# ahead of time?
|
||||
# Keep it short so the test runs fast.
|
||||
lookahead_sign = 12h
|
||||
# HTTP port the exchange listens to
|
||||
port = 8081
|
||||
# Master public key used to sign the exchange's various keys
|
||||
master_public_key = 98NJW3CQHZQGQXTY3K85K531XKPAPAVV4Q5V8PYYRR00NJGZWNVG
|
||||
# How to access our database
|
||||
DB = postgres
|
||||
# Base URL of the exchange. Must be set to a URL where the
|
||||
# exchange (or the twister) is actually listening.
|
||||
base_url = "http://localhost:8081/"
|
||||
|
||||
WIREWATCH_IDLE_SLEEP_INTERVAL = 500 ms
|
||||
|
||||
[exchange-offline]
|
||||
MASTER_PRIV_FILE = ${TALER_DATA_HOME}/exchange/offline-keys/master.priv
|
||||
|
||||
[auditor]
|
||||
BASE_URL = "http://localhost:8083/"
|
||||
|
||||
[exchangedb-postgres]
|
||||
config = "postgres:///talercheck"
|
||||
|
||||
[benchmark-remote-exchange]
|
||||
host = localhost
|
||||
# Adjust $HOME to match remote target!
|
||||
dir = $HOME/repos/taler/exchange/src/benchmark
|
||||
|
||||
[bank]
|
||||
HTTP_PORT = 8082
|
||||
SERVE = http
|
||||
MAX_DEBT = EUR:100000000000.0
|
||||
MAX_DEBT_BANK = EUR:1000000000000000.0
|
||||
|
||||
[benchmark]
|
||||
USER_PAYTO_URI = payto://x-taler-bank/localhost:8082/42?receiver-name=user42
|
||||
@INLINE@ benchmark-common.conf
|
||||
@INLINE@ coins-cs.conf
|
||||
|
||||
[exchange-account-2]
|
||||
# What is the payto://-URL of the exchange (to generate wire response)
|
||||
PAYTO_URI = "payto://x-taler-bank/localhost:8082/Exchange?receiver-name=Exchange"
|
||||
enable_debit = YES
|
||||
enable_credit = YES
|
||||
ENABLE_DEBIT = YES
|
||||
ENABLE_CREDIT = YES
|
||||
|
||||
[exchange-accountcredentials-2]
|
||||
# What is the bank account (with the "Taler Bank" demo system)? Must end with "/".
|
||||
WIRE_GATEWAY_URL = http://localhost:8082/Exchange/
|
||||
# Authentication information for basic authentication
|
||||
WIRE_GATEWAY_AUTH_METHOD = "basic"
|
||||
username = Exchange
|
||||
password = x
|
||||
|
||||
|
||||
|
||||
|
||||
# Sections starting with "coin_" specify which denominations
|
||||
# the exchange should support (and their respective fee structure)
|
||||
[coin_eur_ct_1]
|
||||
value = EUR:0.01
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.00
|
||||
fee_deposit = EUR:0.00
|
||||
fee_refresh = EUR:0.01
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_ct_10]
|
||||
value = EUR:0.10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_1]
|
||||
value = EUR:1
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_5]
|
||||
value = EUR:5
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_10]
|
||||
value = EUR:10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
USERNAME = Exchange
|
||||
PASSWORD = x
|
||||
|
@ -1,133 +1,17 @@
|
||||
# This file is in the public domain.
|
||||
#
|
||||
[paths]
|
||||
# Persistent data storage for the testcase
|
||||
# This value is a default for `taler_config_home'
|
||||
taler_test_home = exchange_benchmark_home/
|
||||
|
||||
[taler]
|
||||
# Currency supported by the exchange (can only be one)
|
||||
currency = EUR
|
||||
CURRENCY_ROUND_UNIT = EUR:0.01
|
||||
|
||||
[exchange]
|
||||
# how long is one signkey valid?
|
||||
signkey_duration = 4 weeks
|
||||
signkey_legal_duration = 2 years
|
||||
# how long do we provide to clients denomination and signing keys
|
||||
# ahead of time?
|
||||
# Keep it short so the test runs fast.
|
||||
lookahead_sign = 12h
|
||||
# HTTP port the exchange listens to
|
||||
port = 8081
|
||||
# Master public key used to sign the exchange's various keys
|
||||
master_public_key = 98NJW3CQHZQGQXTY3K85K531XKPAPAVV4Q5V8PYYRR00NJGZWNVG
|
||||
# How to access our database
|
||||
DB = postgres
|
||||
# Base URL of the exchange. Must be set to a URL where the
|
||||
# exchange (or the twister) is actually listening.
|
||||
base_url = "http://localhost:8081/"
|
||||
|
||||
WIREWATCH_IDLE_SLEEP_INTERVAL = 1500 ms
|
||||
|
||||
[exchange-offline]
|
||||
MASTER_PRIV_FILE = ${TALER_DATA_HOME}/exchange/offline-keys/master.priv
|
||||
|
||||
[auditor]
|
||||
BASE_URL = "http://localhost:8083/"
|
||||
|
||||
[exchangedb-postgres]
|
||||
config = "postgres://exchange:taler@192.168.42.42/exchange"
|
||||
|
||||
[benchmark-remote-exchange]
|
||||
host = localhost
|
||||
# Adjust $HOME to match remote target!
|
||||
dir = $HOME/repos/taler/exchange/src/benchmark
|
||||
|
||||
[bank]
|
||||
HTTP_PORT = 8082
|
||||
SERVE = http
|
||||
MAX_DEBT = EUR:100000000000.0
|
||||
MAX_DEBT_BANK = EUR:1000000000000000.0
|
||||
|
||||
[benchmark]
|
||||
USER_PAYTO_URI = payto://x-taler-bank/localhost:8082/42
|
||||
@INLINE@ benchmark-common.conf
|
||||
@INLINE@ coins-cs.conf
|
||||
|
||||
[exchange-account-2]
|
||||
# What is the payto://-URL of the exchange (to generate wire response)
|
||||
PAYTO_URI = "payto://x-taler-bank/localhost:8082/Exchange"
|
||||
enable_debit = YES
|
||||
enable_credit = YES
|
||||
PAYTO_URI = "payto://x-taler-bank/localhost:8082/Exchange?receiver-name=Exchange"
|
||||
ENABLE_DEBIT = YES
|
||||
ENABLE_CREDIT = YES
|
||||
|
||||
[exchange-accountcredentials-2]
|
||||
# What is the bank account (with the "Taler Bank" demo system)? Must end with "/".
|
||||
WIRE_GATEWAY_URL = http://localhost:8082/Exchange/
|
||||
# Authentication information for basic authentication
|
||||
WIRE_GATEWAY_AUTH_METHOD = "basic"
|
||||
username = Exchange
|
||||
password = x
|
||||
|
||||
|
||||
|
||||
|
||||
# Sections starting with "coin_" specify which denominations
|
||||
# the exchange should support (and their respective fee structure)
|
||||
[coin_eur_ct_1]
|
||||
value = EUR:0.01
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.00
|
||||
fee_deposit = EUR:0.00
|
||||
fee_refresh = EUR:0.01
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_ct_10]
|
||||
value = EUR:0.10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_1]
|
||||
value = EUR:1
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_5]
|
||||
value = EUR:5
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_10]
|
||||
value = EUR:10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
USERNAME = Exchange
|
||||
PASSWORD = x
|
||||
|
59
src/benchmark/benchmark-common.conf
Normal file
59
src/benchmark/benchmark-common.conf
Normal file
@ -0,0 +1,59 @@
|
||||
# This file is in the public domain.
|
||||
[paths]
|
||||
TALER_TEST_HOME=exchange_benchmark_home/
|
||||
|
||||
[taler]
|
||||
CURRENCY=EUR
|
||||
CURRENCY_ROUND_UNIT=EUR:0.01
|
||||
|
||||
[exchange]
|
||||
AML_THRESHOLD=EUR:99999999
|
||||
SIGNKEY_LEGAL_DURATION=2 years
|
||||
PORT=8081
|
||||
MASTER_PUBLIC_KEY=98NJW3CQHZQGQXTY3K85K531XKPAPAVV4Q5V8PYYRR00NJGZWNVG
|
||||
DB=postgres
|
||||
BASE_URL="http://localhost:8081/"
|
||||
AGGREGATOR_SHARD_SIZE=67108864
|
||||
WIREWATCH_IDLE_SLEEP_INTERVAL=5 ms
|
||||
|
||||
[taler-exchange-secmod-rsa]
|
||||
LOOKAHEAD_SIGN="1 d"
|
||||
|
||||
[taler-exchange-secmod-cs]
|
||||
LOOKAHEAD_SIGN="1 d"
|
||||
|
||||
[taler-exchange-secmod-eddsa]
|
||||
DURATION="2 d"
|
||||
LOOKAHEAD_SIGN="1 d"
|
||||
|
||||
[exchangedb-postgres]
|
||||
CONFIG="postgres:///talercheck"
|
||||
|
||||
[exchange-offline]
|
||||
MASTER_PRIV_FILE=${TALER_DATA_HOME}/exchange/offline-keys/master.priv
|
||||
|
||||
[bank]
|
||||
HTTP_PORT=8082
|
||||
SERVE=http
|
||||
MAX_DEBT=EUR:100000000000.0
|
||||
MAX_DEBT_BANK=EUR:1000000000000000.0
|
||||
DATABASE=bank-db.sqlite3
|
||||
|
||||
[libeufin-nexus]
|
||||
DB_CONNECTION="jdbc:postgresql://localhost/talercheck?socketFactory=org.newsclub.net.unix."
|
||||
#DB_CONNECTION="jdbc:sqlite:libeufin-nexus.sqlite3"
|
||||
|
||||
[libeufin-sandbox]
|
||||
DB_CONNECTION="jdbc:postgresql://localhost/talercheck?socketFactory=org.newsclub.net.unix."
|
||||
#DB_CONNECTION="jdbc:sqlite:libeufin-sandbox.sqlite3"
|
||||
|
||||
[auditor]
|
||||
BASE_URL="http://localhost:8083/"
|
||||
|
||||
[benchmark-remote-exchange]
|
||||
HOST=localhost
|
||||
# Adjust $HOME to match remote target!
|
||||
DIR=$HOME/repos/taler/exchange/src/benchmark
|
||||
|
||||
[benchmark]
|
||||
USER_PAYTO_URI="payto://x-taler-bank/localhost:8082/42?receiver-name=user42"
|
@ -1,60 +1,6 @@
|
||||
# This file is in the public domain.
|
||||
#
|
||||
[paths]
|
||||
# Persistent data storage for the testcase
|
||||
# This value is a default for `taler_config_home'
|
||||
TALER_TEST_HOME = exchange_benchmark_home/
|
||||
|
||||
[taler]
|
||||
# Currency supported by the exchange (can only be one)
|
||||
CURRENCY = EUR
|
||||
CURRENCY_ROUND_UNIT = EUR:0.01
|
||||
|
||||
[exchange]
|
||||
|
||||
AML_THRESHOLD = EUR:99999999
|
||||
SIGNKEY_LEGAL_DURATION = 2 years
|
||||
|
||||
# HTTP port the exchange listens to
|
||||
PORT = 8081
|
||||
# Master public key used to sign the exchange's various keys
|
||||
MASTER_PUBLIC_KEY = 98NJW3CQHZQGQXTY3K85K531XKPAPAVV4Q5V8PYYRR00NJGZWNVG
|
||||
# How to access our database
|
||||
DB = postgres
|
||||
# Base URL of the exchange. Must be set to a URL where the
|
||||
# exchange (or the twister) is actually listening.
|
||||
BASE_URL = "http://localhost:8081/"
|
||||
|
||||
AGGREGATOR_SHARD_SIZE = 67108864
|
||||
#AGGREGATOR_SHARD_SIZE = 2147483648
|
||||
|
||||
|
||||
|
||||
WIREWATCH_IDLE_SLEEP_INTERVAL = 5 ms
|
||||
|
||||
[exchange-offline]
|
||||
MASTER_PRIV_FILE = ${TALER_DATA_HOME}/exchange/offline-keys/master.priv
|
||||
|
||||
[auditor]
|
||||
BASE_URL = "http://localhost:8083/"
|
||||
|
||||
[exchangedb-postgres]
|
||||
CONFIG = "postgres:///talercheck"
|
||||
|
||||
[benchmark-remote-exchange]
|
||||
HOST = localhost
|
||||
# Adjust $HOME to match remote target!
|
||||
DIR = $HOME/repos/taler/exchange/src/benchmark
|
||||
|
||||
[bank]
|
||||
HTTP_PORT = 8082
|
||||
SERVE = http
|
||||
MAX_DEBT = EUR:100000000000.0
|
||||
MAX_DEBT_BANK = EUR:1000000000000000.0
|
||||
DATABASE = bank-db.sqlite3
|
||||
|
||||
[benchmark]
|
||||
USER_PAYTO_URI = payto://x-taler-bank/localhost:8082/42
|
||||
@INLINE@ benchmark-common.conf
|
||||
@INLINE@ coins-cs.conf
|
||||
|
||||
[exchange-account-test]
|
||||
# What is the bank account (with the "Taler Bank" demo system)? Must end with "/".
|
||||
@ -68,61 +14,3 @@ WIRE_GATEWAY_URL = http://localhost:8082/Exchange/
|
||||
WIRE_GATEWAY_AUTH_METHOD = "basic"
|
||||
USERNAME = Exchange
|
||||
PASSWORD = x
|
||||
|
||||
|
||||
# Sections starting with "coin_" specify which denominations
|
||||
# the exchange should support (and their respective fee structure)
|
||||
[coin_eur_ct_1]
|
||||
value = EUR:0.01
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.00
|
||||
fee_deposit = EUR:0.00
|
||||
fee_refresh = EUR:0.01
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_ct_10]
|
||||
value = EUR:0.10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_1]
|
||||
value = EUR:1
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_5]
|
||||
value = EUR:5
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_10]
|
||||
value = EUR:10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
@ -1,60 +1,6 @@
|
||||
# This file is in the public domain.
|
||||
#
|
||||
[paths]
|
||||
# Persistent data storage for the testcase
|
||||
# This value is a default for `taler_config_home'
|
||||
TALER_TEST_HOME = exchange_benchmark_home/
|
||||
|
||||
[taler]
|
||||
# Currency supported by the exchange (can only be one)
|
||||
CURRENCY = EUR
|
||||
CURRENCY_ROUND_UNIT = EUR:0.01
|
||||
|
||||
[exchange]
|
||||
|
||||
AML_THRESHOLD = EUR:99999999
|
||||
SIGNKEY_LEGAL_DURATION = 2 years
|
||||
|
||||
# HTTP port the exchange listens to
|
||||
PORT = 8081
|
||||
# Master public key used to sign the exchange's various keys
|
||||
MASTER_PUBLIC_KEY = 98NJW3CQHZQGQXTY3K85K531XKPAPAVV4Q5V8PYYRR00NJGZWNVG
|
||||
# How to access our database
|
||||
DB = postgres
|
||||
# Base URL of the exchange. Must be set to a URL where the
|
||||
# exchange (or the twister) is actually listening.
|
||||
BASE_URL = "http://localhost:8081/"
|
||||
|
||||
AGGREGATOR_SHARD_SIZE = 67108864
|
||||
#AGGREGATOR_SHARD_SIZE = 2147483648
|
||||
|
||||
|
||||
|
||||
WIREWATCH_IDLE_SLEEP_INTERVAL = 5 ms
|
||||
|
||||
[exchange-offline]
|
||||
MASTER_PRIV_FILE = ${TALER_DATA_HOME}/exchange/offline-keys/master.priv
|
||||
|
||||
[auditor]
|
||||
BASE_URL = "http://localhost:8083/"
|
||||
|
||||
[exchangedb-postgres]
|
||||
CONFIG = "postgres:///talercheck"
|
||||
|
||||
[benchmark-remote-exchange]
|
||||
HOST = localhost
|
||||
# Adjust $HOME to match remote target!
|
||||
DIR = $HOME/repos/taler/exchange/src/benchmark
|
||||
|
||||
[bank]
|
||||
HTTP_PORT = 8082
|
||||
SERVE = http
|
||||
MAX_DEBT = EUR:100000000000.0
|
||||
MAX_DEBT_BANK = EUR:1000000000000000.0
|
||||
DATABASE = bank-db.sqlite3
|
||||
|
||||
[benchmark]
|
||||
USER_PAYTO_URI = payto://x-taler-bank/localhost:8082/42
|
||||
@INLINE@ benchmark-common.conf
|
||||
@INLINE@ coins-rsa.conf
|
||||
|
||||
[exchange-account-test]
|
||||
# What is the bank account (with the "Taler Bank" demo system)? Must end with "/".
|
||||
@ -68,66 +14,3 @@ WIRE_GATEWAY_URL = http://localhost:8082/Exchange/
|
||||
WIRE_GATEWAY_AUTH_METHOD = "basic"
|
||||
USERNAME = Exchange
|
||||
PASSWORD = x
|
||||
|
||||
|
||||
# Sections starting with "coin_" specify which denominations
|
||||
# the exchange should support (and their respective fee structure)
|
||||
[coin_eur_ct_1]
|
||||
value = EUR:0.01
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.00
|
||||
fee_deposit = EUR:0.00
|
||||
fee_refresh = EUR:0.01
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_ct_10]
|
||||
value = EUR:0.10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_1]
|
||||
value = EUR:1
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_5]
|
||||
value = EUR:5
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_10]
|
||||
value = EUR:10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
58
src/benchmark/coins-cs.conf
Normal file
58
src/benchmark/coins-cs.conf
Normal file
@ -0,0 +1,58 @@
|
||||
# This file is in the public domain.
|
||||
#
|
||||
# Sections starting with "coin_" specify which denominations
|
||||
# the exchange should support (and their respective fee structure)
|
||||
[coin_eur_ct_1]
|
||||
value = EUR:0.01
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.00
|
||||
fee_deposit = EUR:0.00
|
||||
fee_refresh = EUR:0.01
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_ct_10]
|
||||
value = EUR:0.10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_1]
|
||||
value = EUR:1
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_5]
|
||||
value = EUR:5
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
||||
|
||||
[coin_eur_10]
|
||||
value = EUR:10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = CS
|
63
src/benchmark/coins-rsa.conf
Normal file
63
src/benchmark/coins-rsa.conf
Normal file
@ -0,0 +1,63 @@
|
||||
# This file is in the public domain.
|
||||
#
|
||||
# Sections starting with "coin_" specify which denominations
|
||||
# the exchange should support (and their respective fee structure)
|
||||
[coin_eur_ct_1]
|
||||
value = EUR:0.01
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.00
|
||||
fee_deposit = EUR:0.00
|
||||
fee_refresh = EUR:0.01
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_ct_10]
|
||||
value = EUR:0.10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_1]
|
||||
value = EUR:1
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_5]
|
||||
value = EUR:5
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
||||
|
||||
[coin_eur_10]
|
||||
value = EUR:10
|
||||
duration_withdraw = 7 days
|
||||
duration_spend = 2 years
|
||||
duration_legal = 3 years
|
||||
fee_withdraw = EUR:0.01
|
||||
fee_deposit = EUR:0.01
|
||||
fee_refresh = EUR:0.03
|
||||
fee_refund = EUR:0.01
|
||||
CIPHER = RSA
|
||||
rsa_keysize = 2048
|
@ -51,17 +51,17 @@ START_FAKEBANK=0
|
||||
START_MERCHANT=0
|
||||
START_NEXUS=0
|
||||
START_SANDBOX=0
|
||||
CONF="~/.config/taler.conf"
|
||||
CONF_ORIG="~/.config/taler.conf"
|
||||
LOGLEVEL="DEBUG"
|
||||
|
||||
# Parse command-line options
|
||||
while getopts ':abc:efl:ms' OPTION; do
|
||||
while getopts ':abc:efhl:ms' OPTION; do
|
||||
case "$OPTION" in
|
||||
a)
|
||||
START_AUDITOR="1"
|
||||
;;
|
||||
c)
|
||||
CONF="$OPTARG"
|
||||
CONF_ORIG="$OPTARG"
|
||||
;;
|
||||
e)
|
||||
START_EXCHANGE="1"
|
||||
@ -69,6 +69,19 @@ while getopts ':abc:efl:ms' OPTION; do
|
||||
f)
|
||||
START_FAKEBANK="1"
|
||||
;;
|
||||
h)
|
||||
echo 'Supported options:'
|
||||
echo ' -a -- start auditor'
|
||||
echo ' -c $CONF -- set configuration'
|
||||
echo ' -e -- start exchange'
|
||||
echo ' -f -- start fakebank'
|
||||
echo ' -h -- print this help'
|
||||
echo ' -l $LOGLEVEL -- set log level'
|
||||
echo ' -m -- start merchant'
|
||||
echo ' -n -- start nexus'
|
||||
echo ' -s -- start sandbox'
|
||||
exit 0
|
||||
;;
|
||||
l)
|
||||
LOGLEVEL="$OPTARG"
|
||||
;;
|
||||
@ -87,6 +100,9 @@ while getopts ':abc:efl:ms' OPTION; do
|
||||
esac
|
||||
done
|
||||
|
||||
echo "Starting with configuration file at: $CONF_ORIG"
|
||||
CONF="$CONF_ORIG.edited"
|
||||
cp "${CONF_ORIG}" "${CONF}"
|
||||
|
||||
echo -n "Testing for jq"
|
||||
jq -h > /dev/null || exit_skip " jq required"
|
||||
@ -114,7 +130,7 @@ then
|
||||
fi
|
||||
|
||||
EXCHANGE_URL=$(taler-config -c "$CONF" -s "EXCHANGE" -o "BASE_URL")
|
||||
|
||||
CURRENCY=$(taler-config -c "$CONF" -s "TALER" -o "CURRENCY")
|
||||
|
||||
register_sandbox_account() {
|
||||
export LIBEUFIN_SANDBOX_USERNAME="$1"
|
||||
@ -142,7 +158,6 @@ then
|
||||
export LIBEUFIN_SANDBOX_DB_CONNECTION=$(taler-config -c "$CONF" -s "libeufin-sandbox" -o "DB_CONNECTION")
|
||||
|
||||
# Create the default demobank.
|
||||
CURRENCY=$(taler-config -c "$CONF" -s "EXCHANGE" -o "CURRENCY")
|
||||
libeufin-sandbox config --currency "$CURRENCY" default
|
||||
export LIBEUFIN_SANDBOX_ADMIN_PASSWORD="secret"
|
||||
libeufin-sandbox serve \
|
||||
@ -152,6 +167,7 @@ then
|
||||
echo $! > libeufin-sandbox.pid
|
||||
export LIBEUFIN_SANDBOX_URL="http://localhost:$SANDBOX_PORT/"
|
||||
set +e
|
||||
OK="0"
|
||||
echo -n "Waiting for Sandbox ..."
|
||||
for n in $(seq 1 100); do
|
||||
echo -n "."
|
||||
@ -163,9 +179,14 @@ then
|
||||
-O /dev/null \
|
||||
"$LIBEUFIN_SANDBOX_URL";
|
||||
then
|
||||
OK="1"
|
||||
break
|
||||
fi
|
||||
done
|
||||
if [ "1" != "$OK" ]
|
||||
then
|
||||
exit_skip "Failed to launch services (sandbox)"
|
||||
fi
|
||||
echo "OK"
|
||||
set -e
|
||||
echo -n "Register Sandbox users ..."
|
||||
@ -228,6 +249,7 @@ then
|
||||
export LIBEUFIN_NEXUS_URL="http://localhost:$NEXUS_PORT"
|
||||
echo -n "Waiting for Nexus ..."
|
||||
set +e
|
||||
OK="0"
|
||||
for n in $(seq 1 100); do
|
||||
echo -n "."
|
||||
sleep 0.2
|
||||
@ -238,9 +260,14 @@ then
|
||||
-O /dev/null \
|
||||
"$LIBEUFIN_NEXUS_URL";
|
||||
then
|
||||
OK="1"
|
||||
break
|
||||
fi
|
||||
done
|
||||
if [ "1" != "$OK" ]
|
||||
then
|
||||
exit_skip "Failed to launch services (bank)"
|
||||
fi
|
||||
set -e
|
||||
echo " OK"
|
||||
|
||||
@ -315,7 +342,7 @@ then
|
||||
MPUB=$(taler-config -c "$CONF" -s exchange -o MASTER_PUBLIC_KEY)
|
||||
if [ "$MPUB" != "$MASTER_PUB" ]
|
||||
then
|
||||
echo -n " patching master_pub ... "
|
||||
echo -n " patching master_pub ($MASTER_PUB)..."
|
||||
taler-config -c $CONF -s exchange -o MASTER_PUBLIC_KEY -V "$MASTER_PUB"
|
||||
fi
|
||||
taler-exchange-dbinit -c "$CONF"
|
||||
@ -355,15 +382,15 @@ then
|
||||
echo " DONE"
|
||||
fi
|
||||
|
||||
if ["1" = "$START_NEXUS" || "1" = "$START_FAKEBANK"]
|
||||
if [[ "1" = "$START_NEXUS" || "1" = "$START_FAKEBANK" ]]
|
||||
then
|
||||
echo -n "Waiting for the bank"
|
||||
# Wait for bank to be available (usually the slowest)
|
||||
OK="0"
|
||||
for n in $(seq 1 300)
|
||||
do
|
||||
echo -n "."
|
||||
sleep 0.1
|
||||
OK=0
|
||||
# bank
|
||||
wget --tries=1 \
|
||||
--waitretry=0 \
|
||||
@ -373,17 +400,17 @@ then
|
||||
"http://localhost:8082/" \
|
||||
-o /dev/null \
|
||||
-O /dev/null >/dev/null || continue
|
||||
OK=1
|
||||
OK="1"
|
||||
break
|
||||
done
|
||||
if [ 1 != $OK ]
|
||||
if [ "1" != "$OK" ]
|
||||
then
|
||||
exit_skip "Failed to launch services (bank)"
|
||||
fi
|
||||
echo " OK"
|
||||
fi
|
||||
|
||||
echo -n "Waiting for Taler services "
|
||||
echo -n "Waiting for Taler services ..."
|
||||
# Wait for all other taler services to be available
|
||||
for n in $(seq 1 20)
|
||||
do
|
||||
@ -392,15 +419,30 @@ do
|
||||
OK="0"
|
||||
if [ "1" = "$START_EXCHANGE" ]
|
||||
then
|
||||
wget --tries=1 --timeout=1 http://localhost:8081/seed -o /dev/null -O /dev/null >/dev/null || continue
|
||||
wget \
|
||||
--tries=1 \
|
||||
--timeout=1 \
|
||||
"http://localhost:8081/seed" \
|
||||
-o /dev/null \
|
||||
-O /dev/null >/dev/null || continue
|
||||
fi
|
||||
if [ "1" = "$START_MERCHANT" ]
|
||||
then
|
||||
wget --tries=1 --timeout=1 http://localhost:9966/ -o /dev/null -O /dev/null >/dev/null || continue
|
||||
wget \
|
||||
--tries=1 \
|
||||
--timeout=1 \
|
||||
"http://localhost:9966/" \
|
||||
-o /dev/null \
|
||||
-O /dev/null >/dev/null || continue
|
||||
fi
|
||||
if [ "1" = "$START_AUDITOR" ]
|
||||
then
|
||||
wget --tries=1 --timeout=1 http://localhost:8083/ -o /dev/null -O /dev/null >/dev/null || continue
|
||||
wget \
|
||||
--tries=1 \
|
||||
--timeout=1 \
|
||||
"http://localhost:8083/" \
|
||||
-o /dev/null \
|
||||
-O /dev/null >/dev/null || continue
|
||||
fi
|
||||
OK="1"
|
||||
break
|
||||
@ -414,35 +456,42 @@ echo "OK"
|
||||
if [ "1" = "$START_EXCHANGE" ]
|
||||
then
|
||||
set +e
|
||||
echo -n "Wait exchange /management/keys to be ready "
|
||||
echo -n "Wait for exchange /management/keys to be ready "
|
||||
OK="0"
|
||||
LAST_RESPONSE=$(mktemp tmp-last-response.XXXXXXXX)
|
||||
for n in $(seq 1 50)
|
||||
do
|
||||
echo -n "."
|
||||
sleep 0.1
|
||||
OK=0
|
||||
# exchange
|
||||
wget --tries=3 --waitretry=0 --timeout=1 http://localhost:8081/management/keys -o /dev/null -O $LAST_RESPONSE >/dev/null
|
||||
wget \
|
||||
--tries=3 \
|
||||
--waitretry=0 \
|
||||
--timeout=1 \
|
||||
"http://localhost:8081/management/keys"\
|
||||
-o /dev/null \
|
||||
-O "$LAST_RESPONSE" \
|
||||
>/dev/null
|
||||
DENOMS_COUNT=$(jq '.future_denoms|length' < $LAST_RESPONSE)
|
||||
SIGNKEYS_COUNT=$(jq '.future_signkeys|length' < $LAST_RESPONSE)
|
||||
[[ -z "$SIGNKEYS_COUNT" || "$SIGNKEYS_COUNT" == "0" || -z "$DENOMS_COUNT" || "$DENOMS_COUNT" == "0" ]] && continue
|
||||
OK=1
|
||||
OK="1"
|
||||
break;
|
||||
done
|
||||
set -e
|
||||
if [ 1 != $OK ]
|
||||
if [ "1" != "$OK" ]
|
||||
then
|
||||
exit_skip "Failed to setup exchange keys, check secmod logs"
|
||||
fi
|
||||
rm "$LAST_RESPONSE"
|
||||
echo " OK"
|
||||
|
||||
echo -n "Setting up exchange keys ..."
|
||||
taler-exchange-offline -c "$CONF" \
|
||||
download \
|
||||
sign \
|
||||
enable-account "$EXCHANGE_PAYTO_URI" \
|
||||
enable-auditor $AUDITOR_PUB $AUDITOR_URL "TESTKUDOS Auditor" \
|
||||
wire-fee now iban TESTKUDOS:0.01 TESTKUDOS:0.01 \
|
||||
global-fee now TESTKUDOS:0.01 TESTKUDOS:0.01 TESTKUDOS:0.01 1h 1year 5 \
|
||||
wire-fee now iban "$CURRENCY:0.01" "$CURRENCY:0.01" \
|
||||
global-fee now "$CURRENCY:0.01" "$CURRENCY:0.01" "$CURRENCY:0.01" 1h 1year 5 \
|
||||
upload &> taler-exchange-offline.log
|
||||
echo "OK"
|
||||
for ASEC in $(taler-config -c "$CONF" -S | grep -i "exchange-account-")
|
||||
@ -450,7 +499,7 @@ then
|
||||
ENABLED=$(taler-config -c "$CONF" -s "$ASEC" -o "ENABLE_CREDIT")
|
||||
if [ "YES" = "$ENABLED" ]
|
||||
then
|
||||
echo -n "Configuring bank account $ASEC"
|
||||
echo -n "Configuring bank account $ASEC ..."
|
||||
EXCHANGE_PAYTO_URI=$(taler-config -c "$CONF" -s "$ASEC" -o "PAYTO_URI")
|
||||
taler-exchange-offline -c "$CONF" \
|
||||
enable-account "$EXCHANGE_PAYTO_URI" \
|
||||
@ -462,23 +511,26 @@ then
|
||||
then
|
||||
echo -n "Enabling auditor ..."
|
||||
taler-exchange-offline -c "$CONF" \
|
||||
enable-auditor $AUDITOR_PUB $AUDITOR_URL "TESTKUDOS Auditor" \
|
||||
enable-auditor $AUDITOR_PUB $AUDITOR_URL "$CURRENCY Auditor" \
|
||||
upload &> taler-exchange-offline-auditor.log
|
||||
echo "OK"
|
||||
fi
|
||||
|
||||
echo -n "Checking /keys "
|
||||
OK="0"
|
||||
for n in $(seq 1 3)
|
||||
do
|
||||
echo -n "."
|
||||
OK=0
|
||||
wget --tries=1 --timeout=1 \
|
||||
http://localhost:8081/keys \
|
||||
-o /dev/null -O /dev/null >/dev/null || continue
|
||||
OK=1
|
||||
wget \
|
||||
--tries=1 \
|
||||
--timeout=1 \
|
||||
"http://localhost:8081/keys" \
|
||||
-o /dev/null \
|
||||
-O /dev/null >/dev/null || continue
|
||||
OK="1"
|
||||
break
|
||||
done
|
||||
if [ 1 != $OK ]
|
||||
if [ "1" != "$OK" ]
|
||||
then
|
||||
exit_skip " Failed to setup keys"
|
||||
fi
|
||||
|
@ -17,13 +17,13 @@ TALER_HOME = ${TALER_TEST_HOME:-${HOME:-${USERPROFILE}}}
|
||||
# for how these should be used.
|
||||
|
||||
# Persistent data storage
|
||||
TALER_DATA_HOME = ${XDG_DATA_HOME:-$TALER_HOME/.local/share}/taler/
|
||||
TALER_DATA_HOME = ${TALER_TEST_HOME:-${XDG_DATA_HOME:-${TALER_HOME}/.local/share/}/.local/share/}taler/
|
||||
|
||||
# Configuration files
|
||||
TALER_CONFIG_HOME = ${XDG_CONFIG_HOME:-$TALER_HOME/.config}/taler/
|
||||
TALER_CONFIG_HOME = ${TALER_TEST_HOME:-${XDG_CONFIG_HOME:-${TALER_HOME}/.config/}/.config/}taler/
|
||||
|
||||
# Cached data, no big deal if lost
|
||||
TALER_CACHE_HOME = ${XDG_CACHE_HOME:-$TALER_HOME/.cache}/taler/
|
||||
TALER_CACHE_HOME = ${TALER_TEST_HOME:-${XDG_CACHE_HOME:-${TALER_HOME}/.cache/}/.cache/}taler/
|
||||
|
||||
# Runtime data (always lost on system boot)
|
||||
TALER_RUNTIME_DIR = ${TMPDIR:-${TMP:-/tmp}}/taler-system-runtime/
|
||||
|
Loading…
Reference in New Issue
Block a user