| 1 | 1 | ▶ | use strict; use warnings; | ||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||
| 2 | |||||||||||||||
| 3 | package Net::OAuth2Server::Request::Token::TokenExchange; | ||||||||||||||
| 4 | 1 | our $VERSION = '0.004'; | |||||||||||||
| 5 | |||||||||||||||
| 6 | 1 | ▶ | use parent 'Net::OAuth2Server::Request'; | ||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||
| 7 | |||||||||||||||
| 8 | 0 | ▶ | sub grant_type { 'urn:ietf:params:oauth:grant-type:token-exchange' } | ||||||||||||
|
Subroutine
grant_type: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||||||
| 9 | 0 | ▶ | sub allowed_methods { 'POST' } | ||||||||||||
|
Subroutine
allowed_methods: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||||||
| 10 | 0 | ▶ | sub grant_parameters { qw( subject_token_type subject_token ) } | ||||||||||||
|
Subroutine
grant_parameters: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||||||
| 11 | 1 | *required_parameters = \&grant_parameters; | |||||||||||||
| 12 | |||||||||||||||
| 13 | 0 | ▶ | sub get_grant { | ||||||||||||
|
Subroutine
get_grant: not called CC=5 SCAR=34.0
Pod
undocumented
| |||||||||||||||
| 14 | 0 | my ( $self, $grant_maker ) = ( shift, shift ); | |||||||||||||
| 15 | 0 | ▶ | return if $self->error; | ||||||||||||
|
Branch: 1 branch
| |||||||||||||||
| 16 | |||||||||||||||
| 17 | 0 | ▶ | if ( $self->has_param( 'actor_token' ) ) { | ||||||||||||
|
Branch: 2 branches
| |||||||||||||||
| 18 | 0 | ▶ | $self->ensure_required( 'actor_token_type' ) or return; | ||||||||||||
|
Branch: 1 branch
| |||||||||||||||
| 19 | } | ||||||||||||||
| 20 | elsif ( $self->has_param( 'actor_token_type' ) ) { | ||||||||||||||
| 21 | 0 | $self->set_error_invalid_request( 'extraneous parameter: actor_token_type' ); | |||||||||||||
| 22 | 0 | return; | |||||||||||||
| 23 | } | ||||||||||||||
| 24 | |||||||||||||||
| 25 | 0 | $grant_maker->from_subject_token( $self, $self->params( $self->grant_parameters ), @_ ); | |||||||||||||
| 26 | } | ||||||||||||||
| 27 | |||||||||||||||
| 28 | 1 | 1; | |||||||||||||