10Duke Enterprise C++ SDK
Toggle main menu visibility
Loading...
Searching...
No Matches
Sanitize.h
1
#ifndef TENDUKE_LOG_SANITIZE_H
2
#define TENDUKE_LOG_SANITIZE_H
3
4
#include <cstddef>
5
#include <string>
6
#include <vector>
7
8
namespace
tenduke
{
namespace
log
{
9
11
const
std::size_t
DEFAULT_SANITIZED_MAX_LENGTH
= 64;
12
23
std::string
sanitize
(
const
std::string &untrusted, std::size_t maxLength =
DEFAULT_SANITIZED_MAX_LENGTH
);
24
32
std::string
redactQueryParameters
(
const
std::string &url,
const
std::vector<std::string> ¶meterNames);
33
34
}}
35
36
#endif
//TENDUKE_LOG_SANITIZE_H
tenduke::log
Logging support.
Definition
DevNullLogger.h:6
tenduke::log::sanitize
std::string sanitize(const std::string &untrusted, std::size_t maxLength=DEFAULT_SANITIZED_MAX_LENGTH)
Makes an untrusted value (e.g.
Definition
Sanitize.cpp:5
tenduke::log::DEFAULT_SANITIZED_MAX_LENGTH
const std::size_t DEFAULT_SANITIZED_MAX_LENGTH
Default maximum length of a sanitized value, see tenduke::log::sanitize().
Definition
Sanitize.h:11
tenduke::log::redactQueryParameters
std::string redactQueryParameters(const std::string &url, const std::vector< std::string > ¶meterNames)
Replaces the values of the given query parameters of a URL with REDACTED, for logging a URL that carr...
Definition
Sanitize.cpp:21
tenduke
Root for classes, functions and globals of 10Duke C++ Client.
Definition
APIRequest.h:4
core
core
src
log
Sanitize.h
Generated by
1.17.0