Added fallback exception handling
Added localhost->127.0.0.1 rewriting