OpenDNSSEC-enforcer  2.0.4
Macros | Functions
signconf.h File Reference
#include "daemon/engine.h"
#include "db/db_connection.h"
#include "db/zone.h"
#include "db/policy.h"

Go to the source code of this file.

Macros

#define SIGNCONF_EXPORT_OK   0
 
#define SIGNCONF_EXPORT_ERR_ARGS   1
 
#define SIGNCONF_EXPORT_ERR_XML   2
 
#define SIGNCONF_EXPORT_ERR_DATABASE   3
 
#define SIGNCONF_EXPORT_ERR_MEMORY   4
 
#define SIGNCONF_EXPORT_ERR_FILE   5
 
#define SIGNCONF_EXPORT_NO_CHANGE   6
 

Functions

int signconf_export_all (int sockfd, const db_connection_t *connection, int force)
 
int signconf_export_policy (int sockfd, const db_connection_t *connection, const policy_t *policy, int force)
 

Macro Definition Documentation

◆ SIGNCONF_EXPORT_ERR_ARGS

#define SIGNCONF_EXPORT_ERR_ARGS   1

Indicates an error with the arguments provided to signconf_export*().

Definition at line 44 of file signconf.h.

◆ SIGNCONF_EXPORT_ERR_DATABASE

#define SIGNCONF_EXPORT_ERR_DATABASE   3

Indicates an error with the database like reading, updating or creating.

Definition at line 52 of file signconf.h.

◆ SIGNCONF_EXPORT_ERR_FILE

#define SIGNCONF_EXPORT_ERR_FILE   5

Indicates an error when handing files.

Definition at line 60 of file signconf.h.

◆ SIGNCONF_EXPORT_ERR_MEMORY

#define SIGNCONF_EXPORT_ERR_MEMORY   4

Indicates a memory allocation error or generic internal error.

Definition at line 56 of file signconf.h.

◆ SIGNCONF_EXPORT_ERR_XML

#define SIGNCONF_EXPORT_ERR_XML   2

Indicates an error with the signconf XML like parsing, validating or content.

Definition at line 48 of file signconf.h.

◆ SIGNCONF_EXPORT_NO_CHANGE

#define SIGNCONF_EXPORT_NO_CHANGE   6

Indicates that the operation was successful but no changes where made.

Definition at line 64 of file signconf.h.

◆ SIGNCONF_EXPORT_OK

#define SIGNCONF_EXPORT_OK   0

Indicates a successful signconf export.

Definition at line 40 of file signconf.h.

Function Documentation

◆ signconf_export_all()

int signconf_export_all ( int  sockfd,
const db_connection_t connection,
int  force 
)

Export the signconf XML for all zones.

Parameters
[in]sockfda socket fd.
[in]connectiona db_connection_t pointer.
[in]forceif non-zero it will force the export for all zones even if there are no updates for the zones.
Returns
SIGNCONF_EXPORT_ERR_* on error, otherwise SIGNCONF_EXPORT_OK or SIGNCONF_EXPORT_NO_CHANGE.

Definition at line 56 of file signconf.c.

◆ signconf_export_policy()

int signconf_export_policy ( int  sockfd,
const db_connection_t connection,
const policy_t policy,
int  force 
)

Export the signconf XML for all zones that uses a specified policy.

Parameters
[in]sockfda socket fd.
[in]connectiona db_connection_t pointer.
[in]policya policy_t pointer.
[in]forceif non-zero it will force the export for all zones even if there are no updates for the zones.
Returns
SIGNCONF_EXPORT_ERR_* on error, otherwise SIGNCONF_EXPORT_OK or SIGNCONF_EXPORT_NO_CHANGE.