Package io.servicetalk.http.utils.auth
Class BasicAuthHttpServiceFilter<UserInfo>
java.lang.Object
io.servicetalk.http.utils.auth.BasicAuthHttpServiceFilter<UserInfo>
- Type Parameters:
UserInfo
- a type for authenticated user info object
- All Implemented Interfaces:
HttpExecutionStrategyInfluencer
,StreamingHttpServiceFilterFactory
,ExecutionStrategyInfluencer<HttpExecutionStrategy>
public final class BasicAuthHttpServiceFilter<UserInfo>
extends Object
implements StreamingHttpServiceFilterFactory
A
StreamingHttpServiceFilter
, which filters HTTP requests using
RFC7617: The 'Basic' HTTP Authentication Scheme.- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
A builder for anStreamingHttpServiceFilter
, which filters HTTP requests using RFC7617: The 'Basic' HTTP Authentication Scheme.static interface
Verifiesuser-id
andpassword
, parsed from the 'Basic' HTTP Authentication Scheme credentials. -
Method Summary
Modifier and TypeMethodDescriptioncreate
(StreamingHttpService service) Create aStreamingHttpServiceFilter
using the providedStreamingHttpService
.Return anExecutionStrategy
that describes the offloads required by the influencer.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.servicetalk.http.api.HttpExecutionStrategyInfluencer
influenceStrategy
-
Method Details
-
create
Description copied from interface:StreamingHttpServiceFilterFactory
Create aStreamingHttpServiceFilter
using the providedStreamingHttpService
.- Specified by:
create
in interfaceStreamingHttpServiceFilterFactory
- Parameters:
service
-StreamingHttpService
to filter- Returns:
StreamingHttpServiceFilter
using the providedStreamingHttpService
.
-
requiredOffloads
Description copied from interface:HttpExecutionStrategyInfluencer
Return anExecutionStrategy
that describes the offloads required by the influencer.The provided default implementation requests offloading of all operations. Implementations that require no offloading should be careful to return
HttpExecutionStrategies.offloadNone()
rather thanHttpExecutionStrategies.offloadNever()
. Implementations should avoid returningHttpExecutionStrategies.defaultStrategy()
, instead returning the strategy they require orHttpExecutionStrategies.offloadAll()
if offloading for all paths is required (safe default).- Specified by:
requiredOffloads
in interfaceExecutionStrategyInfluencer<UserInfo>
- Specified by:
requiredOffloads
in interfaceHttpExecutionStrategyInfluencer
- Returns:
- the
ExecutionStrategy
required by the influencer.
-