Class XrootdAuthenticationHandler

  • All Implemented Interfaces:
    io.netty.channel.ChannelHandler, io.netty.channel.ChannelInboundHandler

    public class XrootdAuthenticationHandler
    extends XrootdRequestHandler
    Netty handler implementing Xrootd kXR_auth.

    Delegates the authentication steps to an AuthenticationHandler. Rejects all other messages until login has completed.

    Note the difference between this class and AuthenticationHandler. The latter is part of a plugin implementing the core authentication logic whereas this class is a Netty handler.

    The class may be subclassed to override the authenticated method to add additional operations after authentication.

    • Method Detail

      • getProtocol

        public java.lang.String getProtocol()
      • handlerRemoved

        public void handlerRemoved​(io.netty.channel.ChannelHandlerContext ctx)
        Specified by:
        handlerRemoved in interface io.netty.channel.ChannelHandler
        Overrides:
        handlerRemoved in class io.netty.channel.ChannelHandlerAdapter
      • login

        protected javax.security.auth.Subject login​(io.netty.channel.ChannelHandlerContext context,
                                                    javax.security.auth.Subject subject)
                                             throws XrootdException
        Called at the end of successful login/authentication.

        Subclasses may override this method to add additional processing and internal mapping of the Subject.

        If the subclass throws XrootdException then the login is aborted.

        Parameters:
        context - the Netty context
        subject - the subject that logged in
        Throws:
        XrootdException