Expiring Confirmation Links 

Basics 

Every link femanager sends by email carries a signed expiration date and stops working once that date has passed. This applies to all four workflows:

  • the double-opt-in link the newly registered user receives,
  • the confirmation and refusal links the administrator receives for a registration,
  • the confirmation and refusal links the administrator receives for a profile change,
  • the invitation link.

The default lifetime is one day. Setting the lifetime to 0 disables the expiration, which restores the behaviour of femanager 13 and earlier, where a link stayed valid forever.

The expiration date is part of the signed value, so it cannot be manipulated. No database field is involved and nothing has to be cleaned up.

Besides the expiration date the signature is bound to the uid of the user and to the workflow step the link belongs to, so a link works neither for another user nor for another step. The uid and not the username is signed, because TYPO3 does not enforce unique usernames. Renaming a user therefore keeps the links already sent to them working until they expire.

Note: opening a form with a valid link issues a fresh link for the form itself, so filling in the invitation form or the confirmation dialog cannot fail because the original link expired in the meantime.

TypoScript Settings 

The lifetime is configured per workflow, in seconds:

plugin.tx_femanager {
	settings {
		new {
			# Seconds a registration confirmation link stays valid. 0 lets the links never expire.
			confirmationLinkLifetime = {$plugin.tx_femanager.settings.new.confirmationLinkLifetime}
		}
		edit {
			# Seconds a profile change confirmation link stays valid. 0 lets the links never expire.
			confirmationLinkLifetime = {$plugin.tx_femanager.settings.edit.confirmationLinkLifetime}
		}
		invitation {
			# Seconds an invitation link stays valid. 0 lets the links never expire.
			confirmationLinkLifetime = {$plugin.tx_femanager.settings.invitation.confirmationLinkLifetime}
		}
	}
}
Copied!

Rate limiting 

Requesting a new confirmation mail is subject to the same rate limiter as the registration itself, see Rate Limiter.