From 977475a51380b3fad0a17f3dae936e860923d153 Mon Sep 17 00:00:00 2001 From: TravisCI Date: Fri, 4 Sep 2015 07:30:36 +0000 Subject: [PATCH] Travis pushed coverage of a9f61fd3ed2dcc1a8b0dff875b49b7e1bf0c0f6f@master to gh-pages --- master/AbstractServer.php.html | 68 +-- master/AuthorizationServer.php.html | 42 +- master/Entity/AbstractTokenEntity.php.html | 40 +- master/Entity/AccessTokenEntity.php.html | 44 +- master/Entity/AuthCodeEntity.php.html | 2 +- master/Entity/ClientEntity.php.html | 6 +- master/Entity/EntityTrait.php.html | 14 +- master/Entity/RefreshTokenEntity.php.html | 30 +- master/Entity/ScopeEntity.php.html | 8 +- master/Entity/SessionEntity.php.html | 22 +- master/Entity/dashboard.html | 2 +- master/Entity/index.html | 2 +- .../ClientAuthenticationFailedEvent.php.html | 2 +- master/Event/SessionOwnerEvent.php.html | 2 +- .../UserAuthenticationFailedEvent.php.html | 2 +- master/Event/dashboard.html | 2 +- master/Event/index.html | 2 +- .../Exception/AccessDeniedException.php.html | 2 +- .../Exception/InvalidClientException.php.html | 2 +- .../InvalidCredentialsException.php.html | 2 +- .../Exception/InvalidGrantException.php.html | 2 +- .../InvalidRefreshException.php.html | 2 +- .../InvalidRequestException.php.html | 2 +- .../Exception/InvalidScopeException.php.html | 2 +- master/Exception/OAuthException.php.html | 2 +- .../Exception/ServerErrorException.php.html | 2 +- .../UnauthorizedClientException.php.html | 2 +- .../UnsupportedGrantTypeException.php.html | 2 +- .../UnsupportedResponseTypeException.php.html | 2 +- master/Exception/dashboard.html | 2 +- master/Exception/index.html | 2 +- master/Grant/AbstractGrant.php.html | 54 +- master/Grant/AuthCodeGrant.php.html | 553 ++++++++++-------- master/Grant/ClientCredentialsGrant.php.html | 2 +- master/Grant/GrantTypeInterface.php.html | 2 +- master/Grant/PasswordGrant.php.html | 2 +- master/Grant/RefreshTokenGrant.php.html | 380 +++++++----- master/Grant/dashboard.html | 11 +- master/Grant/index.html | 60 +- master/ResourceServer.php.html | 2 +- master/Storage/AbstractStorage.php.html | 2 +- master/Storage/AccessTokenInterface.php.html | 2 +- master/Storage/AuthCodeInterface.php.html | 2 +- master/Storage/ClientInterface.php.html | 2 +- master/Storage/MacTokenInterface.php.html | 2 +- master/Storage/RefreshTokenInterface.php.html | 2 +- master/Storage/ScopeInterface.php.html | 2 +- master/Storage/SessionInterface.php.html | 2 +- master/Storage/StorageInterface.php.html | 2 +- master/Storage/dashboard.html | 2 +- master/Storage/index.html | 2 +- master/TokenType/AbstractTokenType.php.html | 16 +- master/TokenType/Bearer.php.html | 18 +- master/TokenType/MAC.php.html | 2 +- master/TokenType/TokenTypeInterface.php.html | 2 +- master/TokenType/dashboard.html | 2 +- master/TokenType/index.html | 2 +- .../KeyAlgorithm/DefaultAlgorithm.php.html | 14 +- .../KeyAlgorithmInterface.php.html | 2 +- master/Util/KeyAlgorithm/dashboard.html | 2 +- master/Util/KeyAlgorithm/index.html | 2 +- master/Util/RedirectUri.php.html | 2 +- master/Util/SecureKey.php.html | 8 +- master/Util/dashboard.html | 2 +- master/Util/index.html | 2 +- master/dashboard.html | 13 +- master/index.html | 52 +- 67 files changed, 846 insertions(+), 701 deletions(-) diff --git a/master/AbstractServer.php.html b/master/AbstractServer.php.html index cfa048e3..ed99a804 100644 --- a/master/AbstractServer.php.html +++ b/master/AbstractServer.php.html @@ -667,8 +667,8 @@
100
     */
101
    public function __construct()
102
    { -
103
        $this->setEventEmitter(); -
104
    } +
103
        $this->setEventEmitter(); +
104
    }
105
106
    /**
107
     * Set an event emitter @@ -677,12 +677,12 @@
110
     */
111
    public function setEventEmitter($emitter = null)
112
    { -
113
        if ($emitter === null) { -
114
            $this->eventEmitter = new Emitter(); -
115
        } else { +
113
        if ($emitter === null) { +
114
            $this->eventEmitter = new Emitter(); +
115
        } else {
116
            $this->eventEmitter = $emitter;
117
        } -
118
    } +
118
    }
119
120
    /**
121
     * Add an event listener to the event emitter @@ -726,11 +726,11 @@
159
     */
160
    public function getRequest()
161
    { -
162
        if ($this->request === null) { -
163
            $this->request = Request::createFromGlobals(); -
164
        } +
162
        if ($this->request === null) { +
163
            $this->request = Request::createFromGlobals(); +
164
        }
165
-
166
        return $this->request; +
166
        return $this->request;
167
    }
168
169
    /** @@ -742,10 +742,10 @@
175
     */
176
    public function setClientStorage(ClientInterface $storage)
177
    { -
178
        $storage->setServer($this); -
179
        $this->clientStorage = $storage; +
178
        $storage->setServer($this); +
179
        $this->clientStorage = $storage;
180
-
181
        return $this; +
181
        return $this;
182
    }
183
184
    /** @@ -757,10 +757,10 @@
190
     */
191
    public function setSessionStorage(SessionInterface $storage)
192
    { -
193
        $storage->setServer($this); -
194
        $this->sessionStorage = $storage; +
193
        $storage->setServer($this); +
194
        $this->sessionStorage = $storage;
195
-
196
        return $this; +
196
        return $this;
197
    }
198
199
    /** @@ -772,10 +772,10 @@
205
     */
206
    public function setAccessTokenStorage(AccessTokenInterface $storage)
207
    { -
208
        $storage->setServer($this); -
209
        $this->accessTokenStorage = $storage; +
208
        $storage->setServer($this); +
209
        $this->accessTokenStorage = $storage;
210
-
211
        return $this; +
211
        return $this;
212
    }
213
214
    /** @@ -787,10 +787,10 @@
220
     */
221
    public function setRefreshTokenStorage(RefreshTokenInterface $storage)
222
    { -
223
        $storage->setServer($this); -
224
        $this->refreshTokenStorage = $storage; +
223
        $storage->setServer($this); +
224
        $this->refreshTokenStorage = $storage;
225
-
226
        return $this; +
226
        return $this;
227
    }
228
229
    /** @@ -817,10 +817,10 @@
250
     */
251
    public function setScopeStorage(ScopeInterface $storage)
252
    { -
253
        $storage->setServer($this); -
254
        $this->scopeStorage = $storage; +
253
        $storage->setServer($this); +
254
        $this->scopeStorage = $storage;
255
-
256
        return $this; +
256
        return $this;
257
    }
258
259
    /** @@ -830,7 +830,7 @@
263
     */
264
    public function getClientStorage()
265
    { -
266
        return $this->clientStorage; +
266
        return $this->clientStorage;
267
    }
268
269
    /** @@ -850,7 +850,7 @@
283
     */
284
    public function getSessionStorage()
285
    { -
286
        return $this->sessionStorage; +
286
        return $this->sessionStorage;
287
    }
288
289
    /** @@ -860,7 +860,7 @@
293
     */
294
    public function getRefreshTokenStorage()
295
    { -
296
        return $this->refreshTokenStorage; +
296
        return $this->refreshTokenStorage;
297
    }
298
299
    /** @@ -870,7 +870,7 @@
303
     */
304
    public function getAccessTokenStorage()
305
    { -
306
        return $this->accessTokenStorage; +
306
        return $this->accessTokenStorage;
307
    }
308
309
    /** @@ -892,9 +892,9 @@
325
     */
326
    public function setTokenType(TokenTypeInterface $tokenType)
327
    { -
328
        $tokenType->setServer($this); -
329
        $this->tokenType = $tokenType; -
330
    } +
328
        $tokenType->setServer($this); +
329
        $this->tokenType = $tokenType; +
330
    }
331
332
    /**
333
     * Get the access token type @@ -903,7 +903,7 @@
336
     */
337
    public function getTokenType()
338
    { -
339
        return $this->tokenType; +
339
        return $this->tokenType;
340
    }
341
342
    /** @@ -934,7 +934,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/AuthorizationServer.php.html b/master/AuthorizationServer.php.html index 5759b87b..281c923a 100644 --- a/master/AuthorizationServer.php.html +++ b/master/AuthorizationServer.php.html @@ -518,11 +518,11 @@
77
    public function __construct()
78
    {
79
        // Set Bearer as the default token type -
80
        $this->setTokenType(new Bearer()); +
80
        $this->setTokenType(new Bearer());
81
-
82
        parent::__construct(); +
82
        parent::__construct();
83
-
84
        return $this; +
84
        return $this;
85
    }
86
87
    /** @@ -535,20 +535,20 @@
94
     */
95
    public function addGrantType(GrantTypeInterface $grantType, $identifier = null)
96
    { -
97
        if (is_null($identifier)) { -
98
            $identifier = $grantType->getIdentifier(); -
99
        } +
97
        if (is_null($identifier)) { +
98
            $identifier = $grantType->getIdentifier(); +
99
        }
100
101
        // Inject server into grant -
102
        $grantType->setAuthorizationServer($this); +
102
        $grantType->setAuthorizationServer($this);
103
-
104
        $this->grantTypes[$identifier] = $grantType; +
104
        $this->grantTypes[$identifier] = $grantType;
105
-
106
        if (!is_null($grantType->getResponseType())) { +
106
        if (!is_null($grantType->getResponseType())) {
107
            $this->responseTypes[] = $grantType->getResponseType();
108
        }
109
-
110
        return $this; +
110
        return $this;
111
    }
112
113
    /** @@ -594,7 +594,7 @@
153
     */
154
    public function scopeParamRequired()
155
    { -
156
        return $this->requireScopeParam; +
156
        return $this->requireScopeParam;
157
    }
158
159
    /** @@ -618,7 +618,7 @@
177
     */
178
    public function getDefaultScope()
179
    { -
180
        return $this->defaultScope; +
180
        return $this->defaultScope;
181
    }
182
183
    /** @@ -652,7 +652,7 @@
211
     */
212
    public function getScopeDelimiter()
213
    { -
214
        return $this->scopeDelimiter; +
214
        return $this->scopeDelimiter;
215
    }
216
217
    /** @@ -676,7 +676,7 @@
235
     */
236
    public function getAccessTokenTTL()
237
    { -
238
        return $this->accessTokenTTL; +
238
        return $this->accessTokenTTL;
239
    }
240
241
    /** @@ -702,18 +702,18 @@
261
     */
262
    public function issueAccessToken()
263
    { -
264
        $grantType = $this->getRequest()->request->get('grant_type'); -
265
        if (is_null($grantType)) { +
264
        $grantType = $this->getRequest()->request->get('grant_type'); +
265
        if (is_null($grantType)) {
266
            throw new Exception\InvalidRequestException('grant_type');
267
        }
268
269
        // Ensure grant type is one that is recognised and is enabled -
270
        if (!in_array($grantType, array_keys($this->grantTypes))) { +
270
        if (!in_array($grantType, array_keys($this->grantTypes))) {
271
            throw new Exception\UnsupportedGrantTypeException($grantType);
272
        }
273
274
        // Complete the flow -
275
        return $this->getGrantType($grantType)->completeFlow(); +
275
        return $this->getGrantType($grantType)->completeFlow();
276
    }
277
278
    /** @@ -727,8 +727,8 @@
286
     */
287
    public function getGrantType($grantType)
288
    { -
289
        if (isset($this->grantTypes[$grantType])) { -
290
            return $this->grantTypes[$grantType]; +
289
        if (isset($this->grantTypes[$grantType])) { +
290
            return $this->grantTypes[$grantType];
291
        }
292
293
        throw new Exception\InvalidGrantException($grantType); @@ -746,7 +746,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/AbstractTokenEntity.php.html b/master/Entity/AbstractTokenEntity.php.html index 611bbcba..f9aa5cfb 100644 --- a/master/Entity/AbstractTokenEntity.php.html +++ b/master/Entity/AbstractTokenEntity.php.html @@ -411,9 +411,9 @@
63
     */
64
    public function __construct(AbstractServer $server)
65
    { -
66
        $this->server = $server; +
66
        $this->server = $server;
67
-
68
        return $this; +
68
        return $this;
69
    }
70
71
    /** @@ -425,9 +425,9 @@
77
     */
78
    public function setSession(SessionEntity $session)
79
    { -
80
        $this->session = $session; +
80
        $this->session = $session;
81
-
82
        return $this; +
82
        return $this;
83
    }
84
85
    /** @@ -439,9 +439,9 @@
91
     */
92
    public function setExpireTime($expireTime)
93
    { -
94
        $this->expireTime = $expireTime; +
94
        $this->expireTime = $expireTime;
95
-
96
        return $this; +
96
        return $this;
97
    }
98
99
    /** @@ -451,7 +451,7 @@
103
     */
104
    public function getExpireTime()
105
    { -
106
        return $this->expireTime; +
106
        return $this->expireTime;
107
    }
108
109
    /** @@ -461,7 +461,7 @@
113
     */
114
    public function isExpired()
115
    { -
116
        return ((time() - $this->expireTime) > 0); +
116
        return ((time() - $this->expireTime) > 0);
117
    }
118
119
    /** @@ -473,9 +473,9 @@
125
     */
126
    public function setId($id = null)
127
    { -
128
        $this->id = ($id !== null) ? $id : SecureKey::generate(); +
128
        $this->id = ($id !== null) ? $id : SecureKey::generate();
129
-
130
        return $this; +
130
        return $this;
131
    }
132
133
    /** @@ -485,7 +485,7 @@
137
     */
138
    public function getId()
139
    { -
140
        return $this->id; +
140
        return $this->id;
141
    }
142
143
    /** @@ -513,18 +513,18 @@
165
     */
166
    protected function formatScopes($unformatted = [])
167
    { -
168
        if (is_null($unformatted)) { +
168
        if (is_null($unformatted)) {
169
            return [];
170
        }
171
-
172
        $scopes = []; -
173
        foreach ($unformatted as $scope) { -
174
            if ($scope instanceof ScopeEntity) { -
175
                $scopes[$scope->getId()] = $scope; -
176
            } -
177
        } +
172
        $scopes = []; +
173
        foreach ($unformatted as $scope) { +
174
            if ($scope instanceof ScopeEntity) { +
175
                $scopes[$scope->getId()] = $scope; +
176
            } +
177
        }
178
-
179
        return $scopes; +
179
        return $scopes;
180
    }
181
182
    /** @@ -567,7 +567,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/AccessTokenEntity.php.html b/master/Entity/AccessTokenEntity.php.html index dbc6ab04..f957bc72 100644 --- a/master/Entity/AccessTokenEntity.php.html +++ b/master/Entity/AccessTokenEntity.php.html @@ -234,13 +234,13 @@
23
     */
24
    public function getSession()
25
    { -
26
        if ($this->session instanceof SessionEntity) { -
27
            return $this->session; +
26
        if ($this->session instanceof SessionEntity) { +
27
            return $this->session;
28
        }
29
-
30
        $this->session = $this->server->getSessionStorage()->getByAccessToken($this); +
30
        $this->session = $this->server->getSessionStorage()->getByAccessToken($this);
31
-
32
        return $this->session; +
32
        return $this->session;
33
    }
34
35
    /** @@ -266,13 +266,13 @@
55
     */
56
    public function getScopes()
57
    { -
58
        if ($this->scopes === null) { -
59
            $this->scopes = $this->formatScopes( -
60
                $this->server->getAccessTokenStorage()->getScopes($this) -
61
            ); -
62
        } +
58
        if ($this->scopes === null) { +
59
            $this->scopes = $this->formatScopes( +
60
                $this->server->getAccessTokenStorage()->getScopes($this) +
61
            ); +
62
        }
63
-
64
        return $this->scopes; +
64
        return $this->scopes;
65
    }
66
67
    /** @@ -280,18 +280,18 @@
69
     */
70
    public function save()
71
    { -
72
        $this->server->getAccessTokenStorage()->create( -
73
            $this->getId(), -
74
            $this->getExpireTime(), -
75
            $this->getSession()->getId() -
76
        ); +
72
        $this->server->getAccessTokenStorage()->create( +
73
            $this->getId(), +
74
            $this->getExpireTime(), +
75
            $this->getSession()->getId() +
76
        );
77
78
        // Associate the scope with the token -
79
        foreach ($this->getScopes() as $scope) { -
80
            $this->server->getAccessTokenStorage()->associateScope($this, $scope); -
81
        } +
79
        foreach ($this->getScopes() as $scope) { +
80
            $this->server->getAccessTokenStorage()->associateScope($this, $scope); +
81
        }
82
-
83
        return $this; +
83
        return $this;
84
    }
85
86
    /** @@ -299,8 +299,8 @@
88
     */
89
    public function expire()
90
    { -
91
        $this->server->getAccessTokenStorage()->delete($this); -
92
    } +
91
        $this->server->getAccessTokenStorage()->delete($this); +
92
    }
93
} @@ -314,7 +314,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/AuthCodeEntity.php.html b/master/Entity/AuthCodeEntity.php.html index db7d91f5..372f8bb0 100644 --- a/master/Entity/AuthCodeEntity.php.html +++ b/master/Entity/AuthCodeEntity.php.html @@ -391,7 +391,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/ClientEntity.php.html b/master/Entity/ClientEntity.php.html index 827843d7..dd38ddd2 100644 --- a/master/Entity/ClientEntity.php.html +++ b/master/Entity/ClientEntity.php.html @@ -275,9 +275,9 @@
64
     */
65
    public function __construct(AbstractServer $server)
66
    { -
67
        $this->server = $server; +
67
        $this->server = $server;
68
-
69
        return $this; +
69
        return $this;
70
    }
71
72
    /** @@ -332,7 +332,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/EntityTrait.php.html b/master/Entity/EntityTrait.php.html index cc3bdebe..001073b0 100644 --- a/master/Entity/EntityTrait.php.html +++ b/master/Entity/EntityTrait.php.html @@ -149,13 +149,13 @@
22
     */
23
    public function hydrate(array $properties)
24
    { -
25
        foreach ($properties as $prop => $val) { -
26
            if (property_exists($this, $prop)) { -
27
                $this->{$prop} = $val; -
28
            } -
29
        } +
25
        foreach ($properties as $prop => $val) { +
26
            if (property_exists($this, $prop)) { +
27
                $this->{$prop} = $val; +
28
            } +
29
        }
30
-
31
        return $this; +
31
        return $this;
32
    }
33
} @@ -170,7 +170,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/RefreshTokenEntity.php.html b/master/Entity/RefreshTokenEntity.php.html index 0d8d89f0..f82c59a7 100644 --- a/master/Entity/RefreshTokenEntity.php.html +++ b/master/Entity/RefreshTokenEntity.php.html @@ -264,9 +264,9 @@
53
     */
54
    public function setAccessToken(AccessTokenEntity $accessTokenEntity)
55
    { -
56
        $this->accessTokenEntity = $accessTokenEntity; +
56
        $this->accessTokenEntity = $accessTokenEntity;
57
-
58
        return $this; +
58
        return $this;
59
    }
60
61
    /** @@ -276,11 +276,11 @@
65
     */
66
    public function getAccessToken()
67
    { -
68
        if (! $this->accessTokenEntity instanceof AccessTokenEntity) { -
69
            $this->accessTokenEntity = $this->server->getAccessTokenStorage()->get($this->accessTokenId); -
70
        } +
68
        if (! $this->accessTokenEntity instanceof AccessTokenEntity) { +
69
            $this->accessTokenEntity = $this->server->getAccessTokenStorage()->get($this->accessTokenId); +
70
        }
71
-
72
        return $this->accessTokenEntity; +
72
        return $this->accessTokenEntity;
73
    }
74
75
    /** @@ -288,20 +288,20 @@
77
     */
78
    public function save()
79
    { -
80
        $this->server->getRefreshTokenStorage()->create( -
81
            $this->getId(), -
82
            $this->getExpireTime(), -
83
            $this->getAccessToken()->getId() -
84
        ); -
85
    } +
80
        $this->server->getRefreshTokenStorage()->create( +
81
            $this->getId(), +
82
            $this->getExpireTime(), +
83
            $this->getAccessToken()->getId() +
84
        ); +
85
    }
86
87
    /**
88
     * {@inheritdoc}
89
     */
90
    public function expire()
91
    { -
92
        $this->server->getRefreshTokenStorage()->delete($this); -
93
    } +
92
        $this->server->getRefreshTokenStorage()->delete($this); +
93
    }
94
} @@ -315,7 +315,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/ScopeEntity.php.html b/master/Entity/ScopeEntity.php.html index ba4414b3..eb19c6f1 100644 --- a/master/Entity/ScopeEntity.php.html +++ b/master/Entity/ScopeEntity.php.html @@ -240,9 +240,9 @@
50
     */
51
    public function __construct(AbstractServer $server)
52
    { -
53
        $this->server = $server; +
53
        $this->server = $server;
54
-
55
        return $this; +
55
        return $this;
56
    }
57
58
    /** @@ -252,7 +252,7 @@
62
     */
63
    public function getId()
64
    { -
65
        return $this->id; +
65
        return $this->id;
66
    }
67
68
    /** @@ -290,7 +290,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/SessionEntity.php.html b/master/Entity/SessionEntity.php.html index 39545dd9..88ec023f 100644 --- a/master/Entity/SessionEntity.php.html +++ b/master/Entity/SessionEntity.php.html @@ -512,9 +512,9 @@
91
     */
92
    public function __construct(AbstractServer $server)
93
    { -
94
        $this->server = $server; +
94
        $this->server = $server;
95
-
96
        return $this; +
96
        return $this;
97
    }
98
99
    /** @@ -538,7 +538,7 @@
117
     */
118
    public function getId()
119
    { -
120
        return $this->id; +
120
        return $this->id;
121
    }
122
123
    /** @@ -580,11 +580,11 @@
159
     */
160
    public function getScopes()
161
    { -
162
        if ($this->scopes === null) { -
163
            $this->scopes = $this->formatScopes($this->server->getSessionStorage()->getScopes($this)); -
164
        } +
162
        if ($this->scopes === null) { +
163
            $this->scopes = $this->formatScopes($this->server->getSessionStorage()->getScopes($this)); +
164
        }
165
-
166
        return $this->scopes; +
166
        return $this->scopes;
167
    }
168
169
    /** @@ -596,8 +596,8 @@
175
     */
176
    private function formatScopes($unformatted = [])
177
    { -
178
        $scopes = []; -
179
        if (is_array($unformatted)) { +
178
        $scopes = []; +
179
        if (is_array($unformatted)) {
180
            foreach ($unformatted as $scope) {
181
                if ($scope instanceof ScopeEntity) {
182
                    $scopes[$scope->getId()] = $scope; @@ -605,7 +605,7 @@
184
            }
185
        }
186
-
187
        return $scopes; +
187
        return $scopes;
188
    }
189
190
    /** @@ -739,7 +739,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Entity/dashboard.html b/master/Entity/dashboard.html index 6caba93b..c8a2f5f3 100644 --- a/master/Entity/dashboard.html +++ b/master/Entity/dashboard.html @@ -143,7 +143,7 @@ diff --git a/master/Entity/index.html b/master/Entity/index.html index 7ac4db20..f96b8c00 100644 --- a/master/Entity/index.html +++ b/master/Entity/index.html @@ -305,7 +305,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Event/ClientAuthenticationFailedEvent.php.html b/master/Event/ClientAuthenticationFailedEvent.php.html index fa58c11a..d92ba42b 100644 --- a/master/Event/ClientAuthenticationFailedEvent.php.html +++ b/master/Event/ClientAuthenticationFailedEvent.php.html @@ -234,7 +234,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Event/SessionOwnerEvent.php.html b/master/Event/SessionOwnerEvent.php.html index cec641c6..62ceba20 100644 --- a/master/Event/SessionOwnerEvent.php.html +++ b/master/Event/SessionOwnerEvent.php.html @@ -234,7 +234,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Event/UserAuthenticationFailedEvent.php.html b/master/Event/UserAuthenticationFailedEvent.php.html index 3b985275..578b5294 100644 --- a/master/Event/UserAuthenticationFailedEvent.php.html +++ b/master/Event/UserAuthenticationFailedEvent.php.html @@ -234,7 +234,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Event/dashboard.html b/master/Event/dashboard.html index 3fa93add..faeae0cb 100644 --- a/master/Event/dashboard.html +++ b/master/Event/dashboard.html @@ -141,7 +141,7 @@ diff --git a/master/Event/index.html b/master/Event/index.html index a8c31cdc..730cfa84 100644 --- a/master/Event/index.html +++ b/master/Event/index.html @@ -165,7 +165,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/AccessDeniedException.php.html b/master/Exception/AccessDeniedException.php.html index a7ca85cf..526c88bf 100644 --- a/master/Exception/AccessDeniedException.php.html +++ b/master/Exception/AccessDeniedException.php.html @@ -173,7 +173,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/InvalidClientException.php.html b/master/Exception/InvalidClientException.php.html index ab363265..298e69d4 100644 --- a/master/Exception/InvalidClientException.php.html +++ b/master/Exception/InvalidClientException.php.html @@ -173,7 +173,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/InvalidCredentialsException.php.html b/master/Exception/InvalidCredentialsException.php.html index a7ca995b..1686cd32 100644 --- a/master/Exception/InvalidCredentialsException.php.html +++ b/master/Exception/InvalidCredentialsException.php.html @@ -173,7 +173,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/InvalidGrantException.php.html b/master/Exception/InvalidGrantException.php.html index 08cab443..19e6cc9d 100644 --- a/master/Exception/InvalidGrantException.php.html +++ b/master/Exception/InvalidGrantException.php.html @@ -179,7 +179,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/InvalidRefreshException.php.html b/master/Exception/InvalidRefreshException.php.html index 2beabca6..c0660d99 100644 --- a/master/Exception/InvalidRefreshException.php.html +++ b/master/Exception/InvalidRefreshException.php.html @@ -173,7 +173,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/InvalidRequestException.php.html b/master/Exception/InvalidRequestException.php.html index a52f83f9..7a857bb6 100644 --- a/master/Exception/InvalidRequestException.php.html +++ b/master/Exception/InvalidRequestException.php.html @@ -181,7 +181,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/InvalidScopeException.php.html b/master/Exception/InvalidScopeException.php.html index 4842276f..f580f189 100644 --- a/master/Exception/InvalidScopeException.php.html +++ b/master/Exception/InvalidScopeException.php.html @@ -181,7 +181,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/OAuthException.php.html b/master/Exception/OAuthException.php.html index 80409d74..be6c2872 100644 --- a/master/Exception/OAuthException.php.html +++ b/master/Exception/OAuthException.php.html @@ -330,7 +330,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/ServerErrorException.php.html b/master/Exception/ServerErrorException.php.html index 169f885e..4b924234 100644 --- a/master/Exception/ServerErrorException.php.html +++ b/master/Exception/ServerErrorException.php.html @@ -174,7 +174,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/UnauthorizedClientException.php.html b/master/Exception/UnauthorizedClientException.php.html index 3cd2b1a9..1bea15c1 100644 --- a/master/Exception/UnauthorizedClientException.php.html +++ b/master/Exception/UnauthorizedClientException.php.html @@ -173,7 +173,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/UnsupportedGrantTypeException.php.html b/master/Exception/UnsupportedGrantTypeException.php.html index d1bba7ed..026914ce 100644 --- a/master/Exception/UnsupportedGrantTypeException.php.html +++ b/master/Exception/UnsupportedGrantTypeException.php.html @@ -179,7 +179,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/UnsupportedResponseTypeException.php.html b/master/Exception/UnsupportedResponseTypeException.php.html index 76020b5e..e10650b5 100644 --- a/master/Exception/UnsupportedResponseTypeException.php.html +++ b/master/Exception/UnsupportedResponseTypeException.php.html @@ -174,7 +174,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Exception/dashboard.html b/master/Exception/dashboard.html index b500ba6f..474d3375 100644 --- a/master/Exception/dashboard.html +++ b/master/Exception/dashboard.html @@ -137,7 +137,7 @@ diff --git a/master/Exception/index.html b/master/Exception/index.html index a5a681ae..ee291ed1 100644 --- a/master/Exception/index.html +++ b/master/Exception/index.html @@ -417,7 +417,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Grant/AbstractGrant.php.html b/master/Grant/AbstractGrant.php.html index 9d6f10aa..81e5d302 100644 --- a/master/Grant/AbstractGrant.php.html +++ b/master/Grant/AbstractGrant.php.html @@ -335,7 +335,7 @@
61
     */
62
    public function getIdentifier()
63
    { -
64
        return $this->identifier; +
64
        return $this->identifier;
65
    }
66
67
    /** @@ -353,7 +353,7 @@
79
     */
80
    public function getResponseType()
81
    { -
82
        return $this->responseType; +
82
        return $this->responseType;
83
    }
84
85
    /** @@ -363,11 +363,11 @@
89
     */
90
    public function getAccessTokenTTL()
91
    { -
92
        if ($this->accessTokenTTL) { +
92
        if ($this->accessTokenTTL) {
93
            return $this->accessTokenTTL;
94
        }
95
-
96
        return $this->server->getAccessTokenTTL(); +
96
        return $this->server->getAccessTokenTTL();
97
    }
98
99
    /** @@ -389,9 +389,9 @@
115
     */
116
    public function setAuthorizationServer(AuthorizationServer $server)
117
    { -
118
        $this->server = $server; +
118
        $this->server = $server;
119
-
120
        return $this; +
120
        return $this;
121
    }
122
123
    /** @@ -408,22 +408,22 @@
134
     */
135
    public function validateScopes($scopeParam = '', ClientEntity $client, $redirectUri = null)
136
    { -
137
        $scopesList = explode($this->server->getScopeDelimiter(), $scopeParam); +
137
        $scopesList = explode($this->server->getScopeDelimiter(), $scopeParam);
138
-
139
        for ($i = 0; $i < count($scopesList); $i++) { -
140
            $scopesList[$i] = trim($scopesList[$i]); -
141
            if ($scopesList[$i] === '') { -
142
                unset($scopesList[$i]); // Remove any junk scopes -
143
            } -
144
        } +
139
        for ($i = 0; $i < count($scopesList); $i++) { +
140
            $scopesList[$i] = trim($scopesList[$i]); +
141
            if ($scopesList[$i] === '') { +
142
                unset($scopesList[$i]); // Remove any junk scopes +
143
            } +
144
        }
145
146
        if ( -
147
            $this->server->scopeParamRequired() === true -
148
            && $this->server->getDefaultScope() === null -
149
            && count($scopesList) === 0 -
150
        ) { +
147
            $this->server->scopeParamRequired() === true +
148
            && $this->server->getDefaultScope() === null +
149
            && count($scopesList) === 0 +
150
        ) {
151
            throw new Exception\InvalidRequestException('scope'); -
152
        } elseif (count($scopesList) === 0 && $this->server->getDefaultScope() !== null) { +
152
        } elseif (count($scopesList) === 0 && $this->server->getDefaultScope() !== null) {
153
            if (is_array($this->server->getDefaultScope())) {
154
                $scopesList = $this->server->getDefaultScope();
155
            } else { @@ -431,9 +431,9 @@
157
            }
158
        }
159
-
160
        $scopes = []; +
160
        $scopes = [];
161
-
162
        foreach ($scopesList as $scopeItem) { +
162
        foreach ($scopesList as $scopeItem) {
163
            $scope = $this->server->getScopeStorage()->get(
164
                $scopeItem,
165
                $this->getIdentifier(), @@ -445,9 +445,9 @@
171
            }
172
173
            $scopes[$scope->getId()] = $scope; -
174
        } +
174
        }
175
-
176
        return $scopes; +
176
        return $scopes;
177
    }
178
179
    /** @@ -459,14 +459,14 @@
185
     */
186
    protected function formatScopes($unformated = [])
187
    { -
188
        $scopes = []; -
189
        foreach ($unformated as $scope) { +
188
        $scopes = []; +
189
        foreach ($unformated as $scope) {
190
            if ($scope instanceof ScopeEntity) {
191
                $scopes[$scope->getId()] = $scope;
192
            } -
193
        } +
193
        }
194
-
195
        return $scopes; +
195
        return $scopes;
196
    }
197
} @@ -481,7 +481,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Grant/AuthCodeGrant.php.html b/master/Grant/AuthCodeGrant.php.html index 5413b1c4..ebcb6057 100644 --- a/master/Grant/AuthCodeGrant.php.html +++ b/master/Grant/AuthCodeGrant.php.html @@ -42,65 +42,65 @@ - Total -
-
- 100.00% covered (success) + Total +
+
+ 0.00% covered (danger)
-
100.00%
-
1 / 1
-
-
- 100.00% covered (success) +
0.00%
+
0 / 1
+
+
+ 83.33% covered (warning)
-
100.00%
-
4 / 4
- CRAP +
83.33%
+
5 / 6
+ CRAP
-
- 100.00% covered (success) +
+ 98.15% covered (success)
-
100.00%
-
105 / 105
+
98.15%
+
106 / 108
- AuthCodeGrant -
-
- 100.00% covered (success) + AuthCodeGrant +
+
+ 0.00% covered (danger)
-
100.00%
-
1 / 1
-
-
- 100.00% covered (success) +
0.00%
+
0 / 1
+
+
+ 83.33% covered (warning)
-
100.00%
-
4 / 4
- 25 +
83.33%
+
5 / 6
+ 28
-
- 100.00% covered (success) +
+ 98.15% covered (success)
-
100.00%
-
105 / 105
+
98.15%
+
106 / 108
-  setAuthTokenTTL +  setAuthTokenTTL
100.00% covered (success) @@ -121,7 +121,49 @@ -  checkAuthorizeParams +  setRequireClientSecret +
+
+ 0.00% covered (danger) +
+
+ +
0.00%
+
0 / 1
+ 2 +
+
+ 0.00% covered (danger) +
+
+ +
0.00%
+
0 / 2
+ + + +  shouldRequireClientSecret +
+
+ 100.00% covered (success) +
+
+ +
100.00%
+
1 / 1
+ 1 +
+
+ 100.00% covered (success) +
+
+ +
100.00%
+
1 / 1
+ + + +  checkAuthorizeParams
100.00% covered (success) @@ -142,7 +184,7 @@ -  newAuthorizeRequest +  newAuthorizeRequest
100.00% covered (success) @@ -163,7 +205,7 @@ -  completeFlow +  completeFlow
100.00% covered (success) @@ -172,7 +214,7 @@
100.00%
1 / 1
- 14 + 15
100.00% covered (success) @@ -251,217 +293,246 @@     protected $authTokenTTL = 600;     /** -      * Override the default access token expire time -      * -      * @param int $authTokenTTL -      * -      * @return void -      */ -     public function setAuthTokenTTL($authTokenTTL) -     { -         $this->authTokenTTL = $authTokenTTL; -     } - -     /** -      * Check authorize parameters -      * -      * @return array Authorize request parameters -      * -      * @throws -      */ -     public function checkAuthorizeParams() -     { -         // Get required params -         $clientId = $this->server->getRequest()->query->get('client_id', null); -         if (is_null($clientId)) { -             throw new Exception\InvalidRequestException('client_id'); -         } - -         $redirectUri = $this->server->getRequest()->query->get('redirect_uri', null); -         if (is_null($redirectUri)) { -             throw new Exception\InvalidRequestException('redirect_uri'); -         } - -         // Validate client ID and redirect URI -         $client = $this->server->getClientStorage()->get( -             $clientId, -             null, -             $redirectUri, -             $this->getIdentifier() -         ); - -         if (($client instanceof ClientEntity) === false) { -             $this->server->getEventEmitter()->emit(new Event\ClientAuthenticationFailedEvent($this->server->getRequest())); -             throw new Exception\InvalidClientException(); -         } - -         $state = $this->server->getRequest()->query->get('state', null); -         if ($this->server->stateParamRequired() === true && is_null($state)) { -             throw new Exception\InvalidRequestException('state', $redirectUri); -         } - -         $responseType = $this->server->getRequest()->query->get('response_type', null); -         if (is_null($responseType)) { -             throw new Exception\InvalidRequestException('response_type', $redirectUri); -         } - -         // Ensure response type is one that is recognised -         if (!in_array($responseType, $this->server->getResponseTypes())) { -             throw new Exception\UnsupportedResponseTypeException($responseType, $redirectUri); -         } - -         // Validate any scopes that are in the request -         $scopeParam = $this->server->getRequest()->query->get('scope', ''); -         $scopes = $this->validateScopes($scopeParam, $client, $redirectUri); - -         return [ -             'client'        => $client, -             'redirect_uri'  => $redirectUri, -             'state'         => $state, -             'response_type' => $responseType, -             'scopes'        => $scopes -         ]; -     } - -     /** -      * Parse a new authorize request -      * -      * @param string $type       The session owner's type -      * @param string $typeId     The session owner's ID -      * @param array  $authParams The authorize request $_GET parameters -      * -      * @return string An authorisation code -      */ -     public function newAuthorizeRequest($type, $typeId, $authParams = []) -     { -         // Create a new session -         $session = new SessionEntity($this->server); -         $session->setOwner($type, $typeId); -         $session->associateClient($authParams['client']); +      * Whether to require the client secret when +      * completing the flow. +      * +      * @var boolean +      */ +     protected $requireClientSecret = true; + +     /** +      * Override the default access token expire time +      * +      * @param int $authTokenTTL +      * +      * @return void +      */ +     public function setAuthTokenTTL($authTokenTTL) +     { +         $this->authTokenTTL = $authTokenTTL; +     } + +     /** +      * +      * @param bool $required True to require client secret during access +      *                       token request. False if not. Default = true +      */ +     public function setRequireClientSecret($required) +     { +         $this->requireClientSecret = $required; +     } + +     /** +      * True if client secret is required during +      * access token request. False if it isn't. +      * +      * @return bool +      */ +     public function shouldRequireClientSecret() +     { +         return $this->requireClientSecret; +     } + +     /** +      * Check authorize parameters +      * +      * @return array Authorize request parameters +      * +      * @throws +      */ +     public function checkAuthorizeParams() +     { +         // Get required params +         $clientId = $this->server->getRequest()->query->get('client_id', null); +         if (is_null($clientId)) { +             throw new Exception\InvalidRequestException('client_id'); +         } + +         $redirectUri = $this->server->getRequest()->query->get('redirect_uri', null); +         if (is_null($redirectUri)) { +             throw new Exception\InvalidRequestException('redirect_uri'); +         } + +         // Validate client ID and redirect URI +         $client = $this->server->getClientStorage()->get( +             $clientId, +             null, +             $redirectUri, +             $this->getIdentifier() +         ); + +         if (($client instanceof ClientEntity) === false) { +             $this->server->getEventEmitter()->emit(new Event\ClientAuthenticationFailedEvent($this->server->getRequest())); +             throw new Exception\InvalidClientException(); +         } + +         $state = $this->server->getRequest()->query->get('state', null); +         if ($this->server->stateParamRequired() === true && is_null($state)) { +             throw new Exception\InvalidRequestException('state', $redirectUri); +         } + +         $responseType = $this->server->getRequest()->query->get('response_type', null); +         if (is_null($responseType)) { +             throw new Exception\InvalidRequestException('response_type', $redirectUri); +         } + +         // Ensure response type is one that is recognised +         if (!in_array($responseType, $this->server->getResponseTypes())) { +             throw new Exception\UnsupportedResponseTypeException($responseType, $redirectUri); +         } -         // Create a new auth code -         $authCode = new AuthCodeEntity($this->server); -         $authCode->setId(SecureKey::generate()); -         $authCode->setRedirectUri($authParams['redirect_uri']); -         $authCode->setExpireTime(time() + $this->authTokenTTL); - -         foreach ($authParams['scopes'] as $scope) { -             $authCode->associateScope($scope); -             $session->associateScope($scope); -         } - -         $session->save(); -         $authCode->setSession($session); -         $authCode->save(); - -         return $authCode->generateRedirectUri($authParams['state']); -     } - -     /** -      * Complete the auth code grant -      * -      * @return array -      * -      * @throws -      */ -     public function completeFlow() -     { -         // Get the required params -         $clientId = $this->server->getRequest()->request->get('client_id', $this->server->getRequest()->getUser()); -         if (is_null($clientId)) { -             throw new Exception\InvalidRequestException('client_id'); -         } - -         $clientSecret = $this->server->getRequest()->request->get('client_secret', -             $this->server->getRequest()->getPassword()); -         if (is_null($clientSecret)) { -             throw new Exception\InvalidRequestException('client_secret'); -         } - -         $redirectUri = $this->server->getRequest()->request->get('redirect_uri', null); -         if (is_null($redirectUri)) { -             throw new Exception\InvalidRequestException('redirect_uri'); -         } +         // Validate any scopes that are in the request +         $scopeParam = $this->server->getRequest()->query->get('scope', ''); +         $scopes = $this->validateScopes($scopeParam, $client, $redirectUri); + +         return [ +             'client'        => $client, +             'redirect_uri'  => $redirectUri, +             'state'         => $state, +             'response_type' => $responseType, +             'scopes'        => $scopes +         ]; +     } + +     /** +      * Parse a new authorize request +      * +      * @param string $type       The session owner's type +      * @param string $typeId     The session owner's ID +      * @param array  $authParams The authorize request $_GET parameters +      * +      * @return string An authorisation code +      */ +     public function newAuthorizeRequest($type, $typeId, $authParams = []) +     { +         // Create a new session +         $session = new SessionEntity($this->server); +         $session->setOwner($type, $typeId); +         $session->associateClient($authParams['client']); + +         // Create a new auth code +         $authCode = new AuthCodeEntity($this->server); +         $authCode->setId(SecureKey::generate()); +         $authCode->setRedirectUri($authParams['redirect_uri']); +         $authCode->setExpireTime(time() + $this->authTokenTTL); + +         foreach ($authParams['scopes'] as $scope) { +             $authCode->associateScope($scope); +             $session->associateScope($scope); +         } + +         $session->save(); +         $authCode->setSession($session); +         $authCode->save(); -         // Validate client ID and client secret -         $client = $this->server->getClientStorage()->get( -             $clientId, -             $clientSecret, -             $redirectUri, -             $this->getIdentifier() -         ); - -         if (($client instanceof ClientEntity) === false) { -             $this->server->getEventEmitter()->emit(new Event\ClientAuthenticationFailedEvent($this->server->getRequest())); -             throw new Exception\InvalidClientException(); -         } - -         // Validate the auth code -         $authCode = $this->server->getRequest()->request->get('code', null); -         if (is_null($authCode)) { -             throw new Exception\InvalidRequestException('code'); -         } - -         $code = $this->server->getAuthCodeStorage()->get($authCode); -         if (($code instanceof AuthCodeEntity) === false) { -             throw new Exception\InvalidRequestException('code'); +         return $authCode->generateRedirectUri($authParams['state']); +     } + +     /** +      * Complete the auth code grant +      * +      * @return array +      * +      * @throws +      */ +     public function completeFlow() +     { +         // Get the required params +         $clientId = $this->server->getRequest()->request->get('client_id', $this->server->getRequest()->getUser()); +         if (is_null($clientId)) { +             throw new Exception\InvalidRequestException('client_id'); +         } + +         $clientSecret = $this->server->getRequest()->request->get('client_secret', +             $this->server->getRequest()->getPassword()); +         if ($this->shouldRequireClientSecret() && is_null($clientSecret)) { +             throw new Exception\InvalidRequestException('client_secret');         } -         // Ensure the auth code hasn't expired -         if ($code->isExpired() === true) { -             throw new Exception\InvalidRequestException('code'); +         $redirectUri = $this->server->getRequest()->request->get('redirect_uri', null); +         if (is_null($redirectUri)) { +             throw new Exception\InvalidRequestException('redirect_uri');         } -         // Check redirect URI presented matches redirect URI originally used in authorize request -         if ($code->getRedirectUri() !== $redirectUri) { -             throw new Exception\InvalidRequestException('redirect_uri'); -         } - -         $session = $code->getSession(); -         $session->associateClient($client); +         // Validate client ID and client secret +         $client = $this->server->getClientStorage()->get( +             $clientId, +             $clientSecret, +             $redirectUri, +             $this->getIdentifier() +         ); -         $authCodeScopes = $code->getScopes(); - -         // Generate the access token -         $accessToken = new AccessTokenEntity($this->server); -         $accessToken->setId(SecureKey::generate()); -         $accessToken->setExpireTime($this->getAccessTokenTTL() + time()); - -         foreach ($authCodeScopes as $authCodeScope) { -             $session->associateScope($authCodeScope); -         } +         if (($client instanceof ClientEntity) === false) { +             $this->server->getEventEmitter()->emit(new Event\ClientAuthenticationFailedEvent($this->server->getRequest())); +             throw new Exception\InvalidClientException(); +         } + +         // Validate the auth code +         $authCode = $this->server->getRequest()->request->get('code', null); +         if (is_null($authCode)) { +             throw new Exception\InvalidRequestException('code'); +         } -         foreach ($session->getScopes() as $scope) { -             $accessToken->associateScope($scope); -         } - -         $this->server->getTokenType()->setSession($session); -         $this->server->getTokenType()->setParam('access_token', $accessToken->getId()); -         $this->server->getTokenType()->setParam('expires_in', $this->getAccessTokenTTL()); - -         // Associate a refresh token if set -         if ($this->server->hasGrantType('refresh_token')) { -             $refreshToken = new RefreshTokenEntity($this->server); -             $refreshToken->setId(SecureKey::generate()); -             $refreshToken->setExpireTime($this->server->getGrantType('refresh_token')->getRefreshTokenTTL() + time()); -             $this->server->getTokenType()->setParam('refresh_token', $refreshToken->getId()); -         } - -         // Expire the auth code -         $code->expire(); - -         // Save all the things -         $accessToken->setSession($session); -         $accessToken->save(); - -         if (isset($refreshToken) && $this->server->hasGrantType('refresh_token')) { -             $refreshToken->setAccessToken($accessToken); -             $refreshToken->save(); -         } - -         return $this->server->getTokenType()->generateResponse(); -     } - } +         $code = $this->server->getAuthCodeStorage()->get($authCode); +         if (($code instanceof AuthCodeEntity) === false) { +             throw new Exception\InvalidRequestException('code'); +         } + +         // Ensure the auth code hasn't expired +         if ($code->isExpired() === true) { +             throw new Exception\InvalidRequestException('code'); +         } + +         // Check redirect URI presented matches redirect URI originally used in authorize request +         if ($code->getRedirectUri() !== $redirectUri) { +             throw new Exception\InvalidRequestException('redirect_uri'); +         } + +         $session = $code->getSession(); +         $session->associateClient($client); + +         $authCodeScopes = $code->getScopes(); + +         // Generate the access token +         $accessToken = new AccessTokenEntity($this->server); +         $accessToken->setId(SecureKey::generate()); +         $accessToken->setExpireTime($this->getAccessTokenTTL() + time()); + +         foreach ($authCodeScopes as $authCodeScope) { +             $session->associateScope($authCodeScope); +         } + +         foreach ($session->getScopes() as $scope) { +             $accessToken->associateScope($scope); +         } + +         $this->server->getTokenType()->setSession($session); +         $this->server->getTokenType()->setParam('access_token', $accessToken->getId()); +         $this->server->getTokenType()->setParam('expires_in', $this->getAccessTokenTTL()); + +         // Associate a refresh token if set +         if ($this->server->hasGrantType('refresh_token')) { +             $refreshToken = new RefreshTokenEntity($this->server); +             $refreshToken->setId(SecureKey::generate()); +             $refreshToken->setExpireTime($this->server->getGrantType('refresh_token')->getRefreshTokenTTL() + time()); +             $this->server->getTokenType()->setParam('refresh_token', $refreshToken->getId()); +         } + +         // Expire the auth code +         $code->expire(); + +         // Save all the things +         $accessToken->setSession($session); +         $accessToken->save(); + +         if (isset($refreshToken) && $this->server->hasGrantType('refresh_token')) { +             $refreshToken->setAccessToken($accessToken); +             $refreshToken->save(); +         } + +         return $this->server->getTokenType()->generateResponse(); +     } + } @@ -474,7 +545,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Grant/ClientCredentialsGrant.php.html b/master/Grant/ClientCredentialsGrant.php.html index f08be3fd..13d9e20c 100644 --- a/master/Grant/ClientCredentialsGrant.php.html +++ b/master/Grant/ClientCredentialsGrant.php.html @@ -259,7 +259,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Grant/GrantTypeInterface.php.html b/master/Grant/GrantTypeInterface.php.html index c58f86ba..a8670e91 100644 --- a/master/Grant/GrantTypeInterface.php.html +++ b/master/Grant/GrantTypeInterface.php.html @@ -131,7 +131,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Grant/PasswordGrant.php.html b/master/Grant/PasswordGrant.php.html index e1f27a42..c9b3e9a4 100644 --- a/master/Grant/PasswordGrant.php.html +++ b/master/Grant/PasswordGrant.php.html @@ -361,7 +361,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Grant/RefreshTokenGrant.php.html b/master/Grant/RefreshTokenGrant.php.html index 7c394522..06408d29 100644 --- a/master/Grant/RefreshTokenGrant.php.html +++ b/master/Grant/RefreshTokenGrant.php.html @@ -58,7 +58,7 @@
100.00%
-
5 / 5
+
7 / 7
CRAP
@@ -67,7 +67,7 @@
100.00%
-
66 / 66
+
69 / 69
@@ -87,8 +87,8 @@
100.00%
-
5 / 5
- 16 +
7 / 7
+ 19
100.00% covered (success) @@ -96,11 +96,11 @@
100.00%
-
66 / 66
+
69 / 69
-  setRefreshTokenTTL +  setRefreshTokenTTL
100.00% covered (success) @@ -121,7 +121,7 @@ -  getRefreshTokenTTL +  getRefreshTokenTTL
100.00% covered (success) @@ -142,7 +142,7 @@ -  setRefreshTokenRotation +  setRefreshTokenRotation
100.00% covered (success) @@ -163,7 +163,7 @@ -  shouldRotateRefreshTokens +  shouldRotateRefreshTokens
100.00% covered (success) @@ -184,7 +184,7 @@ -  completeFlow +  setRequireClientSecret
100.00% covered (success) @@ -193,7 +193,49 @@
100.00%
1 / 1
- 12 + 1 +
+
+ 100.00% covered (success) +
+
+ +
100.00%
+
2 / 2
+ + + +  shouldRequireClientSecret +
+
+ 100.00% covered (success) +
+
+ +
100.00%
+
1 / 1
+ 1 +
+
+ 100.00% covered (success) +
+
+ +
100.00%
+
1 / 1
+ + + +  completeFlow +
+
+ 100.00% covered (success) +
+
+ +
100.00%
+
1 / 1
+ 13
100.00% covered (success) @@ -254,154 +296,184 @@     protected $refreshTokenRotate = true;     /** -      * Set the TTL of the refresh token -      * -      * @param int $refreshTokenTTL -      * -      * @return void -      */ -     public function setRefreshTokenTTL($refreshTokenTTL) -     { -         $this->refreshTokenTTL = $refreshTokenTTL; -     } - -     /** -      * Get the TTL of the refresh token -      * -      * @return int -      */ -     public function getRefreshTokenTTL() -     { -         return $this->refreshTokenTTL; -     } - -     /** -      * Set the rotation boolean of the refresh token -      * @param bool $refreshTokenRotate -      */ -     public function setRefreshTokenRotation($refreshTokenRotate = true) -     { -         $this->refreshTokenRotate = $refreshTokenRotate; -     } - -     /** -      * Get rotation boolean of the refresh token -      * -      * @return bool -      */ -     public function shouldRotateRefreshTokens() -     { -         return $this->refreshTokenRotate; -     } - -     /** -      * {@inheritdoc} +      * Whether to require the client secret when +      * completing the flow. +      * +      * @var boolean +      */ +     protected $requireClientSecret = true; + +     /** +      * Set the TTL of the refresh token +      * +      * @param int $refreshTokenTTL +      * +      * @return void +      */ +     public function setRefreshTokenTTL($refreshTokenTTL) +     { +         $this->refreshTokenTTL = $refreshTokenTTL; +     } + +     /** +      * Get the TTL of the refresh token +      * +      * @return int +      */ +     public function getRefreshTokenTTL() +     { +         return $this->refreshTokenTTL; +     } + +     /** +      * Set the rotation boolean of the refresh token +      * @param bool $refreshTokenRotate +      */ +     public function setRefreshTokenRotation($refreshTokenRotate = true) +     { +         $this->refreshTokenRotate = $refreshTokenRotate; +     } + +     /** +      * Get rotation boolean of the refresh token +      * +      * @return bool      */ -     public function completeFlow() +     public function shouldRotateRefreshTokens()     { -         $clientId = $this->server->getRequest()->request->get('client_id', $this->server->getRequest()->getUser()); -         if (is_null($clientId)) { -             throw new Exception\InvalidRequestException('client_id'); -         } - -         $clientSecret = $this->server->getRequest()->request->get('client_secret', -             $this->server->getRequest()->getPassword()); -         if (is_null($clientSecret)) { -             throw new Exception\InvalidRequestException('client_secret'); -         } - -         // Validate client ID and client secret -         $client = $this->server->getClientStorage()->get( -             $clientId, -             $clientSecret, -             null, -             $this->getIdentifier() -         ); - -         if (($client instanceof ClientEntity) === false) { -             $this->server->getEventEmitter()->emit(new Event\ClientAuthenticationFailedEvent($this->server->getRequest())); -             throw new Exception\InvalidClientException(); -         } +         return $this->refreshTokenRotate; +     } + +     /** +      * +      * @param bool $required True to require client secret during access +      *                       token request. False if not. Default = true +      */ +     public function setRequireClientSecret($required) +     { +         $this->requireClientSecret = $required; +     } + +     /** +      * True if client secret is required during +      * access token request. False if it isn't. +      * +      * @return bool +      */ +     public function shouldRequireClientSecret() +     { +         return $this->requireClientSecret; +     } -         $oldRefreshTokenParam = $this->server->getRequest()->request->get('refresh_token', null); -         if ($oldRefreshTokenParam === null) { -             throw new Exception\InvalidRequestException('refresh_token'); -         } - -         // Validate refresh token -         $oldRefreshToken = $this->server->getRefreshTokenStorage()->get($oldRefreshTokenParam); - -         if (($oldRefreshToken instanceof RefreshTokenEntity) === false) { -             throw new Exception\InvalidRefreshException(); -         } - -         // Ensure the old refresh token hasn't expired -         if ($oldRefreshToken->isExpired() === true) { -             throw new Exception\InvalidRefreshException(); + +     /** +      * {@inheritdoc} +      */ +     public function completeFlow() +     { +         $clientId = $this->server->getRequest()->request->get('client_id', $this->server->getRequest()->getUser()); +         if (is_null($clientId)) { +             throw new Exception\InvalidRequestException('client_id'); +         } + +         $clientSecret = $this->server->getRequest()->request->get('client_secret', +             $this->server->getRequest()->getPassword()); +         if ($this->shouldRequireClientSecret() && is_null($clientSecret)) { +             throw new Exception\InvalidRequestException('client_secret');         } -         $oldAccessToken = $oldRefreshToken->getAccessToken(); - -         // Get the scopes for the original session -         $session = $oldAccessToken->getSession(); -         $scopes = $this->formatScopes($session->getScopes()); - -         // Get and validate any requested scopes -         $requestedScopesString = $this->server->getRequest()->request->get('scope', ''); -         $requestedScopes = $this->validateScopes($requestedScopesString, $client); - -         // If no new scopes are requested then give the access token the original session scopes -         if (count($requestedScopes) === 0) { -             $newScopes = $scopes; -         } else { -             // The OAuth spec says that a refreshed access token can have the original scopes or fewer so ensure -             //  the request doesn't include any new scopes -             foreach ($requestedScopes as $requestedScope) { -                 if (!isset($scopes[$requestedScope->getId()])) { -                     throw new Exception\InvalidScopeException($requestedScope->getId()); -                 } -             } - -             $newScopes = $requestedScopes; -         } +         // Validate client ID and client secret +         $client = $this->server->getClientStorage()->get( +             $clientId, +             $clientSecret, +             null, +             $this->getIdentifier() +         ); + +         if (($client instanceof ClientEntity) === false) { +             $this->server->getEventEmitter()->emit(new Event\ClientAuthenticationFailedEvent($this->server->getRequest())); +             throw new Exception\InvalidClientException(); +         } + +         $oldRefreshTokenParam = $this->server->getRequest()->request->get('refresh_token', null); +         if ($oldRefreshTokenParam === null) { +             throw new Exception\InvalidRequestException('refresh_token'); +         } + +         // Validate refresh token +         $oldRefreshToken = $this->server->getRefreshTokenStorage()->get($oldRefreshTokenParam); + +         if (($oldRefreshToken instanceof RefreshTokenEntity) === false) { +             throw new Exception\InvalidRefreshException(); +         } -         // Generate a new access token and assign it the correct sessions -         $newAccessToken = new AccessTokenEntity($this->server); -         $newAccessToken->setId(SecureKey::generate()); -         $newAccessToken->setExpireTime($this->getAccessTokenTTL() + time()); -         $newAccessToken->setSession($session); - -         foreach ($newScopes as $newScope) { -             $newAccessToken->associateScope($newScope); -         } - -         // Expire the old token and save the new one -         $oldAccessToken->expire(); -         $newAccessToken->save(); - -         $this->server->getTokenType()->setSession($session); -         $this->server->getTokenType()->setParam('access_token', $newAccessToken->getId()); -         $this->server->getTokenType()->setParam('expires_in', $this->getAccessTokenTTL()); - -         if ($this->shouldRotateRefreshTokens()) { -             // Expire the old refresh token -             $oldRefreshToken->expire(); - -             // Generate a new refresh token -             $newRefreshToken = new RefreshTokenEntity($this->server); -             $newRefreshToken->setId(SecureKey::generate()); -             $newRefreshToken->setExpireTime($this->getRefreshTokenTTL() + time()); -             $newRefreshToken->setAccessToken($newAccessToken); -             $newRefreshToken->save(); - -             $this->server->getTokenType()->setParam('refresh_token', $newRefreshToken->getId()); -         } else { -             $this->server->getTokenType()->setParam('refresh_token', $oldRefreshToken->getId()); -         } - -         return $this->server->getTokenType()->generateResponse(); -     } - } +         // Ensure the old refresh token hasn't expired +         if ($oldRefreshToken->isExpired() === true) { +             throw new Exception\InvalidRefreshException(); +         } + +         $oldAccessToken = $oldRefreshToken->getAccessToken(); + +         // Get the scopes for the original session +         $session = $oldAccessToken->getSession(); +         $scopes = $this->formatScopes($session->getScopes()); + +         // Get and validate any requested scopes +         $requestedScopesString = $this->server->getRequest()->request->get('scope', ''); +         $requestedScopes = $this->validateScopes($requestedScopesString, $client); + +         // If no new scopes are requested then give the access token the original session scopes +         if (count($requestedScopes) === 0) { +             $newScopes = $scopes; +         } else { +             // The OAuth spec says that a refreshed access token can have the original scopes or fewer so ensure +             //  the request doesn't include any new scopes +             foreach ($requestedScopes as $requestedScope) { +                 if (!isset($scopes[$requestedScope->getId()])) { +                     throw new Exception\InvalidScopeException($requestedScope->getId()); +                 } +             } + +             $newScopes = $requestedScopes; +         } + +         // Generate a new access token and assign it the correct sessions +         $newAccessToken = new AccessTokenEntity($this->server); +         $newAccessToken->setId(SecureKey::generate()); +         $newAccessToken->setExpireTime($this->getAccessTokenTTL() + time()); +         $newAccessToken->setSession($session); + +         foreach ($newScopes as $newScope) { +             $newAccessToken->associateScope($newScope); +         } + +         // Expire the old token and save the new one +         $oldAccessToken->expire(); +         $newAccessToken->save(); + +         $this->server->getTokenType()->setSession($session); +         $this->server->getTokenType()->setParam('access_token', $newAccessToken->getId()); +         $this->server->getTokenType()->setParam('expires_in', $this->getAccessTokenTTL()); + +         if ($this->shouldRotateRefreshTokens()) { +             // Expire the old refresh token +             $oldRefreshToken->expire(); + +             // Generate a new refresh token +             $newRefreshToken = new RefreshTokenEntity($this->server); +             $newRefreshToken->setId(SecureKey::generate()); +             $newRefreshToken->setExpireTime($this->getRefreshTokenTTL() + time()); +             $newRefreshToken->setAccessToken($newAccessToken); +             $newRefreshToken->save(); + +             $this->server->getTokenType()->setParam('refresh_token', $newRefreshToken->getId()); +         } else { +             $this->server->getTokenType()->setParam('refresh_token', $oldRefreshToken->getId()); +         } + +         return $this->server->getTokenType()->generateResponse(); +     } + } @@ -414,7 +486,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Grant/dashboard.html b/master/Grant/dashboard.html index 5081db2b..c21b328a 100644 --- a/master/Grant/dashboard.html +++ b/master/Grant/dashboard.html @@ -112,6 +112,7 @@ + setRequireClientSecret0% @@ -137,7 +138,7 @@
@@ -158,7 +159,7 @@ $(document).ready(function() { .yAxis.tickFormat(d3.format('d')); d3.select('#classCoverageDistribution svg') - .datum(getCoverageDistributionData([0,0,0,0,0,0,0,0,0,0,0,5], "Class Coverage")) + .datum(getCoverageDistributionData([0,0,0,0,0,0,0,0,0,0,1,4], "Class Coverage")) .transition().duration(500).call(chart); nv.utils.windowResize(chart.update); @@ -176,7 +177,7 @@ $(document).ready(function() { .yAxis.tickFormat(d3.format('d')); d3.select('#methodCoverageDistribution svg') - .datum(getCoverageDistributionData([0,0,0,0,0,0,0,0,0,0,0,21], "Method Coverage")) + .datum(getCoverageDistributionData([1,0,0,0,0,0,0,0,0,0,0,24], "Method Coverage")) .transition().duration(500).call(chart); nv.utils.windowResize(chart.update); @@ -226,7 +227,7 @@ $(document).ready(function() { chart.yAxis.axisLabel('Cyclomatic Complexity'); d3.select('#classComplexity svg') - .datum(getComplexityData([[100,21,"AbstractGrant<\/a>"],[100,25,"AuthCodeGrant<\/a>"],[100,6,"ClientCredentialsGrant<\/a>"],[100,15,"PasswordGrant<\/a>"],[100,16,"RefreshTokenGrant<\/a>"]], 'Class Complexity')) + .datum(getComplexityData([[100,21,"AbstractGrant<\/a>"],[98.148148148148,28,"AuthCodeGrant<\/a>"],[100,6,"ClientCredentialsGrant<\/a>"],[100,15,"PasswordGrant<\/a>"],[100,19,"RefreshTokenGrant<\/a>"]], 'Class Complexity')) .transition() .duration(500) .call(chart); @@ -250,7 +251,7 @@ $(document).ready(function() { chart.yAxis.axisLabel('Method Complexity'); d3.select('#methodComplexity svg') - .datum(getComplexityData([[100,1,"AbstractGrant::getIdentifier<\/a>"],[100,1,"AbstractGrant::setIdentifier<\/a>"],[100,1,"AbstractGrant::getResponseType<\/a>"],[100,2,"AbstractGrant::getAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAuthorizationServer<\/a>"],[100,11,"AbstractGrant::validateScopes<\/a>"],[100,3,"AbstractGrant::formatScopes<\/a>"],[100,1,"AuthCodeGrant::setAuthTokenTTL<\/a>"],[100,8,"AuthCodeGrant::checkAuthorizeParams<\/a>"],[100,2,"AuthCodeGrant::newAuthorizeRequest<\/a>"],[100,14,"AuthCodeGrant::completeFlow<\/a>"],[100,6,"ClientCredentialsGrant::completeFlow<\/a>"],[100,1,"PasswordGrant::setVerifyCredentialsCallback<\/a>"],[100,3,"PasswordGrant::getVerifyCredentialsCallback<\/a>"],[100,11,"PasswordGrant::completeFlow<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::getRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenRotation<\/a>"],[100,1,"RefreshTokenGrant::shouldRotateRefreshTokens<\/a>"],[100,12,"RefreshTokenGrant::completeFlow<\/a>"]], 'Method Complexity')) + .datum(getComplexityData([[100,1,"AbstractGrant::getIdentifier<\/a>"],[100,1,"AbstractGrant::setIdentifier<\/a>"],[100,1,"AbstractGrant::getResponseType<\/a>"],[100,2,"AbstractGrant::getAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAuthorizationServer<\/a>"],[100,11,"AbstractGrant::validateScopes<\/a>"],[100,3,"AbstractGrant::formatScopes<\/a>"],[100,1,"AuthCodeGrant::setAuthTokenTTL<\/a>"],[0,1,"AuthCodeGrant::setRequireClientSecret<\/a>"],[100,1,"AuthCodeGrant::shouldRequireClientSecret<\/a>"],[100,8,"AuthCodeGrant::checkAuthorizeParams<\/a>"],[100,2,"AuthCodeGrant::newAuthorizeRequest<\/a>"],[100,15,"AuthCodeGrant::completeFlow<\/a>"],[100,6,"ClientCredentialsGrant::completeFlow<\/a>"],[100,1,"PasswordGrant::setVerifyCredentialsCallback<\/a>"],[100,3,"PasswordGrant::getVerifyCredentialsCallback<\/a>"],[100,11,"PasswordGrant::completeFlow<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::getRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenRotation<\/a>"],[100,1,"RefreshTokenGrant::shouldRotateRefreshTokens<\/a>"],[100,1,"RefreshTokenGrant::setRequireClientSecret<\/a>"],[100,1,"RefreshTokenGrant::shouldRequireClientSecret<\/a>"],[100,13,"RefreshTokenGrant::completeFlow<\/a>"]], 'Method Complexity')) .transition() .duration(500) .call(chart); diff --git a/master/Grant/index.html b/master/Grant/index.html index 24315cbd..428ce17a 100644 --- a/master/Grant/index.html +++ b/master/Grant/index.html @@ -44,29 +44,29 @@ Total
-
- 100.00% covered (success) +
+ 99.38% covered (success)
-
100.00%
-
318 / 318
+
99.38%
+
322 / 324
-
- 100.00% covered (success) +
+ 96.00% covered (success)
-
100.00%
-
21 / 21
-
-
- 100.00% covered (success) +
96.00%
+
24 / 25
+
+
+ 80.00% covered (warning)
-
100.00%
-
5 / 5
+
80.00%
+
4 / 5
@@ -100,29 +100,29 @@
AuthCodeGrant.php
-
- 100.00% covered (success) +
+ 98.15% covered (success)
-
100.00%
-
105 / 105
-
-
- 100.00% covered (success) +
98.15%
+
106 / 108
+
+
+ 83.33% covered (warning)
-
100.00%
-
4 / 4
-
-
- 100.00% covered (success) +
83.33%
+
5 / 6
+
+
+ 0.00% covered (danger)
-
100.00%
-
1 / 1
+
0.00%
+
0 / 1
@@ -203,7 +203,7 @@
100.00%
-
66 / 66
+
69 / 69
100.00% covered (success) @@ -211,7 +211,7 @@
100.00%
-
5 / 5
+
7 / 7
100.00% covered (success) @@ -234,7 +234,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/ResourceServer.php.html b/master/ResourceServer.php.html index 6aa65229..8ac2c5f5 100644 --- a/master/ResourceServer.php.html +++ b/master/ResourceServer.php.html @@ -380,7 +380,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/AbstractStorage.php.html b/master/Storage/AbstractStorage.php.html index 5e0194e1..2b06416e 100644 --- a/master/Storage/AbstractStorage.php.html +++ b/master/Storage/AbstractStorage.php.html @@ -209,7 +209,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/AccessTokenInterface.php.html b/master/Storage/AccessTokenInterface.php.html index c6b1ed17..0e523bec 100644 --- a/master/Storage/AccessTokenInterface.php.html +++ b/master/Storage/AccessTokenInterface.php.html @@ -141,7 +141,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/AuthCodeInterface.php.html b/master/Storage/AuthCodeInterface.php.html index 8453daf9..f17d378c 100644 --- a/master/Storage/AuthCodeInterface.php.html +++ b/master/Storage/AuthCodeInterface.php.html @@ -142,7 +142,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/ClientInterface.php.html b/master/Storage/ClientInterface.php.html index 112966ca..35c5d082 100644 --- a/master/Storage/ClientInterface.php.html +++ b/master/Storage/ClientInterface.php.html @@ -113,7 +113,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/MacTokenInterface.php.html b/master/Storage/MacTokenInterface.php.html index 687d4188..24185daf 100644 --- a/master/Storage/MacTokenInterface.php.html +++ b/master/Storage/MacTokenInterface.php.html @@ -106,7 +106,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/RefreshTokenInterface.php.html b/master/Storage/RefreshTokenInterface.php.html index aa65141c..e2581293 100644 --- a/master/Storage/RefreshTokenInterface.php.html +++ b/master/Storage/RefreshTokenInterface.php.html @@ -121,7 +121,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/ScopeInterface.php.html b/master/Storage/ScopeInterface.php.html index eef08590..735c5eec 100644 --- a/master/Storage/ScopeInterface.php.html +++ b/master/Storage/ScopeInterface.php.html @@ -101,7 +101,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/SessionInterface.php.html b/master/Storage/SessionInterface.php.html index c16dca19..07e36f97 100644 --- a/master/Storage/SessionInterface.php.html +++ b/master/Storage/SessionInterface.php.html @@ -144,7 +144,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/StorageInterface.php.html b/master/Storage/StorageInterface.php.html index b4601da5..702e9bf8 100644 --- a/master/Storage/StorageInterface.php.html +++ b/master/Storage/StorageInterface.php.html @@ -99,7 +99,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Storage/dashboard.html b/master/Storage/dashboard.html index d0e4bdcf..711f6086 100644 --- a/master/Storage/dashboard.html +++ b/master/Storage/dashboard.html @@ -137,7 +137,7 @@
diff --git a/master/Storage/index.html b/master/Storage/index.html index 05287a81..d305f78b 100644 --- a/master/Storage/index.html +++ b/master/Storage/index.html @@ -213,7 +213,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/TokenType/AbstractTokenType.php.html b/master/TokenType/AbstractTokenType.php.html index 1c0de3a5..a5fd98db 100644 --- a/master/TokenType/AbstractTokenType.php.html +++ b/master/TokenType/AbstractTokenType.php.html @@ -232,9 +232,9 @@      */     public function setServer(AbstractServer $server)     { -         $this->server = $server; +         $this->server = $server; -         return $this; +         return $this;     }     /** @@ -242,9 +242,9 @@      */     public function setSession(SessionEntity $session)     { -         $this->session = $session; +         $this->session = $session; -         return $this; +         return $this;     }     /** @@ -252,15 +252,15 @@      */     public function setParam($key, $value)     { -         $this->response[$key] = $value; -     } +         $this->response[$key] = $value; +     }     /**      * {@inheritdoc}      */     public function getParam($key)     { -         return isset($this->response[$key]) ? $this->response[$key] : null; +         return isset($this->response[$key]) ? $this->response[$key] : null;     } } @@ -275,7 +275,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/TokenType/Bearer.php.html b/master/TokenType/Bearer.php.html index adba39d0..5d31d645 100644 --- a/master/TokenType/Bearer.php.html +++ b/master/TokenType/Bearer.php.html @@ -169,16 +169,16 @@     public function generateResponse()     {         $return = [ -             'access_token'  =>  $this->getParam('access_token'), -             'token_type'    =>  'Bearer', -             'expires_in'    =>  $this->getParam('expires_in'), -         ]; +             'access_token'  =>  $this->getParam('access_token'), +             'token_type'    =>  'Bearer', +             'expires_in'    =>  $this->getParam('expires_in'), +         ]; -         if (!is_null($this->getParam('refresh_token'))) { -             $return['refresh_token'] = $this->getParam('refresh_token'); -         } +         if (!is_null($this->getParam('refresh_token'))) { +             $return['refresh_token'] = $this->getParam('refresh_token'); +         } -         return $return; +         return $return;     }     /** @@ -211,7 +211,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/TokenType/MAC.php.html b/master/TokenType/MAC.php.html index 0d5d7525..424693e3 100644 --- a/master/TokenType/MAC.php.html +++ b/master/TokenType/MAC.php.html @@ -349,7 +349,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/TokenType/TokenTypeInterface.php.html b/master/TokenType/TokenTypeInterface.php.html index aa0ab9a7..37f30943 100644 --- a/master/TokenType/TokenTypeInterface.php.html +++ b/master/TokenType/TokenTypeInterface.php.html @@ -140,7 +140,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/TokenType/dashboard.html b/master/TokenType/dashboard.html index 7204f1c1..47863b73 100644 --- a/master/TokenType/dashboard.html +++ b/master/TokenType/dashboard.html @@ -143,7 +143,7 @@
diff --git a/master/TokenType/index.html b/master/TokenType/index.html index c46aa30e..19b42e04 100644 --- a/master/TokenType/index.html +++ b/master/TokenType/index.html @@ -178,7 +178,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Util/KeyAlgorithm/DefaultAlgorithm.php.html b/master/Util/KeyAlgorithm/DefaultAlgorithm.php.html index 7b51ea85..047249b6 100644 --- a/master/Util/KeyAlgorithm/DefaultAlgorithm.php.html +++ b/master/Util/KeyAlgorithm/DefaultAlgorithm.php.html @@ -146,20 +146,20 @@      */     public function generate($len = 40)     { -         $stripped = ''; +         $stripped = '';         do { -             $bytes = openssl_random_pseudo_bytes($len, $strong); +             $bytes = openssl_random_pseudo_bytes($len, $strong);             // We want to stop execution if the key fails because, well, that is bad. -             if ($bytes === false || $strong === false) { +             if ($bytes === false || $strong === false) {                 // @codeCoverageIgnoreStart                 throw new \Exception('Error Generating Key');                 // @codeCoverageIgnoreEnd             } -             $stripped .= str_replace(['/', '+', '='], '', base64_encode($bytes)); -         } while (strlen($stripped) < $len); +             $stripped .= str_replace(['/', '+', '='], '', base64_encode($bytes)); +         } while (strlen($stripped) < $len); -         return substr($stripped, 0, $len); +         return substr($stripped, 0, $len);     } } @@ -174,7 +174,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Util/KeyAlgorithm/KeyAlgorithmInterface.php.html b/master/Util/KeyAlgorithm/KeyAlgorithmInterface.php.html index 064538c3..e33f17af 100644 --- a/master/Util/KeyAlgorithm/KeyAlgorithmInterface.php.html +++ b/master/Util/KeyAlgorithm/KeyAlgorithmInterface.php.html @@ -97,7 +97,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Util/KeyAlgorithm/dashboard.html b/master/Util/KeyAlgorithm/dashboard.html index 2aafa7a2..1f0ef85a 100644 --- a/master/Util/KeyAlgorithm/dashboard.html +++ b/master/Util/KeyAlgorithm/dashboard.html @@ -138,7 +138,7 @@
diff --git a/master/Util/KeyAlgorithm/index.html b/master/Util/KeyAlgorithm/index.html index ad676b59..d5ab321b 100644 --- a/master/Util/KeyAlgorithm/index.html +++ b/master/Util/KeyAlgorithm/index.html @@ -123,7 +123,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Util/RedirectUri.php.html b/master/Util/RedirectUri.php.html index d7973714..3adfc36c 100644 --- a/master/Util/RedirectUri.php.html +++ b/master/Util/RedirectUri.php.html @@ -171,7 +171,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Util/SecureKey.php.html b/master/Util/SecureKey.php.html index 4fd6da01..33fb5510 100644 --- a/master/Util/SecureKey.php.html +++ b/master/Util/SecureKey.php.html @@ -199,7 +199,7 @@      */     public static function generate($len = 40)     { -         return self::getAlgorithm()->generate($len); +         return self::getAlgorithm()->generate($len);     }     /** @@ -215,11 +215,11 @@      */     public static function getAlgorithm()     { -         if (is_null(self::$algorithm)) { +         if (is_null(self::$algorithm)) {             self::$algorithm = new DefaultAlgorithm();         } -         return self::$algorithm; +         return self::$algorithm;     } } @@ -234,7 +234,7 @@ Dead Code

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/Util/dashboard.html b/master/Util/dashboard.html index 7ab3dc34..b6e47aba 100644 --- a/master/Util/dashboard.html +++ b/master/Util/dashboard.html @@ -137,7 +137,7 @@
diff --git a/master/Util/index.html b/master/Util/index.html index 72d1711e..f5335de8 100644 --- a/master/Util/index.html +++ b/master/Util/index.html @@ -165,7 +165,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.

diff --git a/master/dashboard.html b/master/dashboard.html index b0323894..502dd0e6 100644 --- a/master/dashboard.html +++ b/master/dashboard.html @@ -117,8 +117,9 @@ - getRequest0% + setRequireClientSecret0% getRequest0% + getRequest0% hasScope0% determineAccessTokenInHeader66% generateResponse83% @@ -152,7 +153,7 @@
@@ -173,7 +174,7 @@ $(document).ready(function() { .yAxis.tickFormat(d3.format('d')); d3.select('#classCoverageDistribution svg') - .datum(getCoverageDistributionData([0,0,0,0,0,0,0,0,2,2,2,32], "Class Coverage")) + .datum(getCoverageDistributionData([0,0,0,0,0,0,0,0,2,2,3,31], "Class Coverage")) .transition().duration(500).call(chart); nv.utils.windowResize(chart.update); @@ -191,7 +192,7 @@ $(document).ready(function() { .yAxis.tickFormat(d3.format('d')); d3.select('#methodCoverageDistribution svg') - .datum(getCoverageDistributionData([3,0,0,0,0,0,0,1,0,2,1,152], "Method Coverage")) + .datum(getCoverageDistributionData([4,0,0,0,0,0,0,1,0,2,1,155], "Method Coverage")) .transition().duration(500).call(chart); nv.utils.windowResize(chart.update); @@ -241,7 +242,7 @@ $(document).ready(function() { chart.yAxis.axisLabel('Cyclomatic Complexity'); d3.select('#classComplexity svg') - .datum(getComplexityData([[100,24,"AbstractServer<\/a>"],[100,21,"AuthorizationServer<\/a>"],[96.296296296296,18,"AbstractTokenEntity<\/a>"],[84,9,"AccessTokenEntity<\/a>"],[100,11,"AuthCodeEntity<\/a>"],[100,5,"ClientEntity<\/a>"],[100,6,"RefreshTokenEntity<\/a>"],[100,4,"ScopeEntity<\/a>"],[100,23,"SessionEntity<\/a>"],[75,3,"ClientAuthenticationFailedEvent<\/a>"],[100,3,"SessionOwnerEvent<\/a>"],[75,3,"UserAuthenticationFailedEvent<\/a>"],[100,1,"AccessDeniedException<\/a>"],[100,1,"InvalidClientException<\/a>"],[100,1,"InvalidCredentialsException<\/a>"],[100,1,"InvalidGrantException<\/a>"],[100,1,"InvalidRefreshException<\/a>"],[100,1,"InvalidRequestException<\/a>"],[100,1,"InvalidScopeException<\/a>"],[100,15,"OAuthException<\/a>"],[100,2,"ServerErrorException<\/a>"],[100,1,"UnauthorizedClientException<\/a>"],[100,1,"UnsupportedGrantTypeException<\/a>"],[100,1,"UnsupportedResponseTypeException<\/a>"],[100,21,"AbstractGrant<\/a>"],[100,25,"AuthCodeGrant<\/a>"],[100,6,"ClientCredentialsGrant<\/a>"],[100,15,"PasswordGrant<\/a>"],[100,16,"RefreshTokenGrant<\/a>"],[100,13,"ResourceServer<\/a>"],[100,2,"AbstractStorage<\/a>"],[100,5,"AbstractTokenType<\/a>"],[85.714285714286,5,"Bearer<\/a>"],[93.333333333333,22,"MAC<\/a>"],[100,4,"DefaultAlgorithm<\/a>"],[100,2,"RedirectUri<\/a>"],[100,4,"SecureKey<\/a>"],[100,3,"EntityTrait<\/a>"]], 'Class Complexity')) + .datum(getComplexityData([[100,24,"AbstractServer<\/a>"],[100,21,"AuthorizationServer<\/a>"],[96.296296296296,18,"AbstractTokenEntity<\/a>"],[84,9,"AccessTokenEntity<\/a>"],[100,11,"AuthCodeEntity<\/a>"],[100,5,"ClientEntity<\/a>"],[100,6,"RefreshTokenEntity<\/a>"],[100,4,"ScopeEntity<\/a>"],[100,23,"SessionEntity<\/a>"],[75,3,"ClientAuthenticationFailedEvent<\/a>"],[100,3,"SessionOwnerEvent<\/a>"],[75,3,"UserAuthenticationFailedEvent<\/a>"],[100,1,"AccessDeniedException<\/a>"],[100,1,"InvalidClientException<\/a>"],[100,1,"InvalidCredentialsException<\/a>"],[100,1,"InvalidGrantException<\/a>"],[100,1,"InvalidRefreshException<\/a>"],[100,1,"InvalidRequestException<\/a>"],[100,1,"InvalidScopeException<\/a>"],[100,15,"OAuthException<\/a>"],[100,2,"ServerErrorException<\/a>"],[100,1,"UnauthorizedClientException<\/a>"],[100,1,"UnsupportedGrantTypeException<\/a>"],[100,1,"UnsupportedResponseTypeException<\/a>"],[100,21,"AbstractGrant<\/a>"],[98.148148148148,28,"AuthCodeGrant<\/a>"],[100,6,"ClientCredentialsGrant<\/a>"],[100,15,"PasswordGrant<\/a>"],[100,19,"RefreshTokenGrant<\/a>"],[100,13,"ResourceServer<\/a>"],[100,2,"AbstractStorage<\/a>"],[100,5,"AbstractTokenType<\/a>"],[85.714285714286,5,"Bearer<\/a>"],[93.333333333333,22,"MAC<\/a>"],[100,4,"DefaultAlgorithm<\/a>"],[100,2,"RedirectUri<\/a>"],[100,4,"SecureKey<\/a>"],[100,3,"EntityTrait<\/a>"]], 'Class Complexity')) .transition() .duration(500) .call(chart); @@ -265,7 +266,7 @@ $(document).ready(function() { chart.yAxis.axisLabel('Method Complexity'); d3.select('#methodComplexity svg') - .datum(getComplexityData([[100,1,"AbstractServer::__construct<\/a>"],[100,2,"AbstractServer::setEventEmitter<\/a>"],[100,1,"AbstractServer::addEventListener<\/a>"],[100,1,"AbstractServer::getEventEmitter<\/a>"],[100,1,"AbstractServer::setRequest<\/a>"],[100,2,"AbstractServer::getRequest<\/a>"],[100,1,"AbstractServer::setClientStorage<\/a>"],[100,1,"AbstractServer::setSessionStorage<\/a>"],[100,1,"AbstractServer::setAccessTokenStorage<\/a>"],[100,1,"AbstractServer::setRefreshTokenStorage<\/a>"],[100,1,"AbstractServer::setAuthCodeStorage<\/a>"],[100,1,"AbstractServer::setScopeStorage<\/a>"],[100,1,"AbstractServer::getClientStorage<\/a>"],[100,1,"AbstractServer::getScopeStorage<\/a>"],[100,1,"AbstractServer::getSessionStorage<\/a>"],[100,1,"AbstractServer::getRefreshTokenStorage<\/a>"],[100,1,"AbstractServer::getAccessTokenStorage<\/a>"],[100,1,"AbstractServer::getAuthCodeStorage<\/a>"],[100,1,"AbstractServer::setTokenType<\/a>"],[100,1,"AbstractServer::getTokenType<\/a>"],[100,1,"AbstractServer::getMacStorage<\/a>"],[100,1,"AbstractServer::setMacStorage<\/a>"],[100,1,"AuthorizationServer::__construct<\/a>"],[100,3,"AuthorizationServer::addGrantType<\/a>"],[100,1,"AuthorizationServer::hasGrantType<\/a>"],[100,1,"AuthorizationServer::getResponseTypes<\/a>"],[100,1,"AuthorizationServer::requireScopeParam<\/a>"],[100,1,"AuthorizationServer::scopeParamRequired<\/a>"],[100,1,"AuthorizationServer::setDefaultScope<\/a>"],[100,1,"AuthorizationServer::getDefaultScope<\/a>"],[100,1,"AuthorizationServer::stateParamRequired<\/a>"],[100,1,"AuthorizationServer::requireStateParam<\/a>"],[100,1,"AuthorizationServer::getScopeDelimiter<\/a>"],[100,1,"AuthorizationServer::setScopeDelimiter<\/a>"],[100,1,"AuthorizationServer::getAccessTokenTTL<\/a>"],[100,1,"AuthorizationServer::setAccessTokenTTL<\/a>"],[100,3,"AuthorizationServer::issueAccessToken<\/a>"],[100,2,"AuthorizationServer::getGrantType<\/a>"],[100,1,"AbstractTokenEntity::__construct<\/a>"],[100,1,"AbstractTokenEntity::setSession<\/a>"],[100,1,"AbstractTokenEntity::setExpireTime<\/a>"],[100,1,"AbstractTokenEntity::getExpireTime<\/a>"],[100,1,"AbstractTokenEntity::isExpired<\/a>"],[100,2,"AbstractTokenEntity::setId<\/a>"],[100,1,"AbstractTokenEntity::getId<\/a>"],[100,2,"AbstractTokenEntity::associateScope<\/a>"],[88.888888888889,4,"AbstractTokenEntity::formatScopes<\/a>"],[100,2,"AbstractTokenEntity::__toString<\/a>"],[100,1,"AbstractTokenEntity::expire<\/a>"],[100,1,"AbstractTokenEntity::save<\/a>"],[100,2,"AccessTokenEntity::getSession<\/a>"],[0,2,"AccessTokenEntity::hasScope<\/a>"],[100,2,"AccessTokenEntity::getScopes<\/a>"],[100,2,"AccessTokenEntity::save<\/a>"],[100,1,"AccessTokenEntity::expire<\/a>"],[100,1,"AuthCodeEntity::setRedirectUri<\/a>"],[100,1,"AuthCodeEntity::getRedirectUri<\/a>"],[100,2,"AuthCodeEntity::generateRedirectUri<\/a>"],[100,2,"AuthCodeEntity::getSession<\/a>"],[100,2,"AuthCodeEntity::getScopes<\/a>"],[100,2,"AuthCodeEntity::save<\/a>"],[100,1,"AuthCodeEntity::expire<\/a>"],[100,1,"ClientEntity::__construct<\/a>"],[100,1,"ClientEntity::getId<\/a>"],[100,1,"ClientEntity::getSecret<\/a>"],[100,1,"ClientEntity::getName<\/a>"],[100,1,"ClientEntity::getRedirectUri<\/a>"],[100,1,"RefreshTokenEntity::setAccessTokenId<\/a>"],[100,1,"RefreshTokenEntity::setAccessToken<\/a>"],[100,2,"RefreshTokenEntity::getAccessToken<\/a>"],[100,1,"RefreshTokenEntity::save<\/a>"],[100,1,"RefreshTokenEntity::expire<\/a>"],[100,1,"ScopeEntity::__construct<\/a>"],[100,1,"ScopeEntity::getId<\/a>"],[100,1,"ScopeEntity::getDescription<\/a>"],[100,1,"ScopeEntity::jsonSerialize<\/a>"],[100,1,"SessionEntity::__construct<\/a>"],[100,1,"SessionEntity::setId<\/a>"],[100,1,"SessionEntity::getId<\/a>"],[100,2,"SessionEntity::associateScope<\/a>"],[100,2,"SessionEntity::hasScope<\/a>"],[100,2,"SessionEntity::getScopes<\/a>"],[100,4,"SessionEntity::formatScopes<\/a>"],[100,1,"SessionEntity::associateAccessToken<\/a>"],[100,1,"SessionEntity::associateRefreshToken<\/a>"],[100,1,"SessionEntity::associateClient<\/a>"],[100,2,"SessionEntity::getClient<\/a>"],[100,1,"SessionEntity::setOwner<\/a>"],[100,1,"SessionEntity::getOwnerId<\/a>"],[100,1,"SessionEntity::getOwnerType<\/a>"],[100,2,"SessionEntity::save<\/a>"],[100,1,"ClientAuthenticationFailedEvent::__construct<\/a>"],[100,1,"ClientAuthenticationFailedEvent::getName<\/a>"],[0,1,"ClientAuthenticationFailedEvent::getRequest<\/a>"],[100,1,"SessionOwnerEvent::__construct<\/a>"],[100,1,"SessionOwnerEvent::getName<\/a>"],[100,1,"SessionOwnerEvent::getSession<\/a>"],[100,1,"UserAuthenticationFailedEvent::__construct<\/a>"],[100,1,"UserAuthenticationFailedEvent::getName<\/a>"],[0,1,"UserAuthenticationFailedEvent::getRequest<\/a>"],[100,1,"AccessDeniedException::__construct<\/a>"],[100,1,"InvalidClientException::__construct<\/a>"],[100,1,"InvalidCredentialsException::__construct<\/a>"],[100,1,"InvalidGrantException::__construct<\/a>"],[100,1,"InvalidRefreshException::__construct<\/a>"],[100,1,"InvalidRequestException::__construct<\/a>"],[100,1,"InvalidScopeException::__construct<\/a>"],[100,1,"OAuthException::__construct<\/a>"],[100,2,"OAuthException::shouldRedirect<\/a>"],[100,1,"OAuthException::getRedirectUri<\/a>"],[100,11,"OAuthException::getHttpHeaders<\/a>"],[100,2,"ServerErrorException::__construct<\/a>"],[100,1,"UnauthorizedClientException::__construct<\/a>"],[100,1,"UnsupportedGrantTypeException::__construct<\/a>"],[100,1,"UnsupportedResponseTypeException::__construct<\/a>"],[100,1,"AbstractGrant::getIdentifier<\/a>"],[100,1,"AbstractGrant::setIdentifier<\/a>"],[100,1,"AbstractGrant::getResponseType<\/a>"],[100,2,"AbstractGrant::getAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAuthorizationServer<\/a>"],[100,11,"AbstractGrant::validateScopes<\/a>"],[100,3,"AbstractGrant::formatScopes<\/a>"],[100,1,"AuthCodeGrant::setAuthTokenTTL<\/a>"],[100,8,"AuthCodeGrant::checkAuthorizeParams<\/a>"],[100,2,"AuthCodeGrant::newAuthorizeRequest<\/a>"],[100,14,"AuthCodeGrant::completeFlow<\/a>"],[100,6,"ClientCredentialsGrant::completeFlow<\/a>"],[100,1,"PasswordGrant::setVerifyCredentialsCallback<\/a>"],[100,3,"PasswordGrant::getVerifyCredentialsCallback<\/a>"],[100,11,"PasswordGrant::completeFlow<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::getRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenRotation<\/a>"],[100,1,"RefreshTokenGrant::shouldRotateRefreshTokens<\/a>"],[100,12,"RefreshTokenGrant::completeFlow<\/a>"],[100,1,"ResourceServer::__construct<\/a>"],[100,1,"ResourceServer::setIdKey<\/a>"],[100,1,"ResourceServer::getAccessToken<\/a>"],[100,4,"ResourceServer::isValidRequest<\/a>"],[100,6,"ResourceServer::determineAccessToken<\/a>"],[100,1,"AbstractStorage::setServer<\/a>"],[100,1,"AbstractStorage::getServer<\/a>"],[100,1,"AbstractTokenType::setServer<\/a>"],[100,1,"AbstractTokenType::setSession<\/a>"],[100,1,"AbstractTokenType::setParam<\/a>"],[100,2,"AbstractTokenType::getParam<\/a>"],[100,2,"Bearer::generateResponse<\/a>"],[66.666666666667,3,"Bearer::determineAccessTokenInHeader<\/a>"],[83.333333333333,2,"MAC::generateResponse<\/a>"],[100,13,"MAC::determineAccessTokenInHeader<\/a>"],[100,3,"MAC::anonymous function<\/a>"],[90,4,"MAC::hash_equals<\/a>"],[100,4,"DefaultAlgorithm::generate<\/a>"],[100,2,"RedirectUri::make<\/a>"],[100,1,"SecureKey::generate<\/a>"],[100,1,"SecureKey::setAlgorithm<\/a>"],[100,2,"SecureKey::getAlgorithm<\/a>"],[100,3,"EntityTrait::hydrate<\/a>"]], 'Method Complexity')) + .datum(getComplexityData([[100,1,"AbstractServer::__construct<\/a>"],[100,2,"AbstractServer::setEventEmitter<\/a>"],[100,1,"AbstractServer::addEventListener<\/a>"],[100,1,"AbstractServer::getEventEmitter<\/a>"],[100,1,"AbstractServer::setRequest<\/a>"],[100,2,"AbstractServer::getRequest<\/a>"],[100,1,"AbstractServer::setClientStorage<\/a>"],[100,1,"AbstractServer::setSessionStorage<\/a>"],[100,1,"AbstractServer::setAccessTokenStorage<\/a>"],[100,1,"AbstractServer::setRefreshTokenStorage<\/a>"],[100,1,"AbstractServer::setAuthCodeStorage<\/a>"],[100,1,"AbstractServer::setScopeStorage<\/a>"],[100,1,"AbstractServer::getClientStorage<\/a>"],[100,1,"AbstractServer::getScopeStorage<\/a>"],[100,1,"AbstractServer::getSessionStorage<\/a>"],[100,1,"AbstractServer::getRefreshTokenStorage<\/a>"],[100,1,"AbstractServer::getAccessTokenStorage<\/a>"],[100,1,"AbstractServer::getAuthCodeStorage<\/a>"],[100,1,"AbstractServer::setTokenType<\/a>"],[100,1,"AbstractServer::getTokenType<\/a>"],[100,1,"AbstractServer::getMacStorage<\/a>"],[100,1,"AbstractServer::setMacStorage<\/a>"],[100,1,"AuthorizationServer::__construct<\/a>"],[100,3,"AuthorizationServer::addGrantType<\/a>"],[100,1,"AuthorizationServer::hasGrantType<\/a>"],[100,1,"AuthorizationServer::getResponseTypes<\/a>"],[100,1,"AuthorizationServer::requireScopeParam<\/a>"],[100,1,"AuthorizationServer::scopeParamRequired<\/a>"],[100,1,"AuthorizationServer::setDefaultScope<\/a>"],[100,1,"AuthorizationServer::getDefaultScope<\/a>"],[100,1,"AuthorizationServer::stateParamRequired<\/a>"],[100,1,"AuthorizationServer::requireStateParam<\/a>"],[100,1,"AuthorizationServer::getScopeDelimiter<\/a>"],[100,1,"AuthorizationServer::setScopeDelimiter<\/a>"],[100,1,"AuthorizationServer::getAccessTokenTTL<\/a>"],[100,1,"AuthorizationServer::setAccessTokenTTL<\/a>"],[100,3,"AuthorizationServer::issueAccessToken<\/a>"],[100,2,"AuthorizationServer::getGrantType<\/a>"],[100,1,"AbstractTokenEntity::__construct<\/a>"],[100,1,"AbstractTokenEntity::setSession<\/a>"],[100,1,"AbstractTokenEntity::setExpireTime<\/a>"],[100,1,"AbstractTokenEntity::getExpireTime<\/a>"],[100,1,"AbstractTokenEntity::isExpired<\/a>"],[100,2,"AbstractTokenEntity::setId<\/a>"],[100,1,"AbstractTokenEntity::getId<\/a>"],[100,2,"AbstractTokenEntity::associateScope<\/a>"],[88.888888888889,4,"AbstractTokenEntity::formatScopes<\/a>"],[100,2,"AbstractTokenEntity::__toString<\/a>"],[100,1,"AbstractTokenEntity::expire<\/a>"],[100,1,"AbstractTokenEntity::save<\/a>"],[100,2,"AccessTokenEntity::getSession<\/a>"],[0,2,"AccessTokenEntity::hasScope<\/a>"],[100,2,"AccessTokenEntity::getScopes<\/a>"],[100,2,"AccessTokenEntity::save<\/a>"],[100,1,"AccessTokenEntity::expire<\/a>"],[100,1,"AuthCodeEntity::setRedirectUri<\/a>"],[100,1,"AuthCodeEntity::getRedirectUri<\/a>"],[100,2,"AuthCodeEntity::generateRedirectUri<\/a>"],[100,2,"AuthCodeEntity::getSession<\/a>"],[100,2,"AuthCodeEntity::getScopes<\/a>"],[100,2,"AuthCodeEntity::save<\/a>"],[100,1,"AuthCodeEntity::expire<\/a>"],[100,1,"ClientEntity::__construct<\/a>"],[100,1,"ClientEntity::getId<\/a>"],[100,1,"ClientEntity::getSecret<\/a>"],[100,1,"ClientEntity::getName<\/a>"],[100,1,"ClientEntity::getRedirectUri<\/a>"],[100,1,"RefreshTokenEntity::setAccessTokenId<\/a>"],[100,1,"RefreshTokenEntity::setAccessToken<\/a>"],[100,2,"RefreshTokenEntity::getAccessToken<\/a>"],[100,1,"RefreshTokenEntity::save<\/a>"],[100,1,"RefreshTokenEntity::expire<\/a>"],[100,1,"ScopeEntity::__construct<\/a>"],[100,1,"ScopeEntity::getId<\/a>"],[100,1,"ScopeEntity::getDescription<\/a>"],[100,1,"ScopeEntity::jsonSerialize<\/a>"],[100,1,"SessionEntity::__construct<\/a>"],[100,1,"SessionEntity::setId<\/a>"],[100,1,"SessionEntity::getId<\/a>"],[100,2,"SessionEntity::associateScope<\/a>"],[100,2,"SessionEntity::hasScope<\/a>"],[100,2,"SessionEntity::getScopes<\/a>"],[100,4,"SessionEntity::formatScopes<\/a>"],[100,1,"SessionEntity::associateAccessToken<\/a>"],[100,1,"SessionEntity::associateRefreshToken<\/a>"],[100,1,"SessionEntity::associateClient<\/a>"],[100,2,"SessionEntity::getClient<\/a>"],[100,1,"SessionEntity::setOwner<\/a>"],[100,1,"SessionEntity::getOwnerId<\/a>"],[100,1,"SessionEntity::getOwnerType<\/a>"],[100,2,"SessionEntity::save<\/a>"],[100,1,"ClientAuthenticationFailedEvent::__construct<\/a>"],[100,1,"ClientAuthenticationFailedEvent::getName<\/a>"],[0,1,"ClientAuthenticationFailedEvent::getRequest<\/a>"],[100,1,"SessionOwnerEvent::__construct<\/a>"],[100,1,"SessionOwnerEvent::getName<\/a>"],[100,1,"SessionOwnerEvent::getSession<\/a>"],[100,1,"UserAuthenticationFailedEvent::__construct<\/a>"],[100,1,"UserAuthenticationFailedEvent::getName<\/a>"],[0,1,"UserAuthenticationFailedEvent::getRequest<\/a>"],[100,1,"AccessDeniedException::__construct<\/a>"],[100,1,"InvalidClientException::__construct<\/a>"],[100,1,"InvalidCredentialsException::__construct<\/a>"],[100,1,"InvalidGrantException::__construct<\/a>"],[100,1,"InvalidRefreshException::__construct<\/a>"],[100,1,"InvalidRequestException::__construct<\/a>"],[100,1,"InvalidScopeException::__construct<\/a>"],[100,1,"OAuthException::__construct<\/a>"],[100,2,"OAuthException::shouldRedirect<\/a>"],[100,1,"OAuthException::getRedirectUri<\/a>"],[100,11,"OAuthException::getHttpHeaders<\/a>"],[100,2,"ServerErrorException::__construct<\/a>"],[100,1,"UnauthorizedClientException::__construct<\/a>"],[100,1,"UnsupportedGrantTypeException::__construct<\/a>"],[100,1,"UnsupportedResponseTypeException::__construct<\/a>"],[100,1,"AbstractGrant::getIdentifier<\/a>"],[100,1,"AbstractGrant::setIdentifier<\/a>"],[100,1,"AbstractGrant::getResponseType<\/a>"],[100,2,"AbstractGrant::getAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAccessTokenTTL<\/a>"],[100,1,"AbstractGrant::setAuthorizationServer<\/a>"],[100,11,"AbstractGrant::validateScopes<\/a>"],[100,3,"AbstractGrant::formatScopes<\/a>"],[100,1,"AuthCodeGrant::setAuthTokenTTL<\/a>"],[0,1,"AuthCodeGrant::setRequireClientSecret<\/a>"],[100,1,"AuthCodeGrant::shouldRequireClientSecret<\/a>"],[100,8,"AuthCodeGrant::checkAuthorizeParams<\/a>"],[100,2,"AuthCodeGrant::newAuthorizeRequest<\/a>"],[100,15,"AuthCodeGrant::completeFlow<\/a>"],[100,6,"ClientCredentialsGrant::completeFlow<\/a>"],[100,1,"PasswordGrant::setVerifyCredentialsCallback<\/a>"],[100,3,"PasswordGrant::getVerifyCredentialsCallback<\/a>"],[100,11,"PasswordGrant::completeFlow<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::getRefreshTokenTTL<\/a>"],[100,1,"RefreshTokenGrant::setRefreshTokenRotation<\/a>"],[100,1,"RefreshTokenGrant::shouldRotateRefreshTokens<\/a>"],[100,1,"RefreshTokenGrant::setRequireClientSecret<\/a>"],[100,1,"RefreshTokenGrant::shouldRequireClientSecret<\/a>"],[100,13,"RefreshTokenGrant::completeFlow<\/a>"],[100,1,"ResourceServer::__construct<\/a>"],[100,1,"ResourceServer::setIdKey<\/a>"],[100,1,"ResourceServer::getAccessToken<\/a>"],[100,4,"ResourceServer::isValidRequest<\/a>"],[100,6,"ResourceServer::determineAccessToken<\/a>"],[100,1,"AbstractStorage::setServer<\/a>"],[100,1,"AbstractStorage::getServer<\/a>"],[100,1,"AbstractTokenType::setServer<\/a>"],[100,1,"AbstractTokenType::setSession<\/a>"],[100,1,"AbstractTokenType::setParam<\/a>"],[100,2,"AbstractTokenType::getParam<\/a>"],[100,2,"Bearer::generateResponse<\/a>"],[66.666666666667,3,"Bearer::determineAccessTokenInHeader<\/a>"],[83.333333333333,2,"MAC::generateResponse<\/a>"],[100,13,"MAC::determineAccessTokenInHeader<\/a>"],[100,3,"MAC::anonymous function<\/a>"],[90,4,"MAC::hash_equals<\/a>"],[100,4,"DefaultAlgorithm::generate<\/a>"],[100,2,"RedirectUri::make<\/a>"],[100,1,"SecureKey::generate<\/a>"],[100,1,"SecureKey::setAlgorithm<\/a>"],[100,2,"SecureKey::getAlgorithm<\/a>"],[100,3,"EntityTrait::hydrate<\/a>"]], 'Method Complexity')) .transition() .duration(500) .call(chart); diff --git a/master/index.html b/master/index.html index a5d94fb8..bca797fa 100644 --- a/master/index.html +++ b/master/index.html @@ -43,29 +43,29 @@ Total
-
- 98.34% covered (success) +
+ 98.10% covered (success)
-
98.34%
-
769 / 782
+
98.10%
+
773 / 788
-
- 95.54% covered (success) +
+ 95.03% covered (success)
-
95.54%
-
150 / 157
+
95.03%
+
153 / 161
-
- 84.21% covered (warning) +
+ 81.58% covered (warning)
-
84.21%
-
32 / 38
+
81.58%
+
31 / 38
@@ -155,29 +155,29 @@
Grant
-
- 100.00% covered (success) +
+ 99.38% covered (success)
-
100.00%
-
318 / 318
+
99.38%
+
322 / 324
-
- 100.00% covered (success) +
+ 96.00% covered (success)
-
100.00%
-
21 / 21
-
-
- 100.00% covered (success) +
96.00%
+
24 / 25
+
+
+ 80.00% covered (warning)
-
100.00%
-
5 / 5
+
80.00%
+
4 / 5
@@ -360,7 +360,7 @@ High: 90% to 100%

- Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:28:55 UTC 2015. + Generated by PHP_CodeCoverage 2.2.2 using PHP 5.5.21 and PHPUnit 4.3.5 at Fri Sep 4 7:30:20 UTC 2015.