File tree Expand file tree Collapse file tree 4 files changed +13
-16
lines changed Expand file tree Collapse file tree 4 files changed +13
-16
lines changed Original file line number Diff line number Diff line change 1
1
language : php
2
2
3
3
php :
4
- - ' 7.1 '
4
+ - ' 7.2 '
5
5
6
6
sudo : false
7
7
@@ -24,4 +24,4 @@ script:
24
24
- ./vendor/bin/phpcov merge --clover build/logs/clover.xml build/cov
25
25
26
26
after_success :
27
- - travis_retry php vendor/bin/php-coveralls
27
+ - travis_retry php vendor/bin/php-coveralls
Original file line number Diff line number Diff line change 17
17
}
18
18
],
19
19
"require" : {
20
- "php" : " >=7.1 .0" ,
20
+ "php" : " >=7.2 .0" ,
21
21
"ext-openssl" : " *" ,
22
22
"league/oauth2-server" : " ^7.0" ,
23
23
"nette/forms" : " ^2.4" ,
24
24
"psr/container" : " ^1.0" ,
25
25
"simplesamlphp/composer-module-installer" : " ^1.0" ,
26
- "spomky-labs/jose " : " ^7.0 " ,
26
+ "web-token/jwt-framework " : " ^2.1 " ,
27
27
"steverhoades/oauth2-openid-connect-server" : " ^1.0" ,
28
28
"zendframework/zend-diactoros" : " ^1.3"
29
29
},
Original file line number Diff line number Diff line change 14
14
15
15
namespace SimpleSAML \Modules \OpenIDConnect \Services ;
16
16
17
- use Jose \Factory \ JWKFactory ;
18
- use Jose \Object \ JWKSet ;
17
+ use Jose \Component \ Core \ JWKSet ;
18
+ use Jose \Component \ KeyManagement \ JWKFactory ;
19
19
use SimpleSAML \Error \Exception ;
20
20
use SimpleSAML \Utils \Config ;
21
21
@@ -40,12 +40,11 @@ public function __construct()
40
40
'alg ' => 'RS256 ' ,
41
41
]);
42
42
43
- $ this ->jwkSet = new JWKSet ();
44
- $ this ->jwkSet ->addKey ($ jwk );
43
+ $ this ->jwkSet = new JWKSet ([$ jwk ]);
45
44
}
46
45
47
46
public function keys ()
48
47
{
49
- return $ this ->jwkSet ->getKeys ();
48
+ return $ this ->jwkSet ->all ();
50
49
}
51
50
}
Original file line number Diff line number Diff line change 14
14
15
15
namespace Tests \SimpleSAML \Modules \OpenIDConnect \Services ;
16
16
17
- use Jose \Factory \ JWKFactory ;
18
- use Jose \Object \ JWKSet ;
17
+ use Jose \Component \ Core \ JWKSet ;
18
+ use Jose \Component \ KeyManagement \ JWKFactory ;
19
19
use PHPUnit \Framework \TestCase ;
20
20
use SimpleSAML \Configuration ;
21
- use SimpleSAML \Error \Exception ;
22
21
use SimpleSAML \Modules \OpenIDConnect \Services \JsonWebKeySetService ;
23
22
24
23
class JsonWebKeySetServiceTest extends TestCase
@@ -66,16 +65,15 @@ public function testKeys()
66
65
'use ' => 'sig ' ,
67
66
'alg ' => 'RS256 ' ,
68
67
]);
69
- $ JWKSet = new JWKSet ();
70
- $ JWKSet ->addKey ($ jwk );
68
+ $ JWKSet = new JWKSet ([$ jwk ]);
71
69
72
70
$ jsonWebKeySetService = new JsonWebKeySetService ();
73
71
74
- $ this ->assertEquals ($ JWKSet ->getKeys (), $ jsonWebKeySetService ->keys ());
72
+ $ this ->assertEquals ($ JWKSet ->all (), $ jsonWebKeySetService ->keys ());
75
73
}
76
74
77
75
/**
78
- * @expectedException Exception
76
+ * @expectedException \ Exception
79
77
*/
80
78
public function testCertificationFileNotFound ()
81
79
{
You can’t perform that action at this time.
0 commit comments