On 01/17/2013 04:15 PM, Rob Crittenden wrote:
Martin Kosek wrote:
Give a clear message about what is wrong with current Trust settings
before letting AD to return a confusing error message.
https://fedorahosted.org/freeipa/ticket/3193
I hate being picky over wording but...
I think it would read better if you replaced 'this' with 'The IPA server' or
'IPA' or something like that.
rob
No worries, attaching a better worded version.
Martin
From cca2557282ef69e3791126a578e8c45a18460c47 Mon Sep 17 00:00:00 2001
From: Martin Kosek <mko...@redhat.com>
Date: Fri, 11 Jan 2013 16:33:43 +0100
Subject: [PATCH] Test NetBIOS name clash before creating a trust
Give a clear message about what is wrong with current Trust settings
before letting AD to return a confusing error message.
https://fedorahosted.org/freeipa/ticket/3193
---
ipaserver/dcerpc.py | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/ipaserver/dcerpc.py b/ipaserver/dcerpc.py
index 54a70defc9df52db58054d29c1c9f9189a88cabb..f1d148f0bccfff9568dff49d0eb64c6b815d578f 100644
--- a/ipaserver/dcerpc.py
+++ b/ipaserver/dcerpc.py
@@ -585,6 +585,12 @@ class TrustDomainInstance(object):
info.trust_type = lsa.LSA_TRUST_TYPE_UPLEVEL
info.trust_attributes = lsa.LSA_TRUST_ATTRIBUTE_FOREST_TRANSITIVE
+ if self.info['name'] == info.netbios_name.string:
+ # Check that NetBIOS names do not clash
+ raise errors.ValidationError(name=u'AD Trust Setup',
+ error=_('the IPA server and the remote domain cannot share the same '
+ 'NetBIOS name: %s') % self.info['name'])
+
try:
dname = lsa.String()
dname.string = another_domain.info['dns_domain']
--
1.7.11.7
_______________________________________________
Freeipa-devel mailing list
Freeipa-devel@redhat.com
https://www.redhat.com/mailman/listinfo/freeipa-devel