HZNM.COM
welcome to my space
X
Search:  
 HOME   HTTP Proxy
HTTP Proxy
Published by: smith 2009-01-08
Welcome to:hznm.com

  • Hi,

    I'm developing a proxy that it will work between Squid and another program. The problem is that with some sites how hotmail.com, google.com and others is calling, the proxy works very well, but with nba.com (p.ex) don't have answers.

    The code is simple, I 'm working with multi-threading (I have a server and several clients) and I used select().

    Why its happen? I'm expending lot of time to solve this problem and I don't know what more I need to search.

    Thank you...


  • Hi,

    When I test with the site nba.com and others that don't have reply I noted that the recv() = 0 (zero). Then, I would like to know when a socket in the read set closes the connection?

    Thank you.


  • ok, after I understood!!!

    I'm implementing it at this moment.

    Thank you...


  • I am just curious if you are parsing the incoming request as it is arriving from the web browser... e.g. getting the target and starting the connect to squid prior to receiving the rnrn header & body seperator...

    If so, try getting the entire request prior to establishing the outgoing connection to squid... then send it all at once and see if it makes a difference... again, the thinking is that the site is only allowing (or appears to) a second or less for the entire request and doing partial writes may be causing enough of a delay to overrun the server's allowed time... Of course, that would only happen if squid is doing the same thing i.e. if it grabs the target it immediately starts connection before it gets the full headers... and I haven't look at its source code for over a year so not certain...
    freshmeat.net: Project details for TrustWall HTTP Proxy::
    Apr 1, 2003 TrustWall HTTP Proxy protects your internal Web server by acting as an inbound proxy (like a reserve Squid proxy).
    http://freshmeat.net/projects/twhttpd/
    HOME
    Forum Proxy Leecher Home - Overview (buy proxy,buy proxy list,buy ::
    Forum Proxy Leecher Video Tutorial: http://download.my-proxy.com/ fpl_tutorial_zoom2.wmv. News: The 3d2f.com editors have called FPL the most promising in
    http://fpl.my-proxy.com/
    HOME

    If not... still no clue... must think more... though it would be nice if they didn't have their server configured in such a messed up fashion... :-/

    Michael


  • Hi,

    I didn't understand your suggestion? Why it would work?


  • I did a couple of quick tests again the site... nba.com that is...

    I can (programmatically) get the request out quickly enough to the system after establishing a connection... but that server appears to be set to a max 1 second wait before it terminates if it does not (at least start to) get the request headers...

    For a stupid example... just telnet to the site (port 80) and watch how quickly it disconnects...

    I do not have access to squid right now... but I would be curious as to the behaviour if you go from a web browser thru squid to nba.com ... if it works, that would mean there is a solution... if not, its a delay built into squid that is causing the problem... let me know and I will see if I can think of any fixes...
    Charles : Web Debugging Proxy | HTTP Monitor | HTTP Proxy | HTTPS ::
    Charles is an HTTP proxy / HTTP monitor / Reverse Proxy that enables a developer to view all of the HTTP traffic between their machine and the Internet.
    http://www.charlesproxy.com/
    HOME
    Tinyproxy - Light-weight HTTP proxy daemon::
    Tinyproxy is a light-weight HTTP proxy daemon for POSIX operating systems, released under the GNU GPL license.
    http://www.banu.com/tinyproxy/
    HOME

    Michael


  • Hi!

    Thank you for your attention! I solve the problem only working more with my threads. The problem was the threads synchronization.

    bye


  • Be aware of the fact that nba.com does still appear to have apx. a 1 second timeout for the incoming request before it disconnects...

    Either way... good luck with your project!

    Michael


  • Hi, Michael!

    I dont know if your answer will solve my problem because I don't change the headers in my request, I put it in a variable unsigned *char and I only send it to the Squid, the same occur with the Squid reply. But I will check it!!!

    Thank you for the help.

    Iliete


  • I am using a Web Browser thru Squid and I don't have problems... I only have problems when I put my 'proxy' between the Web Browser and the Squid... and I think how you, it must have a solution, it works with other sites!

    Now I'm studying the Timeout, maybe I discover something...

    Thank you more once...


  • I just caught the last messages in this thread...

    The specs require that requests sent to proxy servers use an absolute uri... and since the impl in question is talking to a proxy (squid) the incoming uri shouldn't be modified...

    A side note / fyi on this...

    HTTP 1.1 requires that all in spec servers (proxy / origin) accept the absolute URI format in the request message... so if you know you're writing a non-chained proxy and know you're talking to a 1.1 system (e.g. via cached info from a prior request) then you don't have to do the re-write...

    HTTP 1.0 does require that requests to non-proxy systems transform absolute URIs to an absolute path format with a Host: header field....

    Michael


  • The most often seen reason for that type of behaviour is you are either not terminating the headers in your request with full rn sequences.... or that the responding server is not replying with them... the most common is to see termination being only n which is out of spec... but you have to compensate because MANY servers / clients are out of spec...

    Without more info... thats about all I can say...

    Michael


  • i think, your problem will be solved, when you change http://xxxx.com/sdfsd.fff to /sdfsd.fff or http://xxxx.com/ to /. thats all.


  • when you do a proxy server, you must implement right url change engine depend on rfc specification





  • How much does getting a small tattoo on your hip/stomach hurt?
    Do anyone else have an itchy anus? ?

    You are looking at:hznm.com's HTTP Proxy, click hznm.com to home
  • jewelry mixing practicality and beauty
  • real estate developers at a glance
  • credit card follow your spending patterns
  • cheap secured loans uk can ease up your financial troubles
  • bookkeeping help can make your business look different
  • christmas chocolate delivery for your employees
  • get rid of snarls with seo new york
  • unsecured loans
  • bad credit secured loans for those who need finances badly
  • location profile vasant vihar south delhi
  • property for rent in dubai
  • anti alcohol pills do you need them
  • alcoholism tips and how to stop drinking
  • chocolate delivery outstandingly popular
  •  
  • seo for topping search engine results
  • aluminum die casting manufacturer
  • dinnerware and glassware of christian tortu
  • bad credit payday loans a sure way to get out of cash issues
  • review of wallstreet journal wsj and best and worst ads of 06
  • instant approval payday loans assist to sidetrack cash concerns
  • good boundaries make good neighbors
  • types of natural stones existing
  • some health benefits gained by prescription weight loss drugs
  • 5 ways to make your diet a success
  • how to get affordable car insurance in massachusetts
  • feng shui develops to neo feng shui
  • car lease specials the jaguar xf
  •  Homepage | Add to favorites | Contact us | Exchange links | LOGIN | Site map | 
    Copyright© 2008 hznm.com        Site made:CFZ