gextra
gextra

Reputation: 8885

How to setup user signon authentication in Mochiweb?

It appears that erlang's mochiweb does not have any configuration that allows to setup a logon redirect user authentication. How could this be implemented ?

Upvotes: 0

Views: 144

Answers (1)

Masse
Masse

Reputation: 4344

Mochiweb is a low-level library and as such it doesn't have any authentication/authorization layer out of the box. You need to implement such functionality by yourself.

There is a lot to take into consideration when implementing such system by yourself, but take a look at this answer

To simplify things a bit, you can third party log-in services such as persona. Even if you use third party services you still need a persistence layer where you save at least a list of registered users and a way to get information from forms or javascript. Check out this tutorial on how to access request information. For the persistence, erlang comes with ets/dets and mnesia so that you don't need to install any extra software, at least at the beginning.

Upvotes: 1

Related Questions