summaryrefslogtreecommitdiff
path: root/source4/dns_server/dlz_minimal.h
diff options
context:
space:
mode:
authorAmitay Isaacs <amitay@gmail.com>2012-03-08 18:34:04 +1100
committerAmitay Isaacs <amitay@gmail.com>2012-04-16 11:16:34 +1000
commit07677b2e433e4dc1aa956b2fda0e477a9c7b88b5 (patch)
tree056509ae3f051ef7454f0e3fd46b342946b1ae9a /source4/dns_server/dlz_minimal.h
parent89e998412fe07a01f9c79330973f62d909dc2da2 (diff)
downloadsamba-07677b2e433e4dc1aa956b2fda0e477a9c7b88b5.tar.gz
samba-07677b2e433e4dc1aa956b2fda0e477a9c7b88b5.tar.bz2
samba-07677b2e433e4dc1aa956b2fda0e477a9c7b88b5.zip
dlz_bind9: changes to make dlz_bind9 work with BIND 9.9.0
The main changes are: DLZ_DLOPEN_VERSION changed from 1 to 2 isc_boolean_t changed from bool to int dlz_lookup() now takes 2 additional arguments
Diffstat (limited to 'source4/dns_server/dlz_minimal.h')
-rw-r--r--source4/dns_server/dlz_minimal.h37
1 files changed, 34 insertions, 3 deletions
diff --git a/source4/dns_server/dlz_minimal.h b/source4/dns_server/dlz_minimal.h
index 9aae7766bf..3f408ab117 100644
--- a/source4/dns_server/dlz_minimal.h
+++ b/source4/dns_server/dlz_minimal.h
@@ -23,10 +23,10 @@
tree.
*/
typedef unsigned int isc_result_t;
-typedef bool isc_boolean_t;
+typedef int isc_boolean_t;
typedef uint32_t dns_ttl_t;
-#define DLZ_DLOPEN_VERSION 1
+#define DLZ_DLOPEN_VERSION 2
/* return this in flags to dlz_version() if thread safe */
#define DNS_SDLZFLAG_THREADSAFE 0x00000001U
@@ -34,8 +34,14 @@ typedef uint32_t dns_ttl_t;
/* result codes */
#define ISC_R_SUCCESS 0
#define ISC_R_NOMEMORY 1
+#define ISC_R_NOPERM 6
#define ISC_R_NOTFOUND 23
#define ISC_R_FAILURE 25
+#define ISC_R_NOMORE 29
+
+/* boolean values */
+#define ISC_TRUE 1
+#define ISC_FALSE 0
/* log levels */
#define ISC_LOG_INFO (-1)
@@ -48,6 +54,29 @@ typedef uint32_t dns_ttl_t;
typedef void *dns_sdlzlookup_t;
typedef void *dns_sdlzallnodes_t;
typedef void *dns_view_t;
+typedef void *dns_clientinfomethods_t;
+typedef void *dns_clientinfo_t;
+
+/*
+ * method definitions for callbacks provided by dlopen driver
+ */
+
+typedef void log_t(int level, const char *fmt, ...);
+
+typedef isc_result_t dns_sdlz_putrr_t(dns_sdlzlookup_t *lookup,
+ const char *type,
+ dns_ttl_t ttl,
+ const char *data);
+
+typedef isc_result_t dns_sdlz_putnamedrr_t(dns_sdlzallnodes_t *allnodes,
+ const char *name,
+ const char *type,
+ dns_ttl_t ttl,
+ const char *data);
+
+typedef isc_result_t dns_dlz_writeablezone_t(dns_view_t *view,
+ const char *zone_name);
+
/*
* prototypes for the functions you can include in your driver
@@ -80,7 +109,9 @@ isc_result_t dlz_findzonedb(void *dbdata, const char *name);
dlz_lookup is required for all DLZ external drivers
*/
isc_result_t dlz_lookup(const char *zone, const char *name,
- void *dbdata, dns_sdlzlookup_t *lookup);
+ void *dbdata, dns_sdlzlookup_t *lookup,
+ dns_clientinfomethods_t *methods,
+ dns_clientinfo_t *clientinfo);
/*
dlz_allowzonexfr() is optional, and should be supplied if you want