Official says gunmen have attacked stock exchange building in the country's financial hub and four assailants killed.