x2gobroker.web.uccs module

class x2gobroker.web.uccs.X2GoBrokerWeb(application: Application, request: HTTPServerRequest, **kwargs: Any)[source]

Bases: _RequestHandler

get(path)[source]

With the UCCS protocol, a HEAD request is sent to the server’s base URL (sort of as an is-alive ping).

If X2Go Session Broker runs in debug mode, the processing of the HEAD request reponse is also made available to GET requests. This means, you can open the base URL in a normal web browser and get a reply.

Parameters:

path (str) – URL path

head(path)[source]

With the UCCS protocol, a HEAD request is sent to the server’s base URL (sort of as an is-alive ping).

Parameters:

path (str) – URL path

class x2gobroker.web.uccs.X2GoBrokerWebAPI(*args, **kwargs)[source]

Bases: RequestHandler

HTTP request handler that provides the UCCS web frontend of the X2Go Session Broker.

Currently, Arctica Greeter with Remote Logon Service uses this webfrontend / communication protocol format.

Raises:

tornado.web.HTTPError – on authentication failure a 401 error is raised; on invalid API versions, a 404 error is raised.

get(*args, **kwargs)[source]

Implementation of the UCCS broker API versions 4 (final) and 5 (in development).

Parameters:

path (str) – URL path

http_header_items = {'Content-Type': 'text/plain; charset=utf-8', 'Expires': '+1h'}
x2gobroker.web.uccs.credentials_validate(username, password)[source]

Helper function to validate some given credentials.

Parameters:
  • username (str) – the username

  • password (str) – the user’s password

Returns:

(<username>, <success>) tuple

Return type:

(str, bool)