The Senate has passed a significant sanctions bill aimed at Russia and Iran, a measure that was a priority for the late Senator Lindsey Graham.