Skip to content

Commit 77edfdd

Browse files
committed
SSLContext#security_level= already in native -> make it not raise
1 parent d5215aa commit 77edfdd

2 files changed

Lines changed: 5 additions & 8 deletions

File tree

lib/jopenssl24.rb

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,6 @@
44

55
module OpenSSL
66

7-
module SSL
8-
class SSLContext
9-
# OpenSSL 1.1.0 introduced "security level"
10-
def security_level; 0 end
11-
def security_level=(level); raise NotImplementedError end
12-
end
13-
end
14-
157
module PKey
168

179
class DH

src/main/java/org/jruby/ext/openssl/SSLContext.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -567,6 +567,11 @@ public RubyHash session_cache_stats(final ThreadContext context) {
567567
return RubyHash.newHash(context.runtime);
568568
}
569569

570+
@JRubyMethod(name = "security_level")
571+
public IRubyObject security_level(ThreadContext context) {
572+
return context.runtime.newFixnum(0);
573+
}
574+
570575
@JRubyMethod(name = "security_level=")
571576
public IRubyObject set_security_level(ThreadContext context, IRubyObject level) {
572577
warn(context, "WARNING: SSLContext#security_level= has no effect under JRuby");

0 commit comments

Comments
 (0)