I have a website which should only be reachable over HTTPS except one URL-pattern (because I have on some pages http-iframe's and I would like to avoid security warnings)
E.g. this pages should be redirected to https:
http://example.com
http://example.com/a/this-is-an-article
http://example.com/v/this-is-a-video
This pages should not be redirected to https (or should be redirected form https to http)
http://example.com/l/page-with-unsafe-iframe
http://example.com/l/other-page-with-unsafe-iframe
You may use map and simple redirect rules, for example:
I should mention that 301 redirect is a good practice unlike permanent rewrite.
If the iframe pages are always in the same directory, simple prefix locations could be used.