Ryo Ito > OIDC-Lite-0.02 > Plack::Middleware::Auth::OIDC::ProtectedResource

Download:
OIDC-Lite-0.02.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Source   Latest Release: OIDC-Lite-0.08

NAME ^

Plack::Middleware::Auth::OIDC::ProtectedResource - middleware for OpenID Connect Protected Resource endpoint

SYNOPSIS ^

    my $app = sub {...};
    builder {
        enable "Plack::Middleware::Auth::OIDC::ProtectedResource",
            data_handler => "YourApp::DataHandler",
            error_uri    => q{http://example.org/error/description};
        enable "Plack::Middleware::JSONP";
        enable "Plack::Middleware::ContentLength";
        $app;
    };

    # and on your controller
    $plack_request->env->{REMOTE_USER};
    $plack_request->env->{X_OAUTH_CLIENT_ID};
    $plack_request->env->{X_OAUTH_SCOPE};
    $plack_request->env->{X_OIDC_USERINFO_CLAIMS};
    $plack_request->env->{X_OAUTH_IS_LEGACY};

DESCRIPTION ^

middleware for OpenID Connect Protected Resource endpoint

METHODS ^

call( $env )

ENV VALUES ^

After successful verifying authorization within middleware layer, Following 4 type of values are set in env.

REMOTE_USER

Identifier of user who grant the client to access the user's protected resource that is stored on service provider.

X_OAUTH_CLIENT

Identifier of the client that accesses to user's protected resource on beharf of the user.

X_OAUTH_SCOPE

Scope parameter that represents what kind of resources that the user grant client to access.

X_OIDC_USERINFO_CLAIMS

User Attributes required by client. This claims include UserInfo response.

AUTHOR ^

Ryo Ito, <ritou.06@gmail.com>

COPYRIGHT AND LICENSE ^

Copyright (C) 2012 by Ryo Ito

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.

syntax highlighting: