0

My system has this architecture:

  1. 'Hidden' server A (written in Java) which allow connection only from server B. There is no authentication in A. Server A have very rich API
  2. Server B (PHP, laravel5, MySQL) 'middleware' which have users table and which authenticate user using JWT
  3. File Server C with frontend angular2 app which will use rich API (indirectly from server A).

Server B only authenticates users and should pass they request to server A with very simple mapping (almost one-to-one - only request URL prefixes can changes).

The Question is, How to make such mapping (receive, authenticate JWT, 'redirect' requests to server B, and give back a response from A to web browser) with the less effort in travel? Or maybe this architecture is not good at all?

Please give me an only idea and 'keywords' (not necessarily full implementation :P ).

Kamil Kiełczewski
  • 85,173
  • 29
  • 368
  • 345
  • 1
    Can you change it so angular2 only communicates with server A. Server A contacts Server B with credentials from angular to determine if it's a valid user? That way Server B doesn't need to be concerned about all the API calls, just authentication? – user1669496 Jul 14 '16 at 21:00
  • My client want tho have A server (which contains some important data) separate from rest of the world (only server B have access). – Kamil Kiełczewski Jul 14 '16 at 21:25

0 Answers0