Nancy Pelosi secures US House speakership