]> git.ipfire.org Git - thirdparty/squid.git/blame - src/auth/basic/Config.h
Simplify appending SBuf to String (#2108)
[thirdparty/squid.git] / src / auth / basic / Config.h
CommitLineData
bbc27441 1/*
1f7b830e 2 * Copyright (C) 1996-2025 The Squid Software Foundation and contributors
bbc27441
AJ
3 *
4 * Squid software is distributed under GPLv2+ license and includes
5 * contributions from numerous individuals and organizations.
6 * Please see the COPYING and CONTRIBUTORS files for details.
7 */
8
ff9d9458
FC
9#ifndef SQUID_SRC_AUTH_BASIC_CONFIG_H
10#define SQUID_SRC_AUTH_BASIC_CONFIG_H
5817ee13 11
a0026a6c
AJ
12#if HAVE_AUTH_MODULE_BASIC
13
3ad63615 14#include "auth/Gadgets.h"
ae578099 15#include "auth/SchemeConfig.h"
2d2b0bb7 16#include "auth/UserRequest.h"
24438ec5 17#include "helper/forward.h"
94439e4e 18
bb8909c3
A
19namespace Auth
20{
21namespace Basic
22{
62e76326 23
372fccd6 24/** Basic authentication configuration data */
dc79fed8 25class Config : public Auth::SchemeConfig
62e76326 26{
e6ccf245 27public:
372fccd6 28 Config();
337b9aa4
AR
29 bool active() const override;
30 bool configured() const override;
31 Auth::UserRequest::Pointer decode(char const *proxy_auth, const HttpRequest *request, const char *requestRealm) override;
32 void done() override;
33 void rotateHelpers() override;
34 bool dump(StoreEntry *, const char *, Auth::SchemeConfig *) const override;
35 void fixHeader(Auth::UserRequest::Pointer, HttpReply *, Http::HdrType, HttpRequest *) override;
36 void init(Auth::SchemeConfig *) override;
91d1cfb1 37 void parse(Auth::SchemeConfig *, size_t, char *) override;
c7baff40 38 void decode(char const *httpAuthHeader, Auth::UserRequest::Pointer);
337b9aa4
AR
39 void registerWithCacheManager(void) override;
40 const char * type() const override;
372fccd6
AJ
41
42public:
94439e4e 43 time_t credentialsTTL;
64658378 44 int casesensitive;
431aae42
AJ
45
46private:
7e851a3e 47 char * decodeCleartext(const char *httpAuthHeader, const HttpRequest *request);
94439e4e 48};
49
372fccd6
AJ
50} // namespace Basic
51} // namespace Auth
52
3bd118d6 53extern Helper::ClientPointer basicauthenticators;
fe0a0419 54
a0026a6c 55#endif /* HAVE_AUTH_MODULE_BASIC */
ff9d9458 56#endif /* SQUID_SRC_AUTH_BASIC_CONFIG_H */
f53969cc 57