{"action":"created","issue":{"url":"https://api.github.com/repos/jruby/jruby/issues/2992","repository_url":"https://api.github.com/repos/jruby/jruby","labels_url":"https://api.github.com/repos/jruby/jruby/issues/2992/labels{/name}","comments_url":"https://api.github.com/repos/jruby/jruby/issues/2992/comments","events_url":"https://api.github.com/repos/jruby/jruby/issues/2992/events","html_url":"https://github.com/jruby/jruby/issues/2992","id":81147867,"number":2992,"title":"SSLSocket can't be created from UNIXSocket","user":{"login":"ojab","id":153388,"avatar_url":"https://avatars.githubusercontent.com/u/153388?v=3","gravatar_id":"","url":"https://api.github.com/users/ojab","html_url":"https://github.com/ojab","followers_url":"https://api.github.com/users/ojab/followers","following_url":"https://api.github.com/users/ojab/following{/other_user}","gists_url":"https://api.github.com/users/ojab/gists{/gist_id}","starred_url":"https://api.github.com/users/ojab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ojab/subscriptions","organizations_url":"https://api.github.com/users/ojab/orgs","repos_url":"https://api.github.com/users/ojab/repos","events_url":"https://api.github.com/users/ojab/events{/privacy}","received_events_url":"https://api.github.com/users/ojab/received_events","type":"User","site_admin":false},"labels":[{"id":16326808,"url":"https://api.github.com/repos/jruby/jruby/labels/openssl","name":"openssl","color":"e102d8","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/jruby/jruby/milestones/11","html_url":"https://github.com/jruby/jruby/milestones/Invalid%20or%20Duplicate","labels_url":"https://api.github.com/repos/jruby/jruby/milestones/11/labels","id":350035,"number":11,"title":"Invalid or Duplicate","description":"Bugs that are duplicates, not actually bugs, or user mistakes should go here.","creator":{"login":"headius","id":10135,"avatar_url":"https://avatars.githubusercontent.com/u/10135?v=3","gravatar_id":"","url":"https://api.github.com/users/headius","html_url":"https://github.com/headius","followers_url":"https://api.github.com/users/headius/followers","following_url":"https://api.github.com/users/headius/following{/other_user}","gists_url":"https://api.github.com/users/headius/gists{/gist_id}","starred_url":"https://api.github.com/users/headius/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/headius/subscriptions","organizations_url":"https://api.github.com/users/headius/orgs","repos_url":"https://api.github.com/users/headius/repos","events_url":"https://api.github.com/users/headius/events{/privacy}","received_events_url":"https://api.github.com/users/headius/received_events","type":"User","site_admin":false},"open_issues":3,"closed_issues":506,"state":"open","created_at":"2013-06-06T19:52:53Z","updated_at":"2016-11-18T05:29:31Z","due_on":null,"closed_at":null},"comments":5,"created_at":"2015-05-26T21:40:21Z","updated_at":"2016-12-02T17:40:43Z","closed_at":"2015-06-02T19:53:06Z","body":"Testcase:\n\n``` ruby\nrequire 'socket'\nrequire 'openssl'\n\nfrom, to = UNIXSocket.pair\nssl_to = OpenSSL::SSL::SSLSocket.new(to)\nssl_to.write('foo')\n```\n\nfails with\n\n```\nSSLSocket.java:858:in `getSocketChannel': java.lang.ClassCastException: jnr.unixsocket.UnixSocketChannel cannot be cast to java.nio.channels.SocketChannel\n    from SSLSocket.java:726:in `checkClosed'\n    from SSLSocket.java:687:in `do_syswrite'\n    from SSLSocket.java:711:in `syswrite'\n    from SSLSocket$INVOKER$i$1$0$syswrite.gen:-1:in `call'\n    from CachingCallSite.java:313:in `cacheAndCall'\n    from CachingCallSite.java:163:in `call'\n    from InterpreterEngine.java:292:in `processCall'\n    from StartupInterpreterEngine.java:78:in `interpret'\n    from InterpreterEngine.java:84:in `interpret'\n    from MixedModeIRMethod.java:199:in `INTERPRET_METHOD'\n    from MixedModeIRMethod.java:185:in `call'\n    from DynamicMethod.java:205:in `call'\n    from CachingCallSite.java:313:in `cacheAndCall'\n    from CachingCallSite.java:163:in `call'\n    from InterpreterEngine.java:292:in `processCall'\n    from StartupInterpreterEngine.java:78:in `interpret'\n    from InterpreterEngine.java:84:in `interpret'\n    from MixedModeIRMethod.java:199:in `INTERPRET_METHOD'\n    from MixedModeIRMethod.java:185:in `call'\n    from DynamicMethod.java:205:in `call'\n    from CachingCallSite.java:313:in `cacheAndCall'\n    from CachingCallSite.java:163:in `call'\n    from /tmp/socket.rb:-1:in `invokeOther9:write'\n    from /tmp/socket.rb:6:in `RUBY$script'\n    from MethodHandle.java:625:in `invokeWithArguments'\n    from Compiler.java:111:in `load'\n    from Ruby.java:833:in `runScript'\n    from Ruby.java:822:in `runScript'\n    from Ruby.java:752:in `runNormally'\n    from Ruby.java:574:in `runFromMain'\n    from Main.java:401:in `doRunFromMain'\n    from Main.java:296:in `internalRun'\n    from Main.java:225:in `run'\n    from Main.java:197:in `main'\n```\n\non JRuby `jruby 9.0.0.0-SNAPSHOT (2.2.2) 2015-05-26 78b009c Java HotSpot(TM) 64-Bit Server VM 25.45-b02 on 1.8.0_45-b14 +jit [darwin-x86_64]`, no error on MRI (tested with 1.9 & 2.2).\n"},"comment":{"url":"https://api.github.com/repos/jruby/jruby/issues/comments/264514356","html_url":"https://github.com/jruby/jruby/issues/2992#issuecomment-264514356","issue_url":"https://api.github.com/repos/jruby/jruby/issues/2992","id":264514356,"user":{"login":"andrew-aladev","id":941925,"avatar_url":"https://avatars.githubusercontent.com/u/941925?v=3","gravatar_id":"","url":"https://api.github.com/users/andrew-aladev","html_url":"https://github.com/andrew-aladev","followers_url":"https://api.github.com/users/andrew-aladev/followers","following_url":"https://api.github.com/users/andrew-aladev/following{/other_user}","gists_url":"https://api.github.com/users/andrew-aladev/gists{/gist_id}","starred_url":"https://api.github.com/users/andrew-aladev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andrew-aladev/subscriptions","organizations_url":"https://api.github.com/users/andrew-aladev/orgs","repos_url":"https://api.github.com/users/andrew-aladev/repos","events_url":"https://api.github.com/users/andrew-aladev/events{/privacy}","received_events_url":"https://api.github.com/users/andrew-aladev/received_events","type":"User","site_admin":false},"created_at":"2016-12-02T17:40:42Z","updated_at":"2016-12-02T17:40:42Z","body":"@ojab What is a unix socket? This is the most reliable and fast connection with some application. You can connect to this application and it will create an insecure tunnel to another application. You want to make this tunnel secure, you are going to use `SSLSocket` and you failed with `unknow channel impl: jnr.unixsocket.UnixSocketChannel`. Does this sound reasonable?"}}
{"actor":{"display_login":"andrew-aladev"}}