Skip to content

Dev master #2119

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 94 commits into
base: develop
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
94 commits
Select commit Hold shift + click to select a range
00a5606
Refactor all the things
tymondesigns Mar 10, 2018
5ef16f3
fixes
tymondesigns Mar 15, 2018
bf885e3
php version
tymondesigns Mar 21, 2018
2af55a0
use some optionals
tymondesigns Mar 27, 2018
3e20aad
remove exp if not set
tymondesigns Mar 27, 2018
be8e897
remove 7.0
tymondesigns Mar 28, 2018
52efc6c
update hints
tymondesigns Jun 19, 2018
569500c
macroable
tymondesigns Jun 19, 2018
47e71fd
tweaks
tymondesigns Jun 19, 2018
96042f7
improvements
tymondesigns Sep 7, 2018
eb4e591
remove linter
tymondesigns Sep 8, 2018
fd97b07
Apply fixes from StyleCI (#1662)
tymondesigns Sep 8, 2018
be0b0f9
laravel 5.7
tymondesigns Sep 8, 2018
2123898
revert HO
tymondesigns Sep 8, 2018
d53ca4a
actually l5.4 and above
tymondesigns Sep 8, 2018
f215263
actually l5.4 and above
tymondesigns Sep 8, 2018
2f7d45d
add ability to get carbon and carbon interval instances
tymondesigns Sep 9, 2018
be03e7f
no need for constructor any more
tymondesigns Sep 11, 2018
9a8de68
:art:
tymondesigns Sep 21, 2018
e96aec3
Apply fixes from StyleCI (#1670)
tymondesigns Sep 21, 2018
c670e6a
cs and looser composer requirements
tymondesigns Sep 21, 2018
98785c1
add ability to provider custom claim validators and other bits of cle…
tymondesigns Oct 6, 2018
2a5935e
Apply fixes from StyleCI (#1683)
tymondesigns Oct 6, 2018
a4ab78c
pass value instead of claim
tymondesigns Oct 6, 2018
37be0d7
pass value instead of claim
tymondesigns Oct 6, 2018
6fb0342
fixes
tymondesigns Oct 7, 2018
8397aae
Apply fixes from StyleCI (#1686)
tymondesigns Oct 7, 2018
2421a17
convert to value object
tymondesigns Oct 8, 2018
dde6098
Apply fixes from StyleCI (#1689)
tymondesigns Oct 8, 2018
73a1105
swap to functions
tymondesigns Oct 11, 2018
96a69ae
Apply fixes from StyleCI (#1692)
tymondesigns Oct 11, 2018
ca0f4bb
remove version eye
tymondesigns Oct 11, 2018
417eb8d
rename to verify
tymondesigns Oct 11, 2018
b790865
Merge branch '2.0' of github.com:tymondesigns/jwt-auth into 2.0
tymondesigns Oct 11, 2018
d2d96e5
switch facade
tymondesigns Oct 11, 2018
d4dc398
improvements
tymondesigns Oct 15, 2018
a7e38ff
Apply fixes from StyleCI (#1696)
tymondesigns Oct 15, 2018
a959187
fix composer
tymondesigns Oct 15, 2018
6a7769a
use constants instead
tymondesigns Oct 17, 2018
67a11b4
Apply fixes from StyleCI (#1702)
tymondesigns Oct 21, 2018
a328e1d
use manager facade
tymondesigns Oct 21, 2018
cc5f79c
use constants everywhere
tymondesigns Oct 21, 2018
e7a7405
Apply fixes from StyleCI (#1703)
tymondesigns Oct 21, 2018
087ea90
use constants everywhere
tymondesigns Oct 21, 2018
87baba7
tweaks and improvements
tymondesigns Oct 21, 2018
90bf683
fixes
tymondesigns Oct 22, 2018
036db1b
cleanup
tymondesigns Oct 23, 2018
1876c40
fix tests
tymondesigns Oct 23, 2018
292c938
badges
tymondesigns Nov 20, 2018
43865f2
fix carbon issue
tymondesigns Nov 20, 2018
ed96a29
fixes
tymondesigns Nov 20, 2018
29cad6f
fixes
tymondesigns Nov 22, 2018
ce21451
Apply fixes from StyleCI (#1718)
tymondesigns Nov 22, 2018
5c96db8
fixes
tymondesigns Nov 22, 2018
fffdad2
lots of improvements
tymondesigns Feb 12, 2019
6da1589
Apply fixes from StyleCI (#1752)
tymondesigns Feb 12, 2019
45c5178
remove mkdocs
tymondesigns Feb 12, 2019
277db83
chore(composer): Bump some dependencies
tymondesigns Mar 20, 2019
0794da9
Apply fixes from StyleCI (#1778)
tymondesigns Mar 20, 2019
701044c
chore(composer): Upgrade phpunit
tymondesigns Mar 20, 2019
694313c
fixes
tymondesigns Mar 20, 2019
47d5ee5
refactor: subject hashing
tymondesigns Mar 20, 2019
128070c
Apply fixes from StyleCI (#1779)
tymondesigns Mar 20, 2019
cd75eac
chore: cherry-pick laravel 5.8 cache fix
tymondesigns Mar 4, 2019
719214b
Apply fixes from StyleCI (#1781)
tymondesigns Mar 22, 2019
d8f93a0
chore: cleanup composer
tymondesigns Mar 22, 2019
a8781f3
moving things around
tymondesigns Mar 22, 2019
bc39f5f
moving things around
tymondesigns Mar 22, 2019
1c23560
moving things around
tymondesigns Mar 22, 2019
9119165
Merge branch '2.0' of github.com:tymondesigns/jwt-auth into 2.0
tymondesigns Mar 22, 2019
27ee5ea
Apply fixes from StyleCI (#1782)
tymondesigns Mar 22, 2019
5ef1515
small adjustments
tymondesigns May 12, 2019
a7751aa
Apply fixes from StyleCI (#1807)
tymondesigns May 12, 2019
f12f049
Created events to dispatch in JWTGuard (#1813)
GabrielDeveloper Jul 9, 2019
280978d
Apply fixes from StyleCI (#1845)
tymondesigns Jul 9, 2019
4eb6576
docs
tymondesigns Jul 9, 2019
3efbf19
tweak validator
tymondesigns Sep 4, 2019
290885c
php 7.4
tymondesigns Jan 20, 2020
3f1bd34
merge
tymondesigns Jan 20, 2020
b4fb6dd
Apply fixes from StyleCI (#1924)
tymondesigns Jan 20, 2020
736bf05
ci(gh): Test githib actions
tymondesigns Jan 20, 2020
2fc4a75
fix
tymondesigns Jan 20, 2020
203c556
fix
tymondesigns Jan 20, 2020
225467b
fix
tymondesigns Jan 20, 2020
f6ee0f1
dummy
tymondesigns Jan 20, 2020
1b05498
only php 7.4 and L5.8
tymondesigns Jan 20, 2020
6a6e83c
check without 5.8
tymondesigns Jan 20, 2020
c04fd42
cleanup
tymondesigns Jan 20, 2020
52ac4e8
add coverage
tymondesigns Jan 20, 2020
0946fb4
remove prefer-lowest
tymondesigns Jan 21, 2020
60d5b37
whoops
tymondesigns Jan 21, 2020
0638081
fix windows
tymondesigns Mar 3, 2020
f6f0b32
chore(deps): Testing Laravel 7 support
tymondesigns Mar 3, 2020
ef5e60a
Update composer.json
yuriwf Apr 30, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
remove exp if not set
  • Loading branch information
tymondesigns committed Mar 27, 2018
commit 3e20aade0c39b8a0fa731999d6933f66a708e65b
2 changes: 1 addition & 1 deletion src/Builder.php
Original file line number Diff line number Diff line change
@@ -210,7 +210,7 @@ public function setTTL(?int $ttl): self
*
* @return int|null
*/
public function getTTL()
public function getTTL(): ?int
{
return $this->ttl;
}
2 changes: 1 addition & 1 deletion src/Claims/DatetimeTrait.php
Original file line number Diff line number Diff line change
@@ -102,7 +102,7 @@ public function setLeeway(int $leeway): self
*
* @param int|null $period
*/
public function setMaxRefreshPeriod($period): self
public function setMaxRefreshPeriod(?int $period): self
{
$this->maxRefreshPeriod = $period;

13 changes: 9 additions & 4 deletions src/Factory.php
Original file line number Diff line number Diff line change
@@ -38,11 +38,16 @@ public static function make(array $claims = [], array $options = []): Payload
return ClaimFactory::get($key, $value, $options);
});

$requiredClaims = Arr::get($options, 'required_claims', []);

// If the collection doesn't have an exp then remove it from
// the required claims.
if (! $collection->has('exp')) {
$requiredClaims = Arr::except($requiredClaims, ['exp']);
}

// Validate the claims
$collection = PayloadValidator::check(
$collection,
Arr::get($options, 'required_claims', [])
);
$collection = PayloadValidator::check($collection, $requiredClaims);

return new Payload($collection);
}