The Ottawa Hospital says it was the subject of a cyberattack over the past week.

The hospital issued a statement Saturday saying four of the hospital's 9,800 computers faced a hacker attempt, but no patient information was affected.

The hospital said malware locked down the files after someone using the computer clicked a link that activated it.

The hospital's IT staff wiped its drives in response.

"We are confident we have appropriate safeguards in place to protect patient information and continue to look for ways to increase security," the statement said.

Ottawa Hospital spokesperson Kate Eggins said Sunday the attackers used ransomware — software that locks files and demands money to reopen them — but IT staff fixed the issue without having to make any payments.

With files from CBC Ottawa