Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Encryption of the HTTP protocol (e.g. not its payload)

Simone,

Just following up my initial question, how does one upgrade an Endpoint from within a Servlet? In my setup the encryption keys that are required to upgrade to an encrypted connection are the result of an HttpServletRequest that got processed

I fail to see how to access the underlying data structures down to the HttpConnection and Endpoint in order to do that

Tx

> On 21 Dec 2019, at 11:36, Karel Goderis <karel.goderis@xxxxxx> wrote:
> 
> Hi Simone
> 
>> 
>> All right so what you need is a HttpConnection that upgrades to
>> HAPConnection, and HAPConnection should be setup similarly to
>> SslConnection, which delegates (after decryption) to another
>> connection that happens to be again a (different) HttpConnection.
>> Have a look at SslConnectionFactory as an example for how an
>> encryption/decryption ConnectionFactory would work.
>> 
> 
> Just a question, why do you prefer this approach above building a customised HttpConnection that does the encryption/decryption itself? I already have a custmised HhttpConnection in place to deal with Apple modifying the HTTP Verb for Event handling. I would mean that I have to adapt OnFillable() to deal with decryption, and modify SendCallback to deal with encryption (e.g. the FLUSH case branch). And then in the application layer, whenever I derive the encryption keys, do an Endpoint.upgrade() to this customised class, and I would not have to deal with al the buffer dynamics of Endpoint itself
> 
> Thanks
> Karel



Back to the top