public abstract class io.netty.handler.ssl.AbstractSniHandler extends io.netty.handler.ssl.SslClientHelloHandler
{
protected final long handshakeTimeoutMillis;
private io.netty.util.concurrent.ScheduledFuture timeoutFuture;
private java.lang.String hostname;
private static java.lang.String extractSniHostname(io.netty.buffer.ByteBuf)
{
java.util.Locale v;
short v, v, v;
io.netty.buffer.ByteBuf v;
java.nio.charset.Charset v;
int v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v;
java.lang.String v, v;
v := @parameter: io.netty.buffer.ByteBuf;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: int readerIndex()>();
v = virtualinvoke v.<io.netty.buffer.ByteBuf: int writerIndex()>();
v = v + 34;
v = v - v;
if v < 6 goto label;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: short getUnsignedByte(int)>(v);
v = v + 1;
v = v + v;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: int getUnsignedShort(int)>(v);
v = v + 2;
v = v + v;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: short getUnsignedByte(int)>(v);
v = v + 1;
v = v + v;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: int getUnsignedShort(int)>(v);
v = v + 2;
v = v + v;
if v > v goto label;
label:
v = v - v;
if v < 4 goto label;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: int getUnsignedShort(int)>(v);
v = v + 2;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: int getUnsignedShort(int)>(v);
v = v + 2;
v = v - v;
if v < v goto label;
if v != 0 goto label;
v = v + 2;
v = v - v;
if v < 3 goto label;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: short getUnsignedByte(int)>(v);
v = v + 1;
if v != 0 goto label;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: int getUnsignedShort(int)>(v);
v = v + 2;
v = v - v;
if v < v goto label;
v = <io.netty.util.CharsetUtil: java.nio.charset.Charset US_ASCII>;
v = virtualinvoke v.<io.netty.buffer.ByteBuf: java.lang.String toString(int,int,java.nio.charset.Charset)>(v, v, v);
v = <java.util.Locale: java.util.Locale US>;
v = virtualinvoke v.<java.lang.String: java.lang.String toLowerCase(java.util.Locale)>(v);
return v;
label:
v = v + v;
goto label;
label:
return null;
}
protected void <init>(long)
{
io.netty.handler.ssl.AbstractSniHandler v;
long v, v;
v := @this: io.netty.handler.ssl.AbstractSniHandler;
v := @parameter: long;
specialinvoke v.<io.netty.handler.ssl.SslClientHelloHandler: void <init>()>();
v = staticinvoke <io.netty.util.internal.ObjectUtil: long checkPositiveOrZero(long,java.lang.String)>(v, "handshakeTimeoutMillis");
v.<io.netty.handler.ssl.AbstractSniHandler: long handshakeTimeoutMillis> = v;
return;
}
public void <init>()
{
io.netty.handler.ssl.AbstractSniHandler v;
v := @this: io.netty.handler.ssl.AbstractSniHandler;
specialinvoke v.<io.netty.handler.ssl.AbstractSniHandler: void <init>(long)>(0L);
return;
}
public void handlerAdded(io.netty.channel.ChannelHandlerContext) throws java.lang.Exception
{
io.netty.channel.Channel v;
io.netty.channel.ChannelHandlerContext v;
io.netty.handler.ssl.AbstractSniHandler v;
boolean v;
v := @this: io.netty.handler.ssl.AbstractSniHandler;
v := @parameter: io.netty.channel.ChannelHandlerContext;
v = interfaceinvoke v.<io.netty.channel.ChannelHandlerContext: io.netty.channel.Channel channel()>();
v = interfaceinvoke v.<io.netty.channel.Channel: boolean isActive()>();
if v == 0 goto label;
specialinvoke v.<io.netty.handler.ssl.AbstractSniHandler: void checkStartTimeout(io.netty.channel.ChannelHandlerContext)>(v);
label:
return;
}
public void channelActive(io.netty.channel.ChannelHandlerContext) throws java.lang.Exception
{
io.netty.channel.ChannelHandlerContext v;
io.netty.handler.ssl.AbstractSniHandler v;
v := @this: io.netty.handler.ssl.AbstractSniHandler;
v := @parameter: io.netty.channel.ChannelHandlerContext;
interfaceinvoke v.<io.netty.channel.ChannelHandlerContext: io.netty.channel.ChannelHandlerContext fireChannelActive()>();
specialinvoke v.<io.netty.handler.ssl.AbstractSniHandler: void checkStartTimeout(io.netty.channel.ChannelHandlerContext)>(v);
return;
}
private void checkStartTimeout(io.netty.channel.ChannelHandlerContext)
{
io.netty.util.concurrent.EventExecutor v;
io.netty.handler.ssl.AbstractSniHandler v;
io.netty.util.concurrent.ScheduledFuture v, v;
long v, v;
java.util.concurrent.TimeUnit v;
io.netty.channel.ChannelHandlerContext v;
byte v;
io.netty.handler.ssl.AbstractSniHandler$1 v;
v := @this: io.netty.handler.ssl.AbstractSniHandler;
v := @parameter: io.netty.channel.ChannelHandlerContext;
v = v.<io.netty.handler.ssl.AbstractSniHandler: long handshakeTimeoutMillis>;
v = v cmp 0L;
if v <= 0 goto label;
v = v.<io.netty.handler.ssl.AbstractSniHandler: io.netty.util.concurrent.ScheduledFuture timeoutFuture>;
if v == null goto label;
label:
return;
label:
v = interfaceinvoke v.<io.netty.channel.ChannelHandlerContext: io.netty.util.concurrent.EventExecutor executor()>();
v = new io.netty.handler.ssl.AbstractSniHandler$1;
specialinvoke v.<io.netty.handler.ssl.AbstractSniHandler$1: void <init>(io.netty.handler.ssl.AbstractSniHandler,io.netty.channel.ChannelHandlerContext)>(v, v);
v = v.<io.netty.handler.ssl.AbstractSniHandler: long handshakeTimeoutMillis>;
v = <java.util.concurrent.TimeUnit: java.util.concurrent.TimeUnit MILLISECONDS>;
v = interfaceinvoke v.<io.netty.util.concurrent.EventExecutor: io.netty.util.concurrent.ScheduledFuture schedule(java.lang.Runnable,long,java.util.concurrent.TimeUnit)>(v, v, v);
v.<io.netty.handler.ssl.AbstractSniHandler: io.netty.util.concurrent.ScheduledFuture timeoutFuture> = v;
return;
}
protected io.netty.util.concurrent.Future lookup(io.netty.channel.ChannelHandlerContext, io.netty.buffer.ByteBuf) throws java.lang.Exception
{
io.netty.channel.ChannelHandlerContext v;
io.netty.handler.ssl.AbstractSniHandler v;
io.netty.buffer.ByteBuf v;
java.lang.String v, v;
io.netty.util.concurrent.Future v;
v := @this: io.netty.handler.ssl.AbstractSniHandler;
v := @parameter: io.netty.channel.ChannelHandlerContext;
v := @parameter: io.netty.buffer.ByteBuf;
if v != null goto label;
v = null;
goto label;
label:
v = staticinvoke <io.netty.handler.ssl.AbstractSniHandler: java.lang.String extractSniHostname(io.netty.buffer.ByteBuf)>(v);
label:
v.<io.netty.handler.ssl.AbstractSniHandler: java.lang.String hostname> = v;
v = v.<io.netty.handler.ssl.AbstractSniHandler: java.lang.String hostname>;
v = virtualinvoke v.<io.netty.handler.ssl.AbstractSniHandler: io.netty.util.concurrent.Future lookup(io.netty.channel.ChannelHandlerContext,java.lang.String)>(v, v);
return v;
}
protected void onLookupComplete(io.netty.channel.ChannelHandlerContext, io.netty.util.concurrent.Future) throws java.lang.Exception
{
java.lang.Throwable v;
io.netty.handler.ssl.AbstractSniHandler v;
io.netty.util.concurrent.ScheduledFuture v, v;
io.netty.channel.ChannelHandlerContext v;
java.lang.String v, v, v;
io.netty.util.concurrent.Future v;
v := @this: io.netty.handler.ssl.AbstractSniHandler;
v := @parameter: io.netty.channel.ChannelHandlerContext;
v := @parameter: io.netty.util.concurrent.Future;
v = v.<io.netty.handler.ssl.AbstractSniHandler: io.netty.util.concurrent.ScheduledFuture timeoutFuture>;
if v == null goto label;
v = v.<io.netty.handler.ssl.AbstractSniHandler: io.netty.util.concurrent.ScheduledFuture timeoutFuture>;
interfaceinvoke v.<io.netty.util.concurrent.ScheduledFuture: boolean cancel(boolean)>(0);
label:
v = v.<io.netty.handler.ssl.AbstractSniHandler: java.lang.String hostname>;
virtualinvoke v.<io.netty.handler.ssl.AbstractSniHandler: void onLookupComplete(io.netty.channel.ChannelHandlerContext,java.lang.String,io.netty.util.concurrent.Future)>(v, v, v);
label:
v = v.<io.netty.handler.ssl.AbstractSniHandler: java.lang.String hostname>;
staticinvoke <io.netty.handler.ssl.AbstractSniHandler: void fireSniCompletionEvent(io.netty.channel.ChannelHandlerContext,java.lang.String,io.netty.util.concurrent.Future)>(v, v, v);
goto label;
label:
v := @caughtexception;
v = v.<io.netty.handler.ssl.AbstractSniHandler: java.lang.String hostname>;
staticinvoke <io.netty.handler.ssl.AbstractSniHandler: void fireSniCompletionEvent(io.netty.channel.ChannelHandlerContext,java.lang.String,io.netty.util.concurrent.Future)>(v, v, v);
throw v;
label:
return;
catch java.lang.Throwable from label to label with label;
}
protected abstract io.netty.util.concurrent.Future lookup(io.netty.channel.ChannelHandlerContext, java.lang.String) throws java.lang.Exception;
protected abstract void onLookupComplete(io.netty.channel.ChannelHandlerContext, java.lang.String, io.netty.util.concurrent.Future) throws java.lang.Exception;
private static void fireSniCompletionEvent(io.netty.channel.ChannelHandlerContext, java.lang.String, io.netty.util.concurrent.Future)
{
java.lang.Throwable v;
io.netty.channel.ChannelHandlerContext v;
io.netty.handler.ssl.SniCompletionEvent v, v;
java.lang.String v;
io.netty.util.concurrent.Future v;
v := @parameter: io.netty.channel.ChannelHandlerContext;
v := @parameter: java.lang.String;
v := @parameter: io.netty.util.concurrent.Future;
v = interfaceinvoke v.<io.netty.util.concurrent.Future: java.lang.Throwable cause()>();
if v != null goto label;
v = new io.netty.handler.ssl.SniCompletionEvent;
specialinvoke v.<io.netty.handler.ssl.SniCompletionEvent: void <init>(java.lang.String)>(v);
interfaceinvoke v.<io.netty.channel.ChannelHandlerContext: io.netty.channel.ChannelHandlerContext fireUserEventTriggered(java.lang.Object)>(v);
goto label;
label:
v = new io.netty.handler.ssl.SniCompletionEvent;
specialinvoke v.<io.netty.handler.ssl.SniCompletionEvent: void <init>(java.lang.String,java.lang.Throwable)>(v, v);
interfaceinvoke v.<io.netty.channel.ChannelHandlerContext: io.netty.channel.ChannelHandlerContext fireUserEventTriggered(java.lang.Object)>(v);
label:
return;
}
}