refactored a bit, https proxy keys stub