Mr McCully said New Zealand had the legislative power only to apply United Nations sanctions.
If the law was passed it would not be aimed at any particular country.
But he revealed it was under consideration when being questioned about New Zealand's relationship with Iran, which is seen as more positive than the relationship Tehran has with many other Western countries.
"To the extent that people look at New Zealand as being a little different, that is partly a function of care in being even-handed and fair on foreign policy matters," he said.
"It is also, to be honest, a reflection of the fact that we do not have autonomous sanctions legislation."
Some countries had initiated sanctions against Iran that New Zealand had no legal basis for implementing.
"I have been talking to our people about passing similar legislation, not with any country in mind but on the basis that it is an undesirable position to be in that you can't take any action outside the scope of the UN."
Australia has autonomous sanctions aimed at Iran, Myanmar, Fiji, North Korea and Zimbabwe.
New Zealand's sanctions against Fiji cover areas over which the Government has control, mainly border issues.
Since March last year, New Zealand has required anyone doing business with Iran to register with the Ministry of Foreign Affairs and Trade, whose website says it is unlawful to do business there without being registered.