Well, I feel pretty stupid now. I used an automatic script to generate that config and I just assumed that the rewrite would be included. Thanks & Oops. Posted at Nginx Forum: http://forum.nginx.org/read.php?2,239004,239011#msg-239011