You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Cameron Smith <sh...@gmail.com> on 2009/10/29 14:30:49 UTC

[users@httpd] Sending Unprompted HTTP Responses

Hello, My name is Cameron Smith, and I have a query about Apache HTTP Server.

Is it possible to use Apache to create and send an HTTP Response to
a specified uri, without necessarily responding to a particular HTTP
Request?

I am running Perl 5.8.8 scripts on an Apache HTTP web
server which is running on a linux machine.

I need to receive one HTTP Request, and respond with multiple HTTP
Responses (for the purpose of testing error conditions in a piece of
software.) This is not the kind of thing that would generally make any
sense, as there is generally one HTTP Request followed by one matching
HTTP Response.

I print my HTTP Response Header to <STDOUT>, followed by a blank line,
followed by the HTTP Response Body.  Can I then somehow end that
HTTP Response by maybe printing some special characters, and then
print another HTTP Response Header, blank line and body combo?  If not,
then is there some config I could change to send multiple responses? Or is
it basically impossible, as it doesn't really conform to the HTTP Protocol?

Hope you can help,

Cheers,

Cameron

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Sending Unprompted HTTP Responses

Posted by Eric Covener <co...@gmail.com>.
> Or is
> it basically impossible, as it doesn't really conform to the HTTP Protocol?

I believe that's the case. Clients are expecting a 1:1 relationship.

-- 
Eric Covener
covener@gmail.com

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org