In various circumstances critical support of problematic governments is support of the people when harm to their state by outside actors will bring harm to those people. Most communists have a general understanding that the way Iran is today is in fact America's fault and that the change it needs won't come from outside of it, particularly when the people using various problems as a political weapon do not have the improvement of the lives of the people as their goal but instead various other geopolitical and resource interests.
The most recent historical example of this would be Syria, with Libya a close second and Iraq a close third. All of which are objectively worse off thanks to western interventionism.
You can and should oppose interventionism and outside actors fucking with the situation there if you do care about the people, while also not defending the theocracy and support real local political movements for change (ie the ones not funded by NED or various other cia or nato affiliated intermediaries).