Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add custom sslcontext support in fili #943

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

Chandrasekar-Rajasekar
Copy link
Collaborator

@Chandrasekar-Rajasekar Chandrasekar-Rajasekar commented Jul 25, 2019

User must override getSSLContext method to give their own sslContext. The function should return the object of io.netty.handler.ssl.SslContext.

protected SslContext getSSLContext() {
        //create SSL Context here
       if(sslContext.instanceOf(io.netty.handler.ssl.SslContext.class)) 
              return sslContext;
       if(sslContext.instanceOf(javax.net.ssl.SSLContext.class))
              return new JdkSslContext(sslContext, true, ClientAuth.REQUIRE)
      .
      .
      .
      return null
}

I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.

@michael-mclawhorn
Copy link
Contributor

definitely need a change to CHANGELOG, and you should probably create an issue to link to in the changelog ticket.

Should also add a test to config that this code gets excercised.

@@ -1208,6 +1209,14 @@ protected GranularityDictionary getGranularityDictionary() {
return new HashMap<>(0);
}

/**
* Get a custom configured ssl context.
* @return SSL context
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add to comment:

If null, the system default SSL Context will be applied

Copy link
Contributor

@michael-mclawhorn michael-mclawhorn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had one small documentation change. Otherwise feel free to update in preparation for merging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants