a little nicer wrt pep8
[sfa.git] / docs / pythondoc-geniserver.html
1 <!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'>
2 <html>
3 <head>
4 <meta http-equiv='Content-Type' content='text/html; charset=us-ascii' />
5 <title>The geniserver Module</title>
6 </head>
7 <body>
8 <h1>The geniserver Module</h1>
9 <p>This module implements a general-purpose server layer for geni.
10 The same basic server should be usable on the registry, component, or
11 other interfaces.
12
13 TODO: investigate ways to combine this with existing PLC server?</p>
14 <dl>
15 <dt><b>GeniServer(ip, port, key_file, cert_file)</b> (class) [<a href='#geniserver.GeniServer-class'>#</a>]</dt>
16 <dd>
17 <p>Implements an HTTPS XML-RPC server.</p>
18 <p>For more information about this class, see <a href='#geniserver.GeniServer-class'><i>The GeniServer Class</i></a>.</p>
19 </dd>
20 <dt><b>SecureXMLRpcRequestHandler</b> (class)  [<a href='#geniserver.SecureXMLRpcRequestHandler-class'>#</a>]</dt>
21 <dd>
22 <p>taken from the web (XXX find reference).</p>
23 <p>For more information about this class, see <a href='#geniserver.SecureXMLRpcRequestHandler-class'><i>The SecureXMLRpcRequestHandler Class</i></a>.</p>
24 </dd>
25 <dt><b>SecureXMLRPCServer(server_address, HandlerClass, key_file, cert_file, logRequests=True)</b> (class) [<a href='#geniserver.SecureXMLRPCServer-class'>#</a>]</dt>
26 <dd>
27 <p>Taken from the web (XXX find reference).</p>
28 <p>For more information about this class, see <a href='#geniserver.SecureXMLRPCServer-class'><i>The SecureXMLRPCServer Class</i></a>.</p>
29 </dd>
30 <dt><a id='geniserver.verify_callback-function' name='geniserver.verify_callback-function'><b>verify_callback(conn, x509, err, depth, preverify)</b></a> [<a href='#geniserver.verify_callback-function'>#</a>]</dt>
31 <dd>
32 <p>Verification callback for pyOpenSSL. We do our own checking of keys because
33 we have our own authentication spec. Thus we disable several of the normal
34 prohibitions that OpenSSL places on certificates</p>
35 </dd>
36 </dl>
37 <h2><a id='geniserver.GeniServer-class' name='geniserver.GeniServer-class'>The GeniServer Class</a></h2>
38 <dl>
39 <dt><b>GeniServer(ip, port, key_file, cert_file)</b> (class) [<a href='#geniserver.GeniServer-class'>#</a>]</dt>
40 <dd>
41 <p>Implements an HTTPS XML-RPC server. Generally it is expected that GENI
42 functions will take a credential string, which is passed to
43 decode_authentication. Decode_authentication() will verify the validity of
44 the credential, and verify that the user is using the key that matches the
45 GID supplied in the credential.</p>
46 </dd>
47 <dt><a id='geniserver.GeniServer.decode_authentication-method' name='geniserver.GeniServer.decode_authentication-method'><b>decode_authentication(cred_string, operation)</b></a> [<a href='#geniserver.GeniServer.decode_authentication-method'>#</a>]</dt>
48 <dd>
49 <p>Decode the credential string that was submitted by the caller. Several
50 checks are performed to ensure that the credential is valid, and that the
51 callerGID included in the credential matches the caller that is
52 connected to the HTTPS connection.</p>
53 </dd>
54 <dt><a id='geniserver.GeniServer.noop-method' name='geniserver.GeniServer.noop-method'><b>noop(cred, anything)</b></a> [<a href='#geniserver.GeniServer.noop-method'>#</a>]</dt>
55 <dd>
56 <p>Sample no-op server function. The no-op function decodes the credential
57 that was passed to it.</p>
58 </dd>
59 <dt><a id='geniserver.GeniServer.register_functions-method' name='geniserver.GeniServer.register_functions-method'><b>register_functions()</b></a> [<a href='#geniserver.GeniServer.register_functions-method'>#</a>]</dt>
60 <dd>
61 <p>Register functions that will be served by the XMLRPC server. This
62 function should be overrided by each descendant class.</p>
63 </dd>
64 <dt><a id='geniserver.GeniServer.run-method' name='geniserver.GeniServer.run-method'><b>run()</b></a> [<a href='#geniserver.GeniServer.run-method'>#</a>]</dt>
65 <dd>
66 <p>Execute the server, serving requests forever.</p>
67 </dd>
68 </dl>
69 <h2><a id='geniserver.SecureXMLRpcRequestHandler-class' name='geniserver.SecureXMLRpcRequestHandler-class'>The SecureXMLRpcRequestHandler Class</a></h2>
70 <dl>
71 <dt><b>SecureXMLRpcRequestHandler</b> (class)  [<a href='#geniserver.SecureXMLRpcRequestHandler-class'>#</a>]</dt>
72 <dd>
73 <p>taken from the web (XXX find reference). Implents HTTPS xmlrpc request handler</p>
74 </dd>
75 </dl>
76 <h2><a id='geniserver.SecureXMLRPCServer-class' name='geniserver.SecureXMLRPCServer-class'>The SecureXMLRPCServer Class</a></h2>
77 <dl>
78 <dt><b>SecureXMLRPCServer(server_address, HandlerClass, key_file, cert_file, logRequests=True)</b> (class) [<a href='#geniserver.SecureXMLRPCServer-class'>#</a>]</dt>
79 <dd>
80 <p>Taken from the web (XXX find reference). Implements an HTTPS xmlrpc server</p>
81 </dd>
82 </dl>
83 </body></html>