Committing an Act in the Kaaba
Scholars have said that seeing oneself committing an act in the Kaaba carries a negative connotation related to the caliph or ruler. This vision may indicate a misfortune or affliction that could befall the caliph.
Per Ibn Sirin's Muntakhab al-Kalam fi Tafsir al-Ahlam