Start of an attempt to generalize SessionUser mechanism