SkyHorse.Org

Server-side redirection (a.k.a. tunneling) with PHP

August 1st, 2005 SkyHorse

Some web applications, like my own cPanel and Web Mail, use non-standard tcp ports. Usually this is because they are part of a software package that runs alongside Apache but does not use it to serve the pages.

Problem is many corporate and university firewalls do not allow access to ports such as 2095 and makes all the neat web apps like the ones above completely useless until you get home (where you probably have some other e-mail software anyway).

For some time I have used a simple port redirector installed on my home computer which allowed me to see my e-mails from my work place and my university. This is a bit annoying, though, because not only I have to leave my pc on the all day just for this but also because it is a slower connection and I am the only one who can use it (yes, I am thinking about my own hosting clients/partners who complain about the same problem).

So, I am starting a journey to make a ‘transparent’ PHP application that can successfully accept an incoming HTTP connection, grab the headers and open a server-side connection to another service and use the incoming headers for the request. Upon reception of the response, the script must alter *all* tags to its own name and append a single GET variable with the original href.

Thus, on a simple page, where there is a:

<a xhref="www.skyhorse.org/abc.html?I=rule" mce_href="www.skyhorse.org/abc.html?I=rule">

there will be a:

<a xhref="redirector.php?requestedURL='www.skyhorse.org/abc.html?I=rule'" mce_href="redirector.php?requestedURL='www.skyhorse.org/abc.html?I=rule'">
.

I still don’t know if the use of ‘ or even ” will be tolerated by the HTTP request, but I think as a last resort I can always do some kind of two-way encoding (like base64 or something similar) to encode the original request in an AsciiSimple format.

For now, I have some proof of concept working (yikes, I can open a server-side socket in PHP!) but I am still a long way before I turn off my home computer during the day :)

If anyone has any information on how to accomplish what I am trying to do, please, do give me a shout :)

– Update 1

After some time I discovered another major issue: Images!
I think I will have to make a standalone script or function in PHP just to handle the redirection of images… yes, because there has to be a request for images to a PHP script and those images have to be quested server-side and returned… mmm … maybe not that complicated, just a redirect.php?requestImage=originalURL and the request.php will take care of returning just the binary information taken directly from the server-side connection made to the service… could work… will work!

–Update 2

Ok, so, I finally discovered I was re-inventing the wheel…
I had already looked for this on the web, but couldn’t find anything. But now I stumbled upon cpanelproxy .
It does exactly what is says on the label: server-side proxy to cPanel.
It’s funny how the script I was writting was starting to look like the script they made! Unfortunatelly it does not yet support SSL, perhaps I could find a way to implement it, but I think it would be almost impossible…

DeliciousFacebookTwitterLinkedInShare/Bookmark
Tags: cPanel, Ideas, Programming, Web Design, WHM

Related posts:

  • DirectAdmin to cPanel : a partial BASH solution
  • The Definite Guide of Obscure Tweaks to Install and Maintain cPanel / WHM (version 10)
  • modsec.sh updated

Posted in Ideas, Programming, Web Design | No Comments »

Parse-y Political Broadcast

May 11th, 2005 SkyHorse

I couldn’t stop laughing at this one… but they do struck a chord at one important issue: on what reasons do you vote for a particular party? (and for those NationStates afficionados, “none of the above” is *not* a valid answer)

For that geek web designer inside you, here’s an idea: vote for the party with the better markup-coding ability. (like they said, people vote for far less important reasons)

Here’s the result for the recent UK general election:

The Scottish National Party: 0 errors (XHTML 1.0 Transitional)
The Conservative Party: 0 errors (XHTML 1.0 Transitional)
The Labour Party: 1 error (XHTML 1.0 Transitional)
The Green Party: 5 errors (no DOCTYPE or character encoding, HTML 4.01 Transitional used)
Plaid Cymru: 9 errors (no DOCTYPE or character encoding, HTML 4.01 Transitional used)
Veritas: 11 errors (no DOCTYPE or character encoding, HTML 4.01 Transitional used)
Respect: 26 errors (no DOCTYPE, HTML 4.01 Transitional used)
The Liberal Democrat Party: 148 errors (XHTML 1.0 Transitional)
UKIP: 161 errors (apparently, an attempt at HTML 3.2)

Lets just say if this country was made up of web designers, I would be prime-minister by now ;)

The original laugh:
Industrial & Marine | Blog: Parse-y Political Broadcast

DeliciousFacebookTwitterLinkedInShare/Bookmark
Tags: Ideas, Personal, Web Design

Related posts:

  • Server-side redirection (a.k.a. tunneling) with PHP
  • New web marketing strategy born?
  • HTTP and HTTPS tags without using JavaScript

Posted in Ideas, Personal, Web Design | 1 Comment »

The Web is dead

May 8th, 2005 SkyHorse

It wasn’t enough for the WWW to have to take up with Macromedia’s Flash and Adobe’s PDF Reader loading times, we will probably see more of them if Adobe goes ahead with the promise of increasing “complementary functionality of PDF and Flash” by acquiring Macromedia…

About Adobe – Adobe to acquire Macromedia

Lets pray for the new version of Dreamweaver to not be called DreamLive CS2 …

DeliciousFacebookTwitterLinkedInShare/Bookmark
Tags: Web Design

Related posts:

  • New web marketing strategy born?
  • Meebo lunches Meebo Me!
  • HTTP and HTTPS tags without using JavaScript

Posted in Web Design | No Comments »

Next Entries »
  • Tags

    advertising AI apple behavioural-targeting business Computing cPanel deep packet inspection Downloads DSP Games GNU/Linux google hacking hacking Hardware headphones hosting Ideas Instant Messaging iphone marketing online-advertising online media Personal Philosophy phorm poker Programming satire scripts Security sociology startups technology Travel ubuntu v-moda Visionarism web-2.0 web-marketing Web Design WHM wunderloop yahoo
  • Pages

    • About
    • Web Server Administration
      • Auto update modsecurity rules – modsec.sh
      • DirectAdmin to cPanel : a partial BASH solution
      • The Definite Guide of Obscure Tweaks to Install and Maintain cPanel / WHM (version 10)
        • Configuring E-mail (Exim) related areas
        • Fixing open DNS servers
        • Monitoring your server
        • Scripts and misc information
        • Security by Obscurity
        • Tweaking apache web server
  • Twitter Updates

    • Ads

    • RSS ExchangeWire.com

      • The PostView: Is Cutting Supply Really The Answer To The Current Malaise In Display Advertising? 9 February, 2012
      • Euro Round-Up: The French Get “Serieux” About RTB; mediascale Reports Strong 2011 Growth; Jemm Goes All-In With AppNexus 9 February, 2012
      • Moving On From Retargeting: Why Prospecting In Display Is Good For The Industry 8 February, 2012
    • RSS Lies, Damned Lies…

      • Big (Hairy) Data 8 February, 2012
      • Building the Perfect Display Ad Performance Dashboard, Part II – metrics 20 December, 2011
      • Should Wikipedia accept advertising? 21 November, 2011
    • RSS iMedia Connection: Consumer Strategies

      • A consumer-driven mindset in a big media package
      • Learn to leverage the social-search connection
      • Your social media disaster kit
    • RSS Segmentacion por comportamiento

      • Comment Notifications! 10 February, 2012
      • New Themes: Splendio and Suburbia 7 February, 2012
      • Post Videos from Your iPhone or iPad 3 February, 2012
    • RSS Sandlines

      • The Social Phone doesn’t come with an IVR menu 7 November, 2011
      • Are you ready for Big Data? 2 November, 2011
      • Sandlines @ Mediapro 29 October, 2011
    • RSS Adotas

      • Covario Issues Annual Client Awards for SEO/SEM Success 10 February, 2012
      • Infographic: The Online Ad Industry Is Like the Stock Market 10 February, 2012
      • Mobile Search: More Intent, More SMB Opportunity 10 February, 2012
    • RSS NMA

      • Q&A: Lee Jury, VP studio marketing, The Walt Disney Company EMEA 10 February, 2012
      • Kraft poaches PepsiCo’s global digital chief 9 February, 2012
      • Zeebox launches click-to-buy TV ad service 9 February, 2012
    • RSS Brand Republic

      • NEWSPAPER ABCs: 20p i overtakes The Guardian after TV campaign 10 February, 2012
      • VIDEO: Audi 'believes there is growth in the UK market', says Chambers 10 February, 2012
      • Betfair to knock rivals for the first time in campaign 10 February, 2012
    • RSS MarketingVox

      • Transaction Emails as Marketing Channel? Yes, But Tread Carefully 10 February, 2012
      • Another Shift for AdMob Next Week 10 February, 2012
      • Engagement on Google+. Finally 10 February, 2012
    • RSS Behavioural Targeting news

      • Internet Broadcasting and Exact Drive to Provide Comprehensive Digital ... - Sacramento Bee 9 February, 2012
      • IP Audience Zones Provides Advertisers with Nearly 100% Qualified Reach - Sacramento Bee 8 February, 2012
      • IG Index Launches Cross Platform Campaign - Sacramento Bee 8 February, 2012
      • UK Agency Digital & Wise Partners with Web Optimization Provider SiteSpect to ... - MarketWatch (press release) 6 February, 2012
      • Online behavioural targeting: Q&A - Telegraph.co.uk 1 February, 2012
    • Ads

    • Blogroll

      • 90kts
      • Acxiom Poker Nights
      • Amy’s blog
      • Bytter’s blog
      • Impare Arquitectura
      • Impare Design
      • morena flor no samba da saudade
      • Not Quite There Yet
      • Swedish Pirate Party
    • Cartoons

      • Geek & Poke
      • Order of the Stick
      • User Friendly
    • Gaming

      • Neverwinter Nights
    • online media

      • Knowledge for the Digital Economy
      • Mike on Ads
    • Personal

      • Banksy
      • Designarte
      • Made to measure shirts – Atelier de Camisa
      • My Amazon Wishlist
      • SkyServers.Org
    • Science

      • New Scientist
      • Rex Research
      • ScienceBox
      • Wired
    • Security

      • GPG4Win
      • GPGol
      • GPGShell
      • Mod Security
      • Offline Windows NT(2k,XP) Password Recovery
    • Web Design

      • PageStrength
      • SiteScore
      • UrlTrends
    • Akismet

      99,826 spam comments blocked by
      Akismet
    • Meta

      • Log in
      • Entries RSS
      • Comments RSS
      • WordPress.org

    © 2003 - 2011 Paulo Cunha | SkyHorse.Org is proudly powered by WordPress | Theme based on Bob