Hello, you could use jwt.io. It requires a service to make a login, after that you can share a token between your apps so that only logged users can make requests to your api. Here is a working example, a microservice for login, for you use a shared key between your apps: https://github.com/danizavtz/tokenAuth
On 23 August 2017 at 07:42, <[email protected]> wrote: > Hello, > > I have 3 local services in my server at: > > - localhost:3001 > - localhost:3002 > - localhost:3003 > > I do not want to expose them directly to the outside, so those ports are > only open to local connections. > > I want to build a simple front-end with user authentication, so that when > a user is logged in he can access to the 3 services from the outside. > > - http://www.mydomain.com/ > - login > - service 1 > - service 2 > - service 3 > > I was thinking on using a nodejs based proxy so that only logged users can > get access to the services, but I am not sure if this is posible, and in > case it is, which would be the best combination of modules to do so. > > Does someone know a simple approach to get this done? > > Thanks! > > -- > Job board: http://jobs.nodejs.org/ > New group rules: https://gist.github.com/othiym23/9886289#file- > moderation-policy-md > Old group rules: https://github.com/joyent/node/wiki/Mailing-List- > Posting-Guidelines > --- > You received this message because you are subscribed to the Google Groups > "nodejs" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/nodejs/e4efef67-6d5d-46d1-ad0f-293f698c7e76%40googlegroups.com > <https://groups.google.com/d/msgid/nodejs/e4efef67-6d5d-46d1-ad0f-293f698c7e76%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- []'s -- Job board: http://jobs.nodejs.org/ New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines --- You received this message because you are subscribed to the Google Groups "nodejs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/CAET7tnZcaYMmVQ2ap%2ByyvWjNZzUnkpYnFmhAc2xXuzDh%2B%3DEf3A%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
