idviews: error out if appling Default Trust View on hosts

https://fedorahosted.org/freeipa/ticket/4615

Reviewed-By: Martin Kosek <mkosek@redhat.com>
This commit is contained in:
Petr Vobornik authored and Martin Kosek committed 2014-10-17 14:28:13 +02:00
1 parent b69a8dad2e
commit 49fde3b047
1 file changed
+6
+6
View File
@@ -240,6 +240,12 @@ class baseidview_apply(LDAPQuery):
# the ipaAssignedIDView to None
view_dn = None
if view == 'Default Trust View':
raise errors.ValidationError(
name=_('ID View'),
error=_('Default Trust View cannot be applied on hosts')
)
completed = 0
succeeded = {'host': []}
failed = {