<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
	<id>http://wiki.mipt.ru/index.php?action=history&amp;feed=atom&amp;title=Development%3AMNet_services</id>
	<title>Development:MNet services - История изменений</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.mipt.ru/index.php?action=history&amp;feed=atom&amp;title=Development%3AMNet_services"/>
	<link rel="alternate" type="text/html" href="http://wiki.mipt.ru/index.php?title=Development:MNet_services&amp;action=history"/>
	<updated>2026-05-07T15:13:58Z</updated>
	<subtitle>История изменений этой страницы в вики</subtitle>
	<generator>MediaWiki 1.42.1</generator>
	<entry>
		<id>http://wiki.mipt.ru/index.php?title=Development:MNet_services&amp;diff=11338&amp;oldid=prev</id>
		<title>Олег Давидович: 1 версия импортирована</title>
		<link rel="alternate" type="text/html" href="http://wiki.mipt.ru/index.php?title=Development:MNet_services&amp;diff=11338&amp;oldid=prev"/>
		<updated>2024-10-21T08:51:25Z</updated>

		<summary type="html">&lt;p&gt;1 версия импортирована&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ru&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Предыдущая версия&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Версия от 08:51, 21 октября 2024&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;ru&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(нет различий)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Олег Давидович</name></author>
	</entry>
	<entry>
		<id>http://wiki.mipt.ru/index.php?title=Development:MNet_services&amp;diff=11337&amp;oldid=prev</id>
		<title>1&gt;Tsala: category edit</title>
		<link rel="alternate" type="text/html" href="http://wiki.mipt.ru/index.php?title=Development:MNet_services&amp;diff=11337&amp;oldid=prev"/>
		<updated>2010-02-18T20:19:06Z</updated>

		<summary type="html">&lt;p&gt;category edit&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;This page lists the services (and methods in that service) that are available to MNet clients. Services are MNet&amp;#039;s way of grouping methods, and allowing MNet sites to publish and/or subscribe to services.  The descriptions are not complete.  Please help fill it out!&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== System ==&lt;br /&gt;
&lt;br /&gt;
Implemented in /mnet/xmlrpc/server.php, this provides basic information about the MNet server. These methods may also be called as &amp;quot;system.*&amp;quot; in addition to the &amp;quot;system/*&amp;quot; pattern common to the other method names. The system/listMethods, system/methodSignature, and system/methodHelp methods are based on [http://xmlrpc-c.sourceforge.net/introspection.html XML-RPC Introspection].&lt;br /&gt;
&lt;br /&gt;
This service is not returned by system/listServices, nor are any of the methods listed by the XML-RPC Introspection methods.&lt;br /&gt;
&lt;br /&gt;
=== system/listMethods ===&lt;br /&gt;
Lists the available methods.&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* service name(string) (optional): If provided, list only the methods provided by the given service. If not specified, list all available methods. (This parameter is not present in XML-RPC Introspection.)&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* array of strings, giving the method names&lt;br /&gt;
&lt;br /&gt;
==== Security ====&lt;br /&gt;
Only lists methods that the client is allowed to execute.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== system/methodSignature ===&lt;br /&gt;
Gives the method signature of the requested method.&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* method name(string): The name of the method to provide the method signature for.&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* array, giving the method signature(s). Note: the format is different from the one specified in the XML-RPC Introspection spec.&lt;br /&gt;
** Each array element is itself an array&lt;br /&gt;
*** Each array element is a struct, with fields &amp;quot;type&amp;quot; and &amp;quot;description&amp;quot;, and values being strings.&lt;br /&gt;
*** The first array element represents the return value. Subsequent array elements represent the parameters.&lt;br /&gt;
&lt;br /&gt;
==== Security ====&lt;br /&gt;
If the client is not allowed to execute the method, returns an empty array.&lt;br /&gt;
&lt;br /&gt;
=== system/methodHelp ===&lt;br /&gt;
Give a textual description of the requested method.&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* method name(string): The name of the method to provide help for.&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* string, a description of the method.&lt;br /&gt;
&lt;br /&gt;
==== Security ====&lt;br /&gt;
If the client is not allowed to execute the method, returns server fault 7019.&lt;br /&gt;
&lt;br /&gt;
=== system/listServices ===&lt;br /&gt;
List the available services.&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
none&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* array, giving the service names, versions, and publish/subscription status. Each array element is a struct with the following keys:&lt;br /&gt;
** name(string): the name of the service&lt;br /&gt;
** apiversion(integer): the API version provided&lt;br /&gt;
** publish(integer): whether the server is publishing this service to the client&lt;br /&gt;
** subscribe(integer): whether the server is subscribing to this service from the client&lt;br /&gt;
&lt;br /&gt;
==== Security ====&lt;br /&gt;
Only services that are published or subscribed are returned.&lt;br /&gt;
&lt;br /&gt;
=== system/keySwap ===&lt;br /&gt;
Swap public keys via X509 certificates.&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* wwwroot(string): the client&amp;#039;s wwwroot.&lt;br /&gt;
* certificate(string): the client&amp;#039;s X509 certificate, in PEM format&lt;br /&gt;
* application(string): the application type&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* (string) the server&amp;#039;s X509 certificate, in PEM format&lt;br /&gt;
&lt;br /&gt;
==== Security ====&lt;br /&gt;
This is the only MNet method that can be called from all hosts without encryption and signing (since that is the only way to bootstrap the process).&lt;br /&gt;
&lt;br /&gt;
You really shouldn&amp;#039;t be trusting the client&amp;#039;s parameters, as these can be easily forged. If the certificate differs from the certificate you have stored for the given wwwroot, you should double-check by doing your own system/keySwap call, or trying to send an encrypted and signed XML-RPC request to the client. In this way, a successful attack would require at least DNS hijacking and/or a man-in-the-middle attack, both of which break MNet&amp;#039;s security anyways.&lt;br /&gt;
&lt;br /&gt;
== sso_idp (version 1) ==&lt;br /&gt;
Identity provider for single sign on.&lt;br /&gt;
&lt;br /&gt;
=== auth/mnet/auth.php/user_authorise ===&lt;br /&gt;
(note UK spelling of &amp;quot;authorise&amp;quot;) Return user data for the provided token, compare with user_agent string.&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* token(string): token provided by the IdP&lt;br /&gt;
* user agent(string): SHA-1 hash of the user&amp;#039;s user agent string&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* struct, containing the user&amp;#039;s profile data. The fields provided are: username, email, auth (=&amp;quot;mnet&amp;quot;), confirmed, deleted, firstname, lastname, city, country, lang, timezone, description, mailformat, maildigest, maildisplay, htmleditor, wwwroot (the IdP&amp;#039;s wwwroot), session.gc_maxlifetime, picture (integer/boolean), imagehash (if picture != 0; sha1 hash of profile picture file), myhosts (an array describing how many courses the user is enrolled in, in all known hosts)&lt;br /&gt;
&lt;br /&gt;
=== auth/mnet/auth.php/keepalive_server ===&lt;br /&gt;
&amp;quot;Receives an array of usernames from a remote machine and prods their sessions to keep them alive&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* array of usernames&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* struct:&lt;br /&gt;
** if success:&lt;br /&gt;
*** code (int): 0&lt;br /&gt;
*** message (string): &amp;quot;All ok&amp;quot;&lt;br /&gt;
*** last_log_id (int): the ID of the last log entry received from auth/mnet/auth.php/refresh_log&lt;br /&gt;
** if error:&lt;br /&gt;
**** code (int): 1&lt;br /&gt;
**** message (string): &amp;quot;We failed to refresh the session for the following usernames: ...&amp;quot;&lt;br /&gt;
**** last_log_id (int): the ID of the last log entry received from auth/mnet/auth.php/refresh_log&lt;br /&gt;
&lt;br /&gt;
=== auth/mnet/auth.php/kill_children ===&lt;br /&gt;
&amp;quot;The IdP uses this function to kill child sessions on other hosts&amp;quot;&lt;br /&gt;
&lt;br /&gt;
never seems to be called by Moodle networks (called on logout instead)&lt;br /&gt;
&lt;br /&gt;
=== auth/mnet/auth.php/refresh_log ===&lt;br /&gt;
=== auth/mnet/auth.php/fetch_user_image ===&lt;br /&gt;
&amp;quot;Returns the user&amp;#039;s image as a base64 encoded string.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* username (string)&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* false on error, otherwise struct:&lt;br /&gt;
** f1 (string): base64 encoded copy of user&amp;#039;s f1.jpg&lt;br /&gt;
** f2 (string): base64 encoded copy of user&amp;#039;s f2.jpg&lt;br /&gt;
&lt;br /&gt;
=== auth/mnet/auth.php/fetch_theme_info ===&lt;br /&gt;
&amp;quot;Returns the theme information and logo url as strings.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
none&lt;br /&gt;
&lt;br /&gt;
==== Return value ====&lt;br /&gt;
* struct:&lt;br /&gt;
** themename (string)&lt;br /&gt;
** logourl (string): Url for theme logo&lt;br /&gt;
** auth/mnet/auth.php/update_enrolments&lt;br /&gt;
&lt;br /&gt;
== sso_sp (version 1) ==&lt;br /&gt;
Service provider for single sign on.&lt;br /&gt;
&lt;br /&gt;
=== auth/mnet/auth.php/keepalive_client ===&lt;br /&gt;
&amp;quot;Poll the IdP server to let it know that a user it has authenticated is still online&amp;quot; No, I don&amp;#039;t know what that means either.&lt;br /&gt;
&lt;br /&gt;
never seems to be called by Moodle networks (called by cron instead)&lt;br /&gt;
calls auth/mnet/auth.php/keepalive_server on each IdP that has local users logged in&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
none&lt;br /&gt;
&lt;br /&gt;
==== Return Value ====&lt;br /&gt;
none&lt;br /&gt;
&lt;br /&gt;
=== auth/mnet/auth.php/kill_child ===&lt;br /&gt;
Requests that the SP ends the user&amp;#039;s session. Used for single sign off.&lt;br /&gt;
&lt;br /&gt;
==== Parameters ====&lt;br /&gt;
* username(string)&lt;br /&gt;
* useragent(string): SHA-1 hash of the user&amp;#039;s user agent string&lt;br /&gt;
&lt;br /&gt;
Note that the calling IdP is identified through MNet signatures&lt;br /&gt;
&lt;br /&gt;
==== Return Value ====&lt;br /&gt;
* true on success (boolean)&lt;br /&gt;
&lt;br /&gt;
== mnet_enrol (version 1) ==&lt;br /&gt;
Moodle networks enrolments. Enable remote administrators to enrol users in local courses.&lt;br /&gt;
&lt;br /&gt;
=== enrol/mnet/enrol.php/available_courses ===&lt;br /&gt;
=== enrol/mnet/enrol.php/user_enrolments ===&lt;br /&gt;
=== enrol/mnet/enrol.php/enrol_user ===&lt;br /&gt;
=== enrol/mnet/enrol.php/unenrol_user ===&lt;br /&gt;
=== enrol/mnet/enrol.php/course_enrolments ===&lt;br /&gt;
&lt;br /&gt;
[[Category:MNet]]&lt;/div&gt;</summary>
		<author><name>1&gt;Tsala</name></author>
	</entry>
</feed>