Class ConsoleCallbackHandler

  • All Implemented Interfaces:
    javax.security.auth.callback.CallbackHandler

    public class ConsoleCallbackHandler
    extends java.lang.Object
    implements javax.security.auth.callback.CallbackHandler
    This CallbackHandler reads input from the console. The following callback can be handled:
    • NameCallback
    • PasswordCallback
    • TextInputCallback
    • TextOutputCallback
    It uses the native library juti to turn of echoing.
    See Also:
    SGEUtil.getPassword(java.lang.String)
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void handle​(javax.security.auth.callback.Callback[] callbacks)
      Handle callbacks
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ConsoleCallbackHandler

        public ConsoleCallbackHandler()
    • Method Detail

      • handle

        public void handle​(javax.security.auth.callback.Callback[] callbacks)
                    throws java.io.IOException,
                           javax.security.auth.callback.UnsupportedCallbackException
        Handle callbacks
        Specified by:
        handle in interface javax.security.auth.callback.CallbackHandler
        Parameters:
        callbacks - array of callbacks
        Throws:
        java.io.IOException - on an IO error
        javax.security.auth.callback.UnsupportedCallbackException - if a callback is not supported