Skip to content

Instantly share code, notes, and snippets.

@wavezhang
Last active November 13, 2024 02:42
Show Gist options
  • Save wavezhang/ba8425f24a968ec9b2a8619d7c2d86a6 to your computer and use it in GitHub Desktop.
Save wavezhang/ba8425f24a968ec9b2a8619d7c2d86a6 to your computer and use it in GitHub Desktop.
download java from oracle without login
wget -c --no-cookies --no-check-certificate --header "Cookie: oraclelicense=accept-securebackup-cookie" https://download.oracle.com/otn-pub/java/jdk/12.0.2+10/e482c34c86bd4bf8b56c0b35558996b9/jdk-12.0.2_linux-x64_bin.tar.gz
@lucas-zimerman
Copy link

@SirEnder125
Copy link

Hey, uhh.... A little late, but this doesn't seem to be working. (2/28/2021)
Was it patched? Is there another way?
I need this: https://download.oracle.com/otn-pub/java/jdk/8u51-b16/jdk-8u51-windows-x64.exe

@alecacco
Copy link

alecacco commented Mar 2, 2021

wget the "nexturl" with the otn changed to otn-pub

@telekomancer
Copy link

@rarturo-91
Copy link

Results of current discussion:

https://download.oracle.com/otn-pub/java/jdk/8u281-b09/89d678f2be164786b292527658ca1605/jre-8u281-windows-x64.tar.gz

изображение
изображение
изображение

and replace otn with otn-pub.

This worked like a charm thanks so much!!!

@xyzzyy
Copy link

xyzzyy commented Mar 7, 2021

I got mine by replacing otn in the URL with otn-pub, maybe that might help someone?

Still works! Thanks Peter!

@MrChocolatine
Copy link

Thanks to all the tips above I was able to download the JDK 11 using this link:

https://download.oracle.com/otn-pub/java/jdk/11.0.10%2B8/020c4a6d33b74f6a9d2bc6fbf189da81/jdk-11.0.10_osx-x64_bin.dmg

@zritelru
Copy link

"Я получил свой, заменив otnURL-адрес на otn-pub" - работает!! (19.03.21г)
ссылка
https://download.oracle.com/otn-pub/java/jdk/8u281-b09/89d678f2be164786b292527658ca1605/jre-8u281-windows-x64.tar.gz
плюс Internet Download Manager 6.36
Спасибо!!
НО: как установить полученное? (простите пожалуйста за невежество)

@MrChocolatine
Copy link

"Я получил свой, заменив otnURL-адрес на otn-pub" - работает!! (19.03.21г)
ссылка
download.oracle.com/otn-pub/java/jdk/8u281-b09/89d678f2be164786b292527658ca1605/jre-8u281-windows-x64.tar.gz
плюс Internet Download Manager 6.36
Спасибо!!
НО: как установить полученное? (простите пожалуйста за невежество)

@zritelru

English would be better.

From what I understand you want to know how to install the archive you downloaded.
You should download the executable .exe instead, like any other software for Windows.

@xiaoyu2er
Copy link

@traycho
Copy link

traycho commented Apr 19, 2021

Use sdkman - https://sdkman.io/

  1. List all support java version sdk list java
  2. Install your preffered version sdk install java <Idetifier>

@zritelru
Copy link

zritelru commented Apr 20, 2021 via email

@jariahtiainen
Copy link

@ojaha065
Copy link

Link for JDK 8u291 (Windows x64) if someone happens to be looking for that:
https://download.oracle.com/otn-pub/java/jdk/8u291-b10/d7fc238d0cbf4b0dac67be84580cfb4b/jdk-8u291-windows-x64.exe

@zritelru
Copy link

zritelru commented Apr 27, 2021 via email

@Bind-9
Copy link

Bind-9 commented May 2, 2021

Thanks :)

@mdirienzo
Copy link

otn-pub trick still works like a charm! Thanks for finding this and saving me!

For those wondering: Click on link of file you want, accept agreement checkbox, right click on the green button and "copy address". Paste this into url and keep everything after "nextUrl=". Change "otn" to "otn-pub", and press enter.

Copy link

ghost commented May 8, 2021

Link for JDK 8u291 (Windows x64) if someone happens to be looking for that:
https://download.oracle.com/otn-pub/java/jdk/8u291-b10/d7fc238d0cbf4b0dac67be84580cfb4b/jdk-8u291-windows-x64.exe

Thanks!

@rathaROG
Copy link

(Personal note only) How to generate link for the future update:

  1. Go to https://www.oracle.com/java/technologies/javase/javase-jdk8-downloads.html
  2. Click on the wanted exe file and accept the license agreement
  3. Get the link from the download button

For example: https://www.oracle.com/webapps/redirect/signon?nexturl=https://download.oracle.com/otn/java/jdk/8u261-b12/a4634525489241b9a9e1aa73d9e118e6/jdk-8u261-windows-x64.exe

  1. Add necessary info into this link:

https://javadl.oracle.com/webapps/download/GetFile/1.8.0_[xxx]-b[xx]/[encrypted_path]/windows-i586/[file_name_exe]

  • [xxx] is the update number; for example 261
  • [xx] is the build number; for example 12
  • [encrypted_path] is the encrypted path; for example a4634525489241b9a9e1aa73d9e118e6
  • [file_name_exe] is the exe file name; for example jdk-8u261-windows-x64.exe
  1. Final and ready download link will be:
    https://javadl.oracle.com/webapps/download/GetFile/1.8.0_261-b12/a4634525489241b9a9e1aa73d9e118e6/windows-i586/jdk-8u261-windows-x64.exe

https://javadl.oracle.com/webapps/download/GetFile/1.8.0_291-b10/d7fc238d0cbf4b0dac67be84580cfb4b/windows-i586/jdk-8u291-windows-x64.exe

Still works ^_^

@SofiaSanabria
Copy link

Go to:
https://www.oracle.com/java/technologies/javase-jdk16-downloads.html#license-lightbox

Read under:
Important Oracle JDK License Update
The Oracle JDK License has changed for releases starting April 16, 2019.
Oracle also provides the latest OpenJDK release under the open source GPL License at jdk.java.net.
Then go to:
Java Platform, Standard Edition 16 Reference Implementations:
RI Binary (build 16+36) under the GNU General Public License version 2
Oracle Linux 7.8 x64 Java Development Kit (sha256) 176 MB
Windows 10 x64 Java Development Kit (sha256) 176 MB

https://jdk.java.net/java-se-ri/16

I hope this helps

@anjia0532
Copy link

anjia0532 commented May 14, 2021

(Personal note only) How to generate link for the future update:

  1. Go to https://www.oracle.com/java/technologies/javase/javase-jdk8-downloads.html
  2. Click on the wanted exe file and accept the license agreement
  3. Get the link from the download button

For example: https://www.oracle.com/webapps/redirect/signon?nexturl=https://download.oracle.com/otn/java/jdk/8u261-b12/a4634525489241b9a9e1aa73d9e118e6/jdk-8u261-windows-x64.exe

  1. Add necessary info into this link:

https://javadl.oracle.com/webapps/download/GetFile/1.8.0_[xxx]-b[xx]/[encrypted_path]/windows-i586/[file_name_exe]

  • [xxx] is the update number; for example 261
  • [xx] is the build number; for example 12
  • [encrypted_path] is the encrypted path; for example a4634525489241b9a9e1aa73d9e118e6
  • [file_name_exe] is the exe file name; for example jdk-8u261-windows-x64.exe
  1. Final and ready download link will be:
    https://javadl.oracle.com/webapps/download/GetFile/1.8.0_261-b12/a4634525489241b9a9e1aa73d9e118e6/windows-i586/jdk-8u261-windows-x64.exe

https://javadl.oracle.com/webapps/download/GetFile/1.8.0_291-b10/d7fc238d0cbf4b0dac67be84580cfb4b/windows-i586/jdk-8u291-windows-x64.exe

Still works ^_^

thanks @rathaROG

my post https://juejin.cn/post/6844903945194733575/#heading-1 ,Translation and reference your answer

@bloosd
Copy link

bloosd commented May 14, 2021

thanks all
it's working for me with just replace "otn" to "otn-pub", like this :
https://download.oracle.com/otn/java/jdk/11.0.11%2B9/ab2da78f32ed489abb3ff52fd0a02b1c/jdk-11.0.11_windows-x64_bin.exe

@anjia0532
Copy link

jdk8+ ok ,but jdk8 not

thanks all
it's working for me with just replace "otn" to "otn-pub", like this :
https://download.oracle.com/otn/java/jdk/11.0.11%2B9/ab2da78f32ed489abb3ff52fd0a02b1c/jdk-11.0.11_windows-x64_bin.exe

@aszeli
Copy link

aszeli commented May 17, 2021

Has anyone gotten it to work for jdk8u202?
When I try with "otn", it downloads a HTML header. When I try with "otn-pub", it gives a 404 error
wget -c --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" https://download.oracle.com/otn-pub/java/jdk/8u202-b08/1961070e4c9b4e26a04e7f5a083f551e/jdk-8u202-linux-x64.tar.gz

@aszeli
Copy link

aszeli commented May 17, 2021

@starchivore worked, thank you!

@spaksa
Copy link

spaksa commented May 19, 2021

Oracle needs to get rid of that sign in.........................

@nikpatil18
Copy link

Good one saved the day

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment