Re: Tunnelling SQL over HTTP with MDB2

From: Date: Tue, 25 Apr 2006 15:13:17 +0000
Subject: Re: Tunnelling SQL over HTTP with MDB2
References: 1 2  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-42377@lists.php.net to get a copy of this message
Hi Olivier, Justin Patrin wrote: > On 4/25/06, Olivier Guilyardi <ojaiml@nerim.net> wrote: > >>Hi, >> >>As you all know many hosting providers only permit access through the database >>server from the web server, not from the outside. >> >>I'm currently on a professional project where such remote database access is >>needed. There is a simple solution : encapsulating SQL queries into HTTP requests. >> >>There's a project out there named "PHP Tunnel" that does that : >>http://www.mysqlfront.de/manual/fphptunnel.html >> >>But wouldn't it be great if that was handled as part of the abstraction that >>MDB2 offers ? >> >>One would call $mdb2->query() as usual and that could run on a local or >>remote-over-http server.... >> >>This would simply require to write a new MDB2 driver, and a little server-side >>script to perform the real database queries. >> >>The only critical part I see is at the authentication/security level. >> >>Or have I missed something ? Is this already possible ? > > AFAIK there is no current implementation of such a thing in PEAR. It > sounds like an interesting idea, though (although the latency is > likely to be horrible). > > Why not just run your application on the web server where your > database is located so that it can query directly? > >>What about DB ? >> > > Don't waste your time unless you're using something which relies on DB > specifically. MDB2 is the official DB abstraction layer in PEAR now. > > -- > Justin Patrin I guess what you're actually looking for is a web service front-end to a database. It shouldn't really matter what the backend database is. Once such web service is available (it may already be somewhere on the internet), then a driver for MDB2 could be added. (Could be a "Summer of code" project.) Obviously there are big security concerns on running such a web service, but that's beside the scope. There is also probably some standard or draft specifications somewhere in the Internet for that. -Philippe

« previous php.pear.dev (#42377) next »