gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-exchange] branch master updated: config syntax for accounts


From: gnunet
Subject: [taler-exchange] branch master updated: config syntax for accounts
Date: Sun, 19 Jan 2020 18:48:26 +0100

This is an automated email from the git hooks/post-receive script.

dold pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new 60747908 config syntax for accounts
60747908 is described below

commit 6074790867eb187f4c4de96cb6266fa541dc18ae
Author: Florian Dold <address@hidden>
AuthorDate: Sun Jan 19 18:48:14 2020 +0100

    config syntax for accounts
---
 src/auditor/generate-auditor-basedb.conf                 |  4 ++--
 src/auditor/test-auditor.conf                            |  2 +-
 src/benchmark/benchmark.conf                             |  2 +-
 src/benchmark/taler-exchange-benchmark.c                 |  4 ++--
 src/exchange/test_taler_exchange_httpd.conf              |  4 ++--
 src/exchangedb/exchangedb_accounts.c                     |  7 ++-----
 src/exchangedb/test_exchangedb.c                         | 12 ++++++------
 src/include/taler_exchangedb_lib.h                       |  2 +-
 src/testing/test-taler-exchange-aggregator-postgres.conf |  2 +-
 src/testing/test-taler-exchange-wirewatch-postgres.conf  |  2 +-
 src/testing/test_auditor_api.c                           |  2 +-
 src/testing/test_auditor_api.conf                        |  6 +++---
 src/testing/test_bank_api.c                              |  4 ++--
 src/testing/test_bank_api_fakebank.conf                  |  2 +-
 src/testing/test_bank_api_fakebank_twisted.conf          |  4 ++--
 src/testing/test_bank_api_pybank.conf                    |  2 +-
 src/testing/test_bank_api_pybank_twisted.conf            |  4 ++--
 src/testing/test_bank_api_twisted.c                      |  4 ++--
 src/testing/test_exchange_api.c                          |  2 +-
 src/testing/test_exchange_api.conf                       |  6 +++---
 src/testing/test_exchange_api_keys_cherry_picking.conf   |  4 ++--
 src/testing/test_exchange_api_revocation.c               |  2 +-
 src/testing/test_exchange_api_twisted.c                  |  2 +-
 src/testing/test_exchange_api_twisted.conf               |  4 ++--
 src/testing/test_taler_exchange_aggregator.c             |  2 +-
 src/testing/test_taler_exchange_wirewatch.c              |  2 +-
 26 files changed, 45 insertions(+), 48 deletions(-)

diff --git a/src/auditor/generate-auditor-basedb.conf 
b/src/auditor/generate-auditor-basedb.conf
index 40e5d132..02ed14b7 100644
--- a/src/auditor/generate-auditor-basedb.conf
+++ b/src/auditor/generate-auditor-basedb.conf
@@ -77,7 +77,7 @@ lookahead_provide = 4 weeks 1 day
 [taler]
 CURRENCY = TESTKUDOS
 
-[account-1]
+[exchange-account-1]
 WIRE_RESPONSE = ${TALER_DATA_HOME}/exchange/account-1.json
 PAYTO_URI = payto://x-taler-bank/localhost/Exchange
 METHOD = x-taler-bank
@@ -88,7 +88,7 @@ WIRE_GATEWAY_AUTH_METHOD = basic
 USERNAME = Exchange
 PASSWORD = x
 
-[account-merchant]
+[merchant-account-merchant]
 PAYTO_URI = payto://x-taler-bank/localhost/42
 WIRE_RESPONSE = ${TALER_CONFIG_HOME}/merchant/account-3.json
 METHOD = x-taler-bank
diff --git a/src/auditor/test-auditor.conf b/src/auditor/test-auditor.conf
index fa38bfa6..a76c9187 100644
--- a/src/auditor/test-auditor.conf
+++ b/src/auditor/test-auditor.conf
@@ -2,7 +2,7 @@
 DB = postgres
 TINY_AMOUNT = TESTKUDOS:0.01
 
-[account-1]
+[exchange-account-1]
 WIRE_RESPONSE = ${TALER_DATA_HOME}/exchange/account-1.json
 PAYTO_URI = payto://x-taler-bank/localhost/Exchange
 METHOD = x-taler-bank
diff --git a/src/benchmark/benchmark.conf b/src/benchmark/benchmark.conf
index 1ce943ce..f59d995c 100644
--- a/src/benchmark/benchmark.conf
+++ b/src/benchmark/benchmark.conf
@@ -43,7 +43,7 @@ dir = $HOME/repos/taler/exchange/src/benchmark
 [benchmark]
 USER_PAYTO_URI = payto://x-taler-bank/localhost:8082/42
 
-[account-2]
+[exchange-account-2]
 # What is the payto://-URL of the exchange (to generate wire response)
 PAYTO_URI = "payto://x-taler-bank/localhost:8082/2"
 # What is the bank account (with the "Taler Bank" demo system)? Must end with 
"/".
diff --git a/src/benchmark/taler-exchange-benchmark.c 
b/src/benchmark/taler-exchange-benchmark.c
index 9aa9c2da..38ba810f 100644
--- a/src/benchmark/taler-exchange-benchmark.c
+++ b/src/benchmark/taler-exchange-benchmark.c
@@ -205,9 +205,9 @@ static void
 pick_exchange_account_cb (void *cls,
                           const char *section)
 {
-  if (0 == strncasecmp ("account-",
+  if (0 == strncasecmp ("exchange-account-",
                         section,
-                        strlen ("account-")))
+                        strlen ("exchange-account-")))
   {
     const char **s = cls;
 
diff --git a/src/exchange/test_taler_exchange_httpd.conf 
b/src/exchange/test_taler_exchange_httpd.conf
index 954f24c6..7a233f12 100644
--- a/src/exchange/test_taler_exchange_httpd.conf
+++ b/src/exchange/test_taler_exchange_httpd.conf
@@ -46,7 +46,7 @@ IDLE_RESERVE_EXPIRATION_TIME = 4 weeks
 [exchangedb-postgres]
 CONFIG = "postgres:///talercheck"
 
-[account-1]
+[exchange-account-1]
 PAYTO_URI = "payto://x-taler-bank/localhost:8082/3"
 WIRE_RESPONSE = ${TALER_CONFIG_HOME}/account-1.json
 METHOD = "x-taler-bank"
@@ -55,7 +55,7 @@ ENABLE_CREDIT = YES
 TALER_BANK_AUTH_METHOD = NONE
 
 
-# Wire fees are specified by wire method, NOT by wire plugin.
+# Wire fees are specified by wire method
 [fees-x-taler-bank]
 # Fees for the forseeable future...
 # If you see this after 2018, update to match the next 10 years...
diff --git a/src/exchangedb/exchangedb_accounts.c 
b/src/exchangedb/exchangedb_accounts.c
index fa45fd81..fd8ed538 100644
--- a/src/exchangedb/exchangedb_accounts.c
+++ b/src/exchangedb/exchangedb_accounts.c
@@ -50,9 +50,6 @@ struct FindAccountContext
  * true, call the callback from the context with the
  * rest of the section name.
  *
- * FIXME(dold): This comment is inaccurate!  Also, why
- * is the prefix "account-" and not "exchange-account-"?
- *
  * @param cls our `struct FindEnabledWireContext`
  * @param section name of a section in the configuration
  */
@@ -67,8 +64,8 @@ check_for_account (void *cls,
   struct TALER_EXCHANGEDB_AccountInfo ai;
 
   if (0 != strncasecmp (section,
-                        "account-",
-                        strlen ("account-")))
+                        "exchange-account-",
+                        strlen ("exchange-account-")))
     return;
   if (GNUNET_OK !=
       GNUNET_CONFIGURATION_get_value_string (ctx->cfg,
diff --git a/src/exchangedb/test_exchangedb.c b/src/exchangedb/test_exchangedb.c
index 2a3ab0cb..2f984e93 100644
--- a/src/exchangedb/test_exchangedb.c
+++ b/src/exchangedb/test_exchangedb.c
@@ -1533,7 +1533,7 @@ run (void *cls)
   FAILIF (GNUNET_DB_STATUS_SUCCESS_NO_RESULTS !=
           plugin->get_latest_reserve_in_reference (plugin->cls,
                                                    session,
-                                                   "account-1",
+                                                   "exchange-account-1",
                                                    &rr));
   now = GNUNET_TIME_absolute_get ();
   (void) GNUNET_TIME_round_abs (&now);
@@ -1544,12 +1544,12 @@ run (void *cls)
                                       &value,
                                       now,
                                       sndr,
-                                      "account-1",
+                                      "exchange-account-1",
                                       4));
   FAILIF (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT !=
           plugin->get_latest_reserve_in_reference (plugin->cls,
                                                    session,
-                                                   "account-1",
+                                                   "exchange-account-1",
                                                    &rr));
   FAILIF (4 != rr);
   FAILIF (GNUNET_OK !=
@@ -1567,17 +1567,17 @@ run (void *cls)
                                       &value,
                                       now,
                                       sndr,
-                                      "account-1",
+                                      "exchange-account-1",
                                       5));
   FAILIF (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT !=
           plugin->get_latest_reserve_in_reference (plugin->cls,
                                                    session,
-                                                   "account-1",
+                                                   "exchange-account-1",
                                                    &rr));
   FAILIF (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT !=
           plugin->get_latest_reserve_in_reference (plugin->cls,
                                                    session,
-                                                   "account-1",
+                                                   "exchange-account-1",
                                                    &rr));
   FAILIF (5 != rr);
   FAILIF (GNUNET_OK !=
diff --git a/src/include/taler_exchangedb_lib.h 
b/src/include/taler_exchangedb_lib.h
index 655527b3..a167be33 100644
--- a/src/include/taler_exchangedb_lib.h
+++ b/src/include/taler_exchangedb_lib.h
@@ -389,7 +389,7 @@ struct TALER_EXCHANGEDB_AccountInfo
 {
   /**
    * Section in the configuration file that specifies the
-   * account. Must start with "account-".
+   * account. Must start with "exchange-account-".
    */
   const char *section_name;
 
diff --git a/src/testing/test-taler-exchange-aggregator-postgres.conf 
b/src/testing/test-taler-exchange-aggregator-postgres.conf
index dab0f74a..6f5f9d83 100644
--- a/src/testing/test-taler-exchange-aggregator-postgres.conf
+++ b/src/testing/test-taler-exchange-aggregator-postgres.conf
@@ -54,7 +54,7 @@ IDLE_RESERVE_EXPIRATION_TIME = 4 weeks
 # the legal expiration timeframe of withdrawn coins.
 LEGAL_RESERVE_EXPIRATION_TIME = 7 years
 
-[account-1]
+[exchange-account-1]
 
 # What is the account URL?
 PAYTO_URI = "payto://x-taler-bank/localhost/2"
diff --git a/src/testing/test-taler-exchange-wirewatch-postgres.conf 
b/src/testing/test-taler-exchange-wirewatch-postgres.conf
index 740fbe87..19db0e0b 100644
--- a/src/testing/test-taler-exchange-wirewatch-postgres.conf
+++ b/src/testing/test-taler-exchange-wirewatch-postgres.conf
@@ -43,7 +43,7 @@ BASE_URL = "http://localhost:8083/";
 # HTTP port the auditor listens to
 PORT = 8083
 
-[account-1]
+[exchange-account-1]
 
 # What is the account URL?
 PAYTO_URI = "payto://x-taler-bank/localhost/2"
diff --git a/src/testing/test_auditor_api.c b/src/testing/test_auditor_api.c
index 92236102..144f004d 100644
--- a/src/testing/test_auditor_api.c
+++ b/src/testing/test_auditor_api.c
@@ -673,7 +673,7 @@ main (int argc,
   /* Check fakebank port is available and get configuration data. */
   if (GNUNET_OK !=
       TALER_TESTING_prepare_fakebank (CONFIG_FILE,
-                                      "account-2",
+                                      "exchange-account-2",
                                       &bc))
     return 77;
   TALER_TESTING_cleanup_files (CONFIG_FILE);
diff --git a/src/testing/test_auditor_api.conf 
b/src/testing/test_auditor_api.conf
index dab354cd..9a480490 100644
--- a/src/testing/test_auditor_api.conf
+++ b/src/testing/test_auditor_api.conf
@@ -51,13 +51,13 @@ CONFIG = "postgres:///talercheck"
 [auditordb-postgres]
 CONFIG = "postgres:///talercheck"
 
-# Sections starting with "account-" configure the bank accounts
+# Sections starting with "exchange-account-" configure the bank accounts
 # of the exchange.  The "URL" specifies the account in
 # payto://-format, while the WIRE_JSON specifies the
 # (possibly offline) signed version to be returned in /wire.
 # WIRE_JSON is optional, as not all accounts must be
 # advertised in /wire.
-[account-1]
+[exchange-account-1]
 # What is the URL of our account?
 PAYTO_URI = "payto://x-taler-bank/localhost/42"
 WIRE_GATEWAY_URL = "http://localhost:8082/42/";
@@ -73,7 +73,7 @@ HTTP_PORT = 8082
 
 # ENABLE_CREDIT = YES
 
-[account-2]
+[exchange-account-2]
 # What is the bank account (with the "Taler Bank" demo system)?
 WIRE_GATEWAY_URL = "http://localhost:8082/2/";
 PAYTO_URI = "payto://x-taler-bank/localhost/2"
diff --git a/src/testing/test_bank_api.c b/src/testing/test_bank_api.c
index e7d2aefa..bdafdc5f 100644
--- a/src/testing/test_bank_api.c
+++ b/src/testing/test_bank_api.c
@@ -137,7 +137,7 @@ main (int argc,
     cfgfilename = CONFIG_FILE_FAKEBANK;
     if (GNUNET_OK !=
         TALER_TESTING_prepare_fakebank (CONFIG_FILE_FAKEBANK,
-                                        "account-2",
+                                        "exchange-account-2",
                                         &bc))
     {
       GNUNET_break (0);
@@ -150,7 +150,7 @@ main (int argc,
     cfgfilename = CONFIG_FILE_PYBANK;
     if (GNUNET_OK !=
         TALER_TESTING_prepare_bank (CONFIG_FILE_PYBANK,
-                                    "account-2",
+                                    "exchange-account-2",
                                     &bc))
     {
       GNUNET_break (0);
diff --git a/src/testing/test_bank_api_fakebank.conf 
b/src/testing/test_bank_api_fakebank.conf
index f3325986..3d448ec5 100644
--- a/src/testing/test_bank_api_fakebank.conf
+++ b/src/testing/test_bank_api_fakebank.conf
@@ -3,7 +3,7 @@
 [taler]
 currency = KUDOS
 
-[account-2]
+[exchange-account-2]
 PAYTO_URI = payto://x-taler-bank/localhost/2
 METHOD = x-taler-bank
 WIRE_GATEWAY_URL = "http://localhost:8081/2/";
diff --git a/src/testing/test_bank_api_fakebank_twisted.conf 
b/src/testing/test_bank_api_fakebank_twisted.conf
index 3b7b4961..72ab867b 100644
--- a/src/testing/test_bank_api_fakebank_twisted.conf
+++ b/src/testing/test_bank_api_fakebank_twisted.conf
@@ -27,8 +27,8 @@ serve = http
 http_port = 8081
 database = postgres:///talercheck
 
-[account-1]
+[exchange-account-1]
 PAYTO_URI = payto://x-taler-bank/localhost:8081/1
 
-[account-2]
+[exchange-account-2]
 PAYTO_URI = payto://x-taler-bank/localhost:8081/2
diff --git a/src/testing/test_bank_api_pybank.conf 
b/src/testing/test_bank_api_pybank.conf
index 0e1036da..9070e31e 100644
--- a/src/testing/test_bank_api_pybank.conf
+++ b/src/testing/test_bank_api_pybank.conf
@@ -3,7 +3,7 @@
 [taler]
 currency = KUDOS
 
-[account-2]
+[exchange-account-2]
 PAYTO_URI = payto://x-taler-bank/localhost/Exchange
 METHOD = x-taler-bank
 WIRE_GATEWAY_URL = "http://localhost:8081/taler-wire-gateway/Exchange/";
diff --git a/src/testing/test_bank_api_pybank_twisted.conf 
b/src/testing/test_bank_api_pybank_twisted.conf
index e5408674..3801590b 100644
--- a/src/testing/test_bank_api_pybank_twisted.conf
+++ b/src/testing/test_bank_api_pybank_twisted.conf
@@ -29,11 +29,11 @@ http_port = 8081
 database = postgres:///talercheck
 
 
-[account-1]
+[exchange-account-1]
 PAYTO_URI = payto://x-taler-bank/localhost/1
 
 
-[account-2]
+[exchange-account-2]
 PAYTO_URI = payto://x-taler-bank/localhost/Exchange
 METHOD = x-taler-bank
 WIRE_GATEWAY_URL = "http://localhost:8888/taler-wire-gateway/Exchange/";
diff --git a/src/testing/test_bank_api_twisted.c 
b/src/testing/test_bank_api_twisted.c
index 49028946..4ec4a1b9 100644
--- a/src/testing/test_bank_api_twisted.c
+++ b/src/testing/test_bank_api_twisted.c
@@ -164,7 +164,7 @@ main (int argc,
     TALER_LOG_DEBUG ("Running against the Fakebank.\n");
     if (GNUNET_OK !=
         TALER_TESTING_prepare_fakebank (cfgfilename,
-                                        "account-2",
+                                        "exchange-account-2",
                                         &bc))
     {
       GNUNET_break (0);
@@ -177,7 +177,7 @@ main (int argc,
     TALER_LOG_DEBUG ("Running against the Pybank.\n");
     if (GNUNET_OK !=
         TALER_TESTING_prepare_bank (cfgfilename,
-                                    "account-2",
+                                    "exchange-account-2",
                                     &bc))
     {
       GNUNET_break (0);
diff --git a/src/testing/test_exchange_api.c b/src/testing/test_exchange_api.c
index 84d5dc9b..38d0c921 100644
--- a/src/testing/test_exchange_api.c
+++ b/src/testing/test_exchange_api.c
@@ -795,7 +795,7 @@ main (int argc,
   /* Check fakebank port is available and get config */
   if (GNUNET_OK !=
       TALER_TESTING_prepare_fakebank (CONFIG_FILE,
-                                      "account-2",
+                                      "exchange-account-2",
                                       &bc))
     return 77;
   TALER_TESTING_cleanup_files (CONFIG_FILE);
diff --git a/src/testing/test_exchange_api.conf 
b/src/testing/test_exchange_api.conf
index 028f1d7e..ed74d89e 100644
--- a/src/testing/test_exchange_api.conf
+++ b/src/testing/test_exchange_api.conf
@@ -52,13 +52,13 @@ CONFIG = "postgres:///talercheck"
 [auditordb-postgres]
 CONFIG = "postgres:///talercheck"
 
-# Sections starting with "account-" configure the bank accounts
+# Sections starting with "exchange-account-" configure the bank accounts
 # of the exchange.  The "URL" specifies the account in
 # payto://-format, while the WIRE_JSON specifies the
 # (possibly offline) signed version to be returned in /wire.
 # WIRE_JSON is optional, as not all accounts must be
 # advertised in /wire.
-[account-1]
+[exchange-account-1]
 # What is the URL of our account?
 PAYTO_URI = "payto://x-taler-bank/localhost/42"
 # This is the response we give out for the /wire request.  It provides
@@ -72,7 +72,7 @@ WIRE_GATEWAY_URL = "http://localhost:9081/42/";
 # ENABLE_CREDIT = YES
 
 
-[account-2]
+[exchange-account-2]
 # What is the bank account (with the "Taler Bank" demo system)?
 PAYTO_URI = "payto://x-taler-bank/localhost/2"
 
diff --git a/src/testing/test_exchange_api_keys_cherry_picking.conf 
b/src/testing/test_exchange_api_keys_cherry_picking.conf
index ea516168..6823e81d 100644
--- a/src/testing/test_exchange_api_keys_cherry_picking.conf
+++ b/src/testing/test_exchange_api_keys_cherry_picking.conf
@@ -65,7 +65,7 @@ CONFIG = "postgres:///talercheck"
 CONFIG = "postgres:///talercheck"
 
 
-[account-1]
+[exchange-account-1]
 # This is the response we give out for the /wire request.  It provides
 # wallets with the bank information for transfers to the exchange.
 WIRE_RESPONSE = ${TALER_CONFIG_HOME}/iban.json
@@ -78,7 +78,7 @@ METHOD = "x-taler-bank"
 WIRE_GATEWAY_URL = "http://localhost:9082/42/";
 
 
-[account-2]
+[exchange-account-2]
 # This is the response we give out for the /wire request.  It provides
 # wallets with the bank information for transfers to the exchange.
 WIRE_RESPONSE = ${TALER_CONFIG_HOME}/x-taler-bank.json
diff --git a/src/testing/test_exchange_api_revocation.c 
b/src/testing/test_exchange_api_revocation.c
index 110dec16..45463ded 100644
--- a/src/testing/test_exchange_api_revocation.c
+++ b/src/testing/test_exchange_api_revocation.c
@@ -194,7 +194,7 @@ main (int argc,
   /* Check fakebank port is available and get config */
   if (GNUNET_OK !=
       TALER_TESTING_prepare_fakebank (CONFIG_FILE,
-                                      "account-2",
+                                      "exchange-account-2",
                                       &bc))
     return 77;
   TALER_TESTING_cleanup_files (CONFIG_FILE);
diff --git a/src/testing/test_exchange_api_twisted.c 
b/src/testing/test_exchange_api_twisted.c
index 3b95e151..46807e9c 100644
--- a/src/testing/test_exchange_api_twisted.c
+++ b/src/testing/test_exchange_api_twisted.c
@@ -288,7 +288,7 @@ main (int argc,
 
   if (GNUNET_OK !=
       TALER_TESTING_prepare_fakebank (CONFIG_FILE,
-                                      "account-2",
+                                      "exchange-account-2",
                                       &bc))
     return 77;
 
diff --git a/src/testing/test_exchange_api_twisted.conf 
b/src/testing/test_exchange_api_twisted.conf
index b09f8aa5..5158aefe 100644
--- a/src/testing/test_exchange_api_twisted.conf
+++ b/src/testing/test_exchange_api_twisted.conf
@@ -56,7 +56,7 @@ PORT = 8083
 [auditordb-postgres]
 CONFIG = "postgres:///talercheck"
 
-[account-1]
+[exchange-account-1]
 # What is the URL of our account?
 PAYTO_URI = "payto://x-taler-bank/localhost/42"
 # This is the response we give out for the /wire request.  It provides
@@ -68,7 +68,7 @@ WIRE_GATEWAY_URL = "http://localhost:9081/42/";
 WIRE_GATEWAY_AUTH_METHOD = NONE
 
 
-[account-2]
+[exchange-account-2]
 PAYTO_URI = payto://x-taler-bank/localhost/2
 WIRE_GATEWAY_URL = "http://localhost:8082/2/";
 WIRE_RESPONSE = ${TALER_CONFIG_HOME}/account-2.json
diff --git a/src/testing/test_taler_exchange_aggregator.c 
b/src/testing/test_taler_exchange_aggregator.c
index 84695ca0..c709e5fe 100644
--- a/src/testing/test_taler_exchange_aggregator.c
+++ b/src/testing/test_taler_exchange_aggregator.c
@@ -492,7 +492,7 @@ main (int argc,
   }
 
   if (GNUNET_OK != TALER_TESTING_prepare_fakebank (config_filename,
-                                                   "account-1",
+                                                   "exchange-account-1",
                                                    &bc))
   {
     TALER_LOG_WARNING ("Could not prepare the fakebank\n");
diff --git a/src/testing/test_taler_exchange_wirewatch.c 
b/src/testing/test_taler_exchange_wirewatch.c
index 5a202bef..ab3246b7 100644
--- a/src/testing/test_taler_exchange_wirewatch.c
+++ b/src/testing/test_taler_exchange_wirewatch.c
@@ -168,7 +168,7 @@ main (int argc,
 
   if (GNUNET_OK !=
       TALER_TESTING_prepare_fakebank (config_filename,
-                                      "account-1",
+                                      "exchange-account-1",
                                       &bc))
     return 77;
 

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]