freeipa/ipalib
Petr Viktorin 24bca144a8 Add client capabilities, enable messages
The API version the client sends can now be used to check what the client
expects or is capable of.

All version tests IPA does will be be named and listed in one module,
ipalib.capabilities, which includes a function to test a specific capability
against an API version.
Similarly to Python's __future__ module, capabilities.py also serves as
documentation of backwards-incompatible changes to the API.

The first capability to be defined is "messages". Recent enough clients can
accept a list of warnings or other info under the "messages" key in the
result dict.

If a JSON client does not send the API version, it is assumed this is a testing
client (e.g. curl from the command line). Such a client "has" all capabilities,
but it will always receive a warning mentioning that forward compatibility
is not guaranteed.
If a XML client does not send the API version, it is assumed it uses the API
version before capabilities were introduced. (This is to keep backwards
compatibility with clients containing bug https://fedorahosted.org/freeipa/ticket/3294)

Whenever a capability is added, the API version must be incremented.
To ensure that, capabilities are written to API.txt and checked by
`makeapi --validate`.

Design page: http://freeipa.org/page/V3/Messages
Ticket: https://fedorahosted.org/freeipa/ticket/2732
2013-02-21 16:26:09 +01:00
..
plugins Add the version option to all Commands 2013-02-21 16:26:09 +01:00
__init__.py Add the version option to all Commands 2013-02-21 16:26:09 +01:00
aci.py Use DN objects instead of strings 2012-08-12 16:23:24 -04:00
backend.py Add CLI parsing tests 2012-03-28 15:25:33 +02:00
base.py Change FreeIPA license to GPLv3+ 2010-12-20 17:19:53 -05:00
capabilities.py Add client capabilities, enable messages 2013-02-21 16:26:09 +01:00
cli.py Add the version option to all Commands 2013-02-21 16:26:09 +01:00
config.py Use DN objects instead of strings 2012-08-12 16:23:24 -04:00
constants.py Add list of domains associated to our realm to cn=etc 2013-02-19 14:15:46 +02:00
crud.py Relax restriction for leading/trailing whitespaces in *-find commands 2012-12-11 12:34:28 +01:00
errors.py Add ipalib.messages 2013-02-21 16:26:09 +01:00
frontend.py Add client capabilities, enable messages 2013-02-21 16:26:09 +01:00
krb_utils.py Pylint cleanup. 2013-01-29 15:39:49 +01:00
messages.py Add client capabilities, enable messages 2013-02-21 16:26:09 +01:00
output.py Typo fixes 2012-06-25 21:35:11 -04:00
parameters.py Raise ValidationError on invalid CSV values. 2013-02-08 15:16:37 +01:00
pkcs10.py Fix assorted bugs found by pylint 2011-01-25 14:01:36 -05:00
plugable.py Add tests for the help command & --help options 2013-02-18 13:07:17 -05:00
request.py Remove deprecated i18n code from ipalib/request and all references to it. 2011-03-01 10:31:36 -05:00
rpc.py Log info on failure to connect 2012-12-19 09:50:43 +01:00
session.py Compliant client side session cookie behavior 2012-12-10 12:45:09 -05:00
text.py Fix regressions introduced by pylint false positive fixes. 2011-05-11 16:50:01 +02:00
util.py Add list of domains associated to our realm to cn=etc 2013-02-19 14:15:46 +02:00
x509.py Don't initialize NSS if we don't have to, clean up unused cert refs 2013-01-23 14:26:42 -05:00