/* This file is part of TALER (C) 2014 Christian Grothoff (and other contributing authors) TALER is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version. TALER is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with TALER; see the file COPYING. If not, If not, see */ /** * @file mint/taler-mint_httpd_db.h * @brief Mint-specific database access * @author Chrisitan Grothoff */ #ifndef TALER_MINT_HTTPD_DB_H #define TALER_MINT_HTTPD_DB_H #include #include #include #include "taler_util.h" #include "taler_rsa.h" #include "taler-mint-httpd_keys.h" #include "mint.h" /** * Execute a /deposit. The validity of the coin and signature * have already been checked. The database must now check that * the coin is not (double or over) spent, and execute the * transaction (record details, generate success or failure response). * * @param connection the MHD connection to handle * @param deposit information about the deposit * @return MHD result code */ int TALER_MINT_db_execute_deposit (struct MHD_Connection *connection, const struct Deposit *deposit); /** * Execute a /withdraw/status. * * @param connection the MHD connection to handle * @param reserve_pub public key of the reserve to check * @return MHD result code */ int TALER_MINT_db_execute_withdraw_status (struct MHD_Connection *connection, const struct GNUNET_CRYPTO_EddsaPublicKey *reserve_pub); /** * Execute a /withdraw/sign. * * @param connection the MHD connection to handle * @param wsrd details about the withdraw request * @return MHD result code */ int TALER_MINT_db_execute_withdraw_sign (struct MHD_Connection *connection, const struct TALER_WithdrawRequest *wsrd); #endif /* _NEURO_MINT_DB_H */