Commit 0b2887a5 authored by Daniel Salzman's avatar Daniel Salzman

Unify header files

parent 904d02eb
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,13 +14,10 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Base32hex implementation (RFC 4648).
*
* \note Input Base32hex string can contain a-v characters. These characters
* are considered as A-V equivalent. Lower-case variant is used for encoding!
* @{
*/
#pragma once
......
/* Copyright (C) 2011 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,12 +14,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Base64 implementation (RFC 4648).
*
* \addtogroup contrib
* @{
*/
#pragma once
......
/* Copyright (C) 2016 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -12,14 +12,9 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
*/
/*!
* \file
*
* \brief Dnstap identifiers conversions.
*
* \addtogroup dnstap
* @{
*/
#pragma once
......@@ -62,5 +57,3 @@ bool dt_message_type_is_response(Dnstap__Message__Type type);
* Check if a message role is any type of an initiator.
*/
bool dt_message_role_is_initiator(Dnstap__Message__Type type);
/*! @} */
......@@ -14,14 +14,9 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \author Robert Edmonds <edmonds@fsi.io>
*
* \brief Public interface for dnstap.
*
* \addtogroup dnstap
* @{
*/
#pragma once
......@@ -49,5 +44,3 @@
* \retval NULL if error.
*/
uint8_t* dt_pack(const Dnstap__Dnstap *d, uint8_t **buf, size_t *sz);
/*! @} */
......@@ -14,14 +14,9 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \author Robert Edmonds <edmonds@fsi.io>
*
* \brief Dnstap message interface.
*
* \addtogroup dnstap
* @{
*/
#pragma once
......@@ -65,5 +60,3 @@ int dt_message_fill(Dnstap__Message *m,
const void *wire,
const size_t len_wire,
const struct timespec *mtime);
/*! @} */
......@@ -14,12 +14,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Dnstap file reader.
*
* \addtogroup dnstap
* @{
*/
#pragma once
......@@ -75,5 +70,3 @@ int dt_reader_read(dt_reader_t *reader, Dnstap__Dnstap **d);
* \param d The frame to be freed.
*/
void dt_reader_free_frame(dt_reader_t *reader, Dnstap__Dnstap **d);
/*! @} */
......@@ -14,14 +14,9 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \author Robert Edmonds <edmonds@fsi.io>
*
* \brief Dnstap file writer.
*
* \addtogroup dnstap
* @{
*/
#pragma once
......@@ -73,5 +68,3 @@ void dt_writer_free(dt_writer_t *writer);
* \retval KNOT_ENOMEM
*/
int dt_writer_write(dt_writer_t *writer, const ProtobufCMessage *msg);
/*! @} */
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,7 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \brief Simple write-once allocation-optimal dynamic array.
*
......
/* Copyright (C) 2011 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,12 +14,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Multiplatform getline wrapper.
*
* \addtogroup contrib
* @{
*/
#pragma once
......@@ -41,5 +36,3 @@
* not including terminating. -1 on error or EOF.
*/
ssize_t knot_getline(char **lineptr, size_t *n, FILE *stream);
/*! @} */
/* Copyright (C) 2014 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,12 +14,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Common macros.
*
* \addtogroup contrib
* @{
*/
#pragma once
......@@ -46,5 +41,3 @@
/*! \brief Optimize for x to be false value. */
#define unlikely(x) __builtin_expect((x), 0)
#endif
/*! @} */
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,8 +14,6 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Memory allocation related functions.
*/
......
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,8 +14,6 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief String manipulations.
*/
......
/* Copyright (C) 2011 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,12 +14,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Table for converting ASCII characters to lowercase.
*
* \addtogroup contrib
* @{
*/
#pragma once
......@@ -54,5 +49,3 @@ static inline uint8_t knot_tolower(uint8_t c) {
return tolower_table[c];
}
/*! @} */
/* Copyright (C) 2015 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -14,12 +14,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Heap memory trimmer.
*
* \addtogroup contrib
* @{
*/
#pragma once
......@@ -38,5 +33,3 @@ static inline void mem_trim(void)
#endif
return;
}
/*! @} */
......@@ -13,15 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* Server configuration core.
*
* \addtogroup config
*
* @{
*/
#pragma once
......@@ -286,5 +277,3 @@ int conf_export(
const char *file_name,
yp_style_t style
);
/*! @} */
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,15 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* Server configuration interface.
*
* \addtogroup config
*
* @{
*/
#pragma once
......@@ -722,5 +713,3 @@ static inline conf_remote_t conf_remote(
return conf_remote_txn(conf, &conf->read_txn, id, index);
}
/*! @} */
/* Copyright (C) 2015 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,15 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* Configuration database interface.
*
* \addtogroup config
*
* @{
*/
#pragma once
......@@ -237,5 +228,3 @@ int conf_db_raw_dump(
knot_db_txn_t *txn,
const char *file_name
);
/*! @} */
/* Copyright (C) 2016 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,15 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* Configuration interface.
*
* \addtogroup config
*
* @{
*/
#pragma once
......@@ -225,5 +216,3 @@ int conf_io_unset(
int conf_io_check(
conf_io_t *io
);
/*! @} */
......@@ -72,10 +72,10 @@ static const knot_lookup_t dnssec_key_algs[] = {
};
const knot_lookup_t child_record[] = {
{ CHILD_RECORDS_NONE, "none" },
{ CHILD_RECORDS_EMPTY, "delete-dnssec" },
{ CHILD_RECORDS_NONE, "none" },
{ CHILD_RECORDS_EMPTY, "delete-dnssec" },
{ CHILD_RECORDS_ROLLOVER, "rollover" },
{ CHILD_RECORDS_ALWAYS, "always" },
{ CHILD_RECORDS_ALWAYS, "always" },
{ 0, NULL }
};
......
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,15 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* Server configuration schema.
*
* \addtogroup config
*
* @{
*/
#pragma once
......@@ -127,7 +118,7 @@
enum {
KEYSTORE_BACKEND_PEM = 1,
KEYSTORE_BACKEND_PKCS11 = 2
KEYSTORE_BACKEND_PKCS11 = 2,
};
enum {
......@@ -139,7 +130,7 @@ enum {
enum {
SERIAL_POLICY_INCREMENT = 1,
SERIAL_POLICY_UNIXTIME = 2
SERIAL_POLICY_UNIXTIME = 2,
};
enum {
......@@ -157,5 +148,3 @@ enum {
extern const knot_lookup_t acl_actions[];
extern const yp_item_t conf_schema[];
/*! @} */
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,15 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* Configuration schema callbacks.
*
* \addtogroup config
*
* @{
*/
#pragma once
......@@ -114,5 +105,3 @@ int include_file(
int load_module(
knotd_conf_check_args_t *args
);
/*! @} */
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Server control commands.
*
* \addtogroup ctl
* @{
*/
#pragma once
......@@ -141,5 +133,3 @@ void ctl_log_data(knot_ctl_data_t *data);
* \return True if presented.
*/
bool ctl_has_flag(const char *flags, const char *flag);
/*! @} */
/* Copyright (C) 2016 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Server control processing.
*
* \addtogroup ctl
* @{
*/
#pragma once
......@@ -36,5 +28,3 @@
* \return Error code, KNOT_EOK if successful.
*/
int ctl_process(knot_ctl_t *ctl, server_t *server);
/*! @} */
/* Copyright (C) 2011 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,22 +13,9 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file kdig_exec.h
*
* \author Daniel Salzman <daniel.salzman@nic.cz>
*
* \brief kdig executives.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
#include "utils/common/params.h"
#include "utils/kdig/kdig_params.h"
int kdig_exec(const kdig_params_t *params);
/*! @} */
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief kdig command line parameters.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
......@@ -182,5 +174,3 @@ bool ednsopt_list_empty(const list_t *list);
int kdig_init(kdig_params_t *params);
int kdig_parse(kdig_params_t *params, int argc, char *argv[]);
void kdig_clean(kdig_params_t *params);
/*! @} */
/* Copyright (C) 2016 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief khost command line parameters.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
......@@ -28,5 +20,3 @@
int khost_parse(kdig_params_t *params, int argc, char *argv[]);
void khost_clean(kdig_params_t *params);
/*! @} */
/* Copyright (C) 2017 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Knot control commands.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
......@@ -74,5 +66,3 @@ extern const cmd_desc_t cmd_table[];
/*! \brief Prints commands help. */
void print_commands(void);
/*! @} */
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Memory estimation for zone files.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
......@@ -70,5 +62,3 @@ void estimator_rrset_memsize_wrap(zs_scanner_t *scanner);
* \param data Unused variable.
*/
int estimator_free_trie_node(trie_val_t *val, void *data);
/*! @} */
/* Copyright (C) 2016 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Knot control interactive mode.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
......@@ -32,5 +24,3 @@
* \param[in] params Utility parameters.
*/
int interactive_loop(params_t *params);
/*! @} */
......@@ -13,14 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file
*
* \brief Knot control processing.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
......@@ -75,5 +67,3 @@ void unset_ctl(knot_ctl_t *ctl);
* \return Error code, KNOT_EOK if successful.
*/
int process_cmd(int argc, const char **argv, params_t *params);
/*! @} */
/* Copyright (C) 2011 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
/* Copyright (C) 2018 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
......@@ -13,21 +13,9 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file knsupdate_exec.h
*
* \author Marek Vavrusa <marek.vavrusa@nic.cz>
*
* \brief
*
* \addtogroup knot_utils
* @{
*/
#pragma once
#include "utils/knsupdate/knsupdate_params.h"
int knsupdate_exec(knsupdate_params_t *params);
/*! @} */
......@@ -13,16 +13,6 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*!
* \file knsupdate_params.h
*
* \author Marek Vavrusa <marek.vavrusa@nic.cz>
*
* \brief knsupdate command line parameters.
*
* \addtogroup knot_utils
* @{
*/
#pragma once
......@@ -82,5 +72,3 @@ int knsupdate_set_ttl(knsupdate_params_t *params, const uint32_t ttl);
int knsupdate_set_origin(knsupdate_params_t *params, const char *origin);
void knsupdate_clean(knsupdate_params_t *params);
void knsupdate_reset(knsupdate_params_t *params);
/*! @} */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment