Public domain software
The code is protected as a literary work.
Computers are susceptible to viruses unless they are protected by special software and firewalls.
Software is protected by copyright as a literary work.
Anything other than open source software is protected by copyright; shareware and freeware may be free, but are still protected. Software that is purely functional (e.g., assembly code to perform a basic operation) is not copyrightable. Software created by any employee of the US government is not copyrighted in the USA.
Because registration is not required for protection, there is no way to tell how much software has been protected by copyright. On the other hand, since protection is automatic, you can also say that all software is protected by copyright.
Copyright law ostensibly prevents unlawful distribution, but technical preventions such as DRM tend to be more successful.
If you PDF file is password protected you need a password recovery software.
It is how the software is being protected with encryption or as simple as a password. These things help the software be safe from the files failing of being destroyed by hackers.
setup exe
It depends on what you mean by "protection."
Technology would typically be protected by patent law, with the exception of software, which can fall under both copyright and patent.