Skip to content

Conversation

@Spomky
Copy link
Member

@Spomky Spomky commented Feb 17, 2018

Q A
Branch? master
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Fixed tickets #65
License MIT
Tests added yes
Doc PR web-token/jwt-doc#4

This PR fixes #65 by adding a NestedTokenLoader.
The loader is able to decrypt and verify a nested token i.e. a signed and encrypted token.

Example of Symfony configuration:

jose:
    nested_token:
        loaders:
            nested_token_loader:
                signature_algorithms: ['PS256']
                key_encryption_algorithms: ['RSA-OAEP']
                content_encryption_algorithms: ['A128GCM']
                jws_serializers: ['jws_compact']
                jwe_serializers: ['jwe_compact']
        builders:
            nested_token_builder:
                signature_algorithms: ['RS256']
                key_encryption_algorithms: ['A128KW']
                content_encryption_algorithms: ['A128CBC-HS256']
                jws_serializers: ['jws_compact']
                jwe_serializers: ['jwe_compact']

Usage:

$jws = $loader->load($token, $encryption_key_set, $signature_key_set);

Remaining tasks:

  • Create a NestedTokenBuilder
  • Write documentation

Spomky and others added 2 commits February 17, 2018 14:39
@Spomky Spomky self-assigned this Feb 17, 2018
@Spomky Spomky added this to the Version 1.1.0 milestone Feb 17, 2018
@Spomky Spomky mentioned this pull request Feb 17, 2018
@coveralls
Copy link

coveralls commented Feb 17, 2018

Coverage Status

Coverage increased (+0.9%) to 85.717% when pulling ce810b1 on NestedTokens into 7055ece on v1.1.

@Spomky Spomky merged commit f8c2bc0 into v1.1 Feb 18, 2018
@Spomky Spomky deleted the NestedTokens branch February 18, 2018 08:54
Spomky added a commit that referenced this pull request Feb 18, 2018
Fix #65 Nested Token Support
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants