English 中文(简体)
Securely Transferring Users Between Web Sites
原标题:

Here s the scenario:

  • You have two seperate websites that exist in different environments (I.E. different databases, different web servers/domains)
  • You have full control over the code for both sites, but from the above point, they can not directly communicate with each other s database
  • You must transfer user from site A to site B securely

What is the best way to implement this? Simply sending the user identifier between the sites via query string wouldn t be secure, even if encrypted, since someone else could obtain the URL. It seems like the standard solution is to pass the user identifier along with another temporary key that web site A created, and web site B knows about. If this is the case, what s the proper way of securely setting up the system with the temporary key?

Thanks!

最佳回答

Write a web-service call over HTTPS, at both ends, to retrieve the users details, and that only works for a specific login-pair. Problem solved. You need to make the login-id s at both ends uniform or use single sign on cookies. More details in the paper by Vipin Samar: "Single Sign on Cookies for Web Applications".

They can t get the URL/Passwords unless they go into the application code at one of the servers.

问题回答

I am doing something like this. The best thing I can think of right now is passing a HASH of the user ID, or if that makes you worry, the hash of some other user data.

If yuo want temporary keys(I might do something like this too), how about setting up a web service on A that B can call to to get the user ID based on the temporary key. This way it s a totally separate call, and can be secured.

Take a look at "Pass-through Authentication," its a concept that allows a user s identity to be passed from one system to another.

Additionally, another idea that you may want to try is to create a secure token that does not expose the user s information and pass it on. However, this requires both systems to have similar data to verify the token. As the other answer suggested, hashes are very good uses to create non-descriptive bits about sensitive information.

You need to pass information between Site A and Site B, but you don t need to make the user the conduit for that information.

Site B could have a web-service that allows Site A to create a session for the user. In this design the interaction would go as follows:

  • User clicks button on Site A
  • Site A calls web-service on Site B which passes a temporary login URL back to Site A
  • Site A redirects user to the temporary URL on Site B




相关问题
Signed executables under Linux

For security reasons, it is desirable to check the integrity of code before execution, avoiding tampered software by an attacker. So, my question is How to sign executable code and run only trusted ...

MALICIOUS_CODE EI_EXPOSE_REP Medium

I run findbugs against all of my code and only tackle the top stuff. I finally got the top stuff resolved and now am looking at the details. I have a simple entity, say a user: public class User ...

XSS on jsbin.com

Anyone know if jsbin.com implements any protection for XSS or other javascript attacks? I see jsbin links used fairly regularly on sites like this one and I can t find any indication from the site ...

Make md5 strong

Im making a website that will intergrate with game that only support md5 hashing metod (atm). Which ofc is not especially safe anymore. But how could i make it stronger? Should I just generate long ...

Why running a service as Local System is bad on windows?

I am trying to find out the difference between difference service account types. I tumbled upon this question. The answer was because it has powerful access to local resources, and Network Service ...

Brute-force/DoS prevention in PHP [closed]

I am trying to write a script to prevent brute-force login attempts in a website I m building. The logic goes something like this: User sends login information. Check if username and password is ...

热门标签