summaryrefslogtreecommitdiff
path: root/source4/dns_server/dlz_bind9.c
AgeCommit message (Collapse)AuthorFilesLines
2012-05-24dlz_bind9: Make the talloc destructor static and return 0.Amitay Isaacs1-1/+2
Autobuild-User: Amitay Isaacs <amitay@samba.org> Autobuild-Date: Thu May 24 03:32:50 CEST 2012 on sn-devel-104
2012-05-24dlz_bind9: Fix the named crash on reloading namedAmitay Isaacs1-1/+17
When reloading zones, named first creates new zone instance and then shuts down the old instance. Since ldb layer, keeps the same LDB open, talloc_free() on samdb handle, causes talloc "access after use" error. This patch keeps only single context (dlz_bind9_data) and uses reference counting to decide when to actually free the context. Since samdb handle is reused, use talloc_unlink() instead of talloc_free() on samdb handle.
2012-04-16dlz_bind9: Build shared libraries for both BIND versions 9.8 and 9.9Amitay Isaacs1-0/+5
This adds #define BIND_VERSION_9_8 and keeps the current version as 9.9, so shared libraries can be built for both BIND versions.
2012-04-16dlz_bind9: changes to make dlz_bind9 work with BIND 9.9.0Amitay Isaacs1-19/+19
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
2012-03-08dlz_bind9: Log Samba DEBUG() messages to the bind9 logsAndrew Bartlett1-2/+29
2012-03-01dlz_bind9: Match PTR records as DNS names and not just stringsAmitay Isaacs1-1/+1
This fixes the dynamic update of PTR records. Autobuild-User: Amitay Isaacs <amitay@samba.org> Autobuild-Date: Thu Mar 1 15:58:05 CET 2012 on sn-devel-104
2012-03-02dlz_bind9: Fix handling of TXT records with multiple quoted stringsAmitay Isaacs1-4/+33
2012-03-02dlz_bind9: This fixes the problem with adding/deleting rdatasetAmitay Isaacs1-11/+16
Fix commit 169db333033b72b6f9ac1e7b23f0f2c151218c1f. This change allowed for LDB records without dnsRecord attribute to exist to prevent large number of deleted records. This change fixes the handling of missing dnsRecord attribute and correctly deleting dnsRecord attribute.
2012-02-21dlz_bind9: Fix the log message levelAmitay Isaacs1-5/+5
2012-02-21dlz_bind9: Do not remove LDB record in subrdataset and delrdatasetAmitay Isaacs1-13/+8
This fixes the problem of large number of deleted records in DNS partitions due to frequent dynamic dns updates from windows clients. The typical pattern for dynamic update get converted into subrdataset() followed by addrdataset(). If there are no dnsRecord attributes left as a result of sub/delrdataset(), leave the LDB entry for dns name as is. The subsequent addrdataset() would add the dnsRecord attribute without re-creating the same entry.
2012-01-25dlz_bind9: for authenticated user, set the AUTHENTICATED USERS sid in tokenAmitay Isaacs1-0/+5
2012-01-04dlz_bind9: create session info from PAC using auth contextAmitay Isaacs1-7/+59
This fixes the creation of session info from PAC, after changes in gensec code. Autobuild-User: Amitay Isaacs <amitay@samba.org> Autobuild-Date: Wed Jan 4 01:59:09 CET 2012 on sn-devel-104
2011-12-07s4-dns Use match-by-key in GSSAPI server if principal is not specifiedAndrew Bartlett1-22/+5
This allows dlz_bind9 to match on exactly the same key as bind9 itself Andrew Bartlett Autobuild-User: Amitay Isaacs <amitay@samba.org> Autobuild-Date: Wed Dec 7 02:20:10 CET 2011 on sn-devel-104
2011-12-07dlz_bind9: Add command line options for URL and debugAmitay Isaacs1-8/+27
To specify debug level, use -d <level> in named.conf. To specify sam db, use -H <path/to/sam.ldb> in named.conf. The default log level is set to 0. The log level specified in smb.conf is not used. To set log level, use -d option.
2011-12-07dlz_bind9: Set debugging output to stderrAmitay Isaacs1-0/+3
2011-12-07dlz_bind9: Use client supplied credentials for DNS record updateAmitay Isaacs1-0/+79
This creates the DNS records with correct owner and group settings.
2011-12-07dlz_bind9: For creating a child entry, use only SEC_ADS_CREATE_CHILDAmitay Isaacs1-1/+1
The member servers in AD do not have access to modify the parent, but do have access to create child DNS records.
2011-11-29dlz_bind9: Added access check to verify dynamic updateAmitay Isaacs1-16/+166
This creates session info from kerberos ticket and verifies if the signer has write access to a particular DN corresponding to the name in dynamic update. Pair-Programmed-With: Andrew Tridgell <tridge@samba.org>
2011-11-29dlz_bind9: Use the sam database in dns/ as defaultAmitay Isaacs1-59/+13
This change is introduced to access samdb copy directly, rather than over ildap. The advantage is that the samba server does not need to be running for bind9 to start.
2011-10-17s4:dlz_bind9: add no memory checksStefan Metzmacher1-0/+4
metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Mon Oct 17 14:07:25 CEST 2011 on sn-devel-104
2011-10-17s4:dlz_bind9: Copy dn before changing in b9_has_soaStefan Gohmann1-1/+5
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-10-17s4:dlz_bind9: add missing earch bases for windows 2000 domainsStefan Gohmann1-0/+1
By default the samba4 dlz_bind9 backend searches under CN=MicrosoftDNS,DC=DomainDnsZones and CN=MicrosoftDNS,DC=ForestDnsZones. In my samba4 test setup all DNS zones are under CN=MicrosoftDNS,CN=System. After adding the attached patch it works fine for me. Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-04-29s4:"ldb_connect" calls - proof for "!= LDB_SUCCESS"Matthias Dieter Wallnöfer1-1/+1
Reviewed-by: abartlet
2011-04-29s4-param Rename private_path() -> lpcfg_private_path()Andrew Bartlett1-1/+1
This is consistent with lock_path() Andrew Bartlett
2011-01-14s4-dns: renamed DNS_TYPE_ZERO to DNS_TYPE_TOMBSTONEAndrew Tridgell1-5/+5
we now know that these are tombstone records, with a timestamp Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-01-12s4:dns_server/dlz_bind9.c - initialise "ret" variablesMatthias Dieter Wallnöfer1-2/+2
2010-12-22dns: fixed dns record formatAndrew Tridgell1-4/+9
based on new WSPP docs from Bryan Burgin Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Wed Dec 22 04:45:46 CET 2010 on sn-devel-104
2010-12-21s4-dns: set dwSerial and dwFlagsAndrew Tridgell1-0/+7
we are waiting on full docs on these, but this is better than zero Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org> Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Tue Dec 21 12:05:51 CET 2010 on sn-devel-104
2010-12-21s4-dns: fixed name comparison in bind9 moduleAndrew Tridgell1-6/+21
we need to compare without the trailing '.' Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-12-21s4-dns: return the local hostname as the SOA authorityAndrew Tridgell1-2/+19
this is done by all DCs in the domain to ensure that updates go to the right place
2010-12-21s4-dns: disable segfault handling in dlz_bind9Andrew Tridgell1-0/+2
we don't want bind9 calling the Samba segv handler
2010-12-21s4-dns: fixed a crash bug in dlz_bind9 codeAndrew Tridgell1-2/+0
we need to keep el_ctx for the next part of the loop
2010-12-15s4-dns: implemented parsing and storing of DNS records from bindAndrew Tridgell1-45/+639
DNS updates from nsupdate against our ldb SAM now work Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Wed Dec 15 12:36:46 CET 2010 on sn-devel-104
2010-12-15s4-dns: added basic DLZ writeable support to dlz_bind9Andrew Tridgell1-47/+308
this implements the expanded DLZ update driver API, allowing for bind9 to send dynamic updates to the Samba DLZ driver. This change also adds support for exporting all DNS zones in the SAM database, which also means we now correctly separate the _msdcs zone from the main zone.
2010-12-08s4-dns: use ldb hooks for samba extensions in dlz_bind9Andrew Tridgell1-49/+35
this avoids linking dlz_bind9 directly to heimdal, which allows a RTLD_DEEPBIND in ldb module loading to find the right kerberos version Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-12-08s4-dns: allow a remote ldap server to be used with dlz_bind9Andrew Tridgell1-15/+66
this allows for configs like this: dlz "Samba zone" { database "dlopen /usr/lib/samba/modules/bind9/dlz_bind9.so -H ldap://10.0.0.4 -Uadministrator@v2.tridgell.net%penguin -k no"; };
2010-12-06s4-dns: return the correct TTLAndrew Tridgell1-6/+2
I've now patched the bind9 sdlz layer to cope with multiple TTLS on a name/type pair Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Mon Dec 6 08:12:11 CET 2010 on sn-devel-104
2010-12-06s4-dns: support Samba command line options to the dlz_bind.so moduleAndrew Tridgell1-0/+35
this allows setting of Samba command line options in named.conf
2010-12-06s4-dns: added flags support for dlz_bind9Andrew Tridgell1-1/+1
this will allow us to set the THREADSAFE flag if we make this threadsafe. For now we don't set that flag, and let bind9 do the locking for us.
2010-12-06s4-dns: a dlz module for bind9Andrew Tridgell1-0/+523
this module can be loaded into bind9 if bind9 has been built with the --with-dlz-dlopen option. It provides access bind9 access to the DNS records in SAMDB. You can then start bind9 with this in named.conf: dlz "Samba zone" { database "dlopen /usr/lib/samba/modules/bind9/dlz_bind9.so"; }; See http://git.samba.org/tridge/bind9.git for a bind9 tree with the dlz_dlopen driver. See also the discussion on the bind-workers mailing list Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Mon Dec 6 05:48:30 CET 2010 on sn-devel-104