mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-24 16:23:40 +01:00
Add no-store hint to CAPTCHA challenge stanzas (#2730)
This commit is contained in:
parent
34eed5064b
commit
1246a7a50f
@ -105,12 +105,13 @@ create_captcha(SID, From, To, Lang, Limiter, Args) ->
|
||||
"To unblock them, visit ~s">>, [JID, get_url(Id)]},
|
||||
Body = xmpp:mk_text(BodyString, Lang),
|
||||
OOB = #oob_x{url = get_url(Id)},
|
||||
Hint = #hint{type = 'no-store'},
|
||||
Tref = erlang:send_after(?CAPTCHA_LIFETIME, ?MODULE,
|
||||
{remove_id, Id}),
|
||||
ets:insert(captcha,
|
||||
#captcha{id = Id, pid = self(), key = Key, tref = Tref,
|
||||
args = Args}),
|
||||
{ok, Id, Body, [OOB, Captcha, Data]};
|
||||
{ok, Id, Body, [Hint, OOB, Captcha, Data]};
|
||||
Err -> Err
|
||||
end.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user