gnunet-svn
[Top][All Lists]
Advanced

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

[exchange] branch master updated: robocop sanction list entries do not c


From: Admin
Subject: [exchange] branch master updated: robocop sanction list entries do not come with expiration time (work on #9053)
Date: Sun, 08 Jun 2025 11:00:25 +0200

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

grothoff pushed a commit to branch master
in repository exchange.

The following commit(s) were added to refs/heads/master by this push:
     new 581c632da robocop sanction list entries do not come with expiration 
time (work on #9053)
581c632da is described below

commit 581c632dabab6f59142e17d26133c2eef4c6c50f
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Sun Jun 8 11:00:10 2025 +0200

    robocop sanction list entries do not come with expiration time (work on 
#9053)
---
 src/exchange/taler-exchange-sanctionscheck.c |  3 ---
 src/exchangedb/pg_insert_sanction_list_hit.c |  5 +++--
 src/exchangedb/pg_insert_sanction_list_hit.h |  2 --
 src/include/taler_exchangedb_plugin.h        |  2 --
 src/include/taler_kyclogic_lib.h             |  2 --
 src/kyclogic/kyclogic_sanctions.c            | 10 ++--------
 6 files changed, 5 insertions(+), 19 deletions(-)

diff --git a/src/exchange/taler-exchange-sanctionscheck.c 
b/src/exchange/taler-exchange-sanctionscheck.c
index 22fb8674f..2a7bdeaca 100644
--- a/src/exchange/taler-exchange-sanctionscheck.c
+++ b/src/exchange/taler-exchange-sanctionscheck.c
@@ -270,7 +270,6 @@ begin_transaction (void);
  * @param cls closure
  * @param ec error code, #TALER_EC_NONE on success
  * @param best_match identifies the sanction list entry with the best match
- * @param expires when does the sanction list entry expire
  * @param rating likelihood of the match, from 0 (none) to 1 (perfect)
  * @param confidence confidence in the evaluation, from 0 (none) to 1 (perfect)
  */
@@ -278,7 +277,6 @@ static void
 sanction_cb (void *cls,
              enum TALER_ErrorCode ec,
              const char *best_match,
-             struct GNUNET_TIME_Timestamp expires,
              double rating,
              double confidence)
 {
@@ -330,7 +328,6 @@ sanction_cb (void *cls,
                                               investigate,
                                               new_rules,
                                               properties,
-                                              expires,
                                               1,
                                               events);
     json_decref (properties);
diff --git a/src/exchangedb/pg_insert_sanction_list_hit.c 
b/src/exchangedb/pg_insert_sanction_list_hit.c
index 639b1f3bf..3a59cc3ab 100644
--- a/src/exchangedb/pg_insert_sanction_list_hit.c
+++ b/src/exchangedb/pg_insert_sanction_list_hit.c
@@ -33,11 +33,12 @@ TEH_PG_insert_sanction_list_hit (
   bool to_investigate,
   const json_t *new_rules,
   const json_t *account_properties,
-  struct GNUNET_TIME_Timestamp expiration_time,
   unsigned int num_events,
   const char **events)
 {
   struct PostgresClosure *pg = cls;
+  struct GNUNET_TIME_Timestamp never
+    = GNUNET_TIME_UNIT_FOREVER_TS;
   struct GNUNET_TIME_Timestamp now
     = GNUNET_TIME_timestamp_get ();
   struct TALER_KycCompletedEventP rep = {
@@ -50,7 +51,7 @@ TEH_PG_insert_sanction_list_hit (
   struct GNUNET_PQ_QueryParam params[] = {
     GNUNET_PQ_query_param_auto_from_type (h_payto),
     GNUNET_PQ_query_param_timestamp (&now),
-    GNUNET_PQ_query_param_timestamp (&expiration_time),
+    GNUNET_PQ_query_param_timestamp (&never),
     NULL != account_properties
     ? TALER_PQ_query_param_json (account_properties)
     : GNUNET_PQ_query_param_null (),
diff --git a/src/exchangedb/pg_insert_sanction_list_hit.h 
b/src/exchangedb/pg_insert_sanction_list_hit.h
index 5149034fd..3dc425a74 100644
--- a/src/exchangedb/pg_insert_sanction_list_hit.h
+++ b/src/exchangedb/pg_insert_sanction_list_hit.h
@@ -36,7 +36,6 @@
  * @param new_rules new KYC rules to apply to the account, NULL to preserve
  *        existing rules
  * @param account_properties new account properties
- * @param expiration_time when does the sanction list entry expire?
  * @param num_events length of the @a events array
  * @param events array of KYC events to trigger
  * @return database transaction status
@@ -48,7 +47,6 @@ TEH_PG_insert_sanction_list_hit (
   bool to_investigate,
   const json_t *new_rules,
   const json_t *account_properties,
-  struct GNUNET_TIME_Timestamp expiration_time,
   unsigned int num_events,
   const char **events);
 
diff --git a/src/include/taler_exchangedb_plugin.h 
b/src/include/taler_exchangedb_plugin.h
index 7ff27f60e..622ddd199 100644
--- a/src/include/taler_exchangedb_plugin.h
+++ b/src/include/taler_exchangedb_plugin.h
@@ -7432,7 +7432,6 @@ struct TALER_EXCHANGEDB_Plugin
    * @param new_rules new KYC rules to apply to the account, NULL to preserve
    *        existing rules
    * @param account_properties new account properties
-   * @param expiration_time when does the sanction list entry expire?
    * @param num_events length of the @a events array
    * @param events array of KYC events to trigger
    * @return database transaction status
@@ -7444,7 +7443,6 @@ struct TALER_EXCHANGEDB_Plugin
     bool to_investigate,
     const json_t *new_rules,
     const json_t *account_properties,
-    struct GNUNET_TIME_Timestamp expiration_time,
     unsigned int num_events,
     const char **events);
 
diff --git a/src/include/taler_kyclogic_lib.h b/src/include/taler_kyclogic_lib.h
index 7264e0bd9..a68115573 100644
--- a/src/include/taler_kyclogic_lib.h
+++ b/src/include/taler_kyclogic_lib.h
@@ -1083,7 +1083,6 @@ struct TALER_KYCLOGIC_SanctionRater;
  * @param cls closure
  * @param ec error code, #TALER_EC_NONE on success
  * @param best_match identifies the sanction list entry with the best match
- * @param expiration_time when does the sanction list entry expire
  * @param rating likelihood of the match, from 0 (none) to 1 (perfect)
  * @param confidence confidence in the evaluation, from 0 (none) to 1 (perfect)
  */
@@ -1092,7 +1091,6 @@ typedef void
   void *cls,
   enum TALER_ErrorCode ec,
   const char *best_match,
-  struct GNUNET_TIME_Timestamp expiration_time,
   double rating,
   double confidence);
 
diff --git a/src/kyclogic/kyclogic_sanctions.c 
b/src/kyclogic/kyclogic_sanctions.c
index ccded2df4..3ce169076 100644
--- a/src/kyclogic/kyclogic_sanctions.c
+++ b/src/kyclogic/kyclogic_sanctions.c
@@ -165,7 +165,6 @@ fail_hard (struct TALER_KYCLOGIC_SanctionRater *sr)
     ee->cb (ee->cb_cls,
             TALER_EC_EXCHANGE_GENERIC_KYC_SANCTION_LIST_CHECK_FAILED,
             NULL,
-            GNUNET_TIME_UNIT_ZERO_TS,
             1.0,
             0.0);
     free (ee->write_buf);
@@ -199,7 +198,6 @@ process_buffer (struct TALER_KYCLOGIC_SanctionRater *sr)
     char *nl;
     double rating;
     double confidence;
-    unsigned long long expire;
     char best_match[1024];
     size_t line_len;
 
@@ -209,12 +207,11 @@ process_buffer (struct TALER_KYCLOGIC_SanctionRater *sr)
     GNUNET_assert (NULL != nl);
     *nl = '\0';
     line_len = nl - buf;
-    if (4 !=
+    if (3 !=
         sscanf (buf,
-                "%lf %lf %llu %1023s",
+                "%lf %lf %1023s",
                 &rating,
                 &confidence,
-                &expire,
                 best_match))
     {
       GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
@@ -232,9 +229,6 @@ process_buffer (struct TALER_KYCLOGIC_SanctionRater *sr)
       ee->cb (ee->cb_cls,
               TALER_EC_NONE,
               best_match,
-              0 == expire
-              ? GNUNET_TIME_UNIT_FOREVER_TS
-              : GNUNET_TIME_timestamp_from_s (expire),
               rating,
               confidence);
       free (ee->write_buf);

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

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