webmail: rename query string param "token" to "singleUseToken" to be less scary in access logs

these singleusetokens can be redeemed once. so when you see it in the logs, it
can't be used again. they are short-lived anyway.

this change should help prevent me periodically investigating token handling...
This commit is contained in:
Mechiel Lukkien
2024-08-23 15:08:27 +02:00
parent a977082b89
commit 594182aae5
10 changed files with 35 additions and 29 deletions

View File

@ -7208,7 +7208,7 @@ const init = async () => {
}
} catch (err) {}
eventSource = new window.EventSource('events?token=' + encodeURIComponent(token)+'&request='+encodeURIComponent(JSON.stringify(request))+slow)
eventSource = new window.EventSource('events?singleUseToken=' + encodeURIComponent(token)+'&request='+encodeURIComponent(JSON.stringify(request))+slow)
let eventID = window.setTimeout(() => dom._kids(statusElem, 'Connecting... '), 1000)
eventSource.addEventListener('open', (e: Event) => {
log('eventsource open', {e})