/*
* this 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 2 of the License, or
* (at your option) any later version.
*
* this 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 this program. If not, see .";
*
* (c) Alexander Vdolainen 2026
* subrelay: a minimalistic maillist server based on external IMAPs/SMTPs
*
* configuration.h: configuration file handling
*/
#ifndef __CONFIG_H__
#define __CONFIG_H__
typedef struct subrelay_config {
char *maillist_addr; /* C001.1 */
char *imap_host; /* C001.2 */
int imap_port; /* C001.2 */
char *smtp_host; /* C001.3 */
int smtp_port; /* C001.3 */
char *account_pass; /* C001.4 */
char *maillist_name; /* C001.5 */
char *template_path; /* C001.6 */
char *run_user; /* C001.7 */
char *run_group; /* C001.7 */
char *socket_path; /* C001.8 */
char *subscribers_file;/* C001.9 */
} subrelay_config_t;
int configuration_load(subrelay_config_t *cfg, const char *filepath);
void configuration_free(subrelay_config_t *cfg);
#endif /* __CONFIG_H__ */