Skip to content

Support mTLSΒ #100

@rrhett

Description

@rrhett

πŸ”– Enhancement description

I would like to be able to specify an SSL Socket Factory on the OkHttpClient.Builder when I'm creating a Client so that I can support mutual TLS for a self-hosted instance that's behind a proxy.

Essentially, add a method like:

fun sslSocketFactory(
    sslSocketFactory: SSLSocketFactory,
    trustManager: X509TrustManager
): Client {
    http = http.newBuilder().sslSocketFactory(sslSocketFactory, trustManager).build()
    return this
}

🎀 Pitch

For self-hosted instances, there are a variety of common practices to increase security by reducing the exposure to the public internet. Two common practices are using a VPN and using mutual TLS behind a proxy. This lets apps guard access to the server by client certificates which can be issued and revoked individually, improving security to access the instance.

πŸ‘€ Have you spent some time to check if this issue has been raised before?

  • I checked and didn't find similar issue

🏒 Have you read the Code of Conduct?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions