Marmistrz has ported the sign-on system from harmattan to fremantle I think, so that could be of help.