You can run hgwebdir behind different authentication and https modules just fine, provided your webserver handles them before the REMOTE_USER variable is handed off to the CGI.
I don't know visualsvn, but your ScriptAlias looks a lot like Apache. Do you need an AddHandler line for .cgi?