Article 277 [source]

Spanish Criminal Code
English translation

Anyone who intentionally discloses an invention that is the subject of a secret patent application, in contravention of the provisions of patent legislation, will be punished with imprisonment for six months to two years and a fine of six to twenty-four months, provided that this is to the detriment of national defense.