Commit Graph

1165 Commits

Author SHA1 Message Date
491c23c1e9 Merge remote-tracking branch 'upstream/master' into phpstan-level-7 2018-04-21 21:37:24 +01:00
27323b5c9a Fix spacing issue 2018-04-21 21:31:48 +01:00
80bc291c51 Added null checks before calling set functions 2018-04-21 21:29:21 +01:00
6991777ff3 Fix blank line spacing issue 2018-04-20 18:33:46 +01:00
9febc32e14 Add spacing around logical blocks 2018-04-20 18:27:47 +01:00
c8b44ff5c7 Revert fix for client ID exception 2018-04-20 18:22:07 +01:00
a56acc8dd0 Minor code tidy up 2018-02-28 20:33:19 +00:00
c9b07f386c Fix StyleCI issues and remove phpdoc order from StyleCI 2018-02-28 20:01:01 +00:00
00a7972f74 Merge remote-tracking branch 'upstream/master' 2018-02-28 19:45:41 +00:00
6fd3024c48 Merge pull request #860 from Zaszczyk/new-events-to-emitter-#825
Add new event types: access_token_issued and refresh_token_issued.
2018-02-26 20:01:22 +00:00
62e06b7d3a Removing Yoda condition
Removed Yoda condition from code base
2018-02-26 19:51:03 +00:00
009c109716 TravisCI fix for PHPStan 2018-02-26 16:04:48 +00:00
6723aadfe8 Fix #837
Unifies how we fetch the client_id from the request and allows us to throw a more appropriate exception when the client_id parameter is missing.

Improves the test method for this validation by checking the culpable method in this particular case. The test was missing this by calling the wrong method.
2018-02-26 15:56:28 +00:00
6700b113a8 Add new event types: access_token_issued and refresh_token_issued. 2018-02-23 17:48:51 +01:00
143afc9561 PHPStan level 7 2018-02-18 21:20:48 +01:00
e0cc5ee1b0 Merge branch 'master' of https://github.com/thephpleague/oauth2-server into fix-pkce-implementation 2018-02-18 13:57:19 +00:00
25c3c216a0 Apply fixes from StyleCI 2018-02-17 19:31:59 +00:00
cd5233392e Updated dependencies, more strict static analysis 2018-02-17 18:07:16 +01:00
7a6c35bc29 Merge pull request #849 from lookyman/phpunit-version
Update PHPUnit, run static analysis on tests
2018-02-17 16:28:41 +00:00
8614aea887 Revert "Remove temp variables and @var comments"
This reverts commit 7a5c511807.
2018-02-17 16:27:41 +00:00
7a5c511807 Remove temp variables and @var comments 2018-02-17 16:15:48 +00:00
e0b65a2831 Set default mustValidateSecret to true 2018-02-17 11:46:47 +00:00
ee7d52ecaa Merge pull request #607 from lucadegasperi/patch-5
Make ClientRepositoryInterface more flexible
2018-02-17 11:42:48 +00:00
80a949601f Fixed docblock opener
It's important for tools relying on docblock types to perform static analysis (think phan, phpstan, psalm, etc)
2018-02-12 12:36:59 +02:00
fea577f25b Merge pull request #719 from stratoss/stratoss-patch-exeption
Getter and setter for the payload and ability to pass options to json_encode
2018-02-11 22:48:23 +00:00
1f87c7a7be Update PHPUnit, run static analysis on tests 2018-02-11 23:22:46 +01:00
3098f6d7fa Merge pull request #839 from simesy/master
Allow other secure key permissions.
2018-02-11 22:17:35 +00:00
06a23a1dd0 Update CryptKey.php
Change the error message to reflect that the server will also accept 440 and 400 as a valid file permission
2018-02-11 22:12:55 +00:00
97089ad49e Merge pull request #848 from lookyman/static-analysis
Static analysis with PHPStan
2018-02-11 21:24:52 +00:00
eca385ab08 Static analysis with PHPStan 2018-02-11 22:20:17 +01:00
ef06c29ee8 Merge pull request #840 from liverbool/master
BUGFIX: Wrong redirect uri.
2018-02-11 20:20:41 +00:00
5fb9fc929a Reinstate check on client redirect URI to fail if multiple redirect URIs have been listed for the client and one has not been specified in the auth request 2018-02-11 20:10:01 +00:00
b3cd73cac7 code cleaner
cc.

Co-Authored-By: Andrew Millington <sephster@users.noreply.github.com>
2018-02-09 05:54:05 +07:00
ce2662ece7 Merge branch 'master' of github.com:thephpleague/oauth2-server into fix-pkce-implementation
# Conflicts:
#	tests/Grant/AuthCodeGrantTest.php
2018-02-05 15:32:15 -05:00
d2641b560d Do not create key file if it already exists and it is the same 2018-01-29 11:05:10 +01:00
8bbd218856 Merge pull request #842 from sgomez/fix-challenge-pkce
Fix S256 code challenge method
2018-01-25 23:16:15 +00:00
eb9cde5ab7 Merge pull request #805 from raarts/Accept-RSA-key-with-crlf-v2
Also accept an RSA key with crlf
2018-01-23 22:24:52 +00:00
1b692e2298 Fix S256 code challenge method
According to [RFC7636#section-4.3](https://tools.ietf.org/html/rfc7636#section-4.3):

    If the "code_challenge_method" from Section 4.3 was "S256", the
    received "code_verifier" is hashed by SHA-256, base64url-encoded, and
    then compared to the "code_challenge", i.e.:

    BASE64URL-ENCODE(SHA256(ASCII(code_verifier))) == code_challenge

So, the hash must be done before the base64_encode.

The tests are modified to use example data from the
[RFC7636#appendix-B](https://tools.ietf.org/html/rfc7636#appendix-B).
2018-01-18 05:31:44 +01:00
d22f222e65 BUGFIX: Wrong redirect uri.
This's bugfix when redirect on error.
2018-01-13 11:52:31 +07:00
cf9acb32b8 Allow some more secure options without tsk-tsk. 2018-01-13 15:29:42 +11:00
292272d128 Allow CryptTrait to accept a \Defuse\Crypto\Key as encryption key #812 2018-01-04 15:14:03 +01:00
ef8a741527 In public/private keys, force the header to be on its own line, allow missing \n after the footer 2018-01-04 12:17:31 +01:00
91d9c11fb4 Fixed tests, allow whitespace at the end of a key 2018-01-03 10:18:32 +01:00
b6d9835281 Merge branch 'master' into fix-pkce-implementation 2017-12-28 16:37:37 +00:00
a0cabb573c Update AbstractGrant.php
Temporarily removing check on empty scopes as causing issues for Passport users
2017-12-23 23:33:42 +00:00
1c36b70dab Fixed ordering so we only hash after base64 encoding 2017-12-23 02:06:18 +00:00
f11e4c81cd Merge pull request #697 from fkooman/fix-s256
Fix PKCE code verifier encoding to match specification
2017-12-23 01:52:33 +00:00
f88961eddd flatten code 2017-11-23 21:26:39 +03:30
8c93fd74c9 Merge pull request #573 from ismailbaskin/master
Include redirect_uri check on authorization endpoint
2017-11-19 20:57:27 +00:00
2765481b9f Handle no scope hint 2017-11-18 18:47:38 +00:00