Home / Function/ decrypt() — netty Function Reference

decrypt() — netty Function Reference

Architecture documentation for the decrypt() function in OpenSslPrivateKeyMethodTest.java from the netty codebase.

Function java Buffer Allocators calls 1 called by 2

Entity Profile

Dependency Diagram

graph TD
  64891399_7257_b41d_2d83_0a7379197ce0["decrypt()"]
  b64a66d0_62e7_ce9c_e091_5e0a556ec80a["OpenSslPrivateKeyMethodAdapter"]
  64891399_7257_b41d_2d83_0a7379197ce0 -->|defined in| b64a66d0_62e7_ce9c_e091_5e0a556ec80a
  90ad078f_18cd_88ab_2be6_3ed8d8a318ea["testPrivateKeyMethod()"]
  90ad078f_18cd_88ab_2be6_3ed8d8a318ea -->|calls| 64891399_7257_b41d_2d83_0a7379197ce0
  b15a5bb7_43a2_d1ed_9d3b_43d37b8d6f4b["testPrivateKeyMethodFails()"]
  b15a5bb7_43a2_d1ed_9d3b_43d37b8d6f4b -->|calls| 64891399_7257_b41d_2d83_0a7379197ce0
  03ee458c_000c_e7e6_4f78_d0c6d04acb35["DelegateThread()"]
  64891399_7257_b41d_2d83_0a7379197ce0 -->|calls| 03ee458c_000c_e7e6_4f78_d0c6d04acb35
  style 64891399_7257_b41d_2d83_0a7379197ce0 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

handler/src/test/java/io/netty/handler/ssl/OpenSslPrivateKeyMethodTest.java lines 455–481

        @Override
        public Future<byte[]> decrypt(final SSLEngine engine, final byte[] input) {
            final Promise<byte[]> promise = ImmediateEventExecutor.INSTANCE.newPromise();
            try {
                if (newThread) {
                    // Let's run these in an extra thread to ensure that this would also work if the promise is
                    // notified later.
                    new DelegateThread(new Runnable() {
                        @Override
                        public void run() {
                            try {
                                // Let's sleep for some time to ensure we would notify in an async fashion
                                Thread.sleep(ThreadLocalRandom.current().nextLong(100, 500));
                                promise.setSuccess(keyMethod.decrypt(engine, input));
                            } catch (Throwable cause) {
                                promise.setFailure(cause);
                            }
                        }
                    }).start();
                } else {
                    promise.setSuccess(keyMethod.decrypt(engine, input));
                }
            } catch (Throwable cause) {
                promise.setFailure(cause);
            }
            return promise;
        }

Domain

Subdomains

Frequently Asked Questions

What does decrypt() do?
decrypt() is a function in the netty codebase, defined in handler/src/test/java/io/netty/handler/ssl/OpenSslPrivateKeyMethodTest.java.
Where is decrypt() defined?
decrypt() is defined in handler/src/test/java/io/netty/handler/ssl/OpenSslPrivateKeyMethodTest.java at line 455.
What does decrypt() call?
decrypt() calls 1 function(s): DelegateThread.
What calls decrypt()?
decrypt() is called by 2 function(s): testPrivateKeyMethod, testPrivateKeyMethodFails.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free