Prior to the sanctions, Iran had billions of dollars invested in foreign banks and infrastructure. Their access to this money was cut off when the sanctions were put into place and we're slowly allowing them access. Here's an article from 2014 with more detail:
http://www.reuters.com/article/us-iran-assets-usa-idUSBREA0G...