[#7732] factor out SourceForge-specific https scheme middleware