Close #1105 - don't let security manager get replaced