The Maverick Legacy Server has no direct method of calling back your code when a user logs off.
However, this can easily be handled by the event framework by capturing the EVENT_DISCONNECT event that indicates the user disconnected.
EventServiceImplementation.getInstance().addListener(
new EventListener() {
public void processEvent(Event evt) {
if(evt.getId()==SSHDEventCodes.EVENT_DISCONNECTED) {
Connection con = (Connection) evt.getAttribute(SSHDEventCodes.ATTRIBUTE_CONNECTION);
// Do logoff processing with con.getUsername()
}
}
});