[PATCH] DNS patches for review
Amitay Isaacs
amitay at gmail.com
Mon Jan 14 18:07:16 MST 2013
Hi Andrew,
On Fri, Dec 28, 2012 at 9:21 PM, Andrew Bartlett <abartlet at samba.org> wrote:
> On Fri, 2012-12-28 at 18:31 +1100, Andrew Bartlett wrote:
> > On Fri, 2012-12-28 at 07:02 +0100, Kai Blin wrote:
> > > On 2012-12-28 05:09, Andrew Bartlett wrote:
> > > > index ba597cf..d2cf42f 100755
> > > > --- a/source4/scripting/bin/samba_upgradedns
> > > > +++ b/source4/scripting/bin/samba_upgradedns
> > > > @@ -449,10 +449,17 @@ if __name__ == '__main__':
> > > > "DNSNAME" : dnsname }
> > > > )
> > > >
> > > > + res = ldbs.sam.search(base=domaindn,
> scope=ldb.SCOPE_DEFAULT,
> > > > +
> expression='(sAMAccountName=dns-%s)' % (hostname),
> > > > + attrs=["msDS-KeyVersionNumber"])
> > > > + if "msDS-KeyVersionNumber" in res[0]:
> > > > + dns_key_version_number =
> int(res[0]["msDS-KeyVersionNumber"][0])
> > > > +
> > > > secretsdb_setup_dns(ldbs.secrets, names,
> > > > paths.private_dir,
> realm=names.realm,
> > > > dnsdomain=names.dnsdomain,
> > > > - dns_keytab_path=paths.dns_keytab,
> dnspass=dnspass)
> > > > + dns_keytab_path=paths.dns_keytab,
> dnspass=dnspass,
> > > > +
> key_version_number=dns_key_version_number)
> > >
> > > How do you get a dns_key_version_number if the above if statement
> fails?
> > > Either we're sure the if statement never fails, and then it's
> pointless,
> > > or we need to come up with a fake number ourselves, or raise an
> exception.
> > >
> > > Same logic in the join.py code.
> >
> > Thanks, I'll fix that up. The default value needs to be 1 (really only
> > applies to windows 2000 mode, but worth doing right).
>
> Attached are all my DNS patches to date.
>
>
Minor nitpicks.
'
* patch 0005-scripting-samba_upgradedns-Only-look-for-IPv4-IPv6-a.patch,
paste the lines before:
logger.info("Creating DNS partitions")
* patch 0006-selftest-Add-a-basic-test-of-samba_upgradedns.patch,
+if [ $# -lt 4 ]; then
should be
+if [ $# -lt 5 ]; then
+shift 6
should be
+shift 5
* other patches look fine.
I was unable to apply the patches to current master. Second patch fails.
Amitay.
More information about the samba-technical
mailing list