MI5 threatened to block Scotland's landmark freedom of information law over fears the legislation did not protect the UK's secrets, according to National Archives files.
Security Service officials are alleged to have said they could "arrange" for the Holyrood Act not to receive Royal Assent.
As a result, the previous Labour/Liberal Democrat Scottish Executive agreed to amend their plans after the row reached the UK Cabinet.
In 2001, MSPs passed a radical right-to-know law that gave citizens a legal entitlement to information held by hundreds of public bodies.
Exemptions were in place to protect sensitive material, but it was still more far-reaching than the UK Government equivalent.
However, National Archive files from the time the initial draft bill was being discussed in 2000 reveal a cross-border rift with British spies.
MI5 was concerned the restrictions did not go far enough.
In April 2001, an email between Scottish Executive officials stated: "Not good news ... The Security Services had been raising the prospect that an Order under ... the Scotland Act be arranged to preclude our Act receiving Royal Assent."
Such orders, possible under the legislation that created the Scottish Parliament, can block Acts from being rubber-stamped by the monarch.
One of the officials said there were suspicions that "Special Branch may be the source of the Security Service concerns".
The then Home Secretary Jack Straw wrote to the then Scottish Justice Minister Jim Wallace, saying he was concerned about the release of information directly relating to the intelligence agencies, and noted there was no ministerial veto for national security.
In response, officials said Wallace was "content in principle" to make adjustments. The Scottish Executive then made alterations which brought the Scottish Act more into line with the UK legislation.
The revelation has triggered a row about the SNP's approach to releasing the files of previous governments. Whereas UK Government files are subject to the "30-year" rule, First Minister Alex Salmond has slashed this to 15 years north of the Border.
However, the correspondence on the draft FoI bill is only about a decade old, and was given the OK for release by the Scottish Government.
Labour MSP James Kelly said: "It looks suspiciously like one rule for the SNP and another for everyone else. At a time the SNP are trying to stop extending freedom of information laws for current government decisions, they are willing to selectively release files from more recent administrations."
A Scottish Government spokesperson said: "This government is committed to openness and transparency – the key principle that underpins freedom of information legislation.
"More information than ever – including material from this and previous administrations – is now available for public viewing."
Why are you making commenting on The Herald only available to subscribers?
It should have been a safe space for informed debate, somewhere for readers to discuss issues around the biggest stories of the day, but all too often the below the line comments on most websites have become bogged down by off-topic discussions and abuse.
heraldscotland.com is tackling this problem by allowing only subscribers to comment.
We are doing this to improve the experience for our loyal readers and we believe it will reduce the ability of trolls and troublemakers, who occasionally find their way onto our site, to abuse our journalists and readers. We also hope it will help the comments section fulfil its promise as a part of Scotland's conversation with itself.
We are lucky at The Herald. We are read by an informed, educated readership who can add their knowledge and insights to our stories.
That is invaluable.
We are making the subscriber-only change to support our valued readers, who tell us they don't want the site cluttered up with irrelevant comments, untruths and abuse.
In the past, the journalist’s job was to collect and distribute information to the audience. Technology means that readers can shape a discussion. We look forward to hearing from you on heraldscotland.com
Comments & Moderation
Readers’ comments: You are personally liable for the content of any comments you upload to this website, so please act responsibly. We do not pre-moderate or monitor readers’ comments appearing on our websites, but we do post-moderate in response to complaints we receive or otherwise when a potential problem comes to our attention. You can make a complaint by using the ‘report this post’ link . We may then apply our discretion under the user terms to amend or delete comments.
Post moderation is undertaken full-time 9am-6pm on weekdays, and on a part-time basis outwith those hours.
Read the rules hereComments are closed on this article