Iran has every right to sue Google if Google is operating illegally within their country, while capitalizing on Iranian citizens. Being free has nothing to do with it. Facebook is a business, and like all business are subject to the laws of all the countries they operate in.
It's a burden they willingly take on when they decide to become a multinational corporation.