Mercurial > openid
annotate src/ur/openidUser.urs @ 17:df2eb629f21a
Successfully created an account
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Thu, 06 Jan 2011 14:42:37 -0500 |
parents | 9851bc87b0d7 |
children | dd8eb53da51b |
rev | line source |
---|---|
adam@16 | 1 functor Make(M: sig |
adam@16 | 2 con cols :: {Type} |
adam@16 | 3 constraint [Id] ~ cols |
adam@17 | 4 val folder : folder cols |
adam@17 | 5 val inj : $(map sql_injectable cols) |
adam@16 | 6 (* Extra columns to add to the user database table *) |
adam@16 | 7 |
adam@17 | 8 type creationState |
adam@17 | 9 type creationData |
adam@17 | 10 val creationState : transaction creationState |
adam@17 | 11 val render : creationState -> xtable |
adam@17 | 12 val tabulate : creationState -> signal creationData |
adam@17 | 13 val choose : sql_table ([Id = string] ++ cols) [Pkey = [Id]] -> creationData -> transaction $cols |
adam@17 | 14 |
adam@16 | 15 val sessionLifetime : int |
adam@16 | 16 (* Number of seconds a session may live *) |
adam@16 | 17 |
adam@16 | 18 val afterLogout : url |
adam@16 | 19 (* Where to send the user after he logs out *) |
adam@16 | 20 |
adam@16 | 21 val secureCookies : bool |
adam@16 | 22 (* Should authentication cookies be restricted to SSL connections? *) |
adam@16 | 23 |
adam@16 | 24 val association : Openid.association_mode |
adam@16 | 25 (* OpenID cryptography preferences *) |
adam@16 | 26 |
adam@16 | 27 val realm : option string |
adam@16 | 28 (* See end of [Openid] module's documentation for the meaning of realms *) |
adam@17 | 29 |
adam@17 | 30 val formClass : css_class |
adam@16 | 31 end) : sig |
adam@16 | 32 |
adam@16 | 33 type user |
adam@16 | 34 val show_user : show user |
adam@16 | 35 val inj_user : sql_injectable_prim user |
adam@16 | 36 |
adam@16 | 37 table user : ([Id = user] ++ M.cols) |
adam@16 | 38 PRIMARY KEY Id |
adam@16 | 39 |
adam@16 | 40 val current : transaction (option user) |
adam@16 | 41 |
adam@16 | 42 val main : (string -> xbody -> transaction page) -> transaction xbody |
adam@16 | 43 (* Pass in your generic page template; get out the HTML snippet for user management *) |
adam@16 | 44 |
adam@16 | 45 end |