Package io.meeds.social.security.plugin
Class UserAccountEmailOtpPlugin
java.lang.Object
io.meeds.social.security.plugin.EmailOtpPlugin
io.meeds.social.security.plugin.UserAccountEmailOtpPlugin
- All Implemented Interfaces:
io.meeds.web.security.plugin.OtpPlugin
Same OTP mechanics as
EmailOtpPlugin (generation, TTL, length, send
interval, single-use consumption) and the same email wording, under its
own subject, for the confirmation of an administrator session before
actions on user accounts. Its template is a copy of the base one under its
own path, so a deployment can replace this email on its own, as it can the
other code emails.
The code is stored under a purpose-bound cache key, so a code sent for
another flow never confirms an administrator session.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class io.meeds.social.security.plugin.EmailOtpPlugin
canUse, consumeOtp, generateOtpCode, getCacheKey, getCodeTtlMinutes, getSendIntervalSeconds, validateOtp
-
Field Details
-
NAME
- See Also:
-
-
Constructor Details
-
UserAccountEmailOtpPlugin
public UserAccountEmailOtpPlugin()
-
-
Method Details
-
getName
- Specified by:
getNamein interfaceio.meeds.web.security.plugin.OtpPlugin- Overrides:
getNamein classEmailOtpPlugin
-
getEmailBodyPath
-
getEmailSubjectKey
- Overrides:
getEmailSubjectKeyin classEmailOtpPlugin
-
releasesSendLockOnWrongCode
protected boolean releasesSendLockOnWrongCode()The confirmation dialog offers a new code right after a wrong one, so this method alone lifts its send lock on a wrong code- Overrides:
releasesSendLockOnWrongCodein classEmailOtpPlugin
-