The Samba-Bugzilla – Attachment 8730 Details for
Bug 8393
Allow domain == realm in provision
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
proposed, but unsted patch to fix this in a different way
0001-scripting-provision-Do-not-enforce-domain-realm-if-w.patch (text/plain), 2.53 KB, created by
Andrew Bartlett
on 2013-04-05 01:16:44 UTC
(
hide
)
Description:
proposed, but unsted patch to fix this in a different way
Filename:
MIME Type:
Creator:
Andrew Bartlett
Created:
2013-04-05 01:16:44 UTC
Size:
2.53 KB
patch
obsolete
>From 3c25f8b7bc28fc36ca102a26a3a44e7215d20ea9 Mon Sep 17 00:00:00 2001 >From: Andrew Bartlett <abartlet@samba.org> >Date: Fri, 5 Apr 2013 12:01:17 +1100 >Subject: [PATCH] scripting-provision: Do not enforce domain != realm if we > are joining an existing domain > >This will allow us users to join existing oddly named domains without >objection from provision. > >Andrew Bartlett >--- > python/samba/provision/__init__.py | 11 +++++++---- > 1 file changed, 7 insertions(+), 4 deletions(-) > >diff --git a/python/samba/provision/__init__.py b/python/samba/provision/__init__.py >index 252cfd9..79c7584 100644 >--- a/python/samba/provision/__init__.py >+++ b/python/samba/provision/__init__.py >@@ -561,7 +561,8 @@ def determine_netbios_name(hostname): > > def guess_names(lp=None, hostname=None, domain=None, dnsdomain=None, > serverrole=None, rootdn=None, domaindn=None, configdn=None, >- schemadn=None, serverdn=None, sitename=None): >+ schemadn=None, serverdn=None, sitename=None, >+ domain_names_forced=False): > """Guess configuration settings to use.""" > > if hostname is None: >@@ -624,8 +625,10 @@ def guess_names(lp=None, hostname=None, domain=None, dnsdomain=None, > if hostname.upper() == realm: > raise ProvisioningError("guess_names: Realm '%s' must not be equal to hostname '%s'!" % (realm, hostname)) > if netbiosname.upper() == realm: >- raise ProvisioningError("guess_names: Realm '%s' must not be equal to netbios hostname '%s'!" % (realm, netbiosname)) >- if domain == realm: >+ raise ProvisioningError("guess_names: Realm '%s' must not be equal to NetBIOS hostname '%s'!" % (realm, netbiosname)) >+ if netbiosname.upper() == domain: >+ raise ProvisioningError("guess_names: Short domain '%s' must not be equal to NetBIOS hostname '%s'!" % (domain, netbiosname)) >+ if domain == realm and not domain_names_forced: > raise ProvisioningError("guess_names: Realm '%s' must not be equal to short domain name '%s'!" % (realm, domain)) > > if rootdn is None: >@@ -1984,7 +1987,7 @@ def provision(logger, session_info, credentials, smbconf=None, > names = guess_names(lp=lp, hostname=hostname, domain=domain, > dnsdomain=realm, serverrole=serverrole, domaindn=domaindn, > configdn=configdn, schemadn=schemadn, serverdn=serverdn, >- sitename=sitename, rootdn=rootdn) >+ sitename=sitename, rootdn=rootdn, domain_names_forced=(samdb_fill == FILL_DRS)) > paths = provision_paths_from_lp(lp, names.dnsdomain) > > paths.bind_gid = bind_gid >-- >1.7.11.7 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 8393
:
6796
| 8730