Skip to content
This repository was archived by the owner on Feb 28, 2024. It is now read-only.

Commit 998f8e9

Browse files
authored
Removing exception for A192GCM not being supported
1 parent 94433c9 commit 998f8e9

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

tests/Developer/Interceptors/PsrHttpMessageJweInterceptorTest.php

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -142,30 +142,6 @@ public function testInterceptResponse_ShouldDoNothing_WhenNoPayload()
142142
$this->assertEquals(0, sizeof($response->getHeaders()));
143143
}
144144

145-
public function testInterceptResponse_ShouldThrowAnExceptionWhenEncryptionNotSupported()
146-
{
147-
$this->expectException(EncryptionException::class);
148-
$this->expectExceptionMessage('Encryption method A192GCM not supported');
149-
150-
// GIVEN
151-
$encryptedPayload = "{" .
152-
"\"encryptedPayload\":\"eyJraWQiOiI3NjFiMDAzYzFlYWRlM2E1NDkwZTUwMDBkMzc4ODdiYWE1ZTZlYzBlMjI2YzA3NzA2ZTU5OTQ1MWZjMDMyYTc5IiwiY3R5IjoiYXBwbGljYXRpb25cL2pzb24iLCJlbmMiOiJBMTkyR0NNIiwiYWxnIjoiUlNBLU9BRVAtMjU2In0.peSgTt_lPbcNStWh-gI3yMzhOGtFCwExFwLxKeHwjzsXvHB0Fml5XnG0jRbJSfOHzKx02d0NVBzoDDRSAnafuabbbMKcoaUK-jZNHSg4BHdyBZpCO82kzvWeEm3TTNHIMBTfM00EmdFB03z_a0PaWsT-FIOzu4Sd5Z_nsNLhP9941CtVS-YtZ9WkgDezGipxA7ejQ3X5gFVy2RH1gL8OTbzIYCwBcrfSjAiCQgunNbLxPPlfZHB_6prPK7_50NS6FvuMnAhiqUiiAka8DHMdeGBWOie2Q0FV_bsRDHx_6CY8kQA3F_NXz1dELIclJhdZFfRt1y-TEfwOIj4nDi2JnA.8BYMB5MkH2ZNyFGS._xb3uDsUQcPT5fQyZw.O0MzJ5OvNyj_QMuqaloTWA\"}";
153-
154-
$decryptionKey = DecryptionKey::load("./resources/Keys/Pkcs8/test_key_pkcs8-2048.pem");
155-
156-
$config = JweConfigBuilder::aJweEncryptionConfig()
157-
->withDecryptionKey($decryptionKey)
158-
->withDecryptionPath("$.encryptedPayload", "$.foo")
159-
->build();
160-
161-
$headers = ['Content-Type' => 'application/json'];
162-
$response = new Response(200, $headers, $encryptedPayload);
163-
164-
// WHEN
165-
$instanceUnderTest = new PsrHttpMessageJweInterceptor($config);
166-
$instanceUnderTest->interceptResponse($response);
167-
}
168-
169145
public function testInterceptResponse_ShouldThrowEncryptionException_WhenDecryptionFails()
170146
{
171147
$this->expectException(EncryptionException::class);

0 commit comments

Comments
 (0)