http

creating my own MJPEG stream

Hello everyone. I'm trying to create an MJPEG stream, I have a series of jpegs that I want to put together into a stream so that a user can just hit a URL and get an mjpeg stream. I've been trying for the last few days to get this to work, and it may just not be possible. I've brought up ethereal and listened to the packets coming from...

Problem authenticating by doing a POST to an HTTPS page.

This relates to my other question on accessing a REST service that uses forms authentication, but I feel it is substantially enough a discrete issue. When I paste a REST call into my browser address bar, before I am authenticated, I am redirected to a login page on the services web site. I log in and receive a cookie, which authenticat...

How do you consistently retrieve the path information from the query in php? (/index.php/foo/bar)

Basically if the user requests: index.php/foo/bar I need "/foo/bar" and for index.php I need "" or "/" I couldn't find any information on google because I don't know what this is called (path info got me the pathinfo() function) I found PHP_SELF returns differently if there is path info than if there is no info ...

HTTP Get content type

Hi everyone, I have a program that is supposed to interact with a web server and retrieve a file containing structured data using http and cgi. I have a couple questions: The cgi script on the server needs to specify a body right? What should the content-type be? Should I be using POST or GET? Could anyone tell me a good resource for ...

Weird IIS7 http redirection behavior

I have a web server running Windows Server 2008 with IIS7. I have a bunch of websites which are all bound to the same IP address, but with different host header values. Most of the host headers are something like www.sitename.com. I also have a corresponding website entry for each which listens for the host "sitename.com" and does a red...

2 valid requests and then timeout

Here is my code. It iterates all files from database and try to get the length of the web file. It works only 2 times. After that it gives timeout. If i restart the application it process again 2 files and then fail. I have no idea what might be the problem. I appreciate any help. public void GetFilesSize() { List<int> f...

How do I encode a file name for download?

When the file name is "Algunas MARCAS que nos acompañan" ASP.NET MVC raise an System.FormatExceptin when I try to download that file. But if the file name is "Asistente de Gerencia Comercial" it doesn't. I guess this is because something related to UTF-8 encoding, but I don't know how to encode that string. If I'm right, how can I enc...

http response message

I want to know that when browser sends a request do the server sends back the contents explicitly? And how would i confirm it? ...

Seeing duplicate http requests in server logs

Hi, I have started a small django application in my machine. When i have seen the request logs I figured out that It is actually logging the same requests twice. After a little investigation, I disabled all of my add-ons in my browser and tried. To my surprise i din't see duplicate requests in logs After that. After some trials I foun...

Handle http post request

Hi all! I have the following scenario to implement: I have an ASP.NET Web site. On a click of a button in my site the user is redirected to a 3rd party site. When the user does some actions in this 3rd party site, the site starts sending http post requests to my site with a special message every 1 minute. Now, the problem is that I sh...

How can I bind secondary IP address to urllib2

My server comes with one primary and five additional IP addresses. By default, urllib2 requests are all from primary IP addresses. How can I bind those secondary IP addresses to urllib2 with every reqeust it makes. ...

GZip encoding - what are the potential issues (old versions of IE etc)?

I can vaguely remember that there are certain older versions of certain browsers that do weird things with GZip encoding - in particular I seem to recall a bug in IE which resulted in JavaScript sent over GZip getting mangled. Vague recollections aren't much practical use though. Does anyone know exactly what kind of issues there are an...

ASP.NET MVC - HTTP Authentication Prompt

Hi there, Is it possible to make my application ask for username and password prompting for it before render a view? Just like on twitter API to get information about your account: http://twitter.com/account/verify%5Fcredentials.xml So before render the view || file it asks you to insert you username and password, I think this is made ...

SSH tunneling + HTTP proxy

Hi! Consider the following scenario: I can connect to SSH_Server to access internet. I can also connect to HTTP_Proxy to access blocked ports. Now I want to use the HTTP_Proxy through the tunnel to the SSH_Server! e.g. [uTorrent] > [SSH_Server] > [HTTP_Proxy] > [peer/tracker] I'm on Windows and I use putty. Will privoxy help? Thank...

What's the rationale behind the HTTP Date header?

I have read RFC 2616, but still I wonder, what the Date field is for. There is the Last-Modified field, that actually has a meaning besides just serving metadata, that is, for caching ('If-Modified-Since'). But what use has it to double the info in a separate Date header? ...

Are HTTP cookies port specific?

I have two HTTP services running on one machine. I just want to know if they share their cookies or whether the browser distinguishes between the two server sockets. ...

Check if web page is modifed / has expired with Ruby

I'm writing a crawler for Ruby, and I want to honour the headers that the server sends out in order to make the crawl more efficient. Is there a straightforward way in Ruby of determining whether a page needs to be re-downloaded by the client? I know I need to consider at least these headers: Last Modified Etags Cache Control Expires ...

What HTTP redirect status should I use to link offsite?

While randomly browsing my website via Google, I noticed that it was showing up remote redirects as local files. Now this can be both good and bad, but I'm wondering how can I fix this so it doesn't happen? I'm currently using PHP and header('Location: ... which sends a 302 redirect. Looking over the list of HTTP status codes, I'd take ...

Determining DB in use from http query

Is there a simple way to determine what database is in use behind a website from an external HTTP request? i.e., I make an HTTP request, get back whatever data is going to come from the webserver - can I inspect any of that and reliably determine that DB in use? I am thinking not, but figured I would ask this group. ...

How much network overhead does TLS add compared to a non-encrypted connection?

(Approximately) how many more bits of data must be transferred over the network during an encrypted connection compared to an unencrypted connection? IIUC, once the TLS handshake has completed, the number of bits transferred is equal to those transferred during an unencrypted connection. Is this accurate? As a follow up, is transferrin...