diff options
Diffstat (limited to 'ipalib/plugins')
-rw-r--r-- | ipalib/plugins/baseldap.py | 3 | ||||
-rw-r--r-- | ipalib/plugins/host.py | 3 | ||||
-rw-r--r-- | ipalib/plugins/service.py | 5 | ||||
-rw-r--r-- | ipalib/plugins/user.py | 14 |
4 files changed, 22 insertions, 3 deletions
diff --git a/ipalib/plugins/baseldap.py b/ipalib/plugins/baseldap.py index 88f312998..4fd5fe4a1 100644 --- a/ipalib/plugins/baseldap.py +++ b/ipalib/plugins/baseldap.py @@ -36,9 +36,6 @@ from ipalib.util import json_serialize from ipalib.dn import * global_output_params = ( - Flag('has_keytab', - label=_('Keytab'), - ), Flag('has_password', label=_('Password'), ), diff --git a/ipalib/plugins/host.py b/ipalib/plugins/host.py index 0f3f91565..6557880aa 100644 --- a/ipalib/plugins/host.py +++ b/ipalib/plugins/host.py @@ -162,6 +162,9 @@ def remove_fwd_ptr(ipaddr, host, domain, recordtype): pass host_output_params = ( + Flag('has_keytab', + label=_('Keytab'), + ), Str('managedby_host', label='Managed by', ), diff --git a/ipalib/plugins/service.py b/ipalib/plugins/service.py index 048a6b4f0..dad3ded43 100644 --- a/ipalib/plugins/service.py +++ b/ipalib/plugins/service.py @@ -84,6 +84,9 @@ EXAMPLES: """) output_params = ( + Flag('has_keytab', + label=_('Keytab'), + ), Str('managedby_host', label='Managed by', ), @@ -358,6 +361,7 @@ class service_find(LDAPSearch): member_attributes = ['managedby'] takes_options = LDAPSearch.takes_options has_output_params = LDAPSearch.has_output_params + output_params + def pre_callback(self, ldap, filter, attrs_list, base_dn, scope, *args, **options): # lisp style! custom_filter = '(&(objectclass=ipaService)' \ @@ -392,6 +396,7 @@ class service_show(LDAPRetrieve): doc=_('file to store certificate in'), ), ) + has_output_params = LDAPRetrieve.has_output_params + output_params def post_callback(self, ldap, dn, entry_attrs, *keys, **options): self.obj.get_password_attributes(ldap, dn, entry_attrs) diff --git a/ipalib/plugins/user.py b/ipalib/plugins/user.py index 273c68fb2..d3e63ef9a 100644 --- a/ipalib/plugins/user.py +++ b/ipalib/plugins/user.py @@ -68,6 +68,12 @@ EXAMPLES: NO_UPG_MAGIC = '__no_upg__' +user_output_params = ( + Flag('has_keytab', + label=_('Kerberos keys available'), + ), + ) + def validate_nsaccountlock(entry_attrs): if 'nsaccountlock' in entry_attrs: nsaccountlock = entry_attrs['nsaccountlock'] @@ -352,6 +358,8 @@ class user_add(LDAPCreate): msg_summary = _('Added user "%(value)s"') + has_output_params = LDAPCreate.has_output_params + user_output_params + takes_options = LDAPCreate.takes_options + ( Flag('noprivate', cli_name='noprivate', @@ -477,6 +485,8 @@ class user_mod(LDAPUpdate): msg_summary = _('Modified user "%(value)s"') + has_output_params = LDAPUpdate.has_output_params + user_output_params + def pre_callback(self, ldap, dn, entry_attrs, attrs_list, *keys, **options): if 'mail' in entry_attrs: entry_attrs['mail'] = self.obj._normalize_email(entry_attrs['mail']) @@ -498,6 +508,7 @@ class user_find(LDAPSearch): __doc__ = _('Search for users.') member_attributes = ['memberof'] + has_output_params = LDAPSearch.has_output_params + user_output_params takes_options = LDAPSearch.takes_options + ( Flag('whoami', @@ -532,6 +543,8 @@ api.register(user_find) class user_show(LDAPRetrieve): __doc__ = _('Display information about a user.') + has_output_params = LDAPRetrieve.has_output_params + user_output_params + def post_callback(self, ldap, dn, entry_attrs, *keys, **options): convert_nsaccountlock(entry_attrs) self.obj._convert_manager(entry_attrs, **options) @@ -566,6 +579,7 @@ class user_enable(LDAPQuery): __doc__ = _('Enable a user account.') has_output = output.standard_value + has_output_params = LDAPQuery.has_output_params + user_output_params msg_summary = _('Enabled user account "%(value)s"') def execute(self, *keys, **options): |