MCPcopy Create free account
hub / github.com/3rdparty/libprocess / Authenticator

Class Authenticator

include/process/authenticator.hpp:103–127  ·  view source on GitHub ↗

* The Authenticator interface allows us to implement different * authenticators based on the scheme (e.g. Basic, Digest, SPNEGO). */

Source from the content-addressed store, hash-verified

101 * authenticators based on the scheme (e.g. Basic, Digest, SPNEGO).
102 */
103class Authenticator
104{
105public:
106 virtual ~Authenticator() {}
107
108 /**
109 * Authenticates the given HTTP request.
110 *
111 * NOTE: Libprocess does not perform any timeout handling of
112 * the returned future, it is thus required that this future
113 * is satisfied within a finite amount of time! Otherwise,
114 * the socket will be remain open indefinitely!
115 */
116 // TODO(arojas): Add support for per-connection authentication.
117 // Note that passing the socket is dangerous here because the
118 // authenticator may hold a copy preventing the reference
119 // counted socket from being closed.
120 virtual Future<AuthenticationResult> authenticate(
121 const Request& request) = 0;
122
123 /**
124 * Returns the name of the authentication scheme implemented.
125 */
126 virtual std::string scheme() const = 0;
127};
128
129
130/**

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected