Exemple #1
0
def authorization_code():

    provider = CloudstackAuthorizationProvider()

    response = provider.get_authorization_code_from_uri(request.url)

    res = make_response(response.text, response.status_code)
    for k, v in response.headers.iteritems():
        res.headers[k] = v
    return res
Exemple #2
0
def token():
    provider = CloudstackAuthorizationProvider()

    data = {k: request.form[k] for k in request.form.iterkeys()}

    response = provider.get_token_from_post_data(data)

    res = make_response(response.text, response.status_code)
    for k, v in response.headers.iteritems():
        res.headers[k] = v
    return res
Exemple #3
0
def token():
    provider = CloudstackAuthorizationProvider()

    data = {k: request.form[k] for k in request.form.iterkeys()}

    response = provider.get_token_from_post_data(data)

    res = make_response(response.text, response.status_code)
    for k, v in response.headers.iteritems():
        res.headers[k] = v

    return res