10Duke Enterprise C++ SDK
Toggle main menu visibility
Loading...
Searching...
No Matches
JWKSDownloader.h
1
#ifndef TENDUKE_JWK_JWKSDOWNLOADER_H
2
#define TENDUKE_JWK_JWKSDOWNLOADER_H
3
4
#include "http/HTTPClient.h"
5
#include "http/HTTPResponseToException.h"
6
#include "jwk/JWKS.h"
7
#include "jwk/JWKSParser.h"
8
#include <memory>
9
#include <string>
10
11
namespace
tenduke
{
namespace
jwk
{
12
16
class
JWKSDownloader
17
{
18
public
:
19
virtual
~JWKSDownloader
() =
default
;
20
27
JWKSDownloader
(
28
const
std::shared_ptr<const tenduke::http::HTTPClient> &http,
29
const
std::shared_ptr<const tenduke::jwk::JWKSParser> &parseJwks,
30
const
std::shared_ptr<const tenduke::http::HTTPResponseToException> &throwException
31
);
32
39
virtual
std::unique_ptr<tenduke::jwk::JWKS>
from
(
const
std::string &url)
const
;
40
41
protected
:
47
virtual
std::string
download
(
const
std::string &url)
const
;
48
49
private
:
50
const
std::shared_ptr<const tenduke::http::HTTPClient> http;
51
const
std::shared_ptr<const tenduke::jwk::JWKSParser> parseJWKS;
52
const
std::shared_ptr<const tenduke::http::HTTPResponseToException> throwException;
53
};
54
55
}}
56
57
#endif
//TENDUKE_JWK_JWKSDOWNLOADER_H
tenduke::jwk::JWKSDownloader::JWKSDownloader
JWKSDownloader(const std::shared_ptr< const tenduke::http::HTTPClient > &http, const std::shared_ptr< const tenduke::jwk::JWKSParser > &parseJwks, const std::shared_ptr< const tenduke::http::HTTPResponseToException > &throwException)
Constructs new instance.
Definition
JWKSDownloader.cpp:39
tenduke::jwk::JWKSDownloader::download
virtual std::string download(const std::string &url) const
Downloads content of given URL and returns the payload as string.
Definition
JWKSDownloader.cpp:17
tenduke::jwk::JWKSDownloader::from
virtual std::unique_ptr< tenduke::jwk::JWKS > from(const std::string &url) const
Downloads and parses the JWKS-document.
Definition
JWKSDownloader.cpp:11
tenduke::jwk
Support for JSON Web Keys.
Definition
DynamicJWKSSignatureValidator.h:9
tenduke
Root for classes, functions and globals of 10Duke C++ Client.
Definition
APIRequest.h:4
core
core
src
jwk
JWKSDownloader.h
Generated by
1.17.0