10Duke Scale C++ Client
All Classes Namespaces Files Functions Variables Typedefs Enumerations Pages
JWK.h
1#ifndef TENDUKE_JWK_JWK_H
2#define TENDUKE_JWK_JWK_H
3
4#include "crypto/PublicKey.h"
5#include "crypto/MessageDigest.h"
6
7#include <memory>
8#include <string>
9
10namespace tenduke { namespace jwk {
11
17class JWK {
18public:
25 JWK(
26 std::string id,
27 std::string type,
28 const std::shared_ptr<const tenduke::crypto::PublicKey> &key
29 );
30
32 const std::string id;
34 const std::string type;
36 const std::shared_ptr<const tenduke::crypto::PublicKey> key;
37
45 static tenduke::crypto::MessageDigest::Algorithm mapFromJWTAlgorithm(const std::string &jwtAlgorithm);
46};
47
48}}
49
50#endif //TENDUKE_JWK_JWK_H
Algorithm
Supported algorithms.
Definition MessageDigest.h:24
Describes a JWK, Json Web Key.
Definition JWK.h:17
const std::shared_ptr< const tenduke::crypto::PublicKey > key
Parsed key representation.
Definition JWK.h:36
const std::string id
Id of the key, JWK property "kid".
Definition JWK.h:32
const std::string type
Type of the key, JWK property "kty".
Definition JWK.h:34
JWK(std::string id, std::string type, const std::shared_ptr< const tenduke::crypto::PublicKey > &key)
Constructs new instance.
Definition JWK.cpp:6
static tenduke::crypto::MessageDigest::Algorithm mapFromJWTAlgorithm(const std::string &jwtAlgorithm)
Maps JSON Web Token algorithm (alg) to Algorithm.
Definition JWK.cpp:15
Root for classes, functions and globals of 10Duke C++ Client.
Definition BackendConfiguration.h:7