diff options
author | Simon Frankenberger <simon@fraho.eu> | 2019-01-28 22:01:51 +0100 |
---|---|---|
committer | Kevin Daudt <kdaudt@alpinelinux.org> | 2019-05-11 16:18:53 +0000 |
commit | 60fc00ff4cf84bb74c7ef84672c294f61aef1ab0 (patch) | |
tree | a8459565ef505b665a26b731b63de503208ada38 /testing/openjdk10/Alpine_Bug_10126.java | |
parent | aa586529deda3d628c67cf76854522aa8d81eeab (diff) | |
download | aports-60fc00ff4cf84bb74c7ef84672c294f61aef1ab0.tar.bz2 aports-60fc00ff4cf84bb74c7ef84672c294f61aef1ab0.tar.xz |
testing/openjdk10: New aport
Diffstat (limited to 'testing/openjdk10/Alpine_Bug_10126.java')
-rw-r--r-- | testing/openjdk10/Alpine_Bug_10126.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/testing/openjdk10/Alpine_Bug_10126.java b/testing/openjdk10/Alpine_Bug_10126.java new file mode 100644 index 0000000000..57746f3b95 --- /dev/null +++ b/testing/openjdk10/Alpine_Bug_10126.java @@ -0,0 +1,13 @@ +public class Alpine_Bug_10126 { + public static void main(String[] args) throws Exception { + try (java.net.Socket sock = javax.net.ssl.SSLSocketFactory.getDefault().createSocket("bugs.alpinelinux.org", 443); + java.io.InputStream in = sock.getInputStream(); + java.io.OutputStream out = sock.getOutputStream()) { + out.write("GET / HTTP/1.0\n\nHost: bugs.alpinelinux.org\n\nConnection: close\n\n\n\n".getBytes()); + out.flush(); + while (in.read(new byte[1024]) != -1) ; + } + System.out.println("Secured connection performed successfully"); + } +} + |