473,320 Members | 1,936 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

How to route a request to a proxy server?

Normally, in ASP.NET applications, we read from a Request object and
write to the Response buffer.

However, I wish to read the request object, do some validations on it,
and route the request to a proxy server. How is routing a request to a
proxy server achieved in ASP.NET?
Sep 15 '08 #1
2 1690
you don't explain what you are trying to do. if you just need to see the
first request, then redirect to the proxy.

if you are trying to intercept all traffic to the proxy, then you are
writing a proxy server. you will need to open a conteention to the proxy pass
the data, and return the response. you will also need to map all content
(*.jpg for example) to your app and pass thses on too (or parse the html and
change urls). you will also need to handle remapping the cookies.

-- bruce (sqlwork.com)
"Water Cooler v2" wrote:
Normally, in ASP.NET applications, we read from a Request object and
write to the Response buffer.

However, I wish to read the request object, do some validations on it,
and route the request to a proxy server. How is routing a request to a
proxy server achieved in ASP.NET?
Sep 15 '08 #2
Hi Bruce,

Here's what I am trying to do.

Let's say my app is called MyApp. MyApp has a WebForm called
MyApp.aspx. This web form has a text box named txtInput.

The user browses to MyApp.aspx and enteres the string "foo" into
txtInput. He submits the page via a POST method.

MyApp gets this request. It:

a) authenticates the user;
b) does some validation on the input entered by the user, ie. on the
string "foo".
c) if it wants to handle the request directly, it does so. In this
case, handling the request directly always involves redirecting the
user to some other page. So, in this case, MyApp simply says:

Response.Redirect("http://anotherURL.com/");

d) if MyApp does NOT wish to directly redirect the user, but wants to
send the request for redirection to some other reverse proxy, that
will then perform the redirection, how does MyApp do that? That is my
question.



On Sep 15, 4:08 pm, bruce barker
<brucebar...@discussions.microsoft.comwrote:
you don't explain what you are trying to do. if you just need to see the
first request, then redirect to the proxy.

if you are trying to intercept all traffic to the proxy, then you are
writing a proxy server. you will need to open a conteention to the proxy pass
the data, and return the response. you will also need to map all content
(*.jpg for example) to your app and pass thses on too (or parse the html and
change urls). you will also need to handle remapping the cookies.

-- bruce (sqlwork.com)

"Water Cooler v2" wrote:
Normally, in ASP.NET applications, we read from a Request object and
write to the Response buffer.
However, I wish to read the request object, do some validations on it,
and route the request to a proxy server. How is routing a request to a
proxy server achieved in ASP.NET?
Sep 15 '08 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

18
by: Chris Travers | last post by:
Hi all; I have been looking into how to ensure that synchronous replication, etc. could best be implimented. To date, I see only two options: incorporate the replication code into the database...
5
by: Henrik | last post by:
Hi, I am trying to read some industrial webservers using the HTTP/CGI webequest like this: wrs = (HttpWebRequest)WebRequest.Create(HTTP/CGI-string); mwst = (HttpWebResponse wrs.GetResponse();...
3
by: Codex Twin | last post by:
Hello apologies if this is the wrong newsgroup to be sending this to. Basically, I have an ASP.NET application that I am trying to force to use a proxy server settings. This can be done by...
4
by: Jit Prasad | last post by:
I have a working client-side Vb.Net (.net v1.0) app that talks to a Webspere webservice on a windows 2000 server. The client side app runs on a citrix server, also a Windows 2000 server. The app...
8
by: Tim Reynolds | last post by:
Our .Net application calls a web method of aplpication 2 that resides on their Apache server. When I as a developer C#, Studios 2003, make the call to their web method from my desktop, I receive no...
47
by: Max | last post by:
Due to the behaviour of a particular COM object, I need to ensure that a request for a particular ASP page is finalized before another request for the page is processed. Does IIS have a way to...
4
by: figelwump | last post by:
All, I am writing an HTTP 1.1 compliant proxy in c#.NET, for use as a proxy server for any web browser (IE, firefox, etc). I've got it working fine for GET requests. However, when a POST...
2
by: =?Utf-8?B?U2Fs?= | last post by:
<I MOVED THIS POST TO ITS OWN THREAD. ORIGINAL POST FOUND HERE:...
1
by: Rodrigo Brayner | last post by:
Hi all, I am having a problem when trying to use XMLHttpRequest with a proxy server. The issue is that I want to change the Request-URI from the header. Here is part of the code: var url =...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.