Customs are seeking the power to require people to disclose passwords to their electronic devices when entering New Zealand.
Failing to do so without reasonable excuse should be an offence punishable with three months prison, it has suggested.
It said the power would be useful in helping detect objectionable material and evidence of other offending, such as drugs offences, as well as to verify people's travel plans.
Many travellers were now carrying electronic travel documents, such as tickets and booking details, on computers and smartphones, it said.
The change is one of several canvassed in a discussion paper on a review of the Customs and Excise Act that was released by the department today.
Customs also wants its officers to be able to compel people to empty their pockets if asked. It said they did not currently have that power unless they had "reasonable cause" to suspect someone was hiding something.
The discussion paper said it was rare for people to refuse to empty their pockets when asked. "However, even a small proportion of people refusing to do so can present a significant threat to New Zealand."
Council for Civil Liberties spokesman Thomas Beagle said that under existing legislation, people could not be compelled to disclose passwords, but Customs had the right not to allow electronic devices to be brought into the country if people would not unlock them.
Beagle said he believed that was "a good compromise". It could not be assumed people would always have the passwords to encrypted files on their computers or smartphones, he said.
"They would be implying people couldn't travel with encrypted data at all if they didn't know the password for it."
Another change would let businesses hold their business records overseas, rather than in New Zealand. But Customs said that should only be with its prior approval.
The change would make it easier for "trusted businesses" to take advantage of overseas cloud computing services and would bring the department more into line with Inland Revenue's policies, Customs said.