There are various options you can use for this.
I suggest HTMLUnit.
- Use HTMLUnit API – this has methods to login, passing the username and password.
- HTMLUnit itself allows you to download file.
There are various options you can use for this.
I suggest HTMLUnit.