Applying kohl in the state of ihram, or putting some medicine etc. in the eyes as treatment,
is permissible, as narrated from Uthman (may Allah be pleased with him) that the Messenger of Allah ﷺ said regarding a person in the state of ihram whose eyes are sore:
ضمدها بالصبر
“He should apply a paste of aloe (the name of a medicine) on his eyes.”
Reference: Muslim: 2089, Kitab al-Hajj: Bab Jawaz Mudawat al-Muhrim ‘Aynayhi