Basic web server to server security question

  • Thread starter Thread starter J055
  • Start date Start date
J

J055

Hi

I need to provide some basic security between two web servers. It needs to
be simple to implement. The scenario is as follows:

1. User logs on to website using ASP.NET authentication/authorization
2. They see a list of hyperlinks to documents to download
3. The documents are located on another web server so the links are a
hyperlinks something like:

http://server1/download.aspx?doc1

4. The download.aspx page can locate the document on the second server via
http through a firewall simply filtering by the server1 IP address / post
80.

5. I need to send a post request with username/password for server2 to
authenticate, not sure how to do this
6. If authenticated then I want to load the document into memory on server1
and stream to the response. I know how to stream documents from the same
server but not sure how to do it from another server.

Can someone provide me with a good starting point or suggestions?

Many thanks
Andrew
 
You can send a post request using the httpwebrequest

HttpWebRequest req = (HttpWebRequest)WebRequest.Create("http://myurl.com");
req.Credentials = new NetworkCredential("myLogin", "myPwd");

You can send the stream to server1 and then send it to the client,. or why
not just present the URL to the client if authenticated and let them click
it.

Regards

John Timney (MVP)
http://www.johntimney.com
http://www.johntimney.com/blog
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top