- Your app signs the person out of Aiveth (OpenID Connect RP-Initiated Logout). The person leaves your app and their Aiveth session ends.
- Aiveth tells your app that someone signed out (OpenID Connect Back-Channel Logout). When an Aiveth session ends, for any reason, Aiveth posts a signed notice to your server.
Set up sign-out for an app
1
Open the app
In the console, open Apps and select the app.
2
Add sign-out return addresses
Under Signing out → After sign-out, back to, add one address per line, for example
https://hr.acme.com/signed-out. After signing out through Aiveth, people come back only to one of these.3
Add a back-channel address (optional)
Under Tell the app when someone signs out, add the address where your server receives notices, for example
https://hr.acme.com/aiveth/signed-out. It must be a public https address.4
Save
Select Save.
Sign the person out from your app
Send the browser to the end-session endpoint, withGET or a form POST:
An ID token Aiveth issued to your app for this person. An expired one is fine. It proves the request is genuine.
Your client ID. If you send both, it must match the
aud of the ID token. If you leave it out, Aiveth takes it from the ID token.Where to send the person afterwards. It must match one of the app’s After sign-out, back to addresses exactly, and the app must be on.
What happens
- With proof, the person is signed out at once. The proof is an
id_token_hintissued to your app, for the person signed in to Aiveth in this browser, for this session (itssidmatches). Aiveth ends the session and redirects to yourpost_logout_redirect_uri. - Without proof, Aiveth asks first. The person sees “Do you want to sign out of Aiveth? You’ll be signed out of the apps you signed in to with it, too.” and a Sign out button. A link alone never signs anyone out.
- If nobody is signed in, Aiveth just redirects (or shows “You’re signed out of Aiveth.”).
- If the return address isn’t registered, Aiveth stays on its own page and says “You’re signed out of Aiveth.”
Hear when someone signs out (back-channel)
When an Aiveth session ends, Aiveth posts a logout token to your back-channel address as a form:
It never contains a
nonce.
To handle it:
- Verify the signature,
iss,audandexp, and check thateventscontains the back-channel logout member. - End your own session for that
sid(or every session of thatsub). - Answer
200.
What ends, and when you hear
- One session ends (the person signs out, or the session runs out): the sign-ins that came from that session end. Sign-ins with a refresh token (
offline_access) stand, as the specification says. - Everything of a person ends (a password change or reset, an admin’s “sign out everywhere”, a suspension or removal): every sign-in of that person ends.
- Your app revoking its own refresh token at
/oauth/revokealso sends a notice.
Retries
Aiveth tries at once, then after 5 seconds, 5 minutes and 30 minutes. A400 answer means your app refused the notice, and Aiveth stops trying. Aiveth posts only to public https addresses and does not follow redirects.