[Ur] Request environment variables

Karn Kallio tierpluspluslists at gmail.com
Fri Jul 27 22:34:12 EDT 2012


> Hello all,
> 
> Servers pass a lot of interesting information to the CGI
> programs in the form of environment variables (for example,
> if you do client cert authentication, that info comes in the
> form of an environment variable.)  It would be great if
> Ur/Web could access that information.
> 
> Now, implementing this requires a little bit of cooperation
> from the SAPIs, since, for example, FastCGI passes in its
> environment variables from the wire, so just calling getenv
> doesn't work.  But probably a 'getenv : string -> transaction string'
> would work reasonably well.
> 
> Thoughts?
> 

Maybe

type env_var_name = string
type env_var_content = string

val getenv : transaction (list (env_var_name * env_var_content))

to receive the complete environment at once?






More information about the Ur mailing list