donau

Donation authority for GNU Taler (experimental)
Log | Files | Refs | Submodules | README | LICENSE

donau_util.h (1641B)


      1 /*
      2   This file is part of TALER
      3   Copyright (C) 2014-2025 Taler Systems SA
      4 
      5   TALER is free software; you can redistribute it and/or modify it under the
      6   terms of the GNU General Public License as published by the Free Software
      7   Foundation; either version 3, or (at your option) any later version.
      8 
      9   TALER is distributed in the hope that it will be useful, but WITHOUT ANY
     10   WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
     11   A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
     12 
     13   You should have received a copy of the GNU General Public License along with
     14   TALER; see the file COPYING.  If not, see <http://www.gnu.org/licenses/>
     15 */
     16 /**
     17  * @file include/donau_util.h
     18  * @brief Interface for common utility functions
     19  * @author Sree Harsha Totakura <sreeharsha@totakura.in>
     20  */
     21 #ifndef DONAU_UTIL_H
     22 #define DONAU_UTIL_H
     23 
     24 #include <gnunet/gnunet_common.h>
     25 #define __DONAU_UTIL_LIB_H_INSIDE__
     26 
     27 #include <gnunet/gnunet_util_lib.h>
     28 #include <microhttpd.h>
     29 #include <taler/taler_util.h>
     30 #include "donau_crypto_lib.h"
     31 
     32 /**
     33  * HTTP header with a signature by the charity.
     34  */
     35 #define DONAU_HTTP_HEADER_CHARITY_SIGNATURE "Charity-Signature"
     36 
     37 /**
     38  * Return default project data used by Taler.
     39  */
     40 const struct GNUNET_OS_ProjectData *
     41 DONAU_project_data (void);
     42 
     43 
     44 /**
     45  * Generates the String for the QR Code containing the donation statement.
     46  *
     47  * The returned string will be freshly allocated, and must be free'd
     48  * with #GNUNET_free().
     49  */
     50 char *
     51 DONAU_generate_qr_string (
     52   const struct DONAU_DonauPublicKeyP *pub_key,
     53   const struct DONAU_DonationStatement *donation_statement);
     54 
     55 #endif