public class OtpAuthHandler extends Object implements AuthenticationHandler, Handler<RoutingContext>
original
non RX-ified interface using Vert.x codegen.Modifier and Type | Field and Description |
---|---|
static io.vertx.lang.rx.TypeArg<OtpAuthHandler> |
__TYPE_ARG |
Constructor and Description |
---|
OtpAuthHandler(Object delegate) |
OtpAuthHandler(OtpAuthHandler delegate) |
Modifier and Type | Method and Description |
---|---|
static OtpAuthHandler |
create(HotpAuth hotpAuth)
Create a new instance of this handler using a hash based one time password authentication provider.
|
static OtpAuthHandler |
create(TotpAuth totpAuth)
Create a new instance of this handler using a time based one time password authentication provider.
|
boolean |
equals(Object o) |
OtpAuthHandler |
getDelegate() |
void |
handle(RoutingContext event)
Something has happened, so handle it.
|
int |
hashCode() |
OtpAuthHandler |
issuer(String issuer)
Configure the
issuer value to be shown in the authenticator URL. |
OtpAuthHandler |
label(String label)
Configure the
label value to be shown in the authenticator URL. |
static OtpAuthHandler |
newInstance(OtpAuthHandler arg) |
OtpAuthHandler |
setupCallback(Route route)
Setup the required route where authenticators to submit the challenge response.
|
OtpAuthHandler |
setupRegisterCallback(Route route)
Setup the optional route where authenticators are allowed to register.
|
String |
toString() |
OtpAuthHandler |
verifyUrl(String url)
Specify the URL where requests are to be redirected when a user is already known in the request.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
newInstance
public static final io.vertx.lang.rx.TypeArg<OtpAuthHandler> __TYPE_ARG
public OtpAuthHandler(OtpAuthHandler delegate)
public OtpAuthHandler(Object delegate)
public OtpAuthHandler getDelegate()
getDelegate
in interface AuthenticationHandler
public void handle(RoutingContext event)
handle
in interface Handler<RoutingContext>
handle
in interface AuthenticationHandler
event
- the event to handlepublic static OtpAuthHandler create(TotpAuth totpAuth)
totpAuth
- the time based OTP provider.public static OtpAuthHandler create(HotpAuth hotpAuth)
hotpAuth
- the hash based OTP provider.public OtpAuthHandler verifyUrl(String url)
null
.
If no redirect is provided, requests are terminated immediately with status code 401
.url
- the location where users are to be asked for the OTP code.public OtpAuthHandler setupRegisterCallback(Route route)
null
.route
- the location where users are to register new authenticator devices/apps.public OtpAuthHandler setupCallback(Route route)
null
.route
- the location where users are to submit challenge responses from authenticator devices/apps.public OtpAuthHandler issuer(String issuer)
issuer
value to be shown in the authenticator URL.issuer
- a String
for example Vert.x OTP
public OtpAuthHandler label(String label)
label
value to be shown in the authenticator URL. When this value is provided it will
overwrite the default label which is composed of the issuer
and the current user
id.label
- a String
for example Vert.x OTP
public static OtpAuthHandler newInstance(OtpAuthHandler arg)
Copyright © 2024 Eclipse. All rights reserved.