Your antivirus software scans files in real-time. Since JAR files can execute commands, some antivirus programs (like Avast, Norton, or Windows Defender) kill the download before it finishes.
Which were you using when the download failed? unable to download jar file
Troubleshooting Guide: How to Fix "Unable to Download JAR File" Errors Your antivirus software scans files in real-time