CAIRO — Yemen’s embattled president, Ali Abdullah Saleh, said Saturday that he accepted a proposal by Arab mediators that would shift power to his deputy 30 days from the signing of a formal agreement and grant him and his family, who occupy key positions in Yemen’s security apparatus, immunity from prosecution.