10Duke Enterprise C++ SDK
Toggle main menu visibility
Loading...
Searching...
No Matches
DefaultJWTParserFactory.h
1
#ifndef TENDUKE_JWT_DEFAULTJWTPARSERFACTORY_H
2
#define TENDUKE_JWT_DEFAULTJWTPARSERFACTORY_H
3
4
#include "./JWTParserFactory.h"
5
6
#include "json/JSONParser.h"
7
#include "utl/Base64Decoder.h"
8
9
namespace
tenduke
{
namespace
jwt
{
10
14
class
DefaultJWTParserFactory
:
public
JWTParserFactory
{
15
16
public
:
22
DefaultJWTParserFactory
(
23
const
std::shared_ptr<const tenduke::utl::Base64Decoder> &base64Decoder,
24
const
std::shared_ptr<const tenduke::json::JSONParser> &jsonParser
25
);
26
27
// tenduke::jwt::JWTParserFactory implementation
28
public
:
29
std::unique_ptr<const tenduke::jwt::JWTParser>
create
()
const override
;
30
std::unique_ptr<const tenduke::jwt::JWTParser>
create
(
31
const
std::shared_ptr<const tenduke::crypto::PublicKey> &publicKey,
32
tenduke::crypto::MessageDigest::Algorithm
algorithm
33
)
const override
;
34
std::unique_ptr<const tenduke::jwt::JWTParser>
create
(
const
std::shared_ptr<tenduke::jwt::JWTSignatureValidator> &signatureValidator)
const override
;
35
36
private
:
37
std::shared_ptr<const tenduke::utl::Base64Decoder> base64Decoder;
38
std::shared_ptr<const tenduke::json::JSONParser> jsonParser;
39
};
40
41
}}
42
43
#endif
//TENDUKE_JWT_DEFAULTJWTPARSERFACTORY_H
DefaultJWTParserFactory::DefaultJWTParserFactory
DefaultJWTParserFactory(const std::shared_ptr< const tenduke::utl::Base64Decoder > &base64Decoder, const std::shared_ptr< const tenduke::json::JSONParser > &jsonParser)
Constructs new instance.
Definition
DefaultJWTParserFactory.cpp:49
JWTParserFactory
Definition
JWTParserFactory.h:15
tenduke::crypto::MessageDigest::Algorithm
Algorithm
Supported algorithms.
Definition
MessageDigest.h:24
tenduke::jwt::DefaultJWTParserFactory::DefaultJWTParserFactory
DefaultJWTParserFactory(const std::shared_ptr< const tenduke::utl::Base64Decoder > &base64Decoder, const std::shared_ptr< const tenduke::json::JSONParser > &jsonParser)
Constructs new instance.
Definition
DefaultJWTParserFactory.cpp:49
tenduke::jwt::DefaultJWTParserFactory::create
std::unique_ptr< const tenduke::jwt::JWTParser > create(const std::shared_ptr< tenduke::jwt::JWTSignatureValidator > &signatureValidator) const override
Creates a tenduke::jwt::JWTParser, which validates the signature with given validator.
tenduke::jwt::DefaultJWTParserFactory::create
std::unique_ptr< const tenduke::jwt::JWTParser > create() const override
Creates tenduke::jwt::JWTParser, which does not validate signature.
Definition
DefaultJWTParserFactory.cpp:28
tenduke::jwt::DefaultJWTParserFactory::create
std::unique_ptr< const tenduke::jwt::JWTParser > create(const std::shared_ptr< const tenduke::crypto::PublicKey > &publicKey, tenduke::crypto::MessageDigest::Algorithm algorithm) const override
Creates a tenduke::jwt::JWTParser, which validates the signature with given public key and message di...
tenduke::jwt
Support for JSON Web Tokens.
Definition
DefaultJWTParser.h:11
tenduke
Root for classes, functions and globals of 10Duke C++ Client.
Definition
APIRequest.h:4
core
core
src
jwt
DefaultJWTParserFactory.h
Generated by
1.17.0