AMMAN, Jordan — Saudi Arabia announced on Thursday a big promotion for a veteran security officer who United States officials recently said was without a job and confined to his home.

In a series of royal decrees, King Salman, the Saudi monarch, announced the creation of a new body to handle domestic security and counterterrorism issues and chose the officer, Gen. Abdulaziz al-Huwairini, to lead it.

The apparent change of fate for General Huwairini underlined the vast changes that have been reshaping the often opaque Saudi power structure since Crown Prince Mohammed bin Salman ousted his cousin and rival, Prince Mohammed bin Nayef, last month to become first in line to the throne.

The rise of Mohammed bin Salman, 31, since his father became king in 2015 has overturned decades of royal tradition and put tremendous power in the hands of a young and relatively inexperienced prince.