I am setting up openid-ldap which consists of some Apache config which should be transformed into Nginx. Really I have some trouble to obtain these rewrite rules converted:

RewriteEngine On
RewriteCond %{REQUEST_URI}      !^/(.+)\.php(.*)$
RewriteCond %{THE_REQUEST}      ^[A-Z]{3,9}\ /dir/([A-Za-z0-9]+)\?(.*)\ HTTP/
RewriteRule ^/dir/(.*)$         https://host/dir/index.php?user=%1&%2    [P]

Anybody individuals includes a hint for me personally, specifically for the 2nd RewriteCond?

Cheerio, Chris