On 26.7.2013 12:31, Zip Ly wrote:
Normally if IPA has a well documented API then my approach would be:
user --> (internet) --> webserver --> lPA API --> IPA server


But since there isn't much info about the API then my approach would be:
user --> (internet) --> webserver --> a PHP script which acts as an custom
API --> IPA server


The problem is I don't know which commands are available en which
values/params I should send. For example:

http://www.freeipa.org/docs/1.2/Administrators_Reference/en-US/html/chap-Administration_Reference-XML_RPC_Application_Programming_Interface_API_Documentation.html#
These are commands for xml rpc. Without examples it's difficult to find
out how to use it.

Note that this link points to docs for FreeIPA 1.2.1, which is several years old and totally unsupported. Please use articles written for FreeIPA 2.x or 3.x.

But they are different from this example:
http://adam.younglogic.com/2010/07/talking-to-freeipa-json-web-api-via-curl/
In this example a "user_find" command is used, but this command cannot be
found in the official xml rpc document above.

In ssh I can display a list of commands with "ipa help commands" I don't
know if they are all supported in "/ipa/json" I probably need to replace
all dashes with underscores (correct me if I'm wrong).

If I want to display all the supported params from one certain command
for example "ipa help user-find". Then, are all the double dashed params
also the supported params which I can send with JSON?

I prefer using the native API if there is one (hidden somewhere), because I
don't want to reinvent the wheel with security leaks which I'm not aware
of. Especially when I need to execute CLI commands from the PHP scripts.

--
Petr^2 Spacek

_______________________________________________
Freeipa-users mailing list
Freeipa-users@redhat.com
https://www.redhat.com/mailman/listinfo/freeipa-users

Reply via email to