Adam Culp has followed up some of his previous posts about the setup and configuration of remote debugging in PHP applications (more specifically in Zend Studio) with this new post. In it he shows how to use a SSH tunnel to allow debugging to happen through a firewall for those cases when direct access isn't possible.
In a previous post I covered how to set up step debugging in Zend Studio. But if that doesn’t work there may be a firewall in between the server and the debugging client, or IDE, preventing the connection. Here is a possible way to get around that.
He assumes that you already have the SSH server and connection available to you (he doesn't cover the install of that part). He then steps you through the setup of Zend Studio to add a new server, configure the SSH tunneling and remote/local ports to use. In his case he was using Zend Server so switching on debugging was as easy as turning in debugging via the toolbar. It's also worth noting that another popular PHP IDE can handle SSH-based debugging as well - PHPStorm - as seen here.