finally fix bug #39 correctly across all host types - CSPs are a PITA