Fixing AWS privateKey scope