Sourcemeta Core 0.0.0
Loading...
Searching...
No Matches
oidc_hash.h
1#ifndef SOURCEMETA_CORE_OIDC_HASH_H_
2#define SOURCEMETA_CORE_OIDC_HASH_H_
3
4#ifndef SOURCEMETA_CORE_OIDC_EXPORT
5#include <sourcemeta/core/oidc_export.h>
6#endif
7
8#include <sourcemeta/core/jose.h>
9
10#include <optional> // std::optional
11#include <string> // std::string
12#include <string_view> // std::string_view
13
14namespace sourcemeta::core {
15
37SOURCEMETA_CORE_OIDC_EXPORT
38auto oidc_token_hash(const std::string_view token, const JWSAlgorithm algorithm)
39 -> std::optional<std::string>;
40
54SOURCEMETA_CORE_OIDC_EXPORT
55auto oidc_verify_token_hash(const std::string_view token,
56 const JWSAlgorithm algorithm,
57 const std::string_view claim) -> bool;
58
59} // namespace sourcemeta::core
60
61#endif
JWSAlgorithm
Definition jose_algorithm.h:21
SOURCEMETA_CORE_OIDC_EXPORT auto oidc_verify_token_hash(const std::string_view token, const JWSAlgorithm algorithm, const std::string_view claim) -> bool
SOURCEMETA_CORE_OIDC_EXPORT auto oidc_token_hash(const std::string_view token, const JWSAlgorithm algorithm) -> std::optional< std::string >