Eco,
I think this requires some java code: Store the link for the user, so that you can retrieve this on logout. Implement your own logout button that calls a microflow, retrieving the user's link. In the microflow call a java action, pass it the link, and kill the user session and redirect to the link.
Hope this helps you in the direction of a solution.